---
title: "Quote a task before reserving funds"
method: POST
path: "/api/v1/jobs/quote"
tags: ["Tasks"]
---

# Quote a task before reserving funds

`POST /api/v1/jobs/quote`

## Request

- Base URL: `https://api.popnow.ai`
- URL: `https://api.popnow.ai/api/v1/jobs/quote`
- Auth: HTTP bearer

Validates the same model input and admission rules as task creation,
without creating a task, reserving credits or starting generation.
The signed quote is bound to this account, API key and request and is
valid for five minutes. Pass `quoteId` and `expectedCredits` (or `expectedCost`) with the same request to
createTask to make sure the price you showed is the price that is held. New acceptance rejects an expired
or changed quote with business code 40901. A replay of an already
accepted Idempotency-Key still returns the original task.
A quote does not reserve capacity or guarantee future availability.

## Request body

- CreateTaskRequest
  - `model` 'alibaba/happyhorse-1.1/image-to-video' | 'alibaba/happyhorse-1.1/reference-to-video' | 'alibaba/happyhorse-1.1/text-to-video' | 'alibaba/qwen-3-tts/text-to-speech' | 'alibaba/qwen-image-1.0-lora/edit' | 'alibaba/qwen-image-1.0-lora/text-to-image' | 'alibaba/qwen-image-2.1-lora/edit' | 'alibaba/qwen-image-2.1-lora/text-to-image' | 'alibaba/qwen-image-2.1-pro/edit' | 'alibaba/qwen-image-2.1-pro/text-to-image' | 'alibaba/qwen-image-2.1-turbo/edit' | 'alibaba/qwen-image-2.1-turbo/text-to-image' | 'alibaba/qwen-image-2.1/edit' | 'alibaba/qwen-image-2.1/text-to-image' | 'alibaba/qwen-image-2/edit' | 'alibaba/qwen-image-2/text-to-image' | 'alibaba/qwen-image-2512-lora/edit' | 'alibaba/qwen-image-2512-lora/text-to-image' | 'alibaba/qwen-image-3.0-pro/edit' | 'alibaba/qwen-image-3.0-pro/text-to-image' | 'alibaba/qwen-image-3.0/edit' | 'alibaba/qwen-image-3.0/text-to-image' | 'alibaba/qwen-image-edit-2509-lora/edit' | 'alibaba/wan-2.1-image-lora/edit' | 'alibaba/wan-2.1-image-lora/text-to-image' | 'alibaba/wan-2.1-lora/image-to-video' | 'alibaba/wan-2.1-lora/text-to-video' | 'alibaba/wan-2.1-lora/video-edit' | 'alibaba/wan-2.2-5b-lora/image-to-video' | 'alibaba/wan-2.2-5b-lora/text-to-video' | 'alibaba/wan-2.2-animate/character-animation' | 'alibaba/wan-2.2-image-lora/text-to-image' | 'alibaba/wan-2.2-lora/image-to-video' | 'alibaba/wan-2.2-lora/text-to-video' | 'alibaba/wan-2.2-lora/video-extend' | 'alibaba/wan-2.2/image-to-video' | 'alibaba/wan-2.2/text-to-video' | 'alibaba/wan-2.5/image-to-video' | 'alibaba/wan-2.5/text-to-video' | 'alibaba/wan-2.5/video-extend' | 'alibaba/wan-2.6-flash/image-to-video' | 'alibaba/wan-2.6-flash/reference-to-video' | 'alibaba/wan-2.6/image-to-video' | 'alibaba/wan-2.6/reference-to-video' | 'alibaba/wan-2.6/text-to-video' | 'alibaba/wan-2.7-pro/edit' | 'alibaba/wan-2.7-pro/text-to-image' | 'alibaba/wan-2.7/edit' | 'alibaba/wan-2.7/text-to-image' | 'alibaba/wan-3.0-prime/image-to-video' | 'alibaba/wan-3.0-prime/reference-to-video' | 'alibaba/wan-3.0-prime/text-to-video' | 'alibaba/wan-3.0-prime/video-extend' | 'alibaba/wan-3.0-pro-prime/image-to-video' | 'alibaba/wan-3.0-pro-prime/reference-to-video' | 'alibaba/wan-3.0-pro-prime/text-to-video' | 'alibaba/wan-3.0-pro-prime/video-extend' | 'alibaba/wan-3.0-pro/image-to-video' | 'alibaba/wan-3.0-pro/reference-to-video' | 'alibaba/wan-3.0-pro/text-to-video' | 'alibaba/wan-3.0-pro/video-extend' | 'alibaba/wan-3.0/image-to-video' | 'alibaba/wan-3.0/reference-to-video' | 'alibaba/wan-3.0/text-to-video' | 'alibaba/wan-3.0/video-extend' | 'alibaba/z-image-base-lora/edit' | 'alibaba/z-image-base-lora/text-to-image' | 'alibaba/z-image-turbo-lora/edit' | 'alibaba/z-image-turbo-lora/text-to-image' | 'alibaba/z-image-turbo/text-to-image' | 'black-forest-labs/flux-1-dev-controlnet-lora/text-to-image' | 'black-forest-labs/flux-1-dev-lora/edit' | 'black-forest-labs/flux-1-dev-lora/text-to-image' | 'black-forest-labs/flux-1-fill-dev-lora/edit' | 'black-forest-labs/flux-1-krea-dev-lora/edit' | 'black-forest-labs/flux-1-krea-dev-lora/text-to-image' | 'black-forest-labs/flux-1-schnell-lora/edit' | 'black-forest-labs/flux-1-schnell-lora/text-to-image' | 'black-forest-labs/flux-2-dev-lora/edit' | 'black-forest-labs/flux-2-dev-lora/text-to-image' | 'black-forest-labs/flux-2-dev/edit' | 'black-forest-labs/flux-2-dev/text-to-image' | 'black-forest-labs/flux-2-flex/edit' | 'black-forest-labs/flux-2-flex/text-to-image' | 'black-forest-labs/flux-2-klein-4b-lora/edit' | 'black-forest-labs/flux-2-klein-4b-lora/text-to-image' | 'black-forest-labs/flux-2-klein-4b/edit' | 'black-forest-labs/flux-2-klein-4b/text-to-image' | 'black-forest-labs/flux-2-klein-9b-lora/edit' | 'black-forest-labs/flux-2-klein-9b-lora/text-to-image' | 'black-forest-labs/flux-2-klein-9b/edit' | 'black-forest-labs/flux-2-klein-9b/text-to-image' | 'black-forest-labs/flux-2-klein-base-4b-lora/edit' | 'black-forest-labs/flux-2-klein-base-4b-lora/text-to-image' | 'black-forest-labs/flux-2-klein-base-9b-lora/edit' | 'black-forest-labs/flux-2-klein-base-9b-lora/text-to-image' | 'black-forest-labs/flux-2-max/edit' | 'black-forest-labs/flux-2-max/text-to-image' | 'black-forest-labs/flux-2-pro/edit' | 'black-forest-labs/flux-2-pro/text-to-image' | 'black-forest-labs/flux-3-klein-base-lora/edit' | 'black-forest-labs/flux-3-klein-base-lora/text-to-image' | 'black-forest-labs/flux-3-klein-base/edit' | 'black-forest-labs/flux-3-klein-base/text-to-image' | 'black-forest-labs/flux-3/image-to-video' | 'black-forest-labs/flux-3/text-to-video' | 'black-forest-labs/flux-3/upscale' | 'black-forest-labs/flux-3/video-extend' | 'bytedance/seed-audio-1.0/text-to-audio' | 'bytedance/seed-speech-2.0/text-to-speech' | 'bytedance/seedance-1.5-pro/image-to-video' | 'bytedance/seedance-1.5-pro/text-to-video' | 'bytedance/seedance-1.5-pro/video-extend' | 'bytedance/seedance-2.0-fast/image-to-video' | 'bytedance/seedance-2.0-fast/reference-to-video' | 'bytedance/seedance-2.0-fast/text-to-video' | 'bytedance/seedance-2.0-fast/video-extend' | 'bytedance/seedance-2.0-mini/image-to-video' | 'bytedance/seedance-2.0-mini/reference-to-video' | 'bytedance/seedance-2.0-mini/text-to-video' | 'bytedance/seedance-2.0-mini/video-extend' | 'bytedance/seedance-2.0/image-to-video' | 'bytedance/seedance-2.0/reference-to-video' | 'bytedance/seedance-2.0/text-to-video' | 'bytedance/seedance-2.0/video-extend' | 'bytedance/seedance-2.5/image-to-video' | 'bytedance/seedance-2.5/reference-to-video' | 'bytedance/seedance-2.5/text-to-video' | 'bytedance/seedance-2.5/video-extend' | 'bytedance/seedream-4.0/edit' | 'bytedance/seedream-4.0/text-to-image' | 'bytedance/seedream-5.0-flash/edit' | 'bytedance/seedream-5.0-flash/layer-decomposition' | 'bytedance/seedream-5.0-flash/text-to-image' | 'bytedance/seedream-5.0-lite/edit' | 'bytedance/seedream-5.0-lite/text-to-image' | 'bytedance/seedream-5.0-pro/edit' | 'bytedance/seedream-5.0-pro/layer-decomposition' | 'bytedance/seedream-5.0-pro/text-to-image' | 'circlestone-labs/anima-turbo-lora/edit' | 'circlestone-labs/anima-turbo-lora/text-to-image' | 'circlestone-labs/anima-turbo/edit' | 'circlestone-labs/anima-turbo/text-to-image' | 'google/gemini-2.5-pro-tts/text-to-speech' | 'google/gemini-3.8-flash-lite-tts/text-to-speech' | 'google/gemini-3.8-flash-tts/text-to-speech' | 'google/nano-banana-2.1/edit' | 'google/nano-banana-2.1/text-to-image' | 'google/nano-banana-2/edit' | 'google/nano-banana-2/text-to-image' | 'google/nano-banana-pro/edit' | 'google/nano-banana-pro/text-to-image' | 'heartmula/transcribe/speech-to-text' | 'j1b/jib-mix-qwen-image-lora/text-to-image' | 'j1b/jib-mix-qwen-image/text-to-image' | 'kling/2.1-master/image-to-video' | 'kling/2.1-master/text-to-video' | 'kling/2.1/image-to-video' | 'kling/2.5-turbo/image-to-video' | 'kling/2.5-turbo/text-to-video' | 'kling/2.6/character-animation' | 'kling/2.6/image-to-video' | 'kling/2.6/text-to-video' | 'kling/3.0-turbo/image-to-video' | 'kling/3.0-turbo/text-to-video' | 'kling/3.0/character-animation' | 'kling/3.0/image-to-video' | 'kling/3.0/text-to-video' | 'kling/4.0/image-to-video' | 'kling/4.0/reference-to-video' | 'kling/4.0/text-to-video' | 'kling/o3/image-to-video' | 'kling/o3/reference-to-video' | 'kling/o3/text-to-video' | 'kling/o3/video-edit' | 'krea/2-large/text-to-image' | 'krea/2-medium-turbo/text-to-image' | 'krea/2-medium/text-to-image' | 'krea/2-turbo-lora/edit' | 'krea/2-turbo-lora/text-to-image' | 'krea/3/edit' | 'krea/3/text-to-image' | 'lightricks/ltx-2-19b-lora/image-to-video' | 'lightricks/ltx-2-19b-lora/text-to-video' | 'lightricks/ltx-2-19b/image-to-video' | 'lightricks/ltx-2-19b/text-to-video' | 'lightricks/ltx-2-19b/video-extend' | 'lightricks/ltx-2.3-lora/image-to-video' | 'lightricks/ltx-2.3-lora/text-to-video' | 'lightricks/ltx-2.5/image-to-video' | 'lightricks/ltx-2.5/text-to-video' | 'minimax/h3-360-orbit/image-to-video' | 'minimax/h3-image-lora/edit' | 'minimax/h3-image-lora/text-to-image' | 'minimax/h3-lora/image-to-video' | 'minimax/h3-lora/reference-to-video' | 'minimax/h3-lora/text-to-video' | 'minimax/h3-lora/video-extend' | 'minimax/h3-max/image-to-video' | 'minimax/h3-max/text-to-video' | 'minimax/h3-max/video-extend' | 'minimax/h3-singularity-lora/image-to-video' | 'minimax/h3-singularity-lora/reference-to-video' | 'minimax/h3-singularity-lora/video-extend' | 'minimax/h3/image-to-video' | 'minimax/h3/reference-to-video' | 'minimax/h3/text-to-video' | 'minimax/h3/video-extend' | 'minimax/music-3.0/text-to-audio' | 'minimax/speech-2.8-hd/text-to-speech' | 'minimax/speech-2.8-turbo/text-to-speech' | 'neta-art/neta-lumina/text-to-image' | 'openai/gpt-image-2.5-flare/edit' | 'openai/gpt-image-2.5-flare/text-to-image' | 'openai/gpt-image-2.5-sunburst/edit' | 'openai/gpt-image-2.5-sunburst/text-to-image' | 'openai/gpt-image-2/edit' | 'openai/gpt-image-2/text-to-image' | 'popnow/anime-to-real-v1/edit' | 'popnow/background-remover-v1/edit' | 'popnow/camera-angle-changer-v1/edit' | 'popnow/foley-v1/video-to-audio' | 'popnow/image-expander-v1/edit' | 'popnow/image-upscaler-v1/upscale' | 'popnow/object-eraser-v1/edit' | 'popnow/pose-changer-v1/edit' | 'popnow/relight-v1/edit' | 'popnow/shadow-remover-v1/edit' | 'popnow/video-upscaler-v1/upscale' | 'prefect/pony-xl-lora/text-to-image' | 'prefect/pony-xl/text-to-image' | 'pruna-ai/p-image-lora/edit' | 'pruna-ai/p-image-lora/text-to-image' | 'resemble-ai/chatterbox-v1/text-to-speech' | 'suno/v6-mini/text-to-audio' | 'suno/v6-wild/text-to-audio' | 'suno/v6/text-to-audio' | 'tencent/hunyuan-video-1.5/image-to-video' | 'tencent/hunyuan-video-1.5/text-to-video' | 'vidu/q3-pro/image-to-video' | 'vidu/q3-turbo/image-to-video' | 'vidu/q3-turbo/video-extend' | 'vidu/q3/image-to-video' | 'vidu/q4-preview/image-to-video' | 'vidu/q4-preview/reference-to-video' | 'vidu/q4-preview/video-extend' | 'xai/grok-stt/speech-to-text' | 'xai/grok-tts/text-to-speech', required: Model call name, `<publisher>/<model>/<task>` (for example `alibaba/wan-3.0/image-to-video`). The list below is the catalog at generation time; `GET /api/v1/models` is the live source.
  - `input` object, required: Validated against the selected model's inputSchema (`GET /api/v1/models/{model}`). Declared media fields accept public HTTPS URLs, committed popnow://f/<id> file URIs (common/upload-url, then the file commit endpoint), saved assets as popnow://a/<id> in the media field of the matching kind (the asset must be in the library of the key's workspace; any other asset gets the same rejection as an unknown id), or standard Base64 Data URIs (image/jpeg, image/png, image/webp, image/gif). Inline images are limited to 1048576 decoded bytes and 8388608 pixels each, 8192 pixels per side, and 16 images / 16777216 pixels in total. The complete JSON request must fit within 2097152 bytes. Model-specific limits still apply. Bare Base64, SVG and inline audio/video are not accepted; use HTTPS or file uploads instead. Inline images are stored as account-bound uploaded files; returned input contains file URIs, never the original Base64 bytes. Quote validation does not upload or reserve credits. If the model's inputSchema declares `seed` and you omit it, we pick a random seed for this task, so two identical requests do not come back with the same output. The chosen seed is returned in the task's `input`; pass it back to hold the draw steady (a fixed seed keeps runs comparable, it does not guarantee an identical result). A `seed` you send yourself is always used as given.
  - `callBackUrl` string, uri: Optional public HTTPS endpoint for terminal task delivery. `http://` URLs are rejected: the delivery carries the prompt and signed result links. Explicit ports other than 443 and 80 are rejected, and URL credentials are rejected. The hostname must resolve to public IP addresses and is checked again when connecting. Invalid values return HTTP 400 with code 400, msg "Invalid callback URL", and request_id.
  - `quoteId` string: Signed quote returned by jobs/quote for this same account, API key and request. Does not replace Idempotency-Key.
  - `expectedCost` string: Decimal USD amount encoded as a string to avoid binary floating-point loss.
  - `expectedCredits` integer: Confirmed number of credits to reserve, as returned in `maxCredits` by jobs/quote. 1 credit = $0.001. Send this or `expectedCost` (the same amount in USD); when both are sent, `expectedCredits` wins. A changed price returns business code 40901 before anything is reserved.

