Change the base URL toDocumentation Index
Fetch the complete documentation index at: https://apidoc.cometapi.com/llms.txt
Use this file to discover all available pages before exploring further.
https://api.cometapi.com/v1 when you use OpenAI-compatible SDKs or endpoints. Keep the endpoint path and request body format from the API reference, then use your CometAPI API key.
Use the correct base URL
The OpenAI-compatible base URL is:Python base URL
The following Python example changes only the client configuration:Node.js base URL
The following Node.js example sets the CometAPI base URL:Test the change
The following request verifies that the base URL and API key work:Common errors
| Error | Fix |
|---|---|
404 | Include /v1 in the base URL for OpenAI-compatible endpoints. |
| HTML instead of JSON | Check whether your HTTP client followed a redirect from a wrong path. |
401 | Use Authorization: Bearer $COMETAPI_KEY. |
| Management API auth mismatch | API key management endpoints use a personal access value, not bearer model-request auth. |