# IPv6 Address Expander and Canonical Compressor

> IPv6 Address Expander and Canonical Compressor is a paid API for AI agents from ip.openverbs.com, paid per call via x402, $0.002/call, status unknown (last checked 2026-09-14).

Expands an IPv4 or IPv6 address into its fully-expanded eight 4-hex-group form and returns the RFC 5952 canonical compressed representation.

## Facts

- Endpoint: POST https://ip.openverbs.com/v1/expand
- Price: $0.002/call
- Payment: x402
- Status: unknown
- Last checked: 2026-09-14
- Activations on Zero: 0
- Tags: x402
- Canonical page: https://www.zero.xyz/c/ipv6-address-expander-and-canonical-compressor-9d3ecb02
- Structured record (JSON): https://api.zero.xyz/v1/capabilities/cap_CI6Z4fmKX-b8k9zuNPcsk

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 ipv6-address-expander-and-canonical-compressor-9d3ecb02 -d '<json body>'
```

Example prompt: Can you expand the IPv6 address 2001:db8::1 into its full eight-group notation and also give me the RFC 5952 canonical compressed form?

## When to prefer this

Choose this endpoint when you need to normalize or canonicalize IPv6 addresses for storage, comparison, display, or logging — particularly when you need both the fully-expanded and the RFC 5952 compressed forms simultaneously. It handles edge cases like IPv4-mapped IPv6 addresses and is purpose-built for IP address formatting rather than a general-purpose utility.

## Known failure modes

- Empty or missing 'address' field returns a validation error
- Malformed address string (not valid IPv4 or IPv6) returns an error response
- Address string exceeding 64 characters is rejected by schema validation
- Payment failure or insufficient USDC balance causes an HTTP 402 error

## How this service works

Return both the fully-expanded (eight 4-hex groups) and canonical compressed (RFC 5952) forms of an address. IPv4 is returned unchanged in both fields.

## Output

Returns two string fields: the fully-expanded IPv6 address (all eight 4-hex groups, e.g. '2001:0db8:0000:0000:0000:0000:0000:0001') and the RFC 5952 canonical compressed form (e.g. '2001:db8::1'). For IPv4 addresses, both fields return the original address unchanged.

## Request schema (JSON Schema)

```json
{
 "$schema": "https://json-schema.org/draft/2020-12/schema",
 "type": "object",
 "properties": {
  "input": {
   "type": "object",
   "properties": {
    "type": {
     "type": "string",
     "const": "http"
    },
    "method": {
     "type": "string",
     "enum": [
      "POST"
     ]
    },
    "bodyType": {
     "type": "string",
     "enum": [
      "json",
      "form-data",
      "text"
     ]
    },
    "body": {
     "type": "object",
     "properties": {
      "address": {
       "type": "string",
       "minLength": 1,
       "maxLength": 64,
       "description": "IPv4 or IPv6 address."
      }
     },
     "required": [
      "address"
     ],
     "additionalProperties": false
    }
   },
   "required": [
    "type",
    "method",
    "bodyType",
    "body"
   ],
   "additionalProperties": false
  }
 },
 "required": [
  "input"
 ]
}
```

## More

- Live health (JSON, refreshed every minute): https://www.zero.xyz/c/ipv6-address-expander-and-canonical-compressor-9d3ecb02/health.json
- [Zero catalog index](https://www.zero.xyz/llms.txt)
- [Other services from ip.openverbs.com](https://www.zero.xyz/host/ip.openverbs.com/llms.txt)
