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

# Create Browser Call Request

> The browser data plane: what `@goyappr/client` calls when a mint answers `protocol: "call_request"`, with the session token as `x-yappr-web-token` (a shared link's page sends `x-share-token` instead). Accepts the call request exactly as POST /call-requests does and answers the same `202`, including the `start_capability` that authorizes the read, cancel and start below. The same token asking again gets the same request: a `200` with the request as it is now and no new capability, exactly as POST /call-requests answers a repeated Idempotency-Key. Hand the `request_id` to your server to read the request with GET /call-requests/{id}.


The **browser data plane**: the mint's `connection.call_requests_url`, which
`@goyappr/client` calls when [`POST /calls`](https://docs.goyappr.com/api-reference/calls/create) with
`"type": "web"` answers `protocol: "call_request"` - an agent whose workflow runs steps
before it answers, or has follow-ups. It is authorized by the session token as
`x-yappr-web-token` (a shared link's page sends `x-share-token`), never your secret key.

```bash theme={null}
curl -X POST https://api.goyappr.com/web-call/call-requests \
  -H "x-yappr-web-token: wcs_…" \
  -H "Content-Type: application/json" \
  -d '{}'
```

```json theme={null}
{
  "id": "9f1c…",
  "request_id": "9f1c…",
  "run_id": "4ab2…",
  "call_id": null,
  "type": "web",
  "channel": "web",
  "status": "preparing",
  "preparation_status": "pending",
  "agent_id": "AGENT_ID",
  "accepted_at": "2026-10-02T09:00:00Z",
  "expires_at": "2026-10-02T09:15:00Z",
  "start_capability": "…",
  "status_url": "https://api.goyappr.com/web-call/call-requests/9f1c…",
  "cancel_url": "https://api.goyappr.com/web-call/call-requests/9f1c…/cancel",
  "start_url": "https://api.goyappr.com/web-call/call-requests/9f1c…/start"
}
```

The session names the agent, its variables and its metadata, so send `{}`: set
`variables` and `metadata` on the mint instead. The request is accepted exactly as
[`POST /call-requests`](https://docs.goyappr.com/api-reference/calls/request-create) accepts one, and nothing is
dialled: the browser [polls it](https://docs.goyappr.com/api-reference/web-call/request-get.md) and
[starts it](https://docs.goyappr.com/api-reference/web-call/request-start.md) once it reads `ready`.

`start_capability` is returned **once** and stored only as a hash. Send it as
`x-yappr-call-request-key` on the read, the cancel and the start; it authorizes this one
request and nothing else. Hand `request_id` to your server to read the request with
[`GET /call-requests/{id}`](https://docs.goyappr.com/api-reference/calls/request-get) and your secret key.

## Asking again

The same token asking again gets the same request: a `200` with the request as it is now,
`replayed: true`, the three URLs and **no** `start_capability` - the one that works was
returned by the first answer. A token that already created a request gets it back however
little time the token has left.

## Refusals

| Status | Code | What to do |
| - | - | - |
| `400` | `CALL_REQUEST_FIELD_NOT_ALLOWED` | `metadata` or `variables` in the body. Set them on the mint and send `{}`. |
| `401` | `UNAUTHORIZED` | A token or share link that is not ours, or none at all. |
| `403` | `WEB_SESSION_CANCELLED` | The token was taken back with its `cancel_url`. Mint a new session. |
| `403` | `FORBIDDEN` | The token has expired, or the shared link was revoked or has expired. |
| `409` | `WEB_SESSION_PROTOCOL_OFFER` | The token was minted for `protocol: "offer"`. Send the browser's offer to [Connect a Browser Call](https://docs.goyappr.com/api-reference/web-call/offer.md) instead. |
| `409` | `SESSION_TOKEN_EXPIRES_TOO_SOON` | Less than the five-minute preparation window is left. Mint a new session. |
| `409` | `SHARE_LINK_EXPIRES_TOO_SOON` | The shared link has less than five minutes left. |
| `503` | `WORKFLOW_ADMISSION_UNAVAILABLE` | Temporary. Retry. |
| `503` | `AUTH_UNAVAILABLE` | A dashboard sign-in could not be checked just now. Temporary: retry after `Retry-After` seconds (send the same `Idempotency-Key` to get the same request). |

The lifecycle refusals of [`POST /call-requests`](https://docs.goyappr.com/api-reference/calls/request-create)
apply too, such as `409 WORKFLOW_AGENT_INACTIVE`.


## OpenAPI

````yaml POST /web-call/call-requests
openapi: 3.1.0
info:
  title: Yappr API
  description: >
    Create and manage AI voice agents, purchase phone numbers, configure tools,
    and initiate calls — all via REST.
  version: 1.0.0
  contact:
    url: https://goyappr.com
servers:
  - url: https://api.goyappr.com
    description: Production
security:
  - apiKey: []
paths:
  /web-call/call-requests:
    servers:
      - url: https://api.goyappr.com
        description: >-
          Browser data plane, on the API host (the web mint's connection.host).
          Takes a session token, a call request's capability or a shared link -
          never the secret key.
    post:
      tags:
        - Calls
      summary: Create a browser call request (data plane)
      description: >
        The browser data plane: what `@goyappr/client` calls when a mint answers
        `protocol: "call_request"`, with the session token as
        `x-yappr-web-token` (a shared link's page sends `x-share-token`
        instead). Accepts the call request exactly as POST /call-requests does
        and answers the same `202`, including the `start_capability` that
        authorizes the read, cancel and start below. The same token asking again
        gets the same request: a `200` with the request as it is now and no new
        capability, exactly as POST /call-requests answers a repeated
        Idempotency-Key. Hand the `request_id` to your server to read the
        request with GET /call-requests/{id}.
      operationId: createBrowserCallRequest
      parameters:
        - in: header
          name: x-yappr-web-token
          required: false
          schema:
            type: string
          description: The session token from POST /calls {"type":"web"}.
      requestBody:
        required: true
        content:
          application/json:
            schema:
              type: object
              description: >-
                The session names the agent, its variables and its metadata; a
                token-authorized request sends `{}`.
      responses:
        '200':
          description: >-
            This token already created a request - the request as it is now,
            `replayed` true and no `start_capability`, as POST /call-requests
            answers a repeated key.
          content:
            application/json:
              schema:
                allOf:
                  - $ref: '#/components/schemas/CallRequest'
                  - type: object
                    required:
                      - request_id
                      - replayed
                      - status_url
                      - cancel_url
                      - start_url
                    properties:
                      request_id:
                        type: string
                        format: uuid
                      type:
                        type: string
                        enum:
                          - web
                      agent_id:
                        type:
                          - string
                          - 'null'
                        format: uuid
                      accepted_at:
                        type:
                          - string
                          - 'null'
                        format: date-time
                      replayed:
                        type: boolean
                        enum:
                          - true
                      status_url:
                        type: string
                        format: uri
                      cancel_url:
                        type: string
                        format: uri
                      start_url:
                        type: string
                        format: uri
        '202':
          description: >-
            Accepted, as POST /call-requests answers it - the request, its
            `start_capability` and the three URLs, on this host.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/CallRequestAccepted'
        '400':
          description: >
            CALL_REQUEST_FIELD_NOT_ALLOWED — `metadata` or `variables` in the
            body of a token- or link-authorized request. A Web SDK session
            carries the values it was minted with: set them on POST /calls
            {"type":"web"} and send `{}` here.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '401':
          description: >-
            UNAUTHORIZED - a token or share link that is not one of ours, or no
            token, link or sign-in at all.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '403':
          description: >
            WEB_SESSION_CANCELLED — the token was taken back with its
            cancel_url; mint a new session. FORBIDDEN "This session token has
            expired" — it ran out. A revoked or expired shared link is refused
            the same way.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '409':
          description: >
            WEB_SESSION_PROTOCOL_OFFER — the token was minted for protocol
            "offer": send the browser's SDP offer to POST /web-call with it
            instead. SESSION_TOKEN_EXPIRES_TOO_SOON /
            SHARE_LINK_EXPIRES_TOO_SOON — less than the five-minute preparation
            window is left; mint a new session. Only a new request is refused: a
            token that already created one gets that request back (the `200`),
            however little time it has left. The lifecycle refusals of POST
            /call-requests apply too.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
        '503':
          description: >
            WORKFLOW_ADMISSION_UNAVAILABLE — temporary; retry. AUTH_UNAVAILABLE
            — a dashboard sign-in could not be checked just now (not a refused
            sign-in); retry after the Retry-After header's seconds, with the
            same Idempotency-Key to get the same request.
          content:
            application/json:
              schema:
                $ref: '#/components/schemas/Error'
      security: []
components:
  schemas:
    CallRequest:
      type: object
      description: >
        Lifecycle record for one accepted call on a workflow agent. An outbound
        phone call returns its identity as `request_id` from POST /calls; a
        browser call is created directly with POST /call-requests. Either way
        this object is what you poll and what you cancel, and the two follow the
        same states.
      required:
        - id
        - run_id
        - channel
        - status
        - preparation_status
        - expires_at
      properties:
        id:
          type: string
          format: uuid
        run_id:
          type: string
          format: uuid
          description: Shared lifecycle identity. It does not grant access to call history.
        agent_id:
          type: string
          format: uuid
          description: >-
            The agent the request was made for. On GET /call-requests/{id}, the
            browser's poll and a replayed create.
        channel:
          type: string
          enum:
            - phone
            - web
          description: >
            `phone` is dialled by the platform once it is ready. `web` is
            started by the caller's own browser with POST
            /call-requests/{id}/start, because the microphone is there and not
            here.
        preparation_steps:
          type: array
          description: >
            On GET /call-requests/{id} (either channel) and the browser's poll.
            One entry per before-call step the workflow declares, in document
            order, whatever ran - so a waiting caller can be shown what is
            running, and a server can see which step failed and what its tool
            answered. Empty only between accepting the request and freezing the
            workflow version it runs. Step results are never included.
          items:
            type: object
            required:
              - id
              - label
              - status
            properties:
              id:
                type: string
              label:
                type: string
                description: The author's own name for the step.
              status:
                type: string
                enum:
                  - waiting
                  - inactive
                  - running
                  - pending
                  - unknown
                  - succeeded
                  - failed
                  - blocked
                  - skipped
                  - not_run
                  - cancelled
                description: >
                  waiting (not started yet); inactive (it runs only if an
                  earlier step's route chooses it, and none has yet); running
                  (sent, waiting for the answer); pending (its address accepted
                  the request without a final answer, such as an HTTP 202 -
                  settled as failed in a moment); unknown (the request may or
                  may not have reached its address - a timeout or a dropped
                  connection - settled as failed in a moment, never sent twice);
                  succeeded; failed; blocked (not sent, or its answer was not
                  usable); skipped (its condition said no, no route chose it, a
                  step it depends on was skipped, or an earlier step stopped the
                  preparation); or not_run - the preparation ended (failed,
                  cancelled or ran out of time) before this step ran; or
                  cancelled - the request was cancelled while this step was
                  running, and whatever it answered is not used. waiting,
                  inactive, running, pending and unknown are seen while the
                  request is preparing. A finished preparation reads succeeded,
                  failed, blocked, skipped, not_run and cancelled (an inactive
                  step it never reached reads not_run; a step a cancel overtook
                  reads cancelled, never running), except one that ended
                  preparation_interrupted: the step it was running keeps the
                  status it had.
              error_code:
                type: string
                description: >
                  Only on a step that did not succeed: what its tool answered,
                  in the platform's own codes - `downstream_http_error` (the
                  address answered an HTTP error; see `http_status`),
                  `http_timeout`, `http_network_error`, `url_resolves_private`,
                  `output_schema_invalid` and the like. Never the response
                  itself.
              http_status:
                type: integer
                description: >
                  Only on a step whose address answered: its HTTP status. A 4xx
                  other than 408 and 429 answers the same way on every retry
                  until the tool changes.
              refused_call:
                type: boolean
                description: >
                  true only on the step whose route refused the call (the
                  request reads failed with error_code before_declined). A step
                  refused on a failure keeps its error_code and http_status; one
                  refused on its answer reads succeeded. Absent on every other
                  step.
        status:
          type: string
          enum:
            - preparing
            - scheduled
            - ready
            - dispatching
            - dispatched
            - failed
            - expired
            - cancelled
            - dispatch_unknown
          description: >
            `scheduled` waits for the workspace's next calling window;
            `preparing` and `ready` cover pre-call work; `dispatching` and
            `dispatched` mean the call is being placed or has been placed;
            `dispatch_unknown` means placement is still being confirmed and must
            not be retried blindly; `failed`, `expired` and `cancelled` are
            final.
        preparation_status:
          type: string
          enum:
            - pending
            - running
            - ready
            - failed
            - expired
            - cancelled
            - declined
          description: >
            Progress of the pre-call step only. A preparation that fails or runs
            out of time does not always fail the request - an agent configured
            to continue with whatever is available still calls, with whatever
            the preparation produced. `declined` is a decision rather than a
            failure - a before-call step refused the call, so nothing is
            dialled, no call record is created, and the failure policy does not
            apply.
        workflow_revision_id:
          type:
            - string
            - 'null'
          format: uuid
          description: The published version of the agent frozen for this request.
        call_id:
          type:
            - string
            - 'null'
          format: uuid
          description: Set once a call record exists. Pass it to the call-by-id endpoint.
        expires_at:
          type: string
          format: date-time
          description: >-
            After this moment a request that has not finished is abandoned and
            no call is placed. A request that already failed keeps status failed
            and its error_code.
        error_code:
          type:
            - string
            - 'null'
          description: >
            Present only when status is failed or expired. An expired request is
            always `request_expired`. On a failed one the preparation's own code
            wins wherever it recorded one - `step_failed` when a before-call
            step failed and its failure setting stops the call
            (`preparation_steps` names the step and what its tool answered),
            `before_declined` for a refusal, `preparation_interrupted` when the
            platform could not finish running the steps (a fault on its side,
            never a tool's answer; no step is sent twice - create a new
            request), `preparation_unavailable` when the steps could not be run
            at all, `promotion_stalled` when the agent's latest settings were
            still not ready 30 s after the request was due (retry shortly) - and
            where it recorded nothing the value is `before_declined` for a
            refusal and `request_failed` for anything else.
        execution:
          $ref: '#/components/schemas/CallExecution'
    CallRequestAccepted:
      type: object
      description: >
        The `202` a browser call request answers when it is accepted (POST
        /web-call/call-requests): the call request as it starts, plus the
        capability and the three browser URLs that follow, cancel and start it.
        The steps have not run yet, and nothing is dialled.
      required:
        - id
        - request_id
        - run_id
        - call_id
        - type
        - channel
        - status
        - preparation_status
        - agent_id
        - accepted_at
        - expires_at
        - start_capability
        - status_url
        - cancel_url
        - start_url
      properties:
        id:
          type: string
          format: uuid
          description: Same value as request_id on this channel.
        request_id:
          type: string
          format: uuid
          description: >-
            Hand it to your server to read the request with GET
            /call-requests/{id}.
        run_id:
          type: string
          format: uuid
        call_id:
          type: 'null'
          description: >-
            Always null here. A browser call has no call record until it is
            started.
        type:
          type: string
          enum:
            - web
        channel:
          type: string
          enum:
            - web
        status:
          type: string
          enum:
            - preparing
            - scheduled
        preparation_status:
          type: string
          enum:
            - pending
        agent_id:
          type: string
          format: uuid
        accepted_at:
          type: string
          format: date-time
        expires_at:
          type: string
          format: date-time
          description: >-
            After this the request is abandoned and the capability stops
            working.
        start_capability:
          type: string
          description: >-
            Returned once, and stored only as a hash. Send it as the
            x-yappr-call-request-key header on the read, the cancel and the
            start.
        status_url:
          type: string
          format: uri
          description: GET it with the capability to follow the steps.
        cancel_url:
          type: string
          format: uri
          description: >-
            POST to it with the capability to stop a request that has not
            started.
        start_url:
          type: string
          format: uri
          description: >-
            POST the browser's SDP offer to it with the capability once the
            request reads ready.
    Error:
      type: object
      required:
        - error
        - code
      description: >
        Every error response - the secret-key API and the browser data plane
        alike - carries a

        human-readable `error` and a stable machine `code`, and a refusal that
        names what is

        wrong with the request carries `issues[]` too. Branch on `code`, never
        on the `error`

        text. A refusal that names nothing more specific carries the code its
        status means:

        `BAD_REQUEST` (400), `UNAUTHORIZED` (401, the browser data plane; the
        secret-key API

        answers `MISSING_KEY`, `INVALID_KEY` or `EXPIRED_KEY`), `BILLING_ERROR`
        (402),

        `FORBIDDEN` (403), `NOT_FOUND` (404), `METHOD_NOT_ALLOWED` (405),
        `CONFLICT` (409),

        `GONE` (410), `PAYLOAD_TOO_LARGE` (413), `UNSUPPORTED_MEDIA_TYPE` (415),

        `UNPROCESSABLE_REQUEST` (422), `RATE_LIMIT` (429), `INTERNAL_ERROR`
        (500),

        `UPSTREAM_ERROR` (502), `SERVICE_UNAVAILABLE` (503), `UPSTREAM_TIMEOUT`
        (504). Some

        refusals add members of their own beside these (a call request's
        `status`, a workflow's

        `current_version`); the operation says which.
      properties:
        error:
          type: string
          description: The refusal, in one sentence for a person. Its wording may change.
        code:
          type: string
          description: The stable code to branch on.
        issues:
          type: array
          description: >
            Each thing at fault, on a 400 or 422 that names them: every query
            parameter or body field, not just the first. `path` is the
            parameter's name or the field's location.
          items:
            type: object
            required:
              - code
              - message
            properties:
              code:
                type: string
                description: >-
                  query_param_unknown, query_param_repeated, query_param_blank,
                  query_param_invalid, field_unknown, field_required,
                  field_invalid, or the route's own word.
              path:
                type: string
              message:
                type: string
    CallExecution:
      type: object
      additionalProperties: false
      description: >
        **Execution history — how the platform carried the call out**, beside
        the

        conversation itself. Returned on `GET /calls/{id}` and `GET
        /call-requests/{id}`

        when execution history is enabled for the workspace; absent otherwise.
        Ask for a

        page of it with the `execution_limit` and `execution_cursor` query
        parameters.


        This is an investigation view, not an authority: it is read-only, it is
        retained

        for a limited window, and it never carries the platform's own plumbing.


        **The members below are the whole of this block.** They are written down

        because the API projects onto exactly this list before the response is
        written:

        anything else the platform knows about a call — delivery row ids,
        internal job

        and journal counts, storage-retention flags, internal hostnames, its own

        diagnostic notes — is dropped rather than published, and every URL here
        is

        rewritten onto the public API base whatever the platform recorded. A
        field you

        do not see below will not appear, and a field you do see will not change
        shape.
      properties:
        version:
          type: string
          const: execution-visibility-v1
        audience:
          type: string
          const: company
          description: >-
            Whose view this is. A company-authorized read is the only one this
            API returns.
        subject:
          type: string
          enum:
            - call
            - tool_test
        run_id:
          type:
            - string
            - 'null'
          format: uuid
          description: Shared lifecycle identity of the request and the call it became.
        request_id:
          type:
            - string
            - 'null'
          format: uuid
        call_id:
          type:
            - string
            - 'null'
          format: uuid
        tool_id:
          type:
            - string
            - 'null'
          format: uuid
          description: Tool tests only.
        test_id:
          type:
            - string
            - 'null'
          format: uuid
          description: Tool tests only.
        workflow_revision_id:
          type:
            - string
            - 'null'
          format: uuid
          description: The published version of the agent this run was frozen on.
        strict:
          type:
            - boolean
            - 'null'
          description: Whether the run was admitted under the agent's strict setting.
        owner:
          type: string
          enum:
            - workflow
            - legacy
          description: >-
            Which authoring model owns the run - `workflow` for a workflow
            agent; `legacy` for a call of an agent that runs no workflow (a
            prompt agent, and every call from before workflows), whose history
            is what the call itself recorded (history.coverage
            legacy_best_effort). Such a call reads execution_status included,
            not none.
        channel:
          type:
            - string
            - 'null'
          enum:
            - phone
            - web
            - null
        direction:
          type:
            - string
            - 'null'
          enum:
            - inbound
            - outbound
            - web
            - null
        refresh_after_ms:
          type:
            - integer
            - 'null'
          description: >-
            How long to wait before asking again while work is still running. On
            GET /calls/{id}, null once the call has settled (summary.is_settled
            true): nothing on it will change.
        supplementary:
          type: string
          enum:
            - complete
            - partial
            - not_loaded
          description: >-
            Whether the conversation-side records beside this block were loaded
            for this response.
        supplementary_errors:
          type: array
          description: >-
            Reason codes for anything the read beside this block could not load.
            Empty when `supplementary` is `complete`.
          items:
            type: string
        links:
          type: object
          additionalProperties: false
          description: >
            Public API URLs for the related records, and the only three link
            members there are. Each one is rewritten onto this API's own base
            before it is published.
          properties:
            request:
              type: string
              format: uri
            call_detail:
              type: string
              format: uri
            tool_test:
              type: string
              format: uri
        summary:
          type: object
          additionalProperties: false
          description: Where the call got to, rolled up.
          properties:
            revision:
              type: string
              description: >-
                Monotonic revision of this snapshot, as a string so a large
                value survives JavaScript.
            as_of:
              type: string
              format: date-time
            run_status:
              type:
                - string
                - 'null'
              enum:
                - accepted
                - materialized
                - cancelled
                - failed
                - completed
                - null
              description: >
                Where the call's run is. `materialized` while its window is open
                - a call's follow-ups can still start until the window closes,
                which is hours after the call is accepted - and `completed` once
                the window has closed and every phase of the run, its post-call
                jobs and its call attempts have ended. A follow-up that failed
                does not make the run `failed`: read that on the follow-up's own
                row. `failed` and `cancelled` mean the call was refused,
                abandoned or cancelled before it ran.
            call_state:
              type: string
            physical_end_observed:
              type:
                - boolean
                - 'null'
              description: >-
                Whether the carrier confirmed the line was down, rather than the
                platform inferring it.
            follow_up_state:
              type: string
              enum:
                - not_started
                - running
                - succeeded
                - failed
                - unknown
                - cancelled
                - unavailable
              description: >-
                On GET /calls/{id}, one word for the call's follow_ups member
                and its trigger timeline rows together: failed, running,
                not_started (follow_ups waiting), cancelled (follow_ups
                skipped), unknown, succeeded - the first that fits. unavailable
                when nothing ran and nothing is explained, and on a call request
                (read the call).
            settlement:
              type: string
              enum:
                - unsettled
                - settled
                - unavailable
            is_settled:
              type:
                - boolean
                - 'null'
              description: >
                On GET /calls/{id}, true (with settlement `settled`) once the
                call has ended, its analysis and cost are final, and nothing of
                its own is still running, waiting or due; a browser session that
                ended before anyone connected reads the same. Stop polling then.
                Null while that cannot be said yet.
            settlement_reasons:
              type: array
              description: Reason codes for an unsettled call.
              items:
                type: string
            counts:
              type: object
              additionalProperties: false
              description: >
                Counts by phase and then by status, for the customer's own work
                only - `invocations` (steps the agent ran) and `attempts` (tries
                those took). Internal platform job and journal counts are not
                included. Phase and status keys are lowercase identifiers and
                the values are whole numbers; a bucket holding no counts is
                omitted rather than sent empty.
              properties:
                invocations:
                  type: object
                  propertyNames:
                    pattern: ^[a-z][a-z_]{0,39}$
                  additionalProperties:
                    type: object
                    propertyNames:
                      pattern: ^[a-z][a-z_]{0,39}$
                    additionalProperties:
                      type: integer
                attempts:
                  type: object
                  propertyNames:
                    pattern: ^[a-z][a-z_]{0,39}$
                  additionalProperties:
                    type: object
                    propertyNames:
                      pattern: ^[a-z][a-z_]{0,39}$
                    additionalProperties:
                      type: integer
            active_work:
              type: array
              description: Work still running or waiting at the moment of this snapshot.
              items:
                type: object
                additionalProperties: false
                properties:
                  id:
                    type: string
                    format: uuid
                  phase:
                    type: string
                    enum:
                      - before
                      - during
                      - after
                      - platform
                  kind:
                    type: string
                  status:
                    type: string
                  reason_code:
                    type:
                      - string
                      - 'null'
                  deadline_at:
                    type:
                      - string
                      - 'null'
                    format: date-time
            active_work_truncated:
              type: boolean
              description: True when more work was running than this list shows.
            latest_problem:
              type:
                - object
                - 'null'
              additionalProperties: false
              description: >-
                The most recent piece of work that failed or was blocked, in the
                same shape as active_work.
              properties:
                id:
                  type: string
                  format: uuid
                phase:
                  type: string
                  enum:
                    - before
                    - during
                    - after
                    - platform
                kind:
                  type: string
                status:
                  type: string
                reason_code:
                  type:
                    - string
                    - 'null'
                deadline_at:
                  type:
                    - string
                    - 'null'
                  format: date-time
            next_deadline_at:
              type:
                - string
                - 'null'
              format: date-time
            artifacts:
              type: array
              description: >-
                Readiness of each thing the call produces - recording,
                transcript, analysis, lead, billing.
              items:
                type: object
                additionalProperties: false
                properties:
                  artifact:
                    type: string
                    enum:
                      - recording
                      - transcript
                      - analysis
                      - lead
                      - billing
                  status:
                    type: string
                    enum:
                      - pending
                      - running
                      - succeeded
                      - empty
                      - skipped
                      - failed
                      - not_expected
                      - unavailable
                  version:
                    type: integer
                  output_revision:
                    type: integer
                  attempts:
                    type: integer
                  deadline_at:
                    type:
                      - string
                      - 'null'
                    format: date-time
                  reason_code:
                    type:
                      - string
                      - 'null'
                    description: >
                      Why the artifact is not `succeeded`. On `GET /calls/{id}`
                      the `analysis` entry agrees with the call's `analysis`
                      member: a pass that left no summary reads `failed` /
                      `no_summary` here too. A `lead` entry that reads `skipped`
                      names why: `web_call_no_phone` (a browser rehearsal has no
                      caller's number), `transcript_too_short` (fewer than two
                      turns) or `no_phone_number`.
        history:
          type: object
          additionalProperties: false
          description: The page of history you were given, and how to get the next one.
          properties:
            high_water_mark:
              type: string
              description: Furthest journal position this snapshot covers, as a string.
            retained_from_sequence:
              type: string
              description: Earliest position still retained, as a string.
            coverage:
              type: string
              enum:
                - canonical
                - legacy_best_effort
            coverage_started_at:
              type:
                - string
                - 'null'
              format: date-time
            complete:
              type: boolean
              description: >-
                True when this page is the whole history: on GET /calls/{id}, a
                settled call with no next_url and nothing expired.
            gaps:
              type: array
              description: >-
                Why this page may not be the whole history. Empty when complete
                is true.
              items:
                type: string
            retained_until:
              type:
                - string
                - 'null'
              format: date-time
            filters:
              type: object
              additionalProperties: false
              description: The filters this page was read under, echoed back.
              properties:
                phase:
                  type:
                    - string
                    - 'null'
                  enum:
                    - before
                    - during
                    - after
                    - platform
                    - null
                kind:
                  type:
                    - string
                    - 'null'
                status:
                  type:
                    - string
                    - 'null'
            limit:
              type: integer
            next_url:
              type:
                - string
                - 'null'
              format: uri
              description: Next page, on the public API base. Null on the last page.
            refresh_url:
              type: string
              format: uri
              description: This same page again, on the public API base.
        items:
          type: array
          description: >
            The time-ordered rows themselves - one per step, attempt, phase
            boundary or platform event the call produced. `sequence` is a string
            so a large journal position survives JavaScript. `input` and
            `output` are bounded, redacted previews of the customer's own
            evidence, never raw credentials.
          items:
            type: object
            additionalProperties: false
            properties:
              id:
                type: string
                format: uuid
              sequence:
                type: string
                description: >-
                  Journal position, as a string so a large value survives
                  JavaScript.
              phase:
                type: string
                enum:
                  - before
                  - during
                  - after
                  - platform
              kind:
                type: string
              event:
                type: string
              status:
                type:
                  - string
                  - 'null'
              call_id:
                type:
                  - string
                  - 'null'
                format: uuid
              request_id:
                type:
                  - string
                  - 'null'
                format: uuid
              phase_id:
                type:
                  - string
                  - 'null'
                format: uuid
              invocation_id:
                type:
                  - string
                  - 'null'
                format: uuid
              attempt_id:
                type:
                  - string
                  - 'null'
                format: uuid
              receipt_id:
                type:
                  - string
                  - 'null'
                format: uuid
              attempt_number:
                type:
                  - integer
                  - 'null'
              outer_run:
                type:
                  - integer
                  - 'null'
              inner_attempt:
                type:
                  - integer
                  - 'null'
              reason_code:
                type:
                  - string
                  - 'null'
              late:
                type: boolean
                description: >-
                  True when the row arrived after the page it belongs to was
                  already read.
              selected:
                type:
                  - boolean
                  - 'null'
              should_execute:
                type:
                  - boolean
                  - 'null'
              edges_truncated:
                type: boolean
              action:
                type:
                  - object
                  - 'null'
                additionalProperties: false
                description: The step this row is about, where it is one.
                properties:
                  name:
                    type: string
                  type:
                    type: string
                    enum:
                      - http
                      - app
                      - sequence
                      - end_call
                      - transfer
                      - platform
                  binding_id:
                    type:
                      - string
                      - 'null'
                    format: uuid
                  activation:
                    type:
                      - string
                      - 'null'
                  tool_id:
                    type:
                      - string
                      - 'null'
                    format: uuid
                  tool_revision_id:
                    type:
                      - string
                      - 'null'
                    format: uuid
                  schema_version:
                    type:
                      - string
                      - 'null'
                  adapter_version:
                    type:
                      - string
                      - 'null'
                  compatibility_version:
                    type:
                      - string
                      - 'null'
                  connection_id:
                    type:
                      - string
                      - 'null'
                    format: uuid
                  connection_label:
                    type:
                      - string
                      - 'null'
                  connection_generation:
                    type:
                      - integer
                      - 'null'
              field_errors:
                type: array
                description: Validation failures, by path into the step's own input.
                items:
                  type: object
                  additionalProperties: false
                  properties:
                    path:
                      type: string
                    code:
                      type: string
              edges:
                type: array
                description: >
                  Links to other rows of this same block. Only edges pointing at
                  something you can read here are included - an invocation, a
                  phase, or an artifact.
                items:
                  type: object
                  additionalProperties: false
                  properties:
                    relation:
                      type: string
                      enum:
                        - parent
                        - depends_on
                        - triggered_by
                        - replay_of
                        - receipt_for
                    kind:
                      type: string
                      enum:
                        - invocation
                        - phase
                        - artifact
                    id:
                      type: string
                      format: uuid
              timing:
                type: object
                additionalProperties: false
                properties:
                  occurred_at:
                    type:
                      - string
                      - 'null'
                    format: date-time
                  recorded_at:
                    type: string
                    format: date-time
                  queued_at:
                    type:
                      - string
                      - 'null'
                    format: date-time
                  claimed_at:
                    type:
                      - string
                      - 'null'
                    format: date-time
                  dispatched_at:
                    type:
                      - string
                      - 'null'
                    format: date-time
                    description: When the request actually left, never a claim timestamp.
                  completed_at:
                    type:
                      - string
                      - 'null'
                    format: date-time
                  queue_ms:
                    type:
                      - integer
                      - 'null'
                  validation_ms:
                    type:
                      - integer
                      - 'null'
                  network_ms:
                    type:
                      - integer
                      - 'null'
                  total_ms:
                    type:
                      - integer
                      - 'null'
                  audio_offset_ms:
                    type:
                      - integer
                      - 'null'
                    description: Where in the recording this happened, where that is known.
                  audio_clock_id:
                    type:
                      - string
                      - 'null'
              retry:
                type: object
                additionalProperties: false
                properties:
                  eligibility:
                    type: string
                    enum:
                      - not_eligible
                      - automatic
                      - manual
                      - unknown
                  reason_code:
                    type:
                      - string
                      - 'null'
                  next_at:
                    type:
                      - string
                      - 'null'
                    format: date-time
                  automatic_recovery_stopped:
                    type: boolean
              input:
                type: object
                additionalProperties: false
                description: Bounded, redacted preview of what went into the step.
                properties:
                  value:
                    description: >-
                      The preview itself - any JSON, exactly as the platform
                      recorded it, or null when there is none.
                  availability:
                    type: string
                    enum:
                      - available
                      - not_applicable
                      - unavailable
                  unavailable_reason:
                    type:
                      - string
                      - 'null'
                  redacted:
                    type: boolean
                  truncated:
                    type: boolean
                  omitted:
                    type: array
                    description: What was left out of the preview, and why.
                    items:
                      type: object
                      additionalProperties: false
                      properties:
                        path:
                          type: string
                        reason:
                          type: string
                          enum:
                            - configured_sensitive
                            - credential
                            - private_reference
                            - diagnostic
                            - secret_value
                            - url
                            - depth_limit
                            - byte_limit
                            - node_limit
                            - item_limit
                            - string_limit
                            - unavailable
                  omitted_metadata_truncated:
                    type: boolean
                  expanded:
                    type: boolean
              output:
                type: object
                additionalProperties: false
                description: Bounded, redacted preview of what the step returned.
                properties:
                  value:
                    description: >-
                      The preview itself - any JSON, exactly as the platform
                      recorded it, or null when there is none.
                  availability:
                    type: string
                    enum:
                      - available
                      - not_applicable
                      - unavailable
                  unavailable_reason:
                    type:
                      - string
                      - 'null'
                  redacted:
                    type: boolean
                  truncated:
                    type: boolean
                  omitted:
                    type: array
                    description: What was left out of the preview, and why.
                    items:
                      type: object
                      additionalProperties: false
                      properties:
                        path:
                          type: string
                        reason:
                          type: string
                          enum:
                            - configured_sensitive
                            - credential
                            - private_reference
                            - diagnostic
                            - secret_value
                            - url
                            - depth_limit
                            - byte_limit
                            - node_limit
                            - item_limit
                            - string_limit
                            - unavailable
                  omitted_metadata_truncated:
                    type: boolean
                  expanded:
                    type: boolean
              expansion_url:
                type:
                  - string
                  - 'null'
                format: uri
                description: >-
                  This row on its own, with fuller previews. On the public API
                  base.
  securitySchemes:
    apiKey:
      type: http
      scheme: bearer
      bearerFormat: API Key
      description: >-
        Your Yappr API key (e.g. `ypr_live_...`). Generate one in the dashboard
        under **Settings → API Keys**. No key is `401 MISSING_KEY`; a key that
        is not one of ours, or is revoked, is `401 INVALID_KEY`; an expired one
        is `401 EXPIRED_KEY`. A valid key without the scope an operation needs
        is `403 INSUFFICIENT_SCOPE` on every operation, and the message names
        the scope. Every response, a 401 included, carries X-RateLimit-Limit,
        X-RateLimit-Remaining and X-RateLimit-Reset: the budget is 60 requests a
        minute per API key. Every 429, whatever its code, carries Retry-After
        (whole seconds, never zero): the per-key budget's `RATE_LIMIT` asks for
        what is left of the minute, a route's daily cap (`RATE_LIMITED`) for the
        time until that cap resets. All four headers are listed in
        Access-Control-Expose-Headers, so a browser can read them. A path the
        API does not serve (an unknown sub-path, an id left empty) is `404
        ROUTE_NOT_FOUND`, and a method a served path does not take is `405
        METHOD_NOT_ALLOWED` with an `Allow` header; both are answered before any
        scope check, and nothing is read or changed. A trailing slash is ignored
        where it cannot be an id left empty (`POST /calls/` is `POST /calls`)
        and refused where it can (`GET /calls/`). A doubled slash inside a path
        is merged into one before the request reaches the API (`GET //calls` is
        `GET /calls`).

````

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