List Models
OpenAI-Compatible Endpoints
List Models
Retrieve the list of available models
GET
List Models
Overview
The/v1/models endpoint returns a list of models available to your API key. The response is filtered based on your API key’s allowed_models configuration if present.
This endpoint is useful for:
- Discovering available models before making requests
- Checking model capabilities and metadata
- Validating model access for your API key
- Understanding model restrictions and features
Authentication
Bearer token for API authentication. Format:
Bearer YOUR_API_KEYResponse
Returns a list of model objects.Always
"list".Array of model objects. Each model object contains:
Model Object
Model identifier (slug). Use this value in the
model parameter for completions.Examples: "gpt-4.1", "gpt-5.2", "o3-pro"Always
"model".Unix timestamp when the model list was generated.
Owner identifier. Always
"codex-lb".Extended model metadata with capabilities and configuration.
Model Metadata
Human-readable model name.Example:
"GPT-4.1 Turbo", "O3 Pro"Model description explaining capabilities and use cases.
Maximum context window size in tokens.Example:
128000, 200000Supported input modalities.Possible values:
"text": Text input"image": Image input"audio": Audio input"video": Video input
Available reasoning effort levels for this model.Each level object contains:
effort(string): Effort level identifier (e.g.,"low","medium","high")description(string): Description of the reasoning level
Default reasoning effort level when not specified.Example:
"medium"Whether the model supports reasoning summaries.
Whether the model supports verbosity control.
Default verbosity level when not specified.Example:
"normal", "concise"Whether the model prefers WebSocket connections for streaming.
Whether the model supports calling multiple tools in parallel.
Whether the model is available via API endpoints.
Minimum client version required to use this model.Example:
"1.2.0"Model priority for selection and display ordering. Higher values indicate higher priority.
Examples
List All Available Models
Response Example
Model Filtering
API Key Restrictions
If your API key hasallowed_models configured, the response will only include those models:
API Key with restrictions:
allowed_models list will not appear in the response.
No Restrictions
If your API key has noallowed_models restrictions (or allowed_models is null/empty), all available models are returned.
Use Cases
Check Model Capabilities
Use the metadata to determine if a model supports the features you need:Dynamic Model Selection
Select the best model for your use case:Validate Model Access
Check if you have access to a specific model:Rate Limiting
The/v1/models endpoint is subject to the same rate limiting as other API endpoints. Each request counts toward your API key’s request quota.
Empty Response
If no models are available (e.g., model registry not yet loaded), the endpoint returns:Error Handling
Errors return OpenAI-compatible error envelopes:- 401 Unauthorized: Invalid or missing API key
- 403 Forbidden: API key lacks permission
- 429 Too Many Requests: Rate limit exceeded
- 500 Internal Server Error: Server error
Comparison with OpenAI
This endpoint follows the OpenAI/v1/models format with the following additions:
Standard OpenAI fields:
id,object,created,owned_by
metadataobject with comprehensive model capabilities- Model filtering based on API key restrictions
- Priority-based model ordering
- Detailed reasoning and verbosity support information