List models
List the models this API key may call.
GET
/v1/modelsAPI key authentication only — /v1/* routes always require an API key, even when a valid admin JWT is present.
Request
bash
curl http://localhost:8080/v1/models \
-H "Authorization: Bearer $LLM_PROXY_KEY"Request — OpenAI SDK
python
from openai import OpenAI
client = OpenAI(base_url="http://localhost:8080/v1", api_key="sk-your-proxy-key")
for model in client.models.list():
print(model.id)Response
json
{
"object": "list",
"data": [
{"id": "my-model", "provider": "openai-prod", "object": "model"},
{"id": "auto", "provider": "routing", "object": "model"}
]
}Response
provideris the highest-priority provider for that model.- The list is filtered by the API key's allowlist (
null= all,[]= nothing). auto,fast,bestappear with"provider": "routing"when smart routing is enabled.- No
created/owned_byfields and no pagination.
Related
- Virtual Models & Routing — the
auto/fast/bestvirtual models - Endpoint Index — every route, including
GET /v1/protocols
Request
bash
curl http://localhost:8080/v1/models \
-H "Authorization: Bearer $LLM_PROXY_KEY"Request — OpenAI SDK
python
from openai import OpenAI
client = OpenAI(base_url="http://localhost:8080/v1", api_key="sk-your-proxy-key")
for model in client.models.list():
print(model.id)Response
json
{
"object": "list",
"data": [
{"id": "my-model", "provider": "openai-prod", "object": "model"},
{"id": "auto", "provider": "routing", "object": "model"}
]
}