associate_phone_numbers_with_voice_connector_group

Chime.Client.associate_phone_numbers_with_voice_connector_group(**kwargs)

Associates phone numbers with the specified Amazon Chime Voice Connector group.

See also: AWS API Documentation

Request Syntax

response = client.associate_phone_numbers_with_voice_connector_group(
    VoiceConnectorGroupId='string',
    E164PhoneNumbers=[
        'string',
    ],
    ForceAssociate=True|False
)
Parameters
  • VoiceConnectorGroupId (string) --

    [REQUIRED]

    The Amazon Chime Voice Connector group ID.

  • E164PhoneNumbers (list) --

    [REQUIRED]

    List of phone numbers, in E.164 format.

    • (string) --
  • ForceAssociate (boolean) -- If true, associates the provided phone numbers with the provided Amazon Chime Voice Connector Group and removes any previously existing associations. If false, does not associate any phone numbers that have previously existing associations.
Return type

dict

Returns

Response Syntax

{
    'PhoneNumberErrors': [
        {
            'PhoneNumberId': 'string',
            'ErrorCode': 'BadRequest'|'Conflict'|'Forbidden'|'NotFound'|'PreconditionFailed'|'ResourceLimitExceeded'|'ServiceFailure'|'AccessDenied'|'ServiceUnavailable'|'Throttled'|'Throttling'|'Unauthorized'|'Unprocessable'|'VoiceConnectorGroupAssociationsExist'|'PhoneNumberAssociationsExist',
            'ErrorMessage': 'string'
        },
    ]
}

Response Structure

  • (dict) --

    • PhoneNumberErrors (list) --

      If the action fails for one or more of the phone numbers in the request, a list of the phone numbers is returned, along with error codes and error messages.

      • (dict) --

        If the phone number action fails for one or more of the phone numbers in the request, a list of the phone numbers is returned, along with error codes and error messages.

        • PhoneNumberId (string) --

          The phone number ID for which the action failed.

        • ErrorCode (string) --

          The error code.

        • ErrorMessage (string) --

          The error message.

Exceptions

  • Chime.Client.exceptions.UnauthorizedClientException
  • Chime.Client.exceptions.NotFoundException
  • Chime.Client.exceptions.ForbiddenException
  • Chime.Client.exceptions.BadRequestException
  • Chime.Client.exceptions.AccessDeniedException
  • Chime.Client.exceptions.ThrottledClientException
  • Chime.Client.exceptions.ServiceUnavailableException
  • Chime.Client.exceptions.ServiceFailureException