Share via


PhoneNumbersModelFactory.PurchasedPhoneNumber Method

Definition

public static Azure.Communication.PhoneNumbers.PurchasedPhoneNumber PurchasedPhoneNumber (string id, string phoneNumber, string countryCode, Azure.Communication.PhoneNumbers.PhoneNumberType phoneNumberType, Azure.Communication.PhoneNumbers.PhoneNumberCapabilities capabilities, Azure.Communication.PhoneNumbers.PhoneNumberAssignmentType assignmentType, DateTimeOffset purchaseDate, Azure.Communication.PhoneNumbers.PhoneNumberCost cost);
static member PurchasedPhoneNumber : string * string * string * Azure.Communication.PhoneNumbers.PhoneNumberType * Azure.Communication.PhoneNumbers.PhoneNumberCapabilities * Azure.Communication.PhoneNumbers.PhoneNumberAssignmentType * DateTimeOffset * Azure.Communication.PhoneNumbers.PhoneNumberCost -> Azure.Communication.PhoneNumbers.PurchasedPhoneNumber
Public Shared Function PurchasedPhoneNumber (id As String, phoneNumber As String, countryCode As String, phoneNumberType As PhoneNumberType, capabilities As PhoneNumberCapabilities, assignmentType As PhoneNumberAssignmentType, purchaseDate As DateTimeOffset, cost As PhoneNumberCost) As PurchasedPhoneNumber

Parameters

id
String

The id of the phone number, e.g. 14255550123.

phoneNumber
String

String of the E.164 format of the phone number, e.g. +14255550123.

countryCode
String

The ISO 3166-2 code of the phone number's country, e.g. US.

phoneNumberType
PhoneNumberType

The phone number's type, e.g. Geographic, TollFree.

capabilities
PhoneNumberCapabilities

Capabilities of a phone number.

assignmentType
PhoneNumberAssignmentType

The assignment type of the phone number. A phone number can be assigned to a person, or to an application.

purchaseDate
DateTimeOffset

The date and time that the phone number was purchased.

cost
PhoneNumberCost

The incurred cost for a single phone number.

Returns

Applies to