Agentic jobs. Sealed artifacts. Terminal proof.
Queue is TaskQ's asynchronous execution plane for work that should not pretend to be a chat response: code edits, reports, file deliverables, multi-step analysis, patches, and long-running agent execution. The Gateway still owns auth, policy, placement, proof, usage, and settlement.
Submit a Queue job.
Queue requests are still submitted through the public Gateway. The customer bearer is checked first, then credential handle, policy, balance, eligible capacity, worker lease, and proof entry.
curl https://api.taskq.xyz/q/submit \ -H "authorization: Bearer $TASKQ_API_KEY" \ -H "x-taskq-credential: cred_prod_anthropic_ca" \ -d '{ "task_type": "code_patch", "provider": "anthropic", "model": "claude-sonnet-4-5", "policy": { "must_run_in": ["CA"], "must_not_run_in": ["US"], "worker_trust_floor": "audited", "key_custody": ["pinned","enclave","customer_owned"] }, "input": { "repo_ref": "artifact:repo_bundle_01", "instructions": "Patch the API client and return a diff." } }'
Receive a job object, not fake completion.
Queue returns a job ID, lease reference, request ID, and proof lookup surface. A job is not complete until it reaches a terminal state. "Failed-but-complete" is forbidden.
{
"job_id": "job_01J...",
"request_id": "req_01J...",
"status": "leased",
"lease_id": "lease_01J...",
"worker_ref": "worker_blind:...",
"chain_key": "sha256:...",
"status_url": "/q/thread/job_01J..."
}Every Queue job moves through explicit states.
Billing, artifacts, proof closure, and settlement depend on the terminal state.
Accepted
Gateway accepted the request. No worker has taken the lease yet.
Slot reserved
A compliant worker slot is reserved with a TTL and lease ID.
Execution active
The worker is performing the job and may emit signed checkpoints.
Artifact sealed
Output is content-addressed, hash-recorded, and linked to the chain.
Terminal failure
Failure is explicit. It is not marked complete, and blind retry rules do not hide it.
Refused with proof
If no compliant capacity exists, Queue writes prevention evidence instead of falling back.
The thread endpoint returns state, checkpoints, proof references, and artifact IDs.
curl https://api.taskq.xyz/q/thread/job_01J... \ -H "authorization: Bearer $TASKQ_API_KEY"
{
"job_id": "job_01J...",
"status": "running",
"checkpoint_count": 4,
"placement_proof": "proof_...",
"chain_key": "sha256:...",
"artifacts": []
}Retrieve sealed artifacts.
Artifacts are content-addressed, hash-recorded, retention-policy controlled, optionally encrypted under the customer key domain, and exportable with the chain segment.
curl https://api.taskq.xyz/q/artifacts/art_01J... \ -H "authorization: Bearer $TASKQ_API_KEY" \ -o taskq-output.bundle
Sealed — content hash required
A successful job must point to valid output metadata and artifact hashes.
Exportable — moves with the evidence
The artifact metadata travels with audit exports and verifier bundles.
Queue may run on leased BYOW workers when policy permits it.
Sensitive customers can require audited trust floors, pinned/enclave key custody, customer-owned workers, or private pools. Default sensitive posture: no plain leased credential custody. Leased capacity must satisfy jurisdiction, attestation, health, price, capacity, and lease requirements.
Queue failures are part of the evidence model.
Refusals, lease failures, worker failures, artifact failures, and settlement-pending states are explicit.
No worker satisfies hard constraints. The correct response is refusal with proof.
Eligible capacity existed but lease acquisition failed after retries.
The job failed and must not be presented as complete.
Execution finished, chain closed, but ledger reconciliation is not final yet.