---
updatedAt: 2025-09-02T07:17:19.000Z
agentTools:
  projectIndex: https://jamaibase.readme.io/llms.txt
---

# List the ID of models available.

Deprecated, use `/v1/models/ids` instead. List the ID of models available.

# OpenAPI definition

```json
{
  "openapi": "3.1.0",
  "info": {
    "title": "JamAI Base API",
    "license": {
      "name": "Apache 2.0",
      "url": "https://www.apache.org/licenses/LICENSE-2.0.html"
    },
    "version": "0.1.0",
    "x-logo": {
      "url": "https://www.jamaibase.com/favicon.svg"
    }
  },
  "servers": [
    {
      "url": "https://api.jamaibase.com"
    }
  ],
  "paths": {
    "/api/v1/model_names": {
      "get": {
        "tags": [
          "Serving"
        ],
        "summary": "List the ID of models available.",
        "description": "Deprecated, use `/v1/models/ids` instead. List the ID of models available.",
        "operationId": "model_ids_api_v1_model_names_get",
        "deprecated": true,
        "parameters": [
          {
            "name": "order_by",
            "in": "query",
            "required": false,
            "schema": {
              "enum": [
                "id",
                "name",
                "created_at",
                "updated_at"
              ],
              "type": "string",
              "description": "Sort by this attribute. Defaults to \"id\".",
              "default": "id",
              "title": "Order By"
            },
            "description": "Sort by this attribute. Defaults to \"id\"."
          },
          {
            "name": "order_ascending",
            "in": "query",
            "required": false,
            "schema": {
              "type": "boolean",
              "description": "Whether to sort in ascending order. Defaults to True.",
              "default": true,
              "title": "Order Ascending"
            },
            "description": "Whether to sort in ascending order. Defaults to True."
          },
          {
            "name": "capabilities",
            "in": "query",
            "required": false,
            "schema": {
              "anyOf": [
                {
                  "type": "array",
                  "items": {
                    "$ref": "#/components/schemas/ModelCapability"
                  }
                },
                {
                  "type": "null"
                }
              ],
              "description": "Filter the model info by model's capabilities. Defaults to None (no filter).",
              "examples": [
                [
                  "chat"
                ]
              ],
              "title": "Capabilities"
            },
            "description": "Filter the model info by model's capabilities. Defaults to None (no filter)."
          },
          {
            "name": "prefer",
            "in": "query",
            "required": false,
            "schema": {
              "type": "string",
              "description": "ID of the preferred model.",
              "examples": [
                "openai/gpt-4o-mini"
              ],
              "default": "",
              "title": "Prefer"
            },
            "description": "ID of the preferred model."
          },
          {
            "name": "Authorization",
            "in": "header",
            "required": true,
            "schema": {
              "type": "string",
              "description": "User PAT or service key.",
              "title": "Authorization"
            },
            "description": "User PAT or service key."
          },
          {
            "name": "X-USER-ID",
            "in": "header",
            "required": false,
            "schema": {
              "type": "string",
              "description": "User ID. Can be omitted if PAT is used as token.",
              "default": "",
              "title": "X-User-Id"
            },
            "description": "User ID. Can be omitted if PAT is used as token."
          },
          {
            "name": "X-PROJECT-ID",
            "in": "header",
            "required": false,
            "schema": {
              "type": "string",
              "description": "Project ID. Can be omitted if PAT is used as token.",
              "default": "",
              "title": "X-Project-Id"
            },
            "description": "Project ID. Can be omitted if PAT is used as token."
          }
        ],
        "responses": {
          "200": {
            "description": "Successful Response",
            "content": {
              "application/json": {
                "schema": {
                  "type": "array",
                  "items": {
                    "type": "string"
                  },
                  "title": "Response Model Ids Api V1 Model Names Get"
                }
              }
            }
          },
          "422": {
            "description": "Validation Error",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/HTTPValidationError"
                }
              }
            }
          }
        }
      }
    }
  },
  "components": {
    "schemas": {
      "HTTPValidationError": {
        "properties": {
          "detail": {
            "items": {
              "$ref": "#/components/schemas/ValidationError"
            },
            "type": "array",
            "title": "Detail"
          }
        },
        "type": "object",
        "title": "HTTPValidationError"
      },
      "ModelCapability": {
        "type": "string",
        "enum": [
          "completion",
          "chat",
          "tool",
          "image",
          "audio",
          "embed",
          "rerank",
          "reasoning"
        ],
        "title": "ModelCapability"
      },
      "ValidationError": {
        "properties": {
          "loc": {
            "items": {
              "anyOf": [
                {
                  "type": "string"
                },
                {
                  "type": "integer"
                }
              ]
            },
            "type": "array",
            "title": "Location"
          },
          "msg": {
            "type": "string",
            "title": "Message"
          },
          "type": {
            "type": "string",
            "title": "Error Type"
          }
        },
        "type": "object",
        "required": [
          "loc",
          "msg",
          "type"
        ],
        "title": "ValidationError"
      }
    },
    "securitySchemes": {
      "Authentication": {
        "type": "http",
        "scheme": "bearer"
      }
    }
  },
  "security": [
    {
      "Authentication": []
    }
  ]
}
```