Wait for jobs
wait_jobsWait until a job or batch finishes instead of checking repeatedly: returns as soon as any (or all) of the given jobs/batches are done, or after timeout_s (max 60) with done=false.
Tool call template
This tool declares no required parameters. Add optional parameters from the input schema as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {},
"name": "wait_jobs"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| until | No | any (default): return when the first one finishes; all: when all finished. | |
| job_ids | No | Job IDs to wait for. | |
| batch_ids | No | Batch IDs to wait for (done when all their jobs ended). | |
| timeout_s | No | How long to wait in seconds (default 30, max 60). |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| done | Yes | The wait condition was met (otherwise the time ran out). | |
| next | No | What to do if nothing has finished yet. | |
| items | Yes | State of each job/batch. | |
| total | Yes | How many jobs/batches were given. | |
| finished | No | How many of the given jobs/batches have ended. |