# Hex Encode/Decode

> Hex Encode/Decode is a paid API for AI agents from conclavex402p04.pythonanywhere.com, paid per call via x402, $0.005/call, status unknown (last checked 2026-10-14).

Encodes plain text to hexadecimal or decodes a hex string back to plain text via HTTP POST.

## Facts

- Endpoint: POST https://conclavex402p04.pythonanywhere.com/u/hex?utm_source=zero.xyz
- Price: $0.005/call
- Payment: x402
- Status: unknown
- Last checked: 2026-10-14
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/hex-encode-decode-d446bb08
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_blnuPeM8kUmY2U3Mjvgnk

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-encode-decode-d446bb08 -d '<json body>'
```

Example prompt: Hex encode the text 'hello world' for me — I need the raw hex string output.

## When to prefer this

Choose this endpoint when you need a simple, pay-per-call hex encode or decode operation without setting up a local library or runtime. Ideal for agents that occasionally need hex conversion in a pipeline without installing dependencies. Prefer it over rolling your own conversion when operating in constrained environments or when auditable, consistent hex output is needed.

## Known failure modes

- Missing or malformed 'input' body field returns a 400-level error
- Passing invalid hex characters during decode may return an error or garbled output
- Incorrect bodyType (e.g. sending form-data when json expected) may cause a parse failure
- Network or server errors on pythonanywhere may result in 5xx responses
- Payment failure or insufficient USDC balance returns 402 before the endpoint is reached

## How this service works

Hex encode or decode text — hex string encoder/decoder.

## Output

A JSON object containing the result field 'hex' with either the hex-encoded string (e.g. {"hex":"6869"}) when encoding, or the decoded plaintext when decoding. The response is fast and synchronous.

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

## Response schema (JSON Schema)

```json
{
 "type": "json",
 "example": {
  "hex": "6869"
 }
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/hex-encode-decode-d446bb08/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from conclavex402p04.pythonanywhere.com](https://www.zero.xyz/host/conclavex402p04.pythonanywhere.com/llms.txt)
