---
title: "Poll a short bought with an x402 payment, or read the menu"
method: GET
path: "/api/x402/short"
---

# Poll a short bought with an x402 payment, or read the menu

`GET /api/x402/short`

## Request

- Base URL: `https://www.trezalabs.com`
- URL: `https://www.trezalabs.com/api/x402/short`
- Auth: HTTP bearer

Called with no query parameters, returns the menu. With runId and token (the statusUrl the paid POST handed back), returns the run's status and, once finished, video with outputs.title and outputs.description. Send Prefer: wait=N to hold the answer until it finishes, for up to N seconds (at most 720).

## Query parameters

- `runId` string
- `token` string

## Headers

- `Prefer` string

## Response `200`

Run status plus video once finished; or, with no query parameters, the menu.

- union
  - object
    - `runId` string, required
    - `status` 'success' | 'error' | 'partial' | 'cancelled' | 'running', required: success carries video. error, partial, and cancelled carry the failure fields. running means the short is still rendering; poll statusUrl.
    - `video` string, uri: URL of the finished short (MP4, 9:16). Use it exactly as given.
    - `outputs` object
      - `video` string, uri
      - `title` string
      - `description` string: Two sentences and hashtags, ready to post.
    - `statusUrl` string, uri
    - `pollAfterMs` integer
    - `paidUsd` number
    - `style` string
    - `voice` string
    - `network` string
    - `transaction` string
    - `payer` string
    - `error` string
    - `reason` 'prompt_refused' | 'render_failed'
    - `retryable` boolean
    - `retryUrl` string, uri: Failed runs only. POST with no body to finish the short: steps that succeeded are reused, only what failed re-renders. With {"topic": "..."} it starts over (at the full price, from the balance).
    - `message` string: Failed runs only. What happened, what the steps that ran were charged, and what to do.
  - object: Returned when the GET carries no query parameters: what is on sale, the prices, and how to buy.
    - `service` string, required
    - `description` string
    - `howToBuy` object, required: The request to send: method, an example body, and how payment works.
      - `method` string
      - `body` object
      - `note` string
    - `fields` object, required: Each request field and what it takes.
    - `styles` object[]
      - `id` string
      - `default` boolean
      - `priceUsd` number
    - `limits` object: maxTopicChars, durationSeconds {min, max}, and aspectRatio.
    - `delivery` string: How the paid call answers and where the file ends up.
    - `alreadyPaid` string: Where a file already paid for can be collected, for a buyer that lost its statusUrl.

## Other responses

- `400`: One of runId and token was given without the other.
- `403`: Invalid, expired, or mismatched token
- `404`: Run not found

---

[API](https://skmtc.dev/trezalabs/apis/treza-pipelines-api.md) · [All operations](https://skmtc.dev/trezalabs/apis/treza-pipelines-api/llms.txt) · [OpenAPI document](https://skmtc.dev/trezalabs/apis/treza-pipelines-api/revisions/a76574c1731b?raw)
