Table of Contents

Struct TransferNumberRequest

Namespace
Vonage.SubAccounts.TransferNumber
Assembly
Vonage.dll

Represents a request to transfer a phone number from one account to another within the primary account's hierarchy.

[Builder(new string[] { })]
public readonly struct TransferNumberRequest : IVonageRequest
Implements
Inherited Members

Properties

Country

Sets the two-character country code in ISO 3166-1 alpha-2 format (e.g., "GB", "US").

[JsonPropertyOrder(3)]
[Mandatory(3)]
public string Country { get; }

Property Value

string

Examples

.WithCountry("GB")

From

Sets the API key of the account to transfer the number from.

[JsonPropertyOrder(0)]
[Mandatory(0)]
public string From { get; }

Property Value

string

Examples

.WithFrom("7c9738e6")

Number

Sets the phone number to transfer.

[JsonPropertyOrder(2)]
[Mandatory(2)]
public string Number { get; }

Property Value

string

Examples

.WithNumber("447700900000")

To

Sets the API key of the account to transfer the number to.

[JsonPropertyOrder(1)]
[Mandatory(1)]
public string To { get; }

Property Value

string

Examples

.WithTo("ad6dc56f")

Methods

Build()

public static IBuilderForFrom Build()

Returns

IBuilderForFrom

BuildRequestMessage()

Converts the request to a HttpRequest.

public HttpRequestMessage BuildRequestMessage()

Returns

HttpRequestMessage

The Http request.