Rate this page:

PhoneNumbers

Methods

AttachPhoneNumber

Copy URL

Attach the phone number to the account. Note that phone numbers of some countries may require additional verification steps.

AttachPhoneNumber example

AttachPhoneNumber example

Attach the one US phone number to the account 1.

Parameters

  • phone_count:

    number

    The phone count to attach.

  • phone_number:

    stringlist

    The phone number that can be used instead of phone_count. See the GetNewPhoneNumbers method.

  • country_code:

    string

    Optional

    The country code.

  • phone_category_name:

    string

    Optional

    The phone category name. See the GetPhoneNumberCategories method.

  • country_state:

    string

    Optional

    The country state. See the GetPhoneNumberCategories and GetPhoneNumberCountryStates methods.

  • phone_region_id:

    number

    Optional

    The phone region ID. See the GetPhoneNumberRegions method.

  • regulation_address_id:

    number

    Optional

    The phone regulation address ID.

Returns

BindPhoneNumberToApplication

Copy URL

Bind the phone number to the application or unbind the phone number from the application. You should specify the application_id or application_name if you specify the rule_name.

BindPhoneNumberToApplication example

BindPhoneNumberToApplication example

Bind the phone 1 to the application 1.

Parameters

  • phone_id:

    intlist

    The phone ID list separated by the ';' symbol or the 'all' value.

  • phone_number:

    stringlist

    The phone number list separated by the ';' symbol that can be used instead of phone_id.

  • application_id:

    number

    The application ID.

  • application_name:

    string

    The application name that can be used instead of application_id.

  • rule_id:

    number

    Optional

    The rule ID.

  • rule_name:

    string

    Optional

    The rule name that can be used instead of rule_id.

  • bind:

    boolean

    Optional
    Defaults on:  true

    Bind or unbind?

Returns

  • result:

    number

    1

DeactivatePhoneNumber

Copy URL

Deactivates the phone number.

DeactivatePhoneNumber example

DeactivatePhoneNumber example

Deactivate the phone 1.

Parameters

  • phone_id:

    intlist

    The phone ID list separated by the ';' symbol or the 'all' value.

  • phone_number:

    stringlist

    The phone number list separated by the ';' symbol that can be used instead of phone_id.

Returns

  • result:

    number

    1

GetPhoneNumbers

Copy URL

Gets the account phone numbers.

GetPhoneNumbers example

GetPhoneNumbers example

Get the two attached phone numbers.

Parameters

  • phone_id:

    number

    Optional

    The particular phone ID to filter

  • application_id:

    number

    Optional

    The application ID.

  • application_name:

    string

    Optional

    The application name that can be used instead of application_id.

  • is_bound_to_application:

    boolean

    Optional

    Is a phone bound to an application.

  • phone_template:

    string

    Optional

    The phone number start to filter

  • country_code:

    stringlist

    Optional

    The country code list separated by the ';' symbol.

  • phone_category_name:

    string

    Optional

    The phone category name. See the GetPhoneNumberCategories method.

  • canceled:

    boolean

    Optional

    The flag of the canceled (deleted) subscription to filter.

  • deactivated:

    boolean

    Optional

    The flag of the deactivated (frozen) subscription to filter.

  • auto_charge:

    boolean

    Optional

    The auto_charge flag to filter.

  • from_phone_next_renewal:

    date

    Optional

    The UTC 'from' date filter in format: YYYY-MM-DD

  • to_phone_next_renewal:

    date

    Optional

    The UTC 'to' date filter in format: YYYY-MM-DD

  • from_phone_purchase_date:

    timestamp

    Optional

    The UTC 'from' date filter in 24-h format: YYYY-MM-DD HH:mm:ss

  • to_phone_purchase_date:

    timestamp

    Optional

    The UTC 'to' date filter in 24-h format: YYYY-MM-DD HH:mm:ss

  • child_account_id:

    intlist

    Optional

    The child account ID list separated by the ';' symbol or the 'all' value.

  • children_phones_only:

    boolean

    Optional
    Defaults on:  false

    Set true to get the children phones only.

  • verification_name:

    string

    Optional

    The required account verification name to filter.

  • verification_status:

    stringlist

    Optional

    The account verification status list separated by the ';' symbol. The following values are possible: REQUIRED, IN_PROGRESS, VERIFIED

  • from_unverified_hold_until:

    date

    Optional

    Unverified phone hold until the date (from …) in format: YYYY-MM-DD

  • to_unverified_hold_until:

    date

    Optional

    Unverified phone hold until the date (… to) in format: YYYY-MM-DD

  • can_be_used:

    boolean

    Optional

    Can the unverified account use the phone?

  • order_by:

    string

    Optional

    The following values are available: 'phone_number' (ascent order), 'phone_price' (ascent order), 'phone_country_code' (ascent order), 'deactivated' (deactivated first, active last), 'purchase_date' (descent order), 'phone_next_renewal' (ascent order), 'verification_status', 'unverified_hold_until' (ascent order), 'verification_name'.

  • sandbox:

    string

    Optional

    Flag allows you to display only the numbers of the sandbox, real numbers, or all numbers. The following values are possible: 'all', 'true', 'false'.

  • count:

    number

    Optional
    Defaults on:  100

    The max returning record count.

  • offset:

    number

    Optional
    Defaults on:  0

    The first N records will be skipped in the output.

  • phone_region_name:

    stringlist

    Optional

    The region names list separated by the ';' symbol.

  • rule_id:

    intlist

    Optional

    The rule ID list separated by the ';' symbol.

  • rule_name:

    stringlist

    Optional

    The rule names list separated by the ';' symbol. Can be used only if application_id or application_name is specified.

  • is_bound_to_rule:

    boolean

    Optional

    Is the number bound to any rule?

