All requests below will use this key. Your API key is sent directly to api.cueapi.ai and never stored by the docs site.
POST
/v1/executions/{execution_id}/claimClaim Execution
Claim a pending worker execution for processing. Only one worker can claim each execution.
execution_idstringrequiredpathThe execution UUID.
worker_idstringdefault: anonymous-workerbodyYour worker's identifier. Used for tracking which worker processed the execution.
Request
bash
curl -X POST https://api.cueapi.ai/v1/executions/550e8400-e29b-41d4-a716-446655440000/claim \
-H "Authorization: Bearer cue_sk_YOUR_KEY" \
-H "Content-Type: application/json" \
-d '{"worker_id": "my-laptop"}'Response
json
{
"claimed": true,
"execution_id": "550e8400-e29b-41d4-a716-446655440000",
"payload": {
"task": "draft-linkedin",
"kind": "agent_turn",
"instruction": "Draft a LinkedIn post"
}
}json
{
"error": {
"code": "already_claimed",
"message": "Execution already claimed or not pending",
"status": 409
}
}POST
Try it/v1/executions/{execution_id}/claimReplace path parameters (e.g. {cue_id}) in the URL before sending.
Request Body
Enter your API key above to send requests