## Response `200`

Customer price and maximum charge; no funds were reserved.

- TaskQuoteEnvelope
  - `code` integer, required
  - `msg` string, required
  - `request_id` string, required: Correlation identifier. Include it in support requests.
  - `data` TaskQuoteResponse, required
    - `quoteId` string, required
    - `model` string, required: Resolved endpoint model identifier.
    - `estimatedCost` string, required: Decimal USD amount encoded as a string to avoid binary floating-point loss.
    - `maxCharge` string, required: Decimal USD amount encoded as a string to avoid binary floating-point loss.
    - `maxCredits` integer, required: The most this request can cost, in credits (1 credit = $0.001). This amount is held when the task is accepted; it equals `maxCharge`.
    - `expectedCredits` integer, required: What this request usually costs, in credits. Equal to `maxCredits` unless the final charge depends on the output (for example its real duration); you are never charged more than `maxCredits`.
    - `currency` 'USD', required
    - `quantity` string, required: Estimated billable quantity.
    - `unit` string, required
    - `expiresAt` string, date-time, required

## Other responses

- `400`: Invalid JSON, query, callback URL, model input, or media declaration. Invalid callBackUrl values return code 400 and msg "Invalid callback URL" with request_id. Submitted hosts, IP addresses, and DNS diagnostics are not echoed.
- `401`: Missing, malformed, expired, revoked, or otherwise invalid API key.
- `402`: Insufficient balance (`40201`) or a spend cap was reached (`40202`).
- `403`: Account, model, API-key, IP, or region authorization failed.
- `409`: Idempotency or media-transfer state conflicts with this request.
- `429`: Account-level request limit exceeded.
- `503`: HTTP 503 carries one of three business codes. `50301`: no usable deployment or effective customer price exists for the selected model. `503`: a dependency is temporarily unavailable; retry after the `Retry-After` header when it is present. `50302`: a synchronous generation failed upstream and the charge was refunded. Nothing was charged, but send the retry with a **new** `Idempotency-Key`: reusing the original one replays the recorded failure instead of generating again.

## Changes

- **2026-10-20** `fede911a6e9b`: 84 warning
  - added the new `agent_project_budget` enum value to the `allOf[subschema #2]/data/reason` response property for the response status `400`
  - added the new `agent_project_budget` enum value to the `allOf[subschema #2]/data/reason` response property for the response status `401`
  - added the new `agent_project_budget` enum value to the `allOf[subschema #2]/data/reason` response property for the response status `402`
  - added the new `agent_project_budget` enum value to the `allOf[subschema #2]/data/reason` response property for the response status `403`
  - …80 more

[Operation history](https://skmtc.dev/popnow/apis/popnow-api/changes/api/v1/jobs/quote/post.md)

---

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