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

# List models across providers

> Flat, cursor-paginated list of every model available across all providers, with capability and cost metadata — the catalogue a client offers when switching model mid-session.



## OpenAPI

````yaml /en/openapi/v3-current/narya.yaml get /v1/models
openapi: 3.1.0
info:
  title: Narya Host API
  version: 1.0.0
  description: >-
    The contract between the Narya host and every client. One long-lived host
    runs on your machine and serves this API over a Unix socket in your Narya
    home. Narya creates the socket owner-only, and file permissions are the
    whole authorization. There is no password, no token and no TLS. The terminal
    client and the one-shot command that Lerian ships drive this API, and a
    client you write drives the same one.


    Results never arrive on the response of the request that caused them.
    Submitting a message returns 202 with a turn id. Everything the turn
    produces streams over GET /v1/events as server-sent events with a typed
    envelope, and a stream resumes from a Last-Event-ID header.


    One error envelope: code, title, message, and fields on 422. Codes are NRY-
    followed by four digits. A paged list answers items, limit and a nextCursor
    when more remains. Cursors are opaque.
servers: []
security: []
tags:
  - name: host
    description: The host process itself — version, uptime, mode, store.
  - name: sessions
    description: Durable conversation containers. Archive, never destroy.
  - name: messages
    description: Submitting work into a session and interrupting it.
  - name: events
    description: The server-sent event stream every client consumes.
  - name: lanes
    description: Parallel tracks inside a session — main, subagent, side.
  - name: agents
    description: Named recipes — instructions, tools, model, policy. Read-only in v1.
  - name: ladder
    description: >-
      What a person can type: the skills and command files in force for one
      repository, and expanding one into text. Five origins merged, nearest
      winning a name, the repository's own rungs gated on trust.
  - name: permissions
    description: Pending permission asks, decisions, and the decision audit.
  - name: intercom
    description: Sessions on one machine finding and messaging each other.
  - name: packages
    description: The one thing a user installs — resources, Go code, or both.
  - name: workflows
    description: Deterministic multi-agent orchestration runs.
  - name: providers
    description: Model suppliers, their auth state, and the model catalogue.
  - name: monitors
    description: >-
      Long-running watchers a session keeps beside its conversation — a test
      runner in watch mode, a build, a log being followed. Started by the model
      or by the person, always listed, always killable.
  - name: records
    description: The queryable local record of everything that happened.
  - name: schedules
    description: >-
      Work the host's own clock starts with nobody present — a repository, a
      prompt, a rule and what one fire may spend. Cancel, never destroy.
paths:
  /v1/models:
    get:
      tags:
        - providers
      summary: List models across providers
      description: >-
        Flat, cursor-paginated list of every model available across all
        providers, with capability and cost metadata — the catalogue a client
        offers when switching model mid-session.
      operationId: listModels
      parameters:
        - $ref: '#/components/parameters/CursorParam'
        - $ref: '#/components/parameters/LimitParam'
      responses:
        '200':
          description: One page of models.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ModelPage'
        '400':
          $ref: '#/components/responses/BadRequest'
        '500':
          $ref: '#/components/responses/InternalServerError'
components:
  parameters:
    CursorParam:
      name: cursor
      in: query
      required: false
      description: >-
        Opaque pagination cursor from a previous page's nextCursor or
        prevCursor.
      schema:
        type: string
        maxLength: 1024
    LimitParam:
      name: limit
      in: query
      required: false
      description: Maximum items per page.
      schema:
        type: integer
        minimum: 1
        maximum: 100
        default: 25
  schemas:
    ModelPage:
      type: object
      description: One page of the flat model catalogue.
      required:
        - items
        - limit
      properties:
        items:
          type: array
          items:
            $ref: '#/components/schemas/Model'
        limit:
          type: integer
          minimum: 1
        nextCursor:
          type: string
        prevCursor:
          type: string
      examples:
        - items:
            - id: claude-sonnet-4-5
              provider: anthropic
          limit: 25
    Model:
      type: object
      description: >-
        One model in the flat cross-provider catalogue, with capability and cost
        metadata.
      required:
        - id
        - provider
      properties:
        id:
          type: string
          description: The model's id, unique across providers.
        provider:
          type: string
          description: The provider that serves it.
        name:
          type: string
          description: Display name.
        contextWindow:
          type: integer
          minimum: 0
          description: Context window in tokens.
        maxOutputTokens:
          type: integer
          minimum: 0
        capabilities:
          type: array
          description: Capability flags, for example tools, vision, reasoning, caching.
          items:
            type: string
        inputCostPerMTok:
          type: number
          minimum: 0
          description: Cost per million input tokens, US dollars.
        outputCostPerMTok:
          type: number
          minimum: 0
          description: Cost per million output tokens, US dollars.
        availability:
          type: string
          enum:
            - listed
            - unlisted
            - discovered
          description: >
            What the provider's own model listing said about this model, when a
            credential on this host let narya ask. Absent means nothing has
            asked — no credential, a failed fetch, or a machine that never
            reaches the network — and claims nothing either way. `listed`: the
            provider currently serves it. `unlisted`: the catalogue carries it
            and the provider's listing did not; still offered and still
            runnable, since that listing may be paginated or scoped to an
            organisation. `discovered`: the provider lists it and the catalogue
            does not, so it carries no published window and no published price —
            unknown cost, never zero.
        variants:
          type: array
          description: >-
            Every named preset of request options this model offers, in the
            order a client should list them: the ones declared beside the model
            in configuration first, then the reasoning-effort levels weakest
            first. The levels are built in for every model whose family carries
            that knob and need no declaration anywhere; a configured variant
            reusing one of their names replaces it. Absent or empty means this
            model offers none, and asking for one is refused by name. A client
            reads this and nothing else to decide what to offer — it never
            derives a level, and a model whose endpoint turns out not to accept
            the field is told so by the host wherever the level is chosen — the
            model switch, and opening a session at one.
          items:
            $ref: '#/components/schemas/ModelVariant'
      examples:
        - id: claude-sonnet-4-5
          provider: anthropic
          name: Claude Sonnet 4.5
          contextWindow: 200000
          maxOutputTokens: 64000
          capabilities:
            - tools
            - vision
            - caching
          inputCostPerMTok: 3
          outputCostPerMTok: 15
          availability: listed
          variants:
            - name: low
              effort: low
            - name: medium
              effort: medium
            - name: high
              effort: high
            - name: max
              effort: max
    Error:
      type: object
      description: >-
        The single error envelope every operation returns. Codes are NRY-
        followed by four digits and are catalogued in the top-level
        x-error-catalog extension. fields appears only on 422 validation errors,
        mapping each offending property to its problem.
      required:
        - code
        - title
        - message
      properties:
        code:
          type: string
          pattern: ^NRY-[0-9]{4}$
          description: Machine-readable error code from the NRY catalogue.
        title:
          type: string
          maxLength: 256
          description: Short human-readable summary of the error class.
        message:
          type: string
          maxLength: 4096
          description: Specific, actionable description of what went wrong.
        fields:
          type: object
          description: Per-field validation problems. Present on 422 only.
          additionalProperties:
            type: string
      examples:
        - code: NRY-0002
          title: Session not found
          message: >-
            No session with id 6b9f6d2e-1c3a-4f5b-9d7e-2a8c4e6f0b1d exists on
            this host.
    ModelVariant:
      type: object
      description: >-
        One named preset of request options for a model, selectable as
        `provider/id#name` wherever a model reference is written and as
        `SessionModel.variant` on the switch. It carries request options only
        and never prompt text: what a variant changes is what a turn is SENT
        with, never what it is told.
      required:
        - name
      properties:
        name:
          type: string
          maxLength: 64
          description: >-
            What to ask for. The four reasoning-effort levels are spelled `low`,
            `medium`, `high` and `max`; any other name was declared beside the
            model in configuration.
        effort:
          type: string
          enum:
            - low
            - medium
            - high
            - max
          description: >-
            How hard the model is asked to think on a turn run under this
            variant, in narya's own four words rather than any supplier's — each
            family spells the same idea differently and the host translates once
            per family. Absent leaves the model's own default.
  responses:
    BadRequest:
      description: Malformed request — invalid parameter, cursor, or JSON body.
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'
    InternalServerError:
      description: The host failed — including a store that refuses writes (NRY-0012).
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/Error'

````