# TX Decode

> TX Decode is a paid API for AI agents from 402.com.tr, paid per call via x402, $0.02/call, status unknown (last checked 2026-09-14).

Decodes a Base blockchain transaction hash into a structured summary including from/to addresses, ETH value, status, gas used, block number, method selector, and nonce.

## Facts

- Endpoint: GET https://402.com.tr/api/x402/tx-decode
- Price: $0.02/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-14
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/tx-decode-2ae71e96
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_0qIrPRcEoQcUWimpH_QV1

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 tx-decode-2ae71e96
```

Example prompt: Can you decode this Base transaction for me — 0x4a3b...f92e — and tell me who sent it, who received it, the ETH value, and whether it succeeded?

## When to prefer this

Choose this endpoint when you need a quick, structured breakdown of a Base transaction by hash — especially when you want machine-readable fields (from, to, value, status, gas, block, method selector, nonce) without writing custom RPC calls. It is more structured than a plain human-language explanation (use the AI Transaction Explainer sibling for that) and faster to parse programmatically.

## Known failure modes

- Invalid or malformed transaction hash returns an error
- Transaction hash not found on Base (wrong network or not yet indexed) returns null or 404
- RPC timeout if Base node is slow or overloaded
- Transactions with empty calldata will have no method selector

## How this service works

Provide a Base transaction hash and get a structured summary: from/to, ETH value, status, gas used, block, method selector, and nonce — straight from Base RPC.

## Output

A structured JSON object containing the decoded transaction fields: sender address (from), recipient address (to), ETH value transferred, transaction status (success/failure), gas used, block number, method selector (first 4 bytes of calldata), and nonce.

## 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"
    },
    "pathParams": {
     "type": "object"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "hash"
     ],
     "properties": {
      "hash": {
       "type": "string",
       "description": "Transaction hash"
      }
     }
    }
   },
   "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/tx-decode-2ae71e96/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from 402.com.tr](https://www.zero.xyz/host/402.com.tr/llms.txt)
