Phone number validation: valid, E.164 format, country and line type
No account. Pay by card from $1 and your key appears right after payment. Get a key by card
Validate and format a phone number with the libphonenumber rules: whether it is valid and possible, the E.164 form, international and national formatting, country, calling code and line type (mobile, fixed-line, toll-free, VoIP…). Give +country code, or a national number and a two-letter country. Offline: nothing is sent and it does not say the line is in service. Use to clean contact lists or check a number before an SMS.
$0.001 per call with prepaid credits: $1 by card pays for 1,000 calls, with no account and no subscription.
Inputs
| Name | Type | Description |
|---|---|---|
number (required) | string | Phone number, ideally with +country code |
country | string | Two-letter country for national numbers without +code (US, GB, SE…) |
Request
Over HTTP, with a card key from /credits:
curl -H "Authorization: Bearer adt_…" "https://glyphtools.com/phone/validate?number=%2B1%20650-253-0000"
Node.js
const r = await fetch("https://glyphtools.com/phone/validate?number=%2B1%20650-253-0000", {
headers: { Authorization: "Bearer adt_…" },
});
const data = await r.json(); // 402 until the key is in the header
Python
import requests
r = requests.get("https://glyphtools.com/phone/validate?number=%2B1%20650-253-0000", headers={"Authorization": "Bearer adt_…"}, timeout=60)
data = r.json()
Or one of your 3 free calls, no key — the same request with &trial=1 on the end:
curl "https://glyphtools.com/phone/validate?number=%2B1%20650-253-0000&trial=1"
Without a key, the same URL answers 402 Payment Required with x402 and MPP terms, so an agent with a wallet pays per call in USDC (Base, Polygon, Arbitrum or Solana over x402; Base or Tempo over MPP) and retries.
Example result
{
"input": "+1 650-253-0000",
"valid": true,
"possible": true,
"e164": "+16502530000",
"country": "US",
"countryCallingCode": "+1",
"nationalNumber": "6502530000",
"international": "+1 650 253 0000",
"national": "(650) 253-0000",
"uri": "tel:+16502530000",
"type": "fixed-line-or-mobile"
}
From an AI agent (MCP)
Add the MCP server to Claude, Cursor or any MCP client. This tool is phone_validate, and the first 10 successful calls are free:
https://glyphtools.com/mcp