# Screwtape.ai Agent Action Receipt

> Screwtape.ai Agent Action Receipt is a paid API for AI agents from screwtape.ai, paid per call via x402, $0.003/call, status unknown (last checked 2026-11-28).

Creates a cryptographically signed, tamper-evident receipt recording whether an AI agent was advised to allow or deny a spending action, forming an auditable chain of agent authorization decisions.

## Facts

- Endpoint: POST https://screwtape.ai/v1/receipt?utm_source=zero.xyz
- Price: $0.003/call
- Payment: x402
- Status: unknown
- Last checked: 2026-11-28
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/screwtape-ai-agent-action-receipt-650114dc
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_MHSnZ4mXTEYZkWxfn4J4S

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 screwtape-ai-agent-action-receipt-650114dc -d '<json body>'
```

Example prompt: Log a Screwtape receipt for agent 'trading-bot-001' and event 'evt-20240501-buy-eth' recording that the action to purchase 0.5 ETH was requested — here's the action SHA-256 hash: a3f1c2d4e5b6789012345678901234567890abcdef1234567890abcdef123456.

## When to prefer this

Use this endpoint when you need a cryptographically verifiable, chained audit log of AI agent spending decisions — especially for compliance, governance, or accountability use cases where you must prove an agent checked for authorization before transacting. Prefer this over simple logging services when you need Ed25519-signed receipts that form a hash chain (each receipt links to the previous), enabling tamper-evidence. This is not a payment gateway or fund-holding service; the agent must still enforce the decision — Screwtape records the advisory and proof.

## Known failure modes

- Invalid agent_id or event_id format (must match pattern ^[A-Za-z0-9._:-]+$) returns 400
- Missing required fields (action, status, agent_id, event_id) returns 400
- Invalid status enum value returns 400
- action_sha256 not matching the 64-character hex pattern returns 400
- Payment not included or insufficient USDC (requires $0.003 via x402) returns 402
- Agent submitting a duplicate event_id may receive replayed:true in response
- Signature verification failure downstream if keys_url is unreachable

## How this service works

Screwtape advises and records. Your agent must cooperate by checking the result before acting; we do not hold funds or independently stop payments.

## Output

Returns a signed receipt object containing a unique receipt_id, agent_id, sequence number (position in the agent's hash chain), action_sha256, previous_hash linking to the prior receipt, an Ed25519 signature, the signing key ID, status, issued_at timestamp, and chain identifier. Also returns the receipt_hash for the new record, a verify_url for public verification, a keys_url for signature key lookup, and optionally a replayed flag and request_id.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "properties": {
  "action": {
   "type": "string"
  },
  "status": {},
  "agent_id": {
   "type": "string"
  },
  "children": {
   "type": "array",
   "items": {
    "type": "string"
   },
   "description": "Ordered child receipt ids. Signs children_root over their receipt_hash values so any added, dropped or swapped step fails verification."
  },
  "event_id": {
   "type": "string"
  },
  "reference": {
   "type": "string"
  },
  "action_sha256": {
   "type": "string"
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "schema": {
  "type": "object",
  "required": [
   "receipt",
   "receipt_hash",
   "verify_url",
   "keys_url"
  ],
  "properties": {
   "receipt": {
    "type": "object",
    "required": [
     "receipt_id",
     "agent_id",
     "sequence",
     "action_sha256",
     "previous_hash",
     "signature",
     "kid",
     "alg",
     "status",
     "issued_at",
     "chain",
     "event_id",
     "schema"
    ],
    "properties": {
     "alg": {
      "const": "Ed25519"
     },
     "kid": {
      "type": "string"
     },
     "chain": {
      "type": "string"
     },
     "schema": {
      "const": "screwtape-action-receipt-v1"
     },
     "status": {
      "enum": [
       "requested",
       "succeeded",
       "failed",
       "paid_not_served"
      ]
     },
     "agent_id": {
      "type": "string",
      "pattern": "^[A-Za-z0-9._:-]+$",
      "maxLength": 128,
      "minLength": 1
     },
     "children": {
      "type": "array",
      "items": {
       "type": "string"
      }
     },
     "event_id": {
      "type": "string",
      "pattern": "^[A-Za-z0-9._:-]+$",
      "maxLength": 128,
      "minLength": 1
     },
     "sequence": {
      "type": "integer",
      "minimum": 1
     },
     "issued_at": {
      "type": "string"
     },
     "signature": {
      "type": "string"
     },
     "receipt_id": {
      "type": "string"
     },
     "action_sha256": {
      "type": "string"
     },
     "children_root": {
      "type": "string",
      "description": "SHA-256 of canonical JSON of ordered child receipt_hash values."
     },
     "previous_hash": {
      "type": [
       "string",
       "null"
      ]
     },
     "reference_sha256": {
      "type": "string"
     }
    }
   },
   "keys_url": {
    "type": "string"
   },
   "replayed": {
    "type": "boolean"
   },
   "request_id": {
    "type": "string"
   },
   "verify_url": {
    "type": "string"
   },
   "receipt_hash": {
    "type": "string"
   }
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/screwtape-ai-agent-action-receipt-650114dc/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from screwtape.ai](https://www.zero.xyz/host/screwtape.ai/llms.txt)
