list_phone_numbers_v2
¶
list_phone_numbers_v2(
*,
config_overrides: Optional[ConnectClientConfig] = None,
target_arn: Optional[ARN] = None,
instance_id: Optional[InstanceId] = None,
max_results: Optional[MaxResult1000] = None,
next_token: Optional[LargeNextToken] = None,
phone_number_country_codes: Optional[PhoneNumberCountryCodes] = None,
phone_number_types: Optional[PhoneNumberTypes] = None,
phone_number_prefix: Optional[PhoneNumberPrefix] = None,
) -> ListPhoneNumbersV2Response
Lists phone numbers claimed to your Connect Customer instance or traffic distribution group. If the provided TargetArn is a traffic distribution group, you can call this API in both Amazon Web Services Regions associated with traffic distribution group.
For more information about phone numbers, see Set Up Phone Numbers for Your Contact Center in the Connect Customer Administrator Guide.
-
When given an instance ARN,
ListPhoneNumbersV2returns only the phone numbers claimed to the instance. -
When given a traffic distribution group ARN
ListPhoneNumbersV2returns only the phone numbers claimed to the traffic distribution group.
Parameters:
-
target_arn(Optional[ARN], default:None) –The Amazon Resource Name (ARN) for Connect Customer instances or traffic distribution groups that phone number inbound traffic is routed through. If both
TargetArnandInstanceIdinput are not provided, this API lists numbers claimed to all the Connect Customer instances belonging to your account in the same Amazon Web Services Region as the request. -
instance_id(Optional[InstanceId], default:None) –The identifier of the Connect Customer instance that phone numbers are claimed to. You can find the instance ID in the Amazon Resource Name (ARN) of the instance. If both
TargetArnandInstanceIdare not provided, this API lists numbers claimed to all the Connect Customer instances belonging to your account in the same Amazon Web Services Region as the request. -
max_results(Optional[MaxResult1000], default:None) –The maximum number of results to return per page.
-
next_token(Optional[LargeNextToken], default:None) –The token for the next set of results. Use the value returned in the previous response in the next request to retrieve the next set of results.
-
phone_number_country_codes(Optional[PhoneNumberCountryCodes], default:None) –The ISO country code.
-
phone_number_types(Optional[PhoneNumberTypes], default:None) –The type of phone number.
-
phone_number_prefix(Optional[PhoneNumberPrefix], default:None) –The prefix of the phone number. If provided, it must contain
+as part of the country code.
Raises:
-
AccessDeniedException–You do not have sufficient permissions to perform this action.
-
InternalServiceException–Request processing failed because of an error or failure with the service.
-
InvalidParameterException–One or more of the specified parameters are not valid.
-
ResourceNotFoundException–The specified resource was not found.
-
ThrottlingException–The throttling limit has been exceeded.
-
UnknownServiceError–The service returned an error code this client does not model.
Source code in docs_src/capo_connect/_services/connect.py
16468 16469 16470 16471 16472 16473 16474 16475 16476 16477 16478 16479 16480 16481 16482 16483 16484 16485 16486 16487 16488 16489 16490 16491 16492 16493 16494 16495 16496 16497 16498 16499 16500 16501 16502 16503 16504 16505 16506 16507 16508 16509 16510 16511 16512 16513 16514 16515 16516 16517 16518 16519 16520 16521 16522 16523 16524 16525 16526 16527 16528 16529 16530 16531 16532 16533 16534 16535 16536 16537 16538 16539 16540 16541 16542 16543 16544 16545 16546 16547 | |