Index » Search Phone Numbers
Search Phone Numbers
Usage
Authorization
Query parameters
Examples
Description
Use this method to perform the search of phone numbers.
The endpoint provides you with rich browsing & searching functionality, for example you're able with this endpoint:
- to browse phone numbers (including vanity numbers) in selected US state
- to search vanity number by pattern
- to get all phone numbers matching custom smart pattern (like X0Y0)
- to search vanity phone numbers by industry
- to search by price range
- to use sorting & paging in the search results
- and much more:)
Usage
GET https://api.phonenumberexpert.net/numbers?query_parameters (see available query parameters below)
Authorization
Basic Authentication: username (Account Name) and password (API Key) can be obtained from PNE owner, please contact him at https://www.phonenumberexpert.com/contacts/
Query parameters
- tf - Search within Toll Free Numbers, if tf is specified (e.f. tf=1). It performs the search within Local Numbers otherwise. If digital d or area code ac is provided, tf is detected automatically.
- d - Search for one specific number. Digital should start with area code (without leading 1), and contain only digits (10 digits), without any other sign (no space, no dash, no periods). Example: d=9477777777
- q - Search pattern. Can be digital (e.g. 333), alphanumeric (e.g. MAX - means 629), smart-pattern (combination of X, Y, 0; e.g. XXXYYYY - means double repeaters), combined alphanumeric and smart-pattern (e.g. MAX-XXXX - means 629-3333 or 629-4444 etc). Here for MAX-XXXX it respects dash, so that first "X" belong to word MAX and should be always 9 (on any phone keypad X=9), and XXXX after the dash is consequence of 4 same digit - any digit but zero. q can also contain asterisk, it means any digit (only one digit), for example q=*MAX**3 can match numbers like (305) 2269-703 or (305) 4269-133 etc. Also you can start pattern with NPA or NPA-NPA to search for local numbers starting with area code (see npa2 and np3 below for details). Also you can end pattern with QQQQ to search for local numbers ending with 4 same digits, e.g. q=MAX-QQQQ stands for MAX-3456, MAX-6789, MAX-3210 etc. Similar you can search for longer sequence using more Q letters, e.g. q=QQQQQQQ stands for 7-digit sequence like 2345678, 4567890, 6543210 etc. If you need to search only for ascending sequence, use U letter (shorten for "up") after series of Q, e.g. q=QQQU stands for ascending 4-digit sequence like 3456, but not 6543. Similar, q=QQQQD is descending 5-digit sequence.
- pos - One of the following: begin, end, any. Defines position of pattern in the phone number, e.g. "begin" match MAX-3333, "end" match 3333-MAX, "any" match both MAX-3333 and 3333-MAX, but DOES NOT match pattern in the middle like 3-MAX-33. If you need to search in the middle, use asterisks in q parameter instead of using pos, e.g. q=*MAX**3
- vip - Additional smart pattern for filtering numbers, applied to the end of number. For example, vip=XXXYYYY refines the search for double repeaters only.
- i - Industry. Show only vanity numbers related to specified industry. List of available industries can be observed when try to use unexisted industry (for example, specify i=a and you'll see the error that industry a is absent, following by the list of all available industries). Example: i=pizza
- ac - Area code. Returns numbers for provided comma-separated area codes only e.g. 305,512
- cc - Country code. Returns numbers for provided comma-separated country codes only e.g. US,CA. Is ignored for Toll Free search.
- sc - State code. Returns numbers for provided comma-separated state codes only; e.g. FL,CA. Is ignored for Toll Free search.
- rc - City. Returns numbers for provided comma-separated cities only; e.g. Minneapolis,Big%20Lake. It's ignored for Toll Free search.
- dc - Starting with created/modified date (e.g. dc=2019-12-31). For example, set it to date a week ago to see only new numbers added within last week.
- dm - Starting with created/modified date (e.g. dm=2019-12-31). For example, set it to date a week ago to see only numbers added and/or updated within last week.
- sort - Sort by one of the following: best, name, price, new, random. Here, "best" means best match (vanity & patterned numbers goes first), "new" means newest first, "random" means shuffled numbers (which are shuffled different way each request).
- dir - Direction of sorting - make sense only if sort is set and sort is not "new". Either asc (for ascending order) or desc (for descending order). Default is desc when sotr=new, and asc all the rest sorts. For example, to see search result sorted from expensive to cheap, use sort=price&dir=desc.
- totals - Show total count (it can significally slow down the request)
- filters - Show facets by states, areas, industries (it can significally slow down the request)
- min - Inclusive low bound of price range
- max - Inclusive high bound of price range. Numbers with hidden price ("CALL") are not included in result set when max_price is provided.
- x - Special flags. Can be one or comma-separated combination of the values listed below. Example: x=vanity,npa2
- feat - Show only featured numbers
- new - Show new numbers only (added to the system within last two weeks)
- priced - Show only numbers with price
- vanity - Show only vanity numbers (with pre-defined word pattern)
- npa2 - Show only numbers with local number starting with area code like (NPA) NPA-ABCD, e.g. (305) 305-6023. You can also use search pattern starting with word "NPA" like the following: numbers?q=NPA-ABCD
- npa3 - Show only numbers with local number containing area code two times like (NPA) NPA-NPA-X, e.g. (305) 305-3058. You can also use search pattern starting with word "NPA-NPA" like the following: numbers?q=NPA-NPA
- size - Maximum count of records in result set. Can be from 1 to 1000; default is 100.
- from - Index of the first record in result set, counting from 1. For example, if page size is 12, then for the first page use size=12&from=1, for the second page use size=12&from=13, for the third page use size=12&from=25 etc.
Please bear in mind, any request is limited by 10,000 records.
Examples
1. Get first 3 repeaters:
https://api.phonenumberexpert.net/numbers?vip=X000000&size=3 (see response)
2. Get next 3 repeaters:
https://api.phonenumberexpert.net/numbers?vip=X000000&size=3&from=4 (see response)
3. Show first 20 numbers, starting with "MAX" and ending with four same digits, in Texas, with area code 469, from $500 (inclusive):
https://api.phonenumberexpert.net/numbers?size=20&q=MAX&vip=XXXX&sc=TX&ac=469&min=500 (see response)
4. Show 5 vanity numbers from Jersey City:
https://api.phonenumberexpert.net/numbers?sc=NJ&rc=Jersey%20City&x=vanity&size=5 (see response)
5. Show 3 featured numbers:
https://api.phonenumberexpert.net/numbers?size=3&x=feat (see response)
Response contains success flag, total count of filtered numbers (before paging by "from" and "size" parameters), paging (from/to), records array.
Each record contains the following fields:
"n" - Display Name of the number. Can contain vanity words.
"d" - 10-digits phone number. Just 10 digits in a row without spaces, dashes, letters or any other characters.
"c" - Country Code ("US", "CA"; also we use "IS" for islands, including Puerto Rico)
"s" - State Code
"r" - City
"p" - either Price (number), or string "CALL" when no price defined (means "Call for pricing")
"po" - old price (might be displayed as crossed out)
"abd" - activation business days, how long it takes to activate the number
"note" - optional note
Result of the first query can be similar to the following:
{
"success": true,
"totalCount": 245,
"from": 1,
"to": 3,
"records": [
{ "n": "(224) 400-0000", "d": "2244000000", "c": "US", "s": "IL", "r": "Arlington Heights", "p":"CALL" },
{ "n": "(248) 600-0000", "d": "2486000000", "c": "US", "s": "MI", "r": "Pontiac", "p": "CALL" },
{ "n": "(248) 900-0000", "d": "2489000000", "c": "US", "s": "MI", "r": "Ortonville", "p": "CALL" }
]
}
Result of the second query looks similar to the following:
{
"success": true,
"totalCount": 245,
"from": 4,
"to": 6,
"records": [
{ "n": "(260) 300-0000", "d": "2603000000", "c": "US", "s": "IN", "r": "Woodburn", "p": "CALL" },
{ "n": "(332) 300-0000", "d": "3323000000", "c": "US", "s": "NY", "p": "CALL" },
{ "n": "(332) 500-0000", "d": "3325000000", "c": "US", "s": "NY", "p": "CALL" }
]
}
Result of the third query can be similar to the following:
{
"success": true,
"totalCount": 1,
"from": 1,
"to": 1,
"records": [
{ "n": "(469) MAX-9999", "d": "4696299999", "c": "US", "s": "TX", "r": "Dallas Fort Worth Airport", "p": 799 },
{ "n": "(469) MAX-2222", "d": "4696292222", "c": "US", "s": "TX", "r": "Dallas Fort Worth Airport", "p": 1299.99 },
]
}
Result of the fourth query (vanity Miami numbers) can be similar to the following:
{
"success": true,
"totalCount": 330,
"from": 1,
"to": 5,
"records": [
{ "n": "(201) 918-HIGH", "d": "2019184444", "c": "US", "s": "NJ", "r": "Jersey City", "p": 399.99 },
{ "n": "(201) 984-4444", "d": "2019844444", "c": "US", "s": "NJ", "r": "Jersey City", "p": 699.99 },
{ "n": "(201) 2041-BUT", "d": "2012041288", "c": "US", "s": "NJ", "r": "Jersey City", "p": 249.99 },
{ "n": "(201) 2041-MYR", "d": "2012041697", "c": "US", "s": "NJ", "r": "Jersey City", "p": 199.99 },
{ "n": "(201) 2041-OZU", "d": "2012041698", "c": "US", "s": "NJ", "r": "Jersey City", "p": 199.99 }
]
}
Result of the fifth query (featured vanity numbers) can be similar to the following:
{
"success": true,
"totalCount": 56,
"from": 1,
"to": 3,
"records": [
{"n": "(212) 222-2221", "d": "2122222221", "c": "US", "s": "NY", "r": "New York City Zone 01", "x": ["feat"] },
{"n": "(212) 344-4444", "d": "2123444444", "c": "US", "s": "NY", "r": "New York City Zone 01", "p": 29999, "x": ["feat"] },
{"n": "(310) 928-2437", "d": "3109282437", "c": "US", "s": "CA", "r": "Compton: Compton DA", "p": 49999, "x": ["feat"] }
]
}