> ## Documentation Index
> Fetch the complete documentation index at: https://docs.requesty.ai/llms.txt
> Use this file to discover all available pages before exploring further.

# List Models

> Get all available models. If authenticated with a Requesty API key, returns only approved models for your organization. Otherwise, returns all public models.

<RequestExample>
  ```bash cURL theme={"dark"}
  curl https://router.requesty.ai/v1/models \
    -H "Authorization: Bearer YOUR_REQUESTY_API_KEY"
  ```

  ```python Python theme={"dark"}
  from openai import OpenAI

  client = OpenAI(
      api_key="YOUR_REQUESTY_API_KEY",
      base_url="https://router.requesty.ai/v1",
  )

  models = client.models.list()

  for model in models.data:
      print(model.id)
  ```

  ```typescript TypeScript theme={"dark"}
  import OpenAI from "openai";

  const client = new OpenAI({
    apiKey: process.env.REQUESTY_API_KEY,
    baseURL: "https://router.requesty.ai/v1",
  });

  const models = await client.models.list();

  for (const model of models.data) {
    console.log(model.id);
  }
  ```
</RequestExample>

<ResponseExample>
  ```json Response 200 theme={"dark"}
  {
    "object": "list",
    "data": [
      {
        "id": "openai/gpt-4o",
        "object": "model",
        "created": 1715367049,
        "owned_by": "openai"
      },
      {
        "id": "anthropic/claude-sonnet-4-20250514",
        "object": "model",
        "created": 1715367049,
        "owned_by": "anthropic"
      },
      {
        "id": "google/gemini-2.5-pro",
        "object": "model",
        "created": 1715367049,
        "owned_by": "google"
      }
    ]
  }
  ```
</ResponseExample>

List all models available through Requesty's routing. When authenticated with an API key, returns only the models approved for your organization. Without authentication, returns all publicly available models.

Browse the full catalog interactively on the [Model Library](https://app.requesty.ai/model-list).


## OpenAPI

````yaml GET /v1/models
openapi: 3.0.3
info:
  title: Requesty API
  description: Requesty API for AI model routing and key management
  version: 1.0.0
servers:
  - url: https://api-v2.requesty.ai
    description: Management API endpoint
  - url: https://router.requesty.ai
    description: Inference router endpoint
security:
  - BearerAuth: []
paths:
  /v1/models:
    servers:
      - url: https://router.requesty.ai
        description: Inference router endpoint
    get:
      summary: List available models
      description: >-
        Get all available models. If authenticated with a Requesty API key,
        returns only approved models for your organization. Otherwise, returns
        all public models.
      operationId: listModels
      responses:
        '200':
          description: List of available models
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ModelsResponse'
              example:
                object: list
                data:
                  - id: openai/gpt-4o
                    object: model
                    created: 1715367049
                    owned_by: openai
                  - id: anthropic/claude-sonnet-4-20250514
                    object: model
                    created: 1715367049
                    owned_by: anthropic
                  - id: google/gemini-2.5-pro
                    object: model
                    created: 1715367049
                    owned_by: google
        '400':
          description: Bad request - malformed payload or invalid parameters.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '401':
          description: Unauthorized - missing or empty Authorization header.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '402':
          description: Payment required - organization balance exhausted.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '403':
          description: Forbidden - invalid token or model not in access list.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '404':
          description: Not found - provider/model not supported.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '429':
          description: Rate limit exceeded. Retry after the Retry-After header value.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '500':
          description: Internal server error.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
        '502':
          description: Bad gateway - upstream provider returned an invalid response.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ErrorResponse'
      security:
        - BearerAuth: []
        - {}
components:
  schemas:
    ModelsResponse:
      type: object
      required:
        - object
        - data
      properties:
        object:
          type: string
          enum:
            - list
          description: The object type, always 'list'
        data:
          type: array
          items:
            $ref: '#/components/schemas/Model'
          description: The list of available models
    ErrorResponse:
      type: object
      required:
        - error
      properties:
        error:
          type: object
          required:
            - origin
            - message
          properties:
            origin:
              type: string
              enum:
                - router
                - provider
              description: >-
                Whether the error originated from Requesty's router or an
                upstream provider.
            message:
              type: string
              description: Human-readable error description.
    Model:
      type: object
      properties:
        id:
          type: string
          description: The model identifier (e.g., 'openai/gpt-5-mini')
        object:
          type: string
          enum:
            - model
          description: The object type, always 'model'
        created:
          type: integer
          description: The Unix timestamp (in seconds) when the model was created
        owned_by:
          type: string
          description: The system or organization that owns the model
          example: system
        input_price:
          type: number
          format: float
          description: Price per input token in USD
        caching_price:
          type: number
          format: float
          description: Price per token for caching in USD
        cached_price:
          type: number
          format: float
          description: Price per cached token in USD
        output_price:
          type: number
          format: float
          description: Price per output token in USD
        max_output_tokens:
          type: integer
          description: Maximum number of output tokens the model can generate
        context_window:
          type: integer
          description: Maximum context window size in tokens
        supports_caching:
          type: boolean
          description: Whether the model supports caching
        supports_vision:
          type: boolean
          description: Whether the model supports vision/image inputs
        supports_computer_use:
          type: boolean
          description: Whether the model supports computer use capabilities
        supports_reasoning:
          type: boolean
          description: Whether the model supports reasoning capabilities
        supports_web_search:
          type: boolean
          description: Whether the model supports web search via the `web_search` tool type
        supports_json_schema:
          type: boolean
          description: >-
            Whether the model supports strict structured outputs via
            `response_format` with `{ "type": "json_schema" }`
        description:
          type: string
          description: A description of the model's capabilities and use cases
        retires_at:
          type: string
          format: date-time
          description: >-
            When the model is scheduled to be retired, in ISO 8601 format. After
            this date, requests to the model fail. Null if no retirement is
            scheduled.
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      description: API key for authentication

````