twilio.rest.lookups.v1 package

Submodules

twilio.rest.lookups.v1.phone_number module

This code was generated by / _ _ _| _ _

(_)/(_)(_|/| |(/_ v1.0.0 / /
class twilio.rest.lookups.v1.phone_number.PhoneNumberContext(version, phone_number)[source]

Bases: twilio.base.instance_context.InstanceContext

fetch(country_code=<object object>, type=<object object>, add_ons=<object object>, add_ons_data=<object object>)[source]

Fetch the PhoneNumberInstance

Parameters:
  • country_code (unicode) – The ISO country code of the phone number
  • type (list[unicode]) – The type of information to return
  • add_ons (list[unicode]) – The unique_name of an Add-on you would like to invoke
  • add_ons_data (dict) – Data specific to the add-on you would like to invoke
Returns:

The fetched PhoneNumberInstance

Return type:

twilio.rest.lookups.v1.phone_number.PhoneNumberInstance

class twilio.rest.lookups.v1.phone_number.PhoneNumberInstance(version, payload, phone_number=None)[source]

Bases: twilio.base.instance_resource.InstanceResource

class Type[source]

Bases: object

LANDLINE = 'landline'
MOBILE = 'mobile'
VOIP = 'voip'
add_ons
Returns:A JSON string with the results of the Add-ons you specified
Return type:dict
caller_name
Returns:The name of the phone number’s owner
Return type:dict
carrier
Returns:The telecom company that provides the phone number
Return type:dict
country_code
Returns:The ISO country code for the phone number
Return type:unicode
fetch(country_code=<object object>, type=<object object>, add_ons=<object object>, add_ons_data=<object object>)[source]

Fetch the PhoneNumberInstance

Parameters:
  • country_code (unicode) – The ISO country code of the phone number
  • type (list[unicode]) – The type of information to return
  • add_ons (list[unicode]) – The unique_name of an Add-on you would like to invoke
  • add_ons_data (dict) – Data specific to the add-on you would like to invoke
Returns:

The fetched PhoneNumberInstance

Return type:

twilio.rest.lookups.v1.phone_number.PhoneNumberInstance

national_format
Returns:The phone number, in national format
Return type:unicode
phone_number
Returns:The phone number in E.164 format
Return type:unicode
url
Returns:The absolute URL of the resource
Return type:unicode
class twilio.rest.lookups.v1.phone_number.PhoneNumberList(version)[source]

Bases: twilio.base.list_resource.ListResource

get(phone_number)[source]

Constructs a PhoneNumberContext

Parameters:phone_number – The phone number to fetch in E.164 format
Returns:twilio.rest.lookups.v1.phone_number.PhoneNumberContext
Return type:twilio.rest.lookups.v1.phone_number.PhoneNumberContext
class twilio.rest.lookups.v1.phone_number.PhoneNumberPage(version, response, solution)[source]

Bases: twilio.base.page.Page

get_instance(payload)[source]

Build an instance of PhoneNumberInstance

Parameters:payload (dict) – Payload response from the API
Returns:twilio.rest.lookups.v1.phone_number.PhoneNumberInstance
Return type:twilio.rest.lookups.v1.phone_number.PhoneNumberInstance

Module contents

This code was generated by / _ _ _| _ _

(_)/(_)(_|/| |(/_ v1.0.0 / /
class twilio.rest.lookups.v1.V1(domain)[source]

Bases: twilio.base.version.Version

phone_numbers
Return type:twilio.rest.lookups.v1.phone_number.PhoneNumberList