Format Validator

Validate a value against a known format. $0.01 per request.

What it does

Checks whether a value is structurally valid for a given format — with real checksum validation where it applies (Luhn for cards, mod-97 for IBAN), not just a shape guess.

Endpoint

MethodPOST
Path/validate
Content-Typeapplication/json

Fields

fieldrequireddescription
valueyesThe value to validate
formatyesOne of: email, url, uuid, ipv4, ipv6, credit_card, iban, phone_e164, date_iso8601, postal_code_us, postal_code_uk, postal_code_ca

Example

curl -X POST https://format-validator.pdfextractapi.workers.dev/validate \
  -H "Content-Type: application/json" \
  -d '{"value": "GB29NWBK60161331926819", "format": "iban"}'

Example response

{ "value": "GB29NWBK60161331926819", "format": "iban", "valid": true, "reason": null }

Errors

Errors return a non-200 status with { "error": { "code": "...", "message": "..." } }. Common codes: missing_value, unknown_format.

Payment

This endpoint is paid per-request via the x402 protocol (HTTP 402 + USDC). Unpaid requests receive a 402 response with payment instructions.

Try it in your browser