# Hex Decode

> Hex Decode is a paid API for AI agents from x402-gateway-production-1f21.up.railway.app, paid per call via x402, $0.001/call, status unknown (last checked 2026-10-12).

Decodes a hexadecimal-encoded string back into its original plaintext or binary representation

## Facts

- Endpoint: POST https://x402-gateway-production-1f21.up.railway.app/hex/decode?utm_source=zero.xyz
- Price: $0.001/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-12
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/hex-decode-b03253a3
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_JKWEh1QU8KA_dZN9HGBXR

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 hex-decode-b03253a3 -d '<json body>'
```

Example prompt: Can you decode this hex string for me: '48656c6c6f20576f726c64'? I need to see what the original text says.

## When to prefer this

Use this endpoint when you need a machine-payable, on-demand hex decoding utility without spinning up your own infrastructure — especially useful in automated agent pipelines that already use the x402 micropayment protocol and need lightweight encoding utilities alongside other tools on the same gateway.

## Known failure modes

- Invalid hex string (odd length or non-hex characters) returns an error
- Input exceeds 500,000 character limit
- Malformed request body missing the required 'value' field
- Payment failure or insufficient USDC balance blocks the call

## How this service works

Machine-payable x402 utilities for hashing, Base64, UUID generation, unit and timezone conversion, realtime crypto market data, webpage/document extraction, URL-to-Markdown, metadata, RAG ingestion and deterministic website change detection.

## Output

Returns the decoded plaintext or binary representation of the provided hex-encoded input string, allowing the caller to read the original data that was hex-encoded.

## 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",
    "bodyType",
    "body"
   ],
   "properties": {
    "body": {
     "type": "object",
     "required": [
      "value"
     ],
     "properties": {
      "value": {
       "type": "string",
       "maxLength": 500000
      }
     },
     "additionalProperties": false
    },
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "enum": [
      "POST"
     ],
     "type": "string"
    },
    "bodyType": {
     "enum": [
      "json",
      "form-data",
      "text"
     ],
     "type": "string"
    }
   },
   "additionalProperties": false
  },
  "output": {
   "type": "object",
   "required": [
    "type"
   ],
   "properties": {
    "type": {
     "type": "string"
    },
    "example": {
     "type": "object"
    }
   }
  }
 }
}
```

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "status": "ready"
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/hex-decode-b03253a3/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from x402-gateway-production-1f21.up.railway.app](https://www.zero.xyz/host/x402-gateway-production-1f21.up.railway.app/llms.txt)
