TrackDrive API

    • Calls
      • Calls By Third-Party
      • Call Records
      • Uncompleted Calls
      • Scheduled Callbacks
      • Recording Retention
    • Leads
      • Lead By Third-Party
      • Lead Records
      • Lead Import
      • Lead Action Logs
      • Retarget
      • Lead Retarget Logs
    • Data Append
      • Data Appends
      • Data Append Groups
    • Offers
      • Offer Settings
      • Call Flow
      • Call Flow: Answer Groups
      • Call Flow: Answers
      • Contact Fields
      • Contact Fields: Picklist Values
      • Key Press Flow Groups
      • Key Press Flows
      • Advertising Optimizer Tokens
      • Impression Tokens
      • AMD Flows
      • Real Time Impressions
    • Ping/Post
      • Ping/Post By Third-Party
      • Ping/Post Settings
      • Ping/Post Logs
    • Buyers
      • Buyer Settings
      • Buyer Groups
      • Buyer Fleets
      • Suppression Lists
      • Suppression Files
    • Traffic Sources
      • Traffic Source Settings
      • Conversions Settings
      • Traffic Source Rate Limiters
      • Traffic Source Rate Limits
    • Numbers
      • Phone Numbers
        • Overview
        • GET List your phone numbers
        • POST Purchase a phone number
        • GET Show the details of phone number
        • PUT Update a phone number's source or pool
        • DELETE Unrent a phone number
        • GET Search available phone numbers for purchase
      • Number Pools
        • Overview
        • GET List Phone Number Pools
        • GET Build Phone Number Pool with defaults
        • POST Create Phone Number Pool
        • GET Get Phone Number Pool by id
        • PUT Update Phone Number Pool by id
        • DELETE Destroy Phone Number Pool by id
      • Virtual Numbers
        • Overview
        • GET List Virtual Number records
        • GET Build Virtual Number with defaults
        • POST Create Virtual Number
        • GET Get Virtual Number by id
        • DELETE Destroy Virtual Number by id
      • Number Orders
        • Overview
        • GET List Number Orders
        • GET Build Number Order with defaults
        • POST Create Number Order
        • GET Get Number Order by id
        • PUT Update Number Order by id
        • DELETE Destroy Number Order by id
      • Number Order Prefixes
        • Overview
        • GET List Number Order Prefix records
        • GET Build Number Order Prefix with defaults
        • POST Create Number Order Prefix
        • GET Get Number Order Prefix by id
        • PUT Update Number Order Prefix by id
        • DELETE Destroy Number Order Prefix by id
      • Mitigation Numbers
        • Overview
        • GET List mitigation numbers
        • PUT Update a number's spam-tag mitigation
        • DELETE Remove a number from spam-tag mitigation
      • Telephone Accounts
        • Overview
        • GET List Phone Providers
        • GET Find Specific Phone Provider
        • PUT Update Specific Phone Provider
    • Schedules
      • Schedule Settings
      • Triggers
      • Actions
      • Action Groups
      • Distributions
      • Number Pools
      • Wait Rule Groups
      • Wait Rules
    • Agents
      • Call Centers
      • Agent Wizard
      • Agent Scripts
      • Call Dispositions
      • Call Actions
      • Agent Messages
      • Agent Status Timestamp
    • SMS
      • SMS Flows
      • Outgoing SMS
      • Incoming SMS
    • Transcription
      • Transcripts
      • API Audio Transcriptions
      • Transcription Flow Groups
      • Transcription Flows
      • Transcription Keyword Groups
      • Transcription Keyword
    • Tokens
      • Token
      • Values
      • SIP Header Parsing
      • SIP Key
      • SIP Header
    • Routing Rules
      • State Rules
      • Call Frequency
      • Call Times
      • Holidays
      • Zip Codes
      • Zip Code List Files
    • Contacts & Blacklist
      • Blacklist
      • Blacklist: Files
      • Blacklist: Clear Blacklist
    • Webhooks
      • Event Triggers
      • Webhook URLs
      • Webhook Param
      • Webhook Logs
      • Webhook Subscriptions
    • Integrations
      • Integration
      • Zoho Action
      • Secret
    • Playlists
      • Sound Playlists
      • Sound Files
    • Reports & Exports
      • Data Exports
      • Lead & Call Logs
      • Collections
      • Audit Logs
    • Account
      • My Companies
      • Teams
      • Billing
    1. TrackDrive API
    2. Phone Numbers

    GET /phone_numbers/search

    Authorization Required
    https://[your-subdomain].trackdrive.com/api/v1/phone_numbers/search

    Search available phone numbers for purchase

    Returns a list of available phone numbers for sale. Can be used with POST /api/v1/phone_numbers?requested_number= to purchase a number.

    Params

    Param name Description
    country
    Optional

    Two-letter country code (default: US)

    • Must be a String

    toll_free
    Optional

    Whether to search toll-free numbers

    • Must be one of: true, false.

    prefix
    Optional

    Restrict by area code (NPA). Example: 415, 209, 719

    • Must be a String

    query
    Optional

    Full or partial phone number to match

    • Must be a String

    Example Request
    curl 'https://[your-subdomain].trackdrive.com/api/v1/phone_numbers/search?prefix=415&toll_free=false' \
      -H 'Authorization: Basic BASE64_ENCODED_PUBLIC_KEY_AND_PRIVATE_KEY'
    Example Response 200
    {
      "status": 200,
      "success": true,
      "phone_number_search_results": [
        {
          "id": "+14154151864",
          "type": "PhoneNumberSearchResult",
          "phone_number": "+14154151864",
          "country": "US",
          "toll_free": false,
          "prefix": "415"
        },
        {
          "id": "+14154471210",
          "type": "PhoneNumberSearchResult",
          "phone_number": "+14154471210",
          "country": "US",
          "toll_free": false,
          "prefix": "415"
        },
        {
          "id": "+14155297950",
          "type": "PhoneNumberSearchResult",
          "phone_number": "+14155297950",
          "country": "US",
          "toll_free": false,
          "prefix": "415"
        },
        {
          "id": "+14155868810",
          "type": "PhoneNumberSearchResult",
          "phone_number": "+14155868810",
          "country": "US",
          "toll_free": false,
          "prefix": "415"
        },
        {
          "id": "+14156952675",
          "type": "PhoneNumberSearchResult",
          "phone_number": "+14156952675",
          "country": "US",
          "toll_free": false,
          "prefix": "415"
        },
        {
          "id": "+14156978735",
          "type": "PhoneNumberSearchResult",
          "phone_number": "+14156978735",
          "country": "US",
          "toll_free": false,
          "prefix": "415"
        },
        {
          "id": "+14158677640",
          "type": "PhoneNumberSearchResult",
          "phone_number": "+14158677640",
          "country": "US",
          "toll_free": false,
          "prefix": "415"
        },
        {
          "id": "+14158817332",
          "type": "PhoneNumberSearchResult",
          "phone_number": "+14158817332",
          "country": "US",
          "toll_free": false,
          "prefix": "415"
        },
        {
          "id": "+14159259977",
          "type": "PhoneNumberSearchResult",
          "phone_number": "+14159259977",
          "country": "US",
          "toll_free": false,
          "prefix": "415"
        },
        {
          "id": "+14159415711",
          "type": "PhoneNumberSearchResult",
          "phone_number": "+14159415711",
          "country": "US",
          "toll_free": false,
          "prefix": "415"
        }
      ],
      "metadata": {
        "root": "phone_number_search_results",
        "page": 1,
        "total_pages": 0,
        "per_page": 25,
        "total_count": 10,
        "next_cursor": 0.0
      }
    }