list_phone_numbers
async
¶
list_phone_numbers(
instance_id: InstanceId,
*,
config_overrides: Optional[AsyncConnectClientConfig] = None,
phone_number_types: Optional[PhoneNumberTypes] = None,
phone_number_country_codes: Optional[PhoneNumberCountryCodes] = None,
next_token: Optional[NextToken] = None,
max_results: Optional[MaxResult1000] = None,
) -> ListPhoneNumbersResponse
Provides information about the phone numbers for the specified Connect Customer instance.
For more information about phone numbers, see Set Up Phone Numbers for Your Contact Center in the Connect Customer Administrator Guide.
-
We recommend using ListPhoneNumbersV2 to return phone number types. ListPhoneNumbers doesn't support number types
UIFN,SHARED,THIRD_PARTY_TF, andTHIRD_PARTY_DID. While it returns numbers of those types, it incorrectly lists them asTOLL_FREEorDID. -
The phone number
Arnvalue that is returned from each of the items in the PhoneNumberSummaryList cannot be used to tag phone number resources. It will fail with aResourceNotFoundException. Instead, use the ListPhoneNumbersV2 API. It returns the new phone number ARN that can be used to tag phone number resources.
Parameters:
-
instance_id(InstanceId) –The identifier of the Connect Customer instance. You can find the instance ID in the Amazon Resource Name (ARN) of the instance.
-
phone_number_types(Optional[PhoneNumberTypes], default:None) –The type of phone number.
We recommend using ListPhoneNumbersV2 to return phone number types. While ListPhoneNumbers returns number types
UIFN,SHARED,THIRD_PARTY_TF, andTHIRD_PARTY_DID, it incorrectly lists them asTOLL_FREEorDID. -
phone_number_country_codes(Optional[PhoneNumberCountryCodes], default:None) –The ISO country code.
-
next_token(Optional[NextToken], 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.
-
max_results(Optional[MaxResult1000], default:None) –The maximum number of results to return per page. The default MaxResult size is 100.
Raises:
-
InternalServiceException–Request processing failed because of an error or failure with the service.
-
InvalidParameterException–One or more of the specified parameters are not valid.
-
InvalidRequestException–The request is 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/async_connect.py
16597 16598 16599 16600 16601 16602 16603 16604 16605 16606 16607 16608 16609 16610 16611 16612 16613 16614 16615 16616 16617 16618 16619 16620 16621 16622 16623 16624 16625 16626 16627 16628 16629 16630 16631 16632 16633 16634 16635 16636 16637 16638 16639 16640 16641 16642 16643 16644 16645 16646 16647 16648 16649 16650 16651 16652 16653 16654 16655 16656 16657 16658 16659 16660 16661 16662 16663 16664 16665 | |