---
title: "List Models"
method: GET
path: "/v1/models"
tags: ["AI"]
---

# List Models

`GET /v1/models`

List all models, both machine learning and language models, available in the runtime.
When `status=true` and a model is in `Error`, the response also includes:
- `error`: structured code object with `category`, `type`, and stable `code`
- `error_message`: user-visible details

## Query parameters

- `format` 'json' | 'csv'
- `status` boolean
- `metadata_fields` string

## Response `200`

List of models in JSON format

- ModelListResponse — Response wrapper for the `/v1/models` endpoint (OpenAI-compatible format).
  - `data` ModelInfo[], required — The list of models
    - `datasets` string[], nullable — The datasets associated with this model, if any
    - `error` ComponentError
      - `category` 'dataset' | 'model' | 'worker' | 'runtime', required
      - `code` string, required — Stable machine-readable code (`{category}.{type}`), e.g. `dataset.auth`.
      - `type` 'auth' | 'connection' | 'timeout' | 'validation' | 'not_found' | 'permission' | 'rate_limit' | 'internal' | 'unknown', required
    - `error_message` string, nullable — An optional error message describing why the model entered an error state. Only populated when `status=true`, the model status is `Error`, and an error message was recorded. This value is intended for user-visible display.
    - `id` string, required — The name/identifier of the model
    - `metadata` ModelMetadata — Model metadata fields that can be optionally requested.
      - `supports_responses_api` boolean, required — Whether this model supports the Responses API
    - `object` string, required — The type of the object (always `model`)
    - `owned_by` string, required — The source from which the model was loaded (e.g., `openai`, `spiceai`)
    - `status` union — Represents the status of a component (e.g. dataset, model, etc). The `Error` variant optionally carries a human-readable error message describing what caused the component to enter the error state. Use [`ComponentStatus::error`] for an error without a message, or [`ComponentStatus::error_with_message`] to include one.
      - 'Initializing' — The component is initializing and not yet ready
      - 'Ready' — The component is ready to accept connections
      - 'Disabled' — The component is disabled and not running
      - object — An error occurred in the component, with an optional error message
        - `Error` string, nullable, required — An error occurred in the component, with an optional error message
      - 'Refreshing' — The component is in the process of refreshing its state
      - 'ShuttingDown' — The component is in the process of shutting down
      - 'NotLoaded' — The component is configured but not loaded yet
  - `object` string, required — The type of the response (always `list`)

## Other responses

- `500` — Internal server error occurred while processing models

## Changes

> 53 revisions in range; 26 could not be searched.

- **2025-03-18** `dd94571fef79` — 1 breaking, 4 warning, 1 info
  - added `#/components/schemas/ComponentStatus` to the `data/items/status` response property `oneOf` list for the response status `200` (media type: application/json)
  - deleted the `query` request parameter `metadata_fields`
  - removed the optional property `data/items/error` from the response with the `200` status (media type: application/json)
  - removed the optional property `data/items/error_message` from the response with the `200` status (media type: application/json)
  - …2 more

[Change history](https://skmtc.dev/spiceai/apis/runtime/changes/v1/models/get.md)

---

[API](https://skmtc.dev/spiceai/apis/runtime.md) · [All operations](https://skmtc.dev/spiceai/apis/runtime/llms.txt) · [OpenAPI document](https://skmtc-service-production.skmtc.workers.dev/v1/apis/spiceai/runtime/revisions/fb597a4eaa56/schema)
