Returns information about the provided phone number.
Successful response
Unprocessable entity. Check the 'detail' field in response for details.
import telnyx telnyx.api_key = "YOUR_API_KEY" lookup = telnyx.NumberLookup.retrieve("+18665552368") lookup.type("carrier")
{- "data": {
- "caller_name": {
- "caller_name": "TELNYX LLC",
- "error_code": "10001"
}, - "carrier": {
- "error_code": null,
- "mobile_country_code": "US",
- "mobile_network_code": 866,
- "name": "Telnyx/4",
- "type": "voip"
}, - "country_code": "US",
- "fraud": null,
- "national_format": "(0312) 945-7420",
- "phone_number": "+13129457420",
- "portability": {
- "altspid": "073H",
- "altspid_carrier_name": "Telnyx/4",
- "altspid_carrier_type": "3",
- "city": "WAUKEGAN",
- "line_type": "voip",
- "lrn": "2245701999",
- "ocn": "073H",
- "ported_date": "2017-10-20",
- "ported_status": "Y",
- "spid": "073H",
- "spid_carrier_name": "Telnyx/4",
- "spid_carrier_type": "3",
- "state": "Illinois"
}, - "record_type": "number_lookup"
}
}