x402-native multichain data API

Decode any EVM or Solana transaction into human-readable JSON

Turn any EVM or Solana transaction into a human-readable action plus normalized asset movements. x402-native: $0.005 per call in USDC, no signup, no keys.

Real decoder output

What is txdecode

txdecode is an x402 transaction decoder: a pay-per-call API that resolves a single transaction on Base, Ethereum, Arbitrum, Optimism, Polygon, BNB Chain or Solana into one plain-English summary and a normalized list of asset movements, each with token, amount and USD value.

There is no account and no API key. You pay $0.005 in USDC on Base per call through the x402 protocol, which makes the endpoint callable by humans and autonomous agents alike. See the full API documentation for request and response details.

How it works

  1. Request

    Send a plain GET to /api/v1/decode/{chain}/{txHash} with the chain slug and the transaction hash you want decoded.

  2. 402 Payment Required

    The endpoint answers HTTP 402 with the payment requirements: price, network (Base) and the USDC asset to settle in.

  3. Pay & retry

    An x402 client signs the USDC payment and retries automatically; the decoded JSON comes back on the 200 response.

Example call

The endpoint is pay-per-call, so a plain request surfaces the 402. The decode endpoint reference shows the JS and Python clients that complete the payment and retry.

GET /api/v1/decode/base/0xff39…c1ea
Request
curl · no payment
# plain request → the server answers 402
curl -i \
  https://txdecode.com/api/v1/decode/base/0xff3915bda0e355a1627f4aa8a47afec817cd9008e71382d7181e885f42d9c1ea
response 402 Payment Required
HTTP/1.1 402 Payment Required
www-authenticate: x402
payment-required: # x402 requirements (base64 in the header)
{
  "scheme": "exact",
  "network": "eip155:8453", # Base
  "maxAmountRequired": "5000", # $0.005 (USDC, 6 dec)
  "asset": "0x8335…2913" # USDC on Base
}
x402 client
sign EIP-3009 · USDC on Base 0.005 USDC · facilitator settles retry with X-PAYMENT…
response 200 OK · settled ✓
Uniswap swap

Swapped 150.448225 USDC ($150.42) for 5055.96317 CAS (~$146.48) on Uniswap (Universal Router, 2 hops, 1% CAS transfer tax)

action
swap
chain
8453 · base
status
success
full response 486 lines · application/json

Endpoints

Read the decode transaction endpoint documentation for parameters, the response schema and error codes.

Pricing

One flat price for every call: $0.005 USDC per call

No subscription and no minimum. See the pricing page for the full model.

Failed calls are free. Any non-200 response is never charged — you only pay for a successful decode.

FAQ

What is txdecode?

txdecode is a pay-per-call API that turns any EVM or Solana transaction into a human-readable action plus normalized asset movements (token, amount, USD value). It is x402-native: you pay $0.005 per call in USDC on Base, with no account.

How much does it cost?

$0.005 in USDC per call, flat — the same price with or without `?verbose=true`. No subscription, no minimum. Any non-200 response is never charged, so failed calls are free.

Do I need an account or API key?

No. Payment is handled entirely by the x402 protocol on Base. You send a request, get an HTTP 402 with payment requirements, pay in USDC, and retry. Nothing to sign up for, no key to manage.

What blockchain does it use?

Decoding covers seven chains: Base, Ethereum, Arbitrum, Optimism, Polygon, BNB Chain and Solana. Payments always settle in USDC on Base (chain ID 8453) via x402, whichever chain you decode.

Can AI agents use this autonomously?

Yes — that is the primary use case. An agent can call the endpoint, handle the 402, pay in USDC and read the decoded JSON with no human in the loop. See /llms.txt and /api/openapi.json.