Claim agent queue job
claim_agent_queue_jobClaim the next pending job using the worker token. Returns job:null immediately when no work is available, otherwise a job containing a new secret receipt. Visibility defaults to 60 seconds and accepts 30-900 seconds. Redelivery is possible: make worker side effects idempotent. Jobs fail after 5 unsuccessful claims. No job is executed by the server.
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": {
"queue_id": "<queue_id>",
"worker_token": "<worker_token>"
},
"name": "claim_agent_queue_job"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| queue_id | Yes | The queue_id from create_agent_queue, or from create_agent_run for a run with delegated steps. | |
| worker_token | Yes | The worker_token from create_agent_queue or create_agent_run, shown once. It claims jobs and acknowledges, renews or releases them. | |
| visibility_timeout | No | Claim visibility in seconds, capped by the fixed queue expiry. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| ok | Yes | ||
| job | Yes | ||
| queue_id | Yes | ||
| expire_timestamp | Yes |