Purchases Internet bandwidth for an IPv6 gateway.

Description

You cannot call the AllocateIpv6InternetBandwidth operation to purchase Internet bandwidth for an IPv6 gateway at the same time.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

ParameterTypeRequiredExampleDescription
RegionIdStringYescn-huhehaote

The ID of the region where the IPv6 gateway is deployed. You can call the DescribeRegions operation to obtain the region ID.

Ipv6GatewayIdStringYesipv6gw-uf6hcyzu65v98v3du****

The ID of the IPv6 gateway.

Ipv6AddressIdStringYesipv6-2zen5j4axcp5l5qyy****

The ID of the IPv6 address.

InternetChargeTypeStringNoPayByBandwidth

The metering method of the Internet bandwidth of the IPv6 gateway. Valid values:

  • PayByTraffic: the pay-by-data-transfer metering method
  • PayByBandwidth: the pay-by-bandwidth metering method
BandwidthIntegerYes2

The Internet bandwidth that you want to purchase for the IPv6 gateway. Valid values: 1 to 5000. Unit: Mbit/s.

ClientTokenStringNo123e4567-e89b-12d3-a456-426655440000

The client token that is used to ensure the idempotence of the request.

You can use the client to generate the value, but you must ensure that the value is unique among all requests. ClientToken can contain only ASCII characters.

Note If you do not set this parameter, ClientToken is set to the value of RequestId. The value of RequestId may be different for each API request.
ActionStringYesAllocateIpv6InternetBandwidth

The operation that you want to perform. Set the value to AllocateIpv6InternetBandwidth.

Response parameters

ParameterTypeExampleDescription
Ipv6AddressIdStringipv6-2zen5j4axcp5l5qyy****

The ID of the IPv6 address.

RequestIdString6972A26E-99B1-4367-9890-FBDEBB0F5E7D

The ID of the request.

InternetBandwidthIdStringipv6bw-uf6hcyzu65v98v3du****

The ID of the Internet bandwidth that you purchased for the IPv6 gateway.

Examples

Sample requests

http(s)://[Endpoint]/?RegionId=cn-huhehaote
&Ipv6GatewayId=ipv6gw-uf6hcyzu65v98v3du****
&Ipv6AddressId=ipv6-2zen5j4axcp5l5qyy****
&InternetChargeType=PayByBandwidth
&Bandwidth=2
&ClientToken=123e4567-e89b-12d3-a456-426655440000
&Action=AllocateIpv6InternetBandwidth
&Common request parameters

Sample success responses

XML format

HTTP/1.1 200 OK
Content-Type:application/xml

<AllocateIpv6InternetBandwidthResponse>
    <Ipv6AddressId>ipv6-2zen5j4axcp5l5qyy****</Ipv6AddressId>
    <RequestId>6972A26E-99B1-4367-9890-FBDEBB0F5E7D</RequestId>
    <InternetBandwidthId>ipv6bw-uf6hcyzu65v98v3du****</InternetBandwidthId>
</AllocateIpv6InternetBandwidthResponse>

JSON format

HTTP/1.1 200 OK
Content-Type:application/json

{
  "Ipv6AddressId" : "ipv6-2zen5j4axcp5l5qyy****",
  "RequestId" : "6972A26E-99B1-4367-9890-FBDEBB0F5E7D",
  "InternetBandwidthId" : "ipv6bw-uf6hcyzu65v98v3du****"
}

Error codes

HTTP status codeError codeError messageDescription
404InvalidRegionId.NotFoundThe specified RegionId does not exist in our records.The error message returned because the specified region ID does not exist.

For a list of error codes, see Service error codes.