PinpointSMSVoiceV2 / Paginator / ListAvailablePhoneNumbers

ListAvailablePhoneNumbers

class PinpointSMSVoiceV2.Paginator.ListAvailablePhoneNumbers
paginator = client.get_paginator('list_available_phone_numbers')
paginate(**kwargs)

Creates an iterator that will paginate through responses from PinpointSMSVoiceV2.Client.list_available_phone_numbers().

See also: AWS API Documentation

Request Syntax

response_iterator = paginator.paginate(
    IsoCountryCode='string',
    NumberCapabilities=[
        'SMS'|'VOICE'|'MMS'|'RCS',
    ],
    NumberType='TEN_DLC',
    RegistrationId='string',
    NumberPreference=[
        {
            'PreferenceType': [
                'StartsWith'|'EndsWith'|'Contains'|'ExactMatch',
            ],
            'Filter': [
                'string',
            ]
        },
    ],
    PaginationConfig={
        'MaxItems': 123,
        'PageSize': 123,
        'StartingToken': 'string'
    }
)
Parameters:
  • IsoCountryCode (string) –

    [REQUIRED]

    The two-character code, in ISO 3166-1 alpha-2 format, for the country or region in which to search for available phone numbers. This operation currently supports only US.

  • NumberCapabilities (list) –

    [REQUIRED]

    The capabilities to filter by, such as SMS. Only phone numbers that support all of the specified capabilities are returned.

    • (string) –

  • NumberType (string) –

    [REQUIRED]

    The type of phone number to search for.

  • RegistrationId (string) –

    The registration associated with the request. A registration is required for regulated number types. You can specify either:

    • The unique identifier of the registration.

    • The Amazon Resource Name (ARN) of the registration.

  • NumberPreference (list) –

    Optional. If omitted, returns unfiltered available numbers. Max 1 element for List API.

    • (dict) –

      A single number preference — specifies a pattern type and filter value.

      • PreferenceType (list) – [REQUIRED]

        The type of match to apply to the filter values.

        • StartsWith: Returns numbers that begin with the filter value.

        • EndsWith: Returns numbers that end with the filter value.

        • Contains: Returns numbers that contain the filter value.

        • ExactMatch: Returns the number that exactly matches the filter value.

        • (string) –

          The type of pattern matching to apply.

      • Filter (list) – [REQUIRED]

        The digit pattern values to match against available phone numbers, using the specified preference type.

        • (string) –

          A filter value — either a pattern (e.g., “+1510”) or full E.164 number.

  • PaginationConfig (dict) –

    A dictionary that provides parameters to control pagination.

    • MaxItems (integer) –

      The total number of items to return. If the total number of items available is more than the value specified in max-items then a NextToken will be provided in the output that you can use to resume pagination.

    • PageSize (integer) –

      The size of each page.

    • StartingToken (string) –

      A token to specify where to start paginating. This is the NextToken from a previous response.

Return type:

dict

Returns:

Response Syntax

{
    'AvailablePhoneNumbers': [
        'string',
    ],

}

Response Structure

  • (dict) –

    • AvailablePhoneNumbers (list) –

      An array of phone numbers, in E.164 format, that are available to request based on the specified filters.

      • (string) –