API & MCP

Everything a person can do on LocaleKit Country Format Rules, a program or AI agent can do with the same inputs and get the identical result.

HTTP API

LocaleKit Country Format Rules

Pick a country to get its address form as an ordered field schema (with required flags and local labels like PIN code or Prefecture), the postal-code pattern with examples and validation, the calling code with basic E.164 normalisation, and date/number formatting examples for the country’s likely locale.

Inputs of LocaleKit Country Format Rules
FieldTypeDefaultDescription
country (required)select (AC, AD, AE, AF, AG, AI, AL, AM, AO, AQ, AR, AS, AT, AU, AW, AX, AZ, BA, BB, BD, BE, BF, BG, BH, BI, BJ, BL, BM, BN, BO, BQ, BR, BS, BT, BV, BW, BY, BZ, CA, CC, CD, CF, CG, CH, CI, CK, CL, CM, "DE"Country
postalCodetext—Postal code to validate (optional)
phonetext—Phone number to normalise (optional). National or international format; extensions (ext. 12) are dropped.

Example request

Germany: postal code + phone

curl -X POST https://localekit.usefulweb.site/api/v1/calculate -H 'content-type: application/json' -d '{"country":"DE","postalCode":"10115","phone":"030 901820"}'

Every result contains

inputs (normalised, defaults applied), summary, result (validated against the published schema), units, assumptions, sources, warnings, computedAt and links.

MCP (Model Context Protocol)

{
  "mcpServers": {
    "localekit": { "type": "http", "url": "https://localekit.usefulweb.site/mcp" }
  }
}