wait_generation
Wait for a generation to finish (long-poll up to wait_seconds, then returns current status). Call repeatedly until status is COMPLETED, FAILED or CANCELED. Returns output URLs (and an inline image preview) when done.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"request_id": "<request_id>"
},
"name": "wait_generation"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| request_id | Yes | ||
| wait_seconds | No | ||
| include_preview | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| error | No | ||
| model | Yes | ||
| stage | Yes | ||
| output | Yes | ||
| status | Yes | ||
| version | Yes | ||
| progress | Yes | ||
| snapshot | Yes | ||
| terminal | Yes | ||
| warnings | No | Execution notices for this request. Absent when there are none. Example: code "audio_dropped" — the audio track did not pass the safety check of the model, so the video has no sound; the price is unchanged. Skip codes you do not know. | |
| next_step | No | ||
| created_at | Yes | ||
| media_kind | Yes | ||
| request_id | Yes | ||
| completed_at | Yes | ||
| cost_credits | No | ||
| next_poll_ms | Yes | ||
| schema_version | Yes |