List models
GET /v1/models: list the models this API key can call and the endpoint types each supports. Not billed.
GET /v1/models returns the models this key can call, not every model on the platform. It includes only the enabled, priced models in the key's group (when the key has no group of its own, your account's group is used), and when the key has Model Limits, only the models on that list. The endpoint isn't billed, which makes it handy for checking model names in code or building a model picker. For every model and its price, see Model Square.
GET https://codaapi.com/v1/models
Request headers
| Name | Required | Description |
|---|---|---|
Authorization |
Yes | Bearer sk-…, your API key |
The same address also accepts the Anthropic and Gemini ways of authenticating and returns the list in the matching format (with the same models): with both the x-api-key and anthropic-version headers you get the Anthropic format, and with the x-goog-api-key header or the ?key= parameter you get the Gemini format.
Request body
There are no request parameters and no pagination; all models come back at once.
Request examples
curl
curl https://codaapi.com/v1/models \
-H "Authorization: Bearer $OPENAI_API_KEY"
Python (pip install openai)
from openai import OpenAI
client = OpenAI() # reads OPENAI_BASE_URL and OPENAI_API_KEY
for model in client.models.list():
print(model.id)
Node.js (npm install openai)
import OpenAI from 'openai';
const client = new OpenAI(); // reads OPENAI_BASE_URL and OPENAI_API_KEY
for await (const model of client.models.list()) {
console.log(model.id);
}
Response
{
"success": true,
"object": "list",
"data": [
{
"id": "gpt-5.4-mini",
"object": "model",
"created": 1626777600,
"owned_by": "openai",
"supported_endpoint_types": ["openai"]
},
{
"id": "text-embedding-3-small",
"object": "model",
"created": 1626777600,
"owned_by": "openai",
"supported_endpoint_types": ["openai"]
}
]
}
| Field | Description |
|---|---|
data[].id |
Model name; put it in model when calling |
data[].supported_endpoint_types |
Endpoint types the model supports: openai (Chat Completions), openai-response (Responses), anthropic (Claude Messages), gemini (Gemini generateContent), image-generation (image generation) and so on |
data[].owned_by |
The channel type that serves this model; for reference only |
data[].created |
A fixed value that doesn't reflect the model's release date |
success |
A field the gateway adds; the SDKs ignore it |
supported_endpoint_types is derived from the channel type and isn't always complete. For example, OpenAI models are marked only openai, but they work with Responses too; embedding and speech-to-text models are also marked openai, yet they're called through their own endpoints.
Retrieve a model
GET https://codaapi.com/v1/models/{model}
This endpoint looks names up in a list built into the gateway and ignores this key's group and Model Limits. A name on that list returns a model object (with supported_endpoint_types set to null); any other name returns a model_not_found error body, still with HTTP status 200. Not every name in Model Square is on that list. To find out whether you can use a model, use the list endpoint above.
Errors
If the key is invalid, disabled or expired, the response is 401 with an OpenAI-style error body, {"error": {"message": "…", "type": "…", "code": "…"}}. For common status codes and what to do about them, see Error codes.
Billing
Not billed, and not written to the usage logs.