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

> ## Agent Instructions
> To set Ambral up in a project, run `npx ambral@latest skill install` in the project's root. It installs Ambral's skill, matched to the CLI's version, and the skill says how to do everything these pages describe with the `ambral` CLI. Prefer it to working from these pages. Never ask anyone for an Ambral API key, and never handle one: the person creates it in the web app and stores it where their app reads its secrets.

# Create a message

> Anthropic's Messages API. `model` is `ambral/auto` with an `x-workload` header (or `ambral/auto:<workload>`), which serves the workload's primary model and records the call to its traces. The answer is in the Messages API's own response schema, with `id` the call's own id, `model` the model that served it, and `usage.cost` what the call costs, in USD; any other key the provider adds to the message, its usage, a block or an event is removed (a block or delta of a type the schema doesn't name is kept whole). With `stream: true` the answer is named server-sent events, as the Messages API streams them: `message_start` with the id and model, each block's start, deltas and stop, `message_delta` with the stop reason and the whole call's usage and cost, then `message_stop`, which ends the stream; `ping` keeps it open, and an `error` event is a failure after the 200, or Ambral couldn't read the provider's event. Otherwise it is one JSON message, or the error envelope when Ambral couldn't read it. Every error is Anthropic's envelope, with Ambral's `code` beside its `type`, and an error the provider answers reaches the client with the provider's status. The request's content blocks, the top-level keys the Messages API names, and the provider's own extension keys are passed through as they were sent; any other key is left out. A request Ambral must price and can't is a 400: one that would let the provider choose another model, or run a tool or add-on Ambral doesn't price, or that asks for a premium setting Ambral doesn't price yet (fast `speed`, a regional `inference_geo`). A client tool, which has no `type`, `custom`, or one of Anthropic's versioned client tools (`bash_20250124`, `text_editor_*`, `computer_*`, `memory_*`), is priced; any other tool is run by the provider.



## OpenAPI

````yaml /api-reference/gateway.json post /v1/messages
openapi: 3.1.0
info:
  title: Ambral Gateway API
  version: '1'
servers:
  - url: https://api.ambral.ai
security: []
tags:
  - name: inference
    description: OpenAI's Chat Completions API, and the models it lists
  - name: messages
    description: Anthropic's Messages API
paths:
  /v1/messages:
    post:
      tags:
        - messages
      summary: Create a message
      description: >-
        Anthropic's Messages API. `model` is `ambral/auto` with an `x-workload`
        header (or `ambral/auto:<workload>`), which serves the workload's
        primary model and records the call to its traces. The answer is in the
        Messages API's own response schema, with `id` the call's own id, `model`
        the model that served it, and `usage.cost` what the call costs, in USD;
        any other key the provider adds to the message, its usage, a block or an
        event is removed (a block or delta of a type the schema doesn't name is
        kept whole). With `stream: true` the answer is named server-sent events,
        as the Messages API streams them: `message_start` with the id and model,
        each block's start, deltas and stop, `message_delta` with the stop
        reason and the whole call's usage and cost, then `message_stop`, which
        ends the stream; `ping` keeps it open, and an `error` event is a failure
        after the 200, or Ambral couldn't read the provider's event. Otherwise
        it is one JSON message, or the error envelope when Ambral couldn't read
        it. Every error is Anthropic's envelope, with Ambral's `code` beside its
        `type`, and an error the provider answers reaches the client with the
        provider's status. The request's content blocks, the top-level keys the
        Messages API names, and the provider's own extension keys are passed
        through as they were sent; any other key is left out. A request Ambral
        must price and can't is a 400: one that would let the provider choose
        another model, or run a tool or add-on Ambral doesn't price, or that
        asks for a premium setting Ambral doesn't price yet (fast `speed`, a
        regional `inference_geo`). A client tool, which has no `type`, `custom`,
        or one of Anthropic's versioned client tools (`bash_20250124`,
        `text_editor_*`, `computer_*`, `memory_*`), is priced; any other tool is
        run by the provider.
      operationId: messages.messages
      parameters:
        - name: x-workload
          in: header
          schema:
            allOf:
              - $ref: '#/components/schemas/WorkloadName'
              - description: >-
                  The workload the request is for, which `ambral/auto` serves
                  from its primary model and whose traces record it. A model
                  suffix (`ambral/auto:<workload>`) names it too, and the two
                  must agree. A request that names none and carries the
                  `x-ambral-eval` header is for its eval's workload.
          required: false
        - name: x-ambral-upstream
          in: header
          schema:
            allOf:
              - $ref: '#/components/schemas/UpstreamId'
              - description: >-
                  The upstream that serves the request, at that upstream's
                  price, for debugging. Otherwise Ambral chooses. A model it
                  doesn't serve is a 400.
          required: false
        - name: x-ambral-eval
          in: header
          schema:
            $ref: '#/components/schemas/EvalHeaderEncoded'
          required: false
        - name: x-session-id
          in: header
          schema:
            allOf:
              - $ref: '#/components/schemas/SessionId'
              - description: >-
                  The session the request belongs to: the same id on every
                  request of a session, 8–128 characters of A-Z a-z 0-9 _ -; any
                  other value is ignored. The body's `session_id` or an
                  `x-<vendor>-session-id` header names it too. Without one, each
                  request is a session.
          required: false
        - name: x-ambral-end-user
          in: header
          schema:
            allOf:
              - $ref: '#/components/schemas/EndUserId'
              - description: >-
                  Your own id for the person the request serves, recorded on its
                  session's trace: 1–128 characters of A-Z a-z 0-9 . _ : @ + -;
                  any other value is ignored. Without it, the body's
                  `safety_identifier`, `user` or `metadata.user_id` names them.
                  A session keeps the first one it is sent.
          required: false
        - name: x-ambral-labels
          in: header
          schema:
            type: string
            allOf:
              - description: >-
                  Labels on the request's session, `key=value` or a bare `tag`,
                  comma-separated: up to 16. A key is lowercase letters, digits,
                  `.`, `_` and `-`, starting with a letter or digit, at most 63
                  characters. A value is letters, digits, spaces and `. _ : / @
                  + -`, at most 128 characters; spaces around it are dropped. A
                  session's labels gather every request's, a later value
                  replacing an earlier one's; once a session holds 16, a later
                  request's new keys are dropped. Invalid labels are ignored,
                  all of them, and the response says why in its own
                  `x-ambral-labels` header.
          required: false
        - name: anthropic-version
          in: header
          schema:
            allOf:
              - $ref: '#/components/schemas/MessagesVersion'
              - description: >-
                  The API version, sent on to the provider. Without one,
                  `2023-06-01`.
          required: false
        - name: anthropic-beta
          in: header
          schema:
            allOf:
              - $ref: '#/components/schemas/MessagesBetas'
              - description: >-
                  The betas to turn on, comma-separated, sent on to the
                  provider, which may support only some.
          required: false
      requestBody:
        content:
          application/json:
            schema:
              $ref: '#/components/schemas/MessagesRequest'
        required: true
      responses:
        '200':
          description: 'The provider''s answer: one message, or a stream of events.'
          content:
            application/json:
              schema:
                description: >-
                  The message, or the error envelope when Ambral couldn't read
                  the provider's answer.
                anyOf:
                  - $ref: '#/components/schemas/MessagesMessage'
                  - $ref: '#/components/schemas/MessagesErrorBody'
            text/event-stream:
              schema:
                description: >-
                  Named server-sent events, each event's `data` as JSON: a
                  stream event, named by its `type`; a `ping`; or, named
                  `error`, the error envelope.
                anyOf:
                  - $ref: '#/components/schemas/MessagesStreamEvent'
                  - $ref: '#/components/schemas/MessagesErrorBody'
          headers:
            x-ambral-route:
              schema:
                type: string
                enum:
                  - routed
                allOf:
                  - description: '`routed`: `ambral/auto` chose the model.'
              required: true
            x-ambral-model:
              schema:
                allOf:
                  - $ref: '#/components/schemas/ModelId'
                  - description: The model that served the request.
              required: true
            x-ambral-workload:
              schema:
                allOf:
                  - $ref: '#/components/schemas/WorkloadName'
                  - description: The workload the request was served and recorded for.
              required: true
            x-ambral-upstream:
              schema:
                allOf:
                  - $ref: '#/components/schemas/UpstreamId'
                  - description: >-
                      The upstream that served the request, only when
                      `x-ambral-upstream` pinned it.
              required: false
            x-ambral-recording:
              schema:
                type: string
                allOf:
                  - description: >-
                      `skipped; reason=<reason>` when the request named a
                      workload but wasn't recorded, with `<reason>` one of
                      `unsupported_tools`.
              required: false
            x-session-id:
              schema:
                allOf:
                  - $ref: '#/components/schemas/SessionId'
                  - description: >-
                      The session Ambral made for a request that named none:
                      send it back on the session's next request.
              required: false
            x-ambral-labels:
              schema:
                type: string
                enum:
                  - ignored; reason=too_many
                  - ignored; reason=invalid_key
                  - ignored; reason=invalid_value
                allOf:
                  - description: >-
                      `ignored; reason=<reason>` when the request's
                      `x-ambral-labels` header was ignored: the request was
                      served and recorded without its labels. `too_many` names
                      more than 16 labels, `invalid_key` a key that isn't a
                      label key, and `invalid_value` a value that isn't a label
                      value.
              required: false
            request-id:
              schema:
                allOf:
                  - $ref: '#/components/schemas/CallId'
                  - description: The call's id, as the answer's `id`.
              required: true
        '400':
          description: >-
            The request is invalid: its body, a header, the workload or upstream
            it names, or a model other than `ambral/auto`.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/MessagesErrorBody'
        '401':
          description: >-
            No inference key, or one that is unknown or revoked, or whose org
            isn't active.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/MessagesErrorBody'
        '402':
          description: No available credit.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/MessagesErrorBody'
        '404':
          description: No workload has the name the request gives.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/MessagesErrorBody'
        '429':
          description: The provider is limiting the rate of requests.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/MessagesErrorBody'
        '502':
          description: The provider couldn't be reached. Retry the request.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/MessagesErrorBody'
        '503':
          description: >-
            The key, or the route of the workload the request names, couldn't be
            read. Retry the request.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/MessagesErrorBody'
        default:
          description: >-
            An error the provider answered, with the provider's status, in the
            same error envelope.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/MessagesErrorBody'
      security:
        - bearer: []
        - apiKey: []
components:
  schemas:
    WorkloadName:
      type: string
    UpstreamId:
      type: string
      minLength: 1
    EvalHeaderEncoded:
      type: string
      description: >-
        `<run>; workload=<workload>; model=<model>`: the request is a call of an
        eval run, which Ambral's SDKs set. A request that names no workload (no
        `x-workload`, no model suffix) is for the run's. A request for the run's
        workload is served the run's model, one of the workload's pool, and a
        request for another workload that workload's primary. Either way it is
        recorded as an eval trace of the run, never as production. It needs a
        session, and a value that doesn't parse is a 400.
    SessionId:
      type: string
    EndUserId:
      type: string
      description: >-
        1 to 128 letters, digits, and `. _ : @ + -`: the customer's own id for
        the person served.
    MessagesVersion:
      type: string
    MessagesBetas:
      type: string
    MessagesRequest:
      type: object
      properties:
        model:
          $ref: '#/components/schemas/ModelName'
        max_tokens:
          $ref: '#/components/schemas/TokenCount'
        messages:
          type: array
          items:
            $ref: '#/components/schemas/MessagesMessageParam'
        system:
          $ref: '#/components/schemas/MessagesContent'
        tools:
          type: array
          items:
            $ref: '#/components/schemas/MessagesTool'
        stream:
          type: boolean
        session_id: {}
      required:
        - model
        - max_tokens
        - messages
      allOf:
        - type: object
          additionalProperties: {}
    MessagesMessage:
      type: object
      properties:
        id:
          $ref: '#/components/schemas/MessagesMessageId'
        type:
          type: string
          enum:
            - message
        role:
          type: string
          enum:
            - assistant
        container:
          anyOf:
            - {}
            - type: 'null'
        content:
          type: array
          items:
            $ref: '#/components/schemas/MessagesContentBlock'
        model:
          $ref: '#/components/schemas/ModelName'
        stop_reason:
          anyOf:
            - $ref: '#/components/schemas/MessagesStopReason'
            - type: 'null'
        stop_details:
          anyOf:
            - {}
            - type: 'null'
        stop_sequence:
          anyOf:
            - $ref: '#/components/schemas/MessagesStopSequence'
            - type: 'null'
        usage:
          $ref: '#/components/schemas/MessagesUsage'
        context_management:
          anyOf:
            - {}
            - type: 'null'
      required:
        - id
        - type
        - role
        - content
        - model
        - stop_reason
        - usage
      additionalProperties: false
    MessagesErrorBody:
      type: object
      properties:
        type:
          type: string
          enum:
            - error
        error:
          type: object
          properties:
            type:
              $ref: '#/components/schemas/MessagesErrorType'
            message:
              type: string
            code:
              $ref: '#/components/schemas/ChatCompletionsErrorCode'
          required:
            - type
            - message
            - code
          additionalProperties: false
        request_id:
          $ref: '#/components/schemas/CallId'
      required:
        - type
        - error
        - request_id
      additionalProperties: false
    MessagesStreamEvent:
      anyOf:
        - $ref: '#/components/schemas/MessagesMessageStart'
        - $ref: '#/components/schemas/MessagesContentBlockStart'
        - $ref: '#/components/schemas/MessagesContentBlockDelta'
        - $ref: '#/components/schemas/MessagesContentBlockStop'
        - $ref: '#/components/schemas/MessagesMessageDelta'
        - $ref: '#/components/schemas/MessagesMessageStop'
    ModelId:
      type: string
      minLength: 1
      maxLength: 256
    CallId:
      type: string
      minLength: 1
    ModelName:
      type: string
      minLength: 1
      maxLength: 256
    TokenCount:
      type: integer
      minimum: 0
      maximum: 9007199254740991
    MessagesMessageParam:
      type: object
      properties:
        role:
          $ref: '#/components/schemas/MessagesRole'
        content:
          $ref: '#/components/schemas/MessagesContent'
      required:
        - role
        - content
      allOf:
        - type: object
          additionalProperties: {}
    MessagesContent:
      anyOf:
        - $ref: '#/components/schemas/MessagesText'
        - type: array
          items:
            $ref: '#/components/schemas/MessagesBlockParam'
    MessagesTool:
      type: object
      properties:
        type:
          type: string
        name:
          $ref: '#/components/schemas/ToolName'
        description:
          $ref: '#/components/schemas/MessagesToolDescription'
        input_schema:
          type: object
      allOf:
        - type: object
          additionalProperties: {}
    MessagesMessageId:
      type: string
    MessagesContentBlock:
      anyOf:
        - $ref: '#/components/schemas/MessagesTextBlock'
        - $ref: '#/components/schemas/MessagesThinkingBlock'
        - $ref: '#/components/schemas/MessagesRedactedThinkingBlock'
        - $ref: '#/components/schemas/MessagesToolUseBlock'
        - $ref: '#/components/schemas/MessagesOtherBlock'
    MessagesStopReason:
      type: string
    MessagesStopSequence:
      type: string
    MessagesUsage:
      type: object
      properties:
        input_tokens:
          $ref: '#/components/schemas/TokenCount'
        output_tokens:
          $ref: '#/components/schemas/TokenCount'
        output_tokens_details:
          anyOf:
            - type: object
              properties:
                thinking_tokens:
                  anyOf:
                    - $ref: '#/components/schemas/TokenCount'
                    - type: 'null'
              additionalProperties: false
            - type: 'null'
        cache_creation_input_tokens:
          anyOf:
            - $ref: '#/components/schemas/TokenCount'
            - type: 'null'
        cache_read_input_tokens:
          anyOf:
            - $ref: '#/components/schemas/TokenCount'
            - type: 'null'
        cache_creation:
          anyOf:
            - type: object
              properties:
                ephemeral_5m_input_tokens:
                  $ref: '#/components/schemas/TokenCount'
                ephemeral_1h_input_tokens:
                  $ref: '#/components/schemas/TokenCount'
              required:
                - ephemeral_5m_input_tokens
                - ephemeral_1h_input_tokens
              additionalProperties: false
            - type: 'null'
        inference_geo:
          anyOf:
            - $ref: '#/components/schemas/MessagesInferenceGeo'
            - type: 'null'
        server_tool_use:
          anyOf:
            - {}
            - type: 'null'
        service_tier:
          anyOf:
            - $ref: '#/components/schemas/MessagesServiceTier'
            - type: 'null'
        speed:
          anyOf:
            - $ref: '#/components/schemas/MessagesSpeed'
            - type: 'null'
        cost:
          anyOf:
            - $ref: '#/components/schemas/ShownCostUsd'
            - type: 'null'
          description: What the call costs, in USD.
      required:
        - input_tokens
        - output_tokens
      additionalProperties: false
    MessagesErrorType:
      type: string
      enum:
        - invalid_request_error
        - authentication_error
        - billing_error
        - permission_error
        - not_found_error
        - request_too_large
        - rate_limit_error
        - timeout_error
        - api_error
        - overloaded_error
    ChatCompletionsErrorCode:
      type: string
    MessagesMessageStart:
      type: object
      properties:
        type:
          type: string
          enum:
            - message_start
        message:
          $ref: '#/components/schemas/MessagesMessage'
      required:
        - type
        - message
      additionalProperties: false
    MessagesContentBlockStart:
      type: object
      properties:
        type:
          type: string
          enum:
            - content_block_start
        index:
          $ref: '#/components/schemas/MessagesBlockIndex'
        content_block:
          $ref: '#/components/schemas/MessagesContentBlock'
      required:
        - type
        - index
        - content_block
      additionalProperties: false
    MessagesContentBlockDelta:
      type: object
      properties:
        type:
          type: string
          enum:
            - content_block_delta
        index:
          $ref: '#/components/schemas/MessagesBlockIndex'
        delta:
          $ref: '#/components/schemas/MessagesBlockDelta'
      required:
        - type
        - index
        - delta
      additionalProperties: false
    MessagesContentBlockStop:
      type: object
      properties:
        type:
          type: string
          enum:
            - content_block_stop
        index:
          $ref: '#/components/schemas/MessagesBlockIndex'
      required:
        - type
        - index
      additionalProperties: false
    MessagesMessageDelta:
      type: object
      properties:
        type:
          type: string
          enum:
            - message_delta
        delta:
          type: object
          properties:
            container:
              anyOf:
                - {}
                - type: 'null'
            stop_details:
              anyOf:
                - {}
                - type: 'null'
            stop_reason:
              anyOf:
                - $ref: '#/components/schemas/MessagesStopReason'
                - type: 'null'
            stop_sequence:
              anyOf:
                - $ref: '#/components/schemas/MessagesStopSequence'
                - type: 'null'
          required:
            - stop_reason
          additionalProperties: false
        usage:
          $ref: '#/components/schemas/MessagesDeltaUsage'
        context_management:
          anyOf:
            - {}
            - type: 'null'
      required:
        - type
        - delta
        - usage
      additionalProperties: false
    MessagesMessageStop:
      type: object
      properties:
        type:
          type: string
          enum:
            - message_stop
      required:
        - type
      additionalProperties: false
    MessagesRole:
      type: string
    MessagesText:
      type: string
    MessagesBlockParam:
      type: object
      properties:
        type:
          type: string
      required:
        - type
      allOf:
        - type: object
          additionalProperties: {}
    ToolName:
      type: string
    MessagesToolDescription:
      type: string
    MessagesTextBlock:
      type: object
      properties:
        type:
          type: string
          enum:
            - text
        text:
          $ref: '#/components/schemas/MessagesText'
        citations:
          anyOf:
            - type: array
            - type: 'null'
      required:
        - type
        - text
      additionalProperties: false
    MessagesThinkingBlock:
      type: object
      properties:
        type:
          type: string
          enum:
            - thinking
        thinking:
          $ref: '#/components/schemas/MessagesText'
        signature:
          $ref: '#/components/schemas/MessagesSignature'
      required:
        - type
        - thinking
        - signature
      additionalProperties: false
    MessagesRedactedThinkingBlock:
      type: object
      properties:
        type:
          type: string
          enum:
            - redacted_thinking
        data:
          $ref: '#/components/schemas/MessagesEncryptedThinking'
      required:
        - type
        - data
      additionalProperties: false
    MessagesToolUseBlock:
      type: object
      properties:
        type:
          type: string
          enum:
            - tool_use
        id:
          $ref: '#/components/schemas/MessagesToolUseId'
        caller: {}
        name:
          $ref: '#/components/schemas/ToolName'
        input: {}
        toolset_name:
          anyOf:
            - $ref: '#/components/schemas/MessagesToolsetName'
            - type: 'null'
      required:
        - type
        - id
        - name
        - input
      additionalProperties: false
    MessagesOtherBlock:
      type: object
      properties:
        type:
          type: string
      required:
        - type
      allOf:
        - type: object
          additionalProperties: {}
    MessagesInferenceGeo:
      type: string
    MessagesServiceTier:
      type: string
    MessagesSpeed:
      type: string
    ShownCostUsd:
      type: number
    MessagesBlockIndex:
      type: integer
      minimum: 0
      maximum: 9007199254740991
    MessagesBlockDelta:
      anyOf:
        - $ref: '#/components/schemas/MessagesTextDelta'
        - $ref: '#/components/schemas/MessagesInputJsonDelta'
        - $ref: '#/components/schemas/MessagesThinkingDelta'
        - $ref: '#/components/schemas/MessagesSignatureDelta'
        - $ref: '#/components/schemas/MessagesOtherDelta'
    MessagesDeltaUsage:
      type: object
      properties:
        input_tokens:
          anyOf:
            - $ref: '#/components/schemas/TokenCount'
            - type: 'null'
        output_tokens:
          $ref: '#/components/schemas/TokenCount'
        output_tokens_details:
          anyOf:
            - type: object
              properties:
                thinking_tokens:
                  anyOf:
                    - $ref: '#/components/schemas/TokenCount'
                    - type: 'null'
              additionalProperties: false
            - type: 'null'
        cache_creation_input_tokens:
          anyOf:
            - $ref: '#/components/schemas/TokenCount'
            - type: 'null'
        cache_read_input_tokens:
          anyOf:
            - $ref: '#/components/schemas/TokenCount'
            - type: 'null'
        cache_creation:
          anyOf:
            - type: object
              properties:
                ephemeral_5m_input_tokens:
                  $ref: '#/components/schemas/TokenCount'
                ephemeral_1h_input_tokens:
                  $ref: '#/components/schemas/TokenCount'
              required:
                - ephemeral_5m_input_tokens
                - ephemeral_1h_input_tokens
              additionalProperties: false
            - type: 'null'
        inference_geo:
          anyOf:
            - $ref: '#/components/schemas/MessagesInferenceGeo'
            - type: 'null'
        server_tool_use:
          anyOf:
            - {}
            - type: 'null'
        service_tier:
          anyOf:
            - $ref: '#/components/schemas/MessagesServiceTier'
            - type: 'null'
        speed:
          anyOf:
            - $ref: '#/components/schemas/MessagesSpeed'
            - type: 'null'
        cost:
          anyOf:
            - $ref: '#/components/schemas/ShownCostUsd'
            - type: 'null'
          description: What the call costs, in USD.
      required:
        - output_tokens
      additionalProperties: false
    MessagesSignature:
      type: string
    MessagesEncryptedThinking:
      type: string
    MessagesToolUseId:
      type: string
    MessagesToolsetName:
      type: string
    MessagesTextDelta:
      type: object
      properties:
        type:
          type: string
          enum:
            - text_delta
        text:
          $ref: '#/components/schemas/MessagesText'
      required:
        - type
        - text
      additionalProperties: false
    MessagesInputJsonDelta:
      type: object
      properties:
        type:
          type: string
          enum:
            - input_json_delta
        partial_json:
          $ref: '#/components/schemas/MessagesPartialJson'
      required:
        - type
        - partial_json
      additionalProperties: false
    MessagesThinkingDelta:
      type: object
      properties:
        type:
          type: string
          enum:
            - thinking_delta
        thinking:
          $ref: '#/components/schemas/MessagesText'
      required:
        - type
        - thinking
      additionalProperties: false
    MessagesSignatureDelta:
      type: object
      properties:
        type:
          type: string
          enum:
            - signature_delta
        signature:
          $ref: '#/components/schemas/MessagesSignature'
      required:
        - type
        - signature
      additionalProperties: false
    MessagesOtherDelta:
      type: object
      properties:
        type:
          type: string
      required:
        - type
      allOf:
        - type: object
          additionalProperties: {}
    MessagesPartialJson:
      type: string
  securitySchemes:
    bearer:
      description: An inference key, made on the API keys page of Ambral's app.
      type: http
      scheme: Bearer
    apiKey:
      description: >-
        The Ambral inference key, the same key as the bearer, when no bearer is
        sent. Anthropic's SDK and Claude Code send their API key in this header.
      type: apiKey
      name: x-api-key
      in: header

````

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