Skip to content

Returns information about a destination phone number, including whether the number type and whether it is valid, the carrier, and more

Description

Returns information about a destination phone number, including whether the number type and whether it is valid, the carrier, and more.

Usage

pinpointsmsvoicev2_carrier_lookup(PhoneNumber, EnableCleansing)

Arguments

  • PhoneNumber

[required] The phone number that you want to retrieve information about. You can provide the phone number in various formats including special characters such as parentheses, brackets, spaces, hyphens, periods, and commas. The service automatically converts the input to E164 format for processing.

  • EnableCleansing

Specifies whether the service cleanses the phone number that you provide. When set to true, the service normalizes the phone number according to the destination country's national numbering plan and dialing rules. The service returns the cleansed number in E.164 format in the E164PhoneNumber field and returns the number that you provided in the OriginalPhoneNumber field.

Value

A list with the following syntax:

list(
  E164PhoneNumber = "string",
  DialingCountryCode = "string",
  IsoCountryCode = "string",
  Country = "string",
  MCC = "string",
  MNC = "string",
  Carrier = "string",
  PhoneNumberType = "MOBILE"|"LANDLINE"|"VOIP"|"PREPAID"|"OTHER"|"INVALID",
  OriginalPhoneNumber = "string"
)

Request syntax

svc$carrier_lookup(
  PhoneNumber = "string",
  EnableCleansing = TRUE|FALSE
)