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

# Get model

> One model by id, in the shape OpenAI clients expect.

The `{model}` path segment is written the same way as the `model` field in a request body:
a bare slug for platform models, or a full `accounts/{account}/models/{model}` resource
name for one your account owns. See [Models and resource names](/models-and-resource-names).

A model that exists but is not available to this key returns `403 MODEL_NOT_ALLOWED`; one
that is not visible at all returns `404 MODEL_NOT_FOUND`.


## OpenAPI

````yaml openapi/prentis.openapi.yaml GET /models/{model}
openapi: 3.1.0
info:
  title: Prentis Inference API
  version: 0.2.0
  summary: One inference API, reachable with an OpenAI client or an Anthropic client.
  description: >
    An OpenAI-compatible inference API. Point any OpenAI SDK at this base URL
    with a

    Prentis key and nothing else in your code changes.


    Anthropic clients are served too: the same host answers `/v1/messages`, and

    `x-api-key` is accepted alongside `Authorization: Bearer`.


    Parameters this API does not implement are ignored rather than rejected,
    except the

    few marked **not supported** below, which return `INVALID_REQUEST` so that a
    silently

    wrong answer is never returned in place of an error.
servers:
  - url: https://compute.prentis.ai/v1
    description: Production
security:
  - bearerAuth: []
tags:
  - name: chat
  - name: completions
  - name: messages
  - name: models
paths:
  /models/{model}:
    get:
      tags:
        - models
      summary: Retrieve a model
      description: One model by id, in the shape OpenAI clients expect.
      operationId: retrieveModel
      parameters:
        - name: model
          in: path
          required: true
          schema:
            type: string
          description: >-
            The model to look up, written the same way as the model field in a
            request body.
      responses:
        '200':
          headers:
            x-request-id:
              $ref: '#/components/headers/x-request-id'
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Model'
              example:
                id: deepseek-v4.1-flash
                object: model
                created: 1789286400
                owned_by: maas
          description: OK.
        '401':
          $ref: '#/components/responses/Error401'
        '404':
          $ref: '#/components/responses/Error404'
      x-codeSamples:
        - lang: curl
          label: cURL
          source: |-
            curl https://compute.prentis.ai/v1/models/deepseek-v4.1-flash \
              -H "Authorization: Bearer $PRENTIS_API_KEY"
components:
  headers:
    x-request-id:
      schema:
        type: string
      required: true
      description: >-
        On every response, successes and errors alike. It is the handle that
        reaches the whole path your request took -- quote it when you ask us
        anything about a call.
  schemas:
    Model:
      type: object
      required:
        - id
        - object
        - created
        - owned_by
      properties:
        id:
          type: string
        object:
          type: string
          const: model
        created:
          type: integer
        owned_by:
          type: string
          const: maas
    ErrorResponse:
      type: object
      required:
        - error
      properties:
        error:
          type: object
          required:
            - message
            - type
            - code
          properties:
            message:
              type: string
            type:
              type: string
              enum:
                - invalid_request_error
                - authentication_error
                - permission_error
                - not_found_error
                - rate_limit_error
                - server_error
                - service_unavailable
                - billing_error
            code:
              type: string
              enum:
                - INVALID_API_KEY
                - TENANT_SUSPENDED
                - MODEL_NOT_ALLOWED
                - AGREEMENT_REQUIRED
                - INVALID_REQUEST
                - MODEL_NOT_FOUND
                - MODEL_CAPABILITY_UNSUPPORTED
                - CONTEXT_LENGTH_EXCEEDED
                - IDEMPOTENCY_CONFLICT
                - MEDIA_TOO_LARGE
                - MEDIA_FETCH_FAILED
                - MEDIA_UNSUPPORTED
                - TENANT_RATE_LIMITED
                - TENANT_BUDGET_EXCEEDED
                - INSUFFICIENT_BALANCE
                - PAYMENT_REQUIRED
                - CONTENT_BLOCKED_INPUT
                - CONTENT_BLOCKED_OUTPUT
                - UPSTREAM_RATE_LIMITED
                - UPSTREAM_UNAVAILABLE
                - UPSTREAM_TIMEOUT
                - PARTIAL_RESPONSE_TIMEOUT
                - UPSTREAM_CONTENT_REJECTED
                - DEPLOYMENT_SCALING_UP
                - REQUEST_CANCELLED
                - REQUEST_DEADLINE_EXCEEDED
                - INTERNAL
                - STORAGE_UNAVAILABLE
            param:
              type:
                - string
                - 'null'
  responses:
    Error401:
      headers:
        x-request-id:
          $ref: '#/components/headers/x-request-id'
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
      description: >-
        `error.code` is one of: `INVALID_API_KEY`. See the Errors page for what
        each one means, whether it is safe to retry, and whether it is billed.
    Error404:
      headers:
        x-request-id:
          $ref: '#/components/headers/x-request-id'
      content:
        application/json:
          schema:
            $ref: '#/components/schemas/ErrorResponse'
      description: >-
        `error.code` is one of: `MODEL_NOT_FOUND`. See the Errors page for what
        each one means, whether it is safe to retry, and whether it is billed.
  securitySchemes:
    bearerAuth:
      type: http
      scheme: bearer
      description: >-
        `Authorization: Bearer <your API key>`. On `/v1/messages`, the
        Anthropic-style `x-api-key: <your API key>` header is accepted instead.

````