# x402 Utility APIs Pay-per-call utility APIs, paywalled with the x402 HTTP payment protocol. No API keys, no signup, no subscription — pay in USDC on Base mainnet, per call. Unpaid requests return HTTP 402 with payment requirements in the `payment-required` response header (base64-encoded JSON), per the x402 protocol (https://x402.org). x402-aware HTTP clients pay and retry automatically. ## GET /api/qrcode — $0.01 USDC QR code image (PNG or SVG) for any text or URL. - data (required, string, max 2000 chars) Text or URL to encode - size (optional, integer, default 300, max 1000) Pixel width of the output image - format (optional, string, "png" | "svg", default "png") Output image format - ecLevel (optional, string, "L" | "M" | "Q" | "H", default "M") QR error correction level - dark (optional, string, default "000000") Foreground color, 6 or 8 digit hex - light (optional, string, default "ffffff") Background color, 6 or 8 digit hex Example: GET https://x402-qr-api.vercel.app/api/qrcode?data=https://example.com&size=400&format=svg ## GET /api/read — $0.005 USDC Fetch a URL, strip nav/ads/boilerplate, return clean Markdown + title/byline/wordCount. - url (required, string) Public http(s) URL to fetch and extract. Internal/private addresses are rejected. Example: GET https://x402-qr-api.vercel.app/api/read?url=https://en.wikipedia.org/wiki/QR_code ## GET /api/hash — $0.001 USDC MD5 / SHA1 / SHA256 / SHA512 digests of input text. - text (required, string, max 100000 chars) Text to hash Example: GET https://x402-qr-api.vercel.app/api/hash?text=hello ## GET /api/dns — $0.003 USDC DNS lookup: A, AAAA, MX, TXT, NS, CNAME records for a domain. - domain (required, string) Domain name to look up Example: GET https://x402-qr-api.vercel.app/api/dns?domain=example.com ## GET /api/headers — $0.003 USDC HTTP status, response headers, redirect chain, and timing for a URL. - url (required, string) Public http(s) URL to inspect. Internal/private addresses are rejected. Example: GET https://x402-qr-api.vercel.app/api/headers?url=https://example.com ## GET /api/ssl — $0.005 USDC TLS certificate inspection: issuer, subject, validity dates, SANs. - domain (required, string) Domain name to check - port (optional, integer, default 443) TCP port to connect to Example: GET https://x402-qr-api.vercel.app/api/ssl?domain=example.com ## GET /api/convert — $0.002 USDC Convert data between JSON, YAML, and CSV. - data (required, string, max 100000 chars) Input to convert - from (required, string, "json" | "yaml" | "csv") Input format - to (required, string, "json" | "yaml" | "csv") Output format Example: GET https://x402-qr-api.vercel.app/api/convert?data=%7B%22a%22%3A1%7D&from=json&to=yaml ## GET /api/text-stats — $0.001 USDC Word/sentence/syllable counts, reading time, Flesch reading-ease score. - text (required, string, max 100000 chars) Text to analyze Example: GET https://x402-qr-api.vercel.app/api/text-stats?text=hello%20world ## GET /api/validate — $0.002 USDC Email validation: format check plus a live MX record lookup on the domain. - email (required, string, max 320 chars) Email address to validate Example: GET https://x402-qr-api.vercel.app/api/validate?email=hello@example.com ## GET /api/jwt — $0.001 USDC Decode a JWT's header/payload and check expiry — signature is not verified. - token (required, string, max 8000 chars) JWT to decode Example: GET https://x402-qr-api.vercel.app/api/jwt?token=eyJhbGciOiJIUzI1NiJ9... ## GET /api/domain-report — $0.03 USDC [premium — synthesizes multiple checks into one call] Synthesized DNS + TLS + HTTP security report with a 0-100 score and findings — one call instead of three. - domain (required, string) Domain to generate the report for Example: GET https://x402-qr-api.vercel.app/api/domain-report?domain=example.com ## Machine-readable references - Discovery manifest: https://x402-qr-api.vercel.app/.well-known/x402.json - OpenAPI spec: https://x402-qr-api.vercel.app/openapi.json