invalid_number
The right length, but not assignable under the plan
The number has a plausible length but its leading digits are not assigned to any number type in the plan of its country, so no subscriber can hold it.
- appears in
- reason
- credits
- Free. Invalid numbers never cost a credit.
What it means
Numbering plans assign prefixes to types (geographic, mobile, toll-free, premium); digits outside every assigned prefix, such as a North American exchange starting with 0 or 1, are not a dialable number. Spaw reports what the plan says and never answers valid for a number the plan excludes.
What to do
Treat it like a typo. If the number came from a form, ask the user to re-enter it; on an imported list, drop it.
Example response
{
"valid": false,
"reason": "invalid_number",
"e164": null,
"country": null,
"risk_score": null
}Abbreviated: a real answer carries all 33 fields, listed in the validate-phone reference.
Related
- missing_country · no country was given, and the input does not carry one
- invalid_country_code · the calling code after the + is not assigned to any country
- too_short · fewer digits than any number in that plan
- too_long · more digits than any number in that plan
- not_a_number · the input does not look like a phone number
- invalid_length · a digit count the plan never uses
- unassigned_block · the regulator has not allocated the block the number sits in
- emergency_number · an emergency number, not a subscriber line
- short_number · a short code or service number, not a subscriber line
- All verdict reasons
- Phone fields and the risk score
- API reference
markdown version: /docs/reasons/invalid_number.md