# Blockchain Transaction Explainer (decode-tx)

> Blockchain Transaction Explainer (decode-tx) is a paid API for AI agents from api.api-agent-ia.ch, paid per call via x402, $0.005/call, status unknown (last checked 2026-10-26).

Takes a blockchain transaction hash and returns a plain-English explanation of what the transaction did

## Facts

- Endpoint: GET https://api.api-agent-ia.ch/decode-tx?utm_source=zero.xyz
- Price: $0.005/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-26
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/blockchain-transaction-explainer-decode-tx-1e69c833
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_MAuCxRsDKKU9k8bXdXvyX

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 blockchain-transaction-explainer-decode-tx-1e69c833
```

Example prompt: Can you explain to me in plain English what happened in this transaction: 0x4a1b2c3d4e5f6789abcdef1234567890abcdef1234567890abcdef1234567890ab?

## When to prefer this

Choose this endpoint when you need a human-readable, natural-language explanation of a single blockchain transaction by hash, especially for non-technical users who cannot interpret raw on-chain data. It is ideal for wallet dashboards, DeFi audit tools, customer support bots, or any agent that needs to bridge raw transaction data and plain English. Prefer this over raw block explorer APIs when you need interpretation rather than raw data.

## Known failure modes

- Invalid or malformed transaction hash returns an error
- Transaction hash not found on the supported network
- Network timeout when fetching on-chain data
- Unsupported transaction type or contract interaction that cannot be decoded
- Missing required 'hash' query parameter returns a validation error

## How this service works

What did this Base transaction do? Returns a one-sentence explanation in French, built by rules from on-chain data (no AI), with its status and decoded ERC-20 transfers ($0.005 per call).

## Output

A JSON object containing the original transaction hash and a plain-English explanation (labeled 'explication') describing what the transaction did — e.g. who sent what asset to whom, what smart contract was called, or what DeFi operation was executed.

## 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",
      "HEAD",
      "DELETE"
     ],
     "type": "string"
    },
    "queryParams": {
     "type": "object",
     "required": [
      "hash"
     ],
     "properties": {
      "hash": {
       "type": "string"
      }
     }
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object"
    }
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "de": "0x1d7f97D26ae2C01F9b01Fc252B73Cf0Db3397E95",
  "hash": "0x8a841e4f28fbef9ea69921e055a80f3ddf097d7969b87ecc3e9940e54b8a5a20",
  "vers": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913",
  "statut": "réussie",
  "valeur_eth": "0",
  "explication": "Cette transaction a appelé le contrat 0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913. Elle a été réussie. Elle a transféré : 6.14 USDC de 0x747b72260748e8b999e19e58D5c373587282A473 vers 0x1d7f97D26ae2C01F9b01Fc252B73Cf0Db3397E95.",
  "transferts_tokens": [
   {
    "de": "0x747b72260748e8b999e19e58D5c373587282A473",
    "vers": "0x1d7f97D26ae2C01F9b01Fc252B73Cf0Db3397E95",
    "token": "0x833589fCD6eDb6E08f4c7C32D4f71b54bdA02913",
    "montant": "6.14",
    "symbole": "USDC",
    "montant_brut": "6140000"
   }
  ],
  "nb_transferts_tokens": 1
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/blockchain-transaction-explainer-decode-tx-1e69c833/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from api.api-agent-ia.ch](https://www.zero.xyz/host/api.api-agent-ia.ch/llms.txt)
