# Calldata Decoder + Signing Warnings

> Calldata Decoder + Signing Warnings is a paid API for AI agents from automaton-tx-explainer.vercel.app, paid per call via x402, $0.005/call, status unknown (last checked 2026-10-17).

Decodes raw EVM hex calldata into human-readable function signatures and arguments, with plain-English risk warnings for dangerous approvals and unlimited token grants.

## Facts

- Endpoint: GET https://automaton-tx-explainer.vercel.app/v1/decode?utm_source=zero.xyz
- Price: $0.005/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-17
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/calldata-decoder-signing-warnings-dcb0a9b1
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_czPP5Iccfg8R1-QvJkeEW

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 calldata-decoder-signing-warnings-dcb0a9b1
```

Example prompt: Before I sign this transaction, can you decode this calldata and tell me if it's doing anything dangerous like setting an unlimited approval or a setApprovalForAll — here's the hex: 0x095ea7b3000000000000000000000000def1c0ded9bec7f1a1670819833240f027b25effffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffffe

## When to prefer this

Choose this endpoint when you need to explain raw EVM calldata to a user before they sign a transaction, especially in wallet, agent, or security contexts. It is particularly valuable for flagging approve/permit/setApprovalForAll patterns that could drain user funds. Prefer this over a general block explorer lookup when you need immediate, structured, plain-English risk analysis without requiring a network/chain context — just the raw hex data is sufficient.

## Known failure modes

- Calldata shorter than 4 bytes (missing selector) returns an error — must be 0x + at least 8 hex chars
- Unknown or very new function selectors may return no signature candidates from the openchain DB
- Malformed hex string not matching ^0x[0-9a-fA-F]{8,}$ pattern causes a 400 validation error
- Calldata exceeding 8010 character maxLength is rejected
- Ambiguous ABI types may produce multiple signature candidates with uncertain decoding
- Network errors reaching the openchain signature database may result in empty candidates list

## How this service works

Decode EVM calldata before signing: function signature candidates (openchain DB), decoded args, and plain-English warnings for approve/setApprovalForAll/permit/unlimited amounts.

## Output

Returns the most likely function signature candidates (sourced from the openchain.xyz signature database), ABI-decoded argument values with their types, and a set of plain-English warning messages flagging high-risk patterns such as ERC-20 approve with unlimited amounts, setApprovalForAll on NFT contracts, EIP-2612 permit calls, or other dangerous signing patterns the user should review before proceeding.

## Request schema (JSON Schema)

```json
{
 "type": "object",
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "required": [
  "input"
 ],
 "properties": {
  "input": {
   "type": "object",
   "required": [
    "type",
    "method"
   ],
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "GET"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "data"
     ],
     "properties": {
      "data": {
       "type": "string",
       "pattern": "^0x[0-9a-fA-F]{8,}$",
       "maxLength": 8010,
       "description": "hex calldata (0x + selector + args)"
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object"
    }
   }
  }
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/calldata-decoder-signing-warnings-dcb0a9b1/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from automaton-tx-explainer.vercel.app](https://www.zero.xyz/host/automaton-tx-explainer.vercel.app/llms.txt)