Returns

GetNewPhoneNumbers

Copy URL

Gets the new phone numbers.

GetNewPhoneNumbers example

GetNewPhoneNumbers example

Get the two new fixed Russian phone numbers at max.

Parameters

  • country_code:

    string

    Optional

    The country code.

  • phone_category_name:

    string

    Optional

    The phone category name. See the GetPhoneNumberCategories function.

  • country_state:

    string

    Optional

    The country state. See the GetPhoneNumberCategories and GetPhoneNumberCountryStates functions.

  • phone_region_id:

    number

    Optional

    The phone region ID. See the GetPhoneNumberRegions method.

  • count:

    number

    Optional
    Defaults on:  20

    The max returning record count.

  • offset:

    number

    Optional
    Defaults on:  0

    The first N records will be skipped in the output.

Returns

  • total_count:

    number

    The total found phone count.

  • count:

    number

    The returned phone count.

GetPhoneNumberCategories

Copy URL

Gets the phone number categories.

GetPhoneNumberCategories example

GetPhoneNumberCategories example

Get the all phone number categories.

Parameters

  • country_code:

    string

    Optional

    The country code.

  • sandbox:

    string

    Optional

    Flag allows you to display phone number categories only of the sandbox, real or all .The following values are possible: 'all', 'true', 'false'.

  • locale:

    string

    Optional

    The 2-letter locale code. Supported values are EN, RU.

GetPhoneNumberCountryStates

Copy URL

Gets the phone number country states.

GetPhoneNumberCountryStates example

GetPhoneNumberCountryStates example

Get the USA states.

Parameters

  • country_code:

    string

    Optional

    The country code.

  • phone_category_name:

    string

    Optional

    The phone category name. See the GetPhoneNumberCategories function.

  • country_state:

    string

    Optional

    The country state code (example: AL, CA, … ).

GetPhoneNumberRegions

Copy URL

Get the country regions of the phone numbers. The response will also contain the info about multiple numbers subscription for the child accounts.

GetPhoneNumberRegions example

GetPhoneNumberRegions example

Get the Russian regions of the phone numbers.

Parameters

  • country_code:

    string

    Optional

    The country code.

  • phone_category_name:

    string

    Optional

    The phone category name. See the GetPhoneNumberCategories method.

  • country_state:

    string

    Optional

    The country state code (example: AL, CA, … ).

  • omit_empty:

    boolean

    Optional
    Defaults on:  true

    Set to 'false' to show all the regions (with and without phone numbers in stock).

  • phone_region_id:

    number

    Optional

    The phone region ID to filter.

  • phone_region_name:

    string

    Optional

    The phone region name to filter.

  • phone_region_code:

    string

    Optional

    The region phone prefix to filter.

  • locale:

    string

    Optional

    The 2-letter locale code. Supported values are EN, RU.

GetActualPhoneNumberRegion

Copy URL

Get actual info on the country region of the phone numbers. The response will also contain the info about multiple numbers subscription for the child accounts.

GetActualPhoneNumberRegion example

GetActualPhoneNumberRegion example

Get the Germany region of the phone numbers.

Parameters

  • country_code:

    string

    Optional

    The country code.

  • phone_category_name:

    string

    Optional

    The phone category name. See the GetPhoneNumberCategories method.

  • phone_region_id:

    number

    Optional

    The phone region ID to filter.

  • locale:

    string

    Optional

    The 2-letter locale code. Supported values are EN, RU.