# x402 Agent Wallet Tools – Permit/Permit2 Decoder

> x402 Agent Wallet Tools – Permit/Permit2 Decoder is a paid API for AI agents from x402-wallet.558686.xyz, paid per call via x402, $0.013/call, status unknown (last checked 2026-09-15).

Decodes and risk-analyzes EIP-712 typed data for Permit and Permit2 token approval signatures, extracting domain, spender, amount, and risk findings.

## Facts

- Endpoint: POST https://x402-wallet.558686.xyz/v1/tools/permit-permit2-decoder
- Price: $0.013/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-15
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/x402-agent-wallet-tools-permit-permit2-decoder-5e7212c4
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_rN2dgC3a-u9NHgKU8nKl8

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 x402-agent-wallet-tools-permit-permit2-decoder-5e7212c4 -d '<json body>'
```

Example prompt: Before I sign this Permit2 request, can you decode and risk-check this EIP-712 typed data — domain is 'Permit2' on chainId 8453, primaryType is 'PermitSingle', spender is 0x4444444444444444444444444444444444444444, and amount is 1000000?

## When to prefer this

Use this endpoint when an AI agent or wallet needs to decode and risk-assess a Permit or Permit2 EIP-712 typed data payload before presenting it to a user for signing. It is the right choice when you need to extract human-readable fields (spender, amount, deadline) and a risk classification from a raw typed-data object, specifically for ERC20 token approval flows on EVM chains. Prefer this over generic EIP-712 decoders when you specifically need Permit/Permit2 family detection and risk findings.

## Known failure modes

- Missing required domain.name or domain.chainId fields returns a validation error
- Missing message.spender or message.amount returns an input schema error
- Unrecognized primaryType may return empty family classification with limited findings
- Malformed EIP-712 typed data object returns a parse error
- Payment not included or insufficient returns HTTP 402

## How this service works

A buyer-side control console for signature risk, EIP-712 review, transaction decoding, ERC20 allowance risk, Permit/Permit2 approvals, transaction simulation summaries, spend guard policy, receipt gate enforcement, and private-key boundaries.

## Output

Returns a JSON object with: the decoded domain fields, the permit family (e.g. Permit, Permit2, PermitSingle, PermitBatch), extracted structured fields (spender, amount, nonce, deadline), a list of risk findings (anomalies, suspicious spenders, excessive amounts), and an overall riskLevel classification. The result is deterministic for the same input.

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "ok": true,
  "tool": "permit-permit2-decoder",
  "input": {
   "typedData": {
    "domain": {
     "name": "Permit2",
     "chainId": 8453
    },
    "message": {
     "amount": "1000000",
     "spender": "0x4444444444444444444444444444444444444444"
    },
    "primaryType": "PermitSingle"
   }
  },
  "route": "/v1/tools/permit-permit2-decoder",
  "result": {
   "domain": {},
   "family": "family_example",
   "findings": [],
   "extracted": {},
   "riskLevel": "riskLevel_example"
  },
  "project": "x402-agent-wallet-tools",
  "deterministic": true
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/x402-agent-wallet-tools-permit-permit2-decoder-5e7212c4/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from x402-wallet.558686.xyz](https://www.zero.xyz/host/x402-wallet.558686.xyz/llms.txt)
