About this endpoint
What it does
Parses a phone number and returns its formatted representations, including E.164, international, and national formats. It also indicates whether the number is valid and may include region and country code details.
Query Parameter(s)
| Attribute | Type | Mandatory | Description |
|---|---|---|---|
| number | String | Yes | The phone number to parse. |
| country | String | No | Default: US. The country to use for parsing. |
Response
Returns a JSON object with e164, input, valid, region, national, country_code, and international fields. The response includes formatted phone number strings, a boolean validity flag, and optional region and country code information.
| Attribute | Type | Mandatory | Description |
|---|---|---|---|
| e164 | String | No | The phone number in E.164 format. |
| input | String | No | The input phone number as parsed by the service. |
| valid | Boolean | No | Whether the phone number is valid. |
| region | String | No | The detected region for the phone number. |
| national | String | No | The phone number in national format. |
| country_code | Integer | No | The country calling code. |
| international | String | No | The phone number in international format. |