# Datoka Agent Execution Receipt Issuer

> Datoka Agent Execution Receipt Issuer is a paid API for AI agents from datoka-agent.bhazarstudio.workers.dev, paid per call via x402, $0.002/call, status unknown (last checked 2026-10-12).

Issues a signed, cryptographically-verifiable execution receipt for a single AI agent step/tool invocation, recording its outcome and input/output hashes.

## Facts

- Endpoint: POST https://datoka-agent.bhazarstudio.workers.dev/v1/operations/issue_agent_receipt?utm_source=zero.xyz
- Price: $0.002/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-12
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/datoka-agent-execution-receipt-issuer-e747ef25
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_UaXFF4vzgJPCDf896MkGD

Status and success rate cover calls made through Zero and Zero's own probes. Third-party monitors may report differently.

## How to call it through Zero

Zero handles the 402 payment challenge and records the run. With the Zero CLI installed (`npm i -g @zeroxyz/cli`):

```sh
zero fetch --capability datoka-agent-execution-receipt-issuer-e747ef25 -d '<json body>'
```

Example prompt: Issue a Datoka signed execution receipt for agent 'agent-prod-001', run 'run-2024-abc123', step 'step-01', tool 'web-search', outcome 'success', started at 2024-06-10T14:00:00.000Z and completed at 2024-06-10T14:00:02.500Z, with inputHash SHA-256 digest 'a3f1...e9c2' and outputHash SHA-256 digest 'b7d4...1f08', using idempotency key 'idem-run-abc123-step-01'.

## When to prefer this

Choose this endpoint when you need a paid, cryptographically-signed, tamper-evident receipt for a specific AI agent execution step — particularly for audit trails, compliance records, or verifiable compute proofs where an immutable third-party attestation is required. Prefer this over self-signed or in-process logging when the downstream consumer needs an externally-verifiable declaration of what an agent did, with what inputs and outputs, and at what time.

## Known failure modes

- Duplicate idempotency key with different event payload returns a conflict error (use a unique key per distinct event)
- Invalid SHA-256 digest format (must be exactly 64 lowercase hex characters) returns a validation error
- Malformed timestamp (must be ISO 8601 UTC with milliseconds) returns a schema validation error
- Missing required fields (agentId, runId, stepId, tool, outcome, startedAt, completedAt, inputHash, outputHash) returns 422 unprocessable entity
- Payment failure or insufficient USDC balance returns 402 Payment Required — retry with same event and idempotency key after resolving payment

## How this service works

Datoka Agent: one signed execution declaration receipt. Retry with the same event, idempotency key and payment.

## Output

Returns a signed execution declaration receipt (datoka.agent.execution.v1) confirming the recorded agent step, including the receipt identifier, cryptographic signatures over the event data, and attestation metadata that can be used for audit, compliance, or verification purposes.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "event": {
   "type": "object",
   "required": [
    "version",
    "agentId",
    "runId",
    "stepId",
    "tool",
    "outcome",
    "startedAt",
    "completedAt",
    "inputHash",
    "outputHash"
   ],
   "properties": {
    "tool": {
     "type": "string",
     "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]{0,127}$",
     "description": "Tool or operation identifier declared by the caller."
    },
    "runId": {
     "type": "string",
     "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]{0,127}$",
     "description": "Stable identifier for this execution run."
    },
    "stepId": {
     "type": "string",
     "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]{0,127}$",
     "description": "Stable identifier of the step within the run."
    },
    "agentId": {
     "type": "string",
     "pattern": "^[A-Za-z0-9][A-Za-z0-9._:-]{0,127}$",
     "description": "Identifier of the declaring agent, not an independently verified identity."
    },
    "outcome": {
     "enum": [
      "success",
      "error"
     ],
     "type": "string",
     "description": "Outcome declared by the caller; Datoka does not observe execution."
    },
    "version": {
     "type": "string",
     "const": "datoka.agent.execution.v1",
     "description": "Declaration format version; preserve this literal."
    },
    "inputHash": {
     "type": "object",
     "required": [
      "algorithm",
      "digest"
     ],
     "properties": {
      "digest": {
       "type": "string",
       "pattern": "^[a-f0-9]{64}$",
       "description": "64 lowercase hexadecimal characters; SHA-256 of exact bytes."
      },
      "algorithm": {
       "type": "string",
       "const": "sha256",
       "description": "Hash algorithm."
      }
     },
     "description": "SHA-256 of the exact input bytes, computed locally. Never send raw input.",
     "additionalProperties": false
    },
    "startedAt": {
     "type": "string",
     "format": "date-time",
     "pattern": "^(?:(?:\\d\\d[2468][048]|\\d\\d[13579][26]|\\d\\d0[48]|[02468][048]00|[13579][26]00)-02-29|\\d{4}-(?:(?:0[13578]|1[02])-(?:0[1-9]|[12]\\d|3[01])|(?:0[469]|11)-(?:0[1-9]|[12]\\d|30)|(?:02)-(?:0[1-9]|1\\d|2[0-8])))T(?:(?:[01]\\d|2[0-3]):[0-5]\\d:[0-5]\\d\\.\\d{3}(?:Z))$",
     "description": "Declared start time in UTC, with milliseconds."
    },
    "outputHash": {
     "type": "object",
     "required": [
      "algorithm",
      "digest"
     ],
     "properties": {
      "digest": {
       "type": "string",
       
… (truncated)
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "event": {
   "tool": "number.add",
   "runId": "demo-run",
   "stepId": "addition-001",
   "agentId": "demo-agent",
   "outcome": "success",
   "version": "datoka.agent.execution.v1",
   "inputHash": {
    "digest": "206f7b5543e6f2ef39bf334988fd7097b725caeed16588cd9d785480f2f0f8f6",
    "algorithm": "sha256"
   },
   "startedAt": "2026-09-29T13:36:18.844Z",
   "outputHash": {
    "digest": "4403134882233d347dfa35d23b98c42a4442478ce521631ef566d21df77e2a52",
    "algorithm": "sha256"
   },
   "completedAt": "2026-09-29T13:36:18.844Z"
  },
  "receipt": {
   "body": {
    "id": "48fe5c2f-012c-4e52-a6b0-74ca3c487c98",
    "keyId": "test-key-1",
    "issuer": "datoka.agent.test",
    "request": {
     "chain": "run:5bbe50afe842854e909b091a6be364f4b16f541a8a6c1195e777d1e0f58d6867",
     "scope": "tenant-a",
     "subject": {
      "digest": "5ad65af6a67c968f55f77ed7b8d6bf4c5c65167ca3c81fc4811ee61e4fdc3559",
      "encoding": "jcs",
      "algorithm": "sha256"
     },
     "eventType": "datoka.agent.execution"
    },
    "version": "datoka.receipt.v1",
    "issuedAt": "2026-09-29T13:36:19.022Z",
    "previous": null,
    "sequence": 1
   },
   "algorithm": "Ed25519",
   "signature": "QFlVdquYWg4FkGtI02U5V6QKLRiKWs-ACsL0k3dsZXIVOOr_gn8C7Mq0XccRbvVEXMt3HnO0Cth0zsHqXYcQBw"
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/datoka-agent-execution-receipt-issuer-e747ef25/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from datoka-agent.bhazarstudio.workers.dev](https://www.zero.xyz/host/datoka-agent.bhazarstudio.workers.dev/llms.txt)
