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

# List and retrieve models.

> GET /v1/models is the catalog, self-describing and always authoritative. Every entry carries its capabilities, limits, list pricing, and the parameters it accepts — so a client can decide what to send without a hard-coded table.

## Why read the catalog

The [Models](/models) page is a snapshot of the catalog at the time it was generated. The
endpoint is the catalog. Models are added, retired and repriced without an API version bump
([Reliability](/reliability)), so anything that picks a model at runtime — a router, a
model-picker UI, a capability check before sending an image — should read it here rather
than ship a copy.

This endpoint is **unauthenticated** and cacheable (`cache-control: public, max-age=300`).
Every SDK calls it at client-init; it costs you nothing and draws no usage.

## List

```http theme={null}
GET /v1/models
```

```sh theme={null}
curl https://api.layerx1.com/v1/models
```

```json title="Response (OpenAI shape)" theme={null}
{
  "object": "list",
  "data": [
    {
      "id": "lx1-gpt-oss-120b",
      "object": "model",
      "created": 1735689600,
      "owned_by": "sideren",
      "aliases": ["gpt-oss-120b"],
      "tier": "workhorse",
      "context_window": 131072,
      "max_output": 32768,
      "capabilities": {
        "tools": true,
        "reasoning": false,
        "vision": false,
        "documents": false
      },
      "pricing_usd_per_mtok": {
        "input": 0.05,
        "output": 0.35,
        "cached_input": null
      },
      "supported_parameters": [
        "messages", "system", "max_tokens", "temperature",
        "top_p", "stop", "stream", "tools", "tool_choice"
      ],
      "native_wires": ["chat_completions"]
    }
  ]
}
```

### Fields

| Field                    | Notes                                                                                                                                                                                                                    |
| ------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
| `id`                     | The canonical catalog id — always what you put in `model`.                                                                                                                                                               |
| `aliases`                | Other strings that resolve to this model. See [Model routing](/guides/model-routing).                                                                                                                                    |
| `tier`                   | The catalog tier this model sits in (`frontier`, `premium`, `workhorse`, …), matching the groupings on [Models](/models).                                                                                                |
| `context_window`         | Total tokens the model accepts.                                                                                                                                                                                          |
| `max_output`             | Output ceiling, or `null` when the model publishes none.                                                                                                                                                                 |
| `capabilities.tools`     | Accepts `tools` / `tool_choice`.                                                                                                                                                                                         |
| `capabilities.reasoning` | Has a reasoning mode. See [Reasoning](/guides/reasoning).                                                                                                                                                                |
| `capabilities.vision`    | Reads images. See [Vision](/guides/vision).                                                                                                                                                                              |
| `capabilities.documents` | Accepts document/PDF input.                                                                                                                                                                                              |
| `pricing_usd_per_mtok`   | List rates per million tokens: `input`, `output`, and `cached_input` — `null` when the model publishes no cached rate, which is also when repeated context earns no discount ([Prompt caching](/guides/prompt-caching)). |
| `supported_parameters`   | The parameter names this model honors. A capability-aware client should check here before sending `response_format` or a forced `tool_choice`.                                                                           |
| `native_wires`           | Protocols this model is served over natively. Informational — every model works on every endpoint.                                                                                                                       |

<Note>
  Providers and upstream deployment names are never in the response. One row is one
  *logical* model; which backend serves it is an implementation detail that can change
  mid-flight, which is exactly what makes [continuity](/reliability) possible.
</Note>

### Anthropic shape

Send an `anthropic-version` header — as every Anthropic SDK does — and the same endpoint
answers in Anthropic's list envelope instead, so `client.models.list()` type-checks:

```json theme={null}
{
  "data": [
    {
      "type": "model",
      "id": "lx1-gpt-oss-120b",
      "display_name": "lx1-gpt-oss-120b",
      "created_at": "2025-01-01T00:00:00.000Z"
    }
  ],
  "has_more": false,
  "first_id": "lx1-gpt-oss-120b",
  "last_id": "lx1-qwen3.7-max"
}
```

## Retrieve one

```http theme={null}
GET /v1/models/{id}
```

Accepts a canonical id, an alias, or the bare id without its `lx1-` prefix — so
`lx1-gpt-oss-120b`, `gpt-oss-120b` and any published alias all resolve. Returns the same
entry shape as the list (or the Anthropic per-item shape with `anthropic-version` set).

```sh theme={null}
curl https://api.layerx1.com/v1/models/lx1-gpt-oss-120b
```

An unknown id returns `404`:

```json theme={null}
{ "error": { "type": "not_found", "message": "no such model: lx1-nope" } }
```

<Note>
  Retrieve is a **validity check**, so it is deliberately stricter than the chat endpoints:
  the foreign-name compatibility handles that let `gpt-4o` work in a chat request are not
  resolved here. If you need to know what a foreign id maps to, send it to a chat endpoint
  and read the model back off the response.
</Note>

## From the CLI

```sh theme={null}
npx layerx1 models
```

Prints the catalog with pricing, straight from this endpoint.
