# Hexdump API
> Produce a canonical hex dump of any input and parse a hex dump back into bytes. The dump endpoint formats data the way hexdump -C and xxd do — an offset column, the bytes in hex (grouped in eights), and a printable-ASCII gutter — with a configurable number of bytes per line and optional uppercase. Feed text as UTF-8, or binary as hex or base64. The parse endpoint reverses any hex dump — tolerating offset columns and ASCII gutters, or a plain run of hex — and returns the reconstructed bytes as hex, base64 and (when printable) text. Perfect for inspecting binary payloads, debugging protocols and file formats, diffing buffers and teaching. Pure local computation — no key, no third-party service, instant; up to 1 MB via POST. Live, nothing stored. 3 endpoints. Distinct from a plain base64/hex encoder.

## Authentication
All requests require your oanor API key in the `x-oanor-key` header. Get one at https://www.oanor.com/developer/keys.

```bash
curl -H "x-oanor-key: oanor_live_…" "https://api.oanor.com/hexdump-api/..."
```

## Pricing
- **Free** (Free) — 1,075 calls/Mo, 2 req/s
- **Starter** ($1/Mo) — 9,150 calls/Mo, 8 req/s
- **Pro** ($21/Mo) — 142,500 calls/Mo, 20 req/s
- **Mega** ($59/Mo) — 755,000 calls/Mo, 50 req/s

## Endpoints

### Hexdump

#### `GET /v1/dump` — Hex dump of input

**Parameters:**
- `text` (query, required, string) — Input Example: `hello world`
- `encoding` (query, optional, string) — utf8|hex|base64 (default utf8) Example: `utf8`
- `bytes_per_line` (query, optional, string) — 1-64 (default 16) Example: `16`
- `uppercase` (query, optional, string) — true/false

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/hexdump-api/v1/dump?text=hello+world&encoding=utf8&bytes_per_line=16"
```

**Response:**
```json
{
    "data": {
        "dump": "00000000  68 65 6c 6c 6f 20 77 6f  72 6c 64                 |hello world|\n0000000b",
        "bytes": 11,
        "lines": 2,
        "bytes_per_line": 16
    },
    "meta": {
        "timestamp": "2026-06-03T01:09:46.101Z",
        "request_id": "06dac5c9-11f7-4c4d-82f3-50a3d2c77d6e"
    },
    "status": "ok",
    "message": "Hex dump of input",
    "success": true
}
```

#### `GET /v1/parse` — Parse a hex dump to bytes

**Parameters:**
- `dump` (query, required, string) — A hex dump or plain hex Example: `68 65 6c 6c 6f`

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/hexdump-api/v1/parse?dump=68+65+6c+6c+6f"
```

**Response:**
```json
{
    "data": {
        "hex": "68656c6c6f",
        "text": "hello",
        "bytes": 5,
        "base64": "aGVsbG8="
    },
    "meta": {
        "timestamp": "2026-06-03T01:09:46.204Z",
        "request_id": "08451001-9b17-4f97-8403-6062e82c5f61"
    },
    "status": "ok",
    "message": "Parse a hex dump to bytes",
    "success": true
}
```

### Meta

#### `GET /v1/meta` — Spec

**Example:**
```bash
curl -H "x-oanor-key: $KEY" \
  "https://api.oanor.com/hexdump-api/v1/meta"
```

**Response:**
```json
{
    "data": {
        "name": "Hexdump API",
        "notes": "Send binary input as hex or base64 via the encoding parameter. parse tolerates offset columns and ASCII gutters as well as plain hex. Max 1 MB.",
        "version": "v1",
        "endpoints": [
            {
                "path": "/v1/dump",
                "params": {
                    "text": "input (required)",
                    "encoding": "utf8|hex|base64 (default utf8)",
                    "uppercase": "true/false",
                    "bytes_per_line": "1-64 (default 16)"
                },
                "returns": "the formatted hex dump"
            },
            {
                "path": "/v1/parse",
                "params": {
                    "dump": "a hex dump or plain hex (required)"
                },
                "returns": "the reconstructed bytes as hex, base64 and text"
            },
            {
                "path": "/v1/meta",
                "params": [],
                "returns": "this document"
            }
        ],
        "description": "Produce a canonical hex dump (like hexdump -C / xxd) of any input — an offset column, the bytes in hex, and a printable-ASCII gutter — and parse a hex dump back into bytes. Pure local, no key."
    },
    "meta": {
        "timestamp": "2026-06-03T01:09:46.304Z",
        "request_id": "afe1b9f5-6621-40ab-a4e9-3952bc02843d"
    },
    "status": "ok",
    "message": "Meta",
    "success": true
}
```


---
Marketplace page: https://www.oanor.com/api/hexdump-api
OpenAPI spec: https://www.oanor.com/api/hexdump-api/openapi.json
