Validate and format a phone number (offline)
parse_phone_numberValidate one phone number offline against libphonenumber metadata and return E.164, international, national and RFC 3966 formats, region, calling code and line type (from the original allocation). Valid means the number fits an allocated range, not that the line is connected or reachable; no carrier/HLR lookup. Read-only. Same engine, keys and limits as POST /v1/parse.
Tool call template
Replace each placeholder with a value matching the input schema. Only required parameters are included; add optional parameters as needed.
{
"id": 1,
"jsonrpc": "2.0",
"method": "tools/call",
"params": {
"arguments": {
"number": "<number>"
},
"name": "parse_phone_number"
}
}Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| number | Yes | The phone number, e.g. "+44 20 7946 0018" or "(213) 373-4253". Max 64 characters. | |
| default_country | No | Optional ISO 3166-1 alpha-2 region used when the number has no +country code, e.g. US, GB. |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| e164 | No | ||
| input | No | ||
| valid | Yes | ||
| reason | No | ||
| country | No | ||
| message | No | ||
| rfc3966 | No | ||
| national | No | ||
| possible | No | ||
| extension | No | ||
| line_type | No | ||
| calling_code | No | ||
| country_name | No | ||
| international | No | ||
| non_geographic | No | ||
| default_country | No | ||
| national_number | No |