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

# List Draft Provider Models Route

> The models an unsaved provider form can call (the runtime lists them,
else the catalog suggests them). Validated like the draft test; stores
nothing.



## OpenAPI

````yaml https://cp.xenovia.io/openapi.json post /api/v1/providers/models/draft
openapi: 3.1.0
info:
  title: Xenovia Control Plane API
  version: 1.0.0
  description: >-
    Management API for agents, providers, policies, telemetry, alerts and
    organization settings.
servers:
  - url: https://cp.xenovia.io
    description: Production
security:
  - BearerAuth: []
paths:
  /api/v1/providers/models/draft:
    post:
      tags:
        - providers
      summary: List Draft Provider Models Route
      description: |-
        The models an unsaved provider form can call (the runtime lists them,
        else the catalog suggests them). Validated like the draft test; stores
        nothing.
      operationId: list_draft_provider_models_route_api_v1_providers_models_draft_post
      parameters: []
      requestBody:
        required: true
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/ProviderModelsDraft'
      responses:
        '200':
          description: Successful Response
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/ProviderModelList'
        '422':
          description: Validation Error
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/HTTPValidationError'
components:
  schemas:
    ProviderModelsDraft:
      properties:
        provider:
          type: string
          maxLength: 255
          minLength: 1
          title: Provider
        model:
          anyOf:
            - type: string
              maxLength: 255
              minLength: 1
            - type: 'null'
          title: Model
        params:
          anyOf:
            - additionalProperties: true
              type: object
            - type: 'null'
          title: Params
        api_token:
          anyOf:
            - type: string
            - type: 'null'
          title: Api Token
        provider_id:
          anyOf:
            - type: string
              format: uuid
            - type: 'null'
          title: Provider Id
      type: object
      required:
        - provider
      title: ProviderModelsDraft
      description: |-
        The draft connection test's body, for listing the models an unsaved
        form can call. The model is not needed to list them.
    ProviderModelList:
      properties:
        models:
          items:
            $ref: '#/components/schemas/ProviderModelOption'
          type: array
          title: Models
        source:
          type: string
          enum:
            - live
            - directory
            - catalog
          title: Source
        error:
          anyOf:
            - type: string
            - type: 'null'
          title: Error
      type: object
      required:
        - models
        - source
      title: ProviderModelList
      description: >-
        The models a provider can call. ``live`` is the upstream's own list

        (through the runtime, or OpenRouter's public list); ``directory`` is the

        public model directory's list for the entry (models.dev), answered when

        no live list can be had (no key yet, no discovery, a failed or

        unconfigured runtime); ``catalog`` is the catalog's suggestions, when
        the

        entry has no directory list or the directory cannot be reached.
        ``error``

        says why a live list was refused (the runtime's fixed message), or is

        null.
    HTTPValidationError:
      properties:
        detail:
          items:
            $ref: '#/components/schemas/ValidationError'
          type: array
          title: Detail
      type: object
      title: HTTPValidationError
    ProviderModelOption:
      properties:
        id:
          type: string
          title: Id
        name:
          type: string
          title: Name
      type: object
      required:
        - id
        - name
      title: ProviderModelOption
    ValidationError:
      properties:
        loc:
          items:
            anyOf:
              - type: string
              - type: integer
          type: array
          title: Location
        msg:
          type: string
          title: Message
        type:
          type: string
          title: Error Type
        input:
          title: Input
        ctx:
          type: object
          title: Context
      type: object
      required:
        - loc
        - msg
        - type
      title: ValidationError
  securitySchemes:
    BearerAuth:
      type: http
      scheme: bearer
      description: >-
        Bearer token: an organization API key (`ak_…`) created under Settings →
        API Keys, or a dashboard user session token. Agent keys (`xe_…`) are not
        accepted here. Endpoints marked as user-only in their description reject
        organization keys with `403`.

````

This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.