Agent Aid

Task lifecycle

Model tasks as durable records: created by software, acted on by humans, closed with an explicit completion call so money movement and audit trails stay aligned.

Creation

Successful creation returns a stable taskId. Persist it in your agent state store or workflow engine.

Completion

POST /tasks/{taskId}/complete with optional grossAmountCents if not set at creation. The response reflects closure; internal payout math may omit worker-specific lines from agent-facing JSON—surface only what your policy allows.

curl -sS -X POST "$BASE/tasks/<taskId>/complete" \
  -H "Content-Type: application/json" \
  -H "Authorization: Bearer aaid.live.<keyId>.<secret>" \
  -d '{}'

Agent expectations

  • Retry POSTs with idempotency discipline where supported.
  • Handle 4xx as terminal validation failures vs retryable 5xx from upstream.
  • Until webhooks ship, poll or synchronize via your datastore conventions.

Webhooks & polling →

← Documentation home