Domain name for API request: vpc.intl.tencentcloudapi.com.
This API is used to apply for an IPv6 address for the ENI.
This API is completed asynchronously. If you need to query the execution result of an async task, please use the RequestId
returned by this API to poll the DescribeVpcTaskResult
API.
A maximum of 20 requests can be initiated per second for this API.
The following request parameter list only provides API request parameters and some common parameters. For the complete common parameter list, see Common Request Parameters.
Parameter Name | Required | Type | Description |
---|---|---|---|
Action | Yes | String | Common Params. The value used for this API: AssignIpv6Addresses. |
Version | Yes | String | Common Params. The value used for this API: 2017-03-12. |
Region | Yes | String | Common Params. For more information, please see the list of regions supported by the product. |
NetworkInterfaceId | Yes | String | The ID of the ENI instance, such as eni-m6dyj72l . |
Ipv6Addresses.N | No | Array of Ipv6Address | A list of IPv6 addresses. You can specify a maximum of 10 at one time. The quota is calculated together with that of Ipv6AddressCount , a required input parameter alternative to this one. |
Ipv6AddressCount | No | Integer | The number of automatically assigned IPv6 addresses. The total number of private IP addresses cannot exceed the quota. The quota is calculated together with that of Ipv6Addresses , a required input parameter alternative to this one. |
Parameter Name | Type | Description |
---|---|---|
Ipv6AddressSet | Array of Ipv6Address | The list of IPv6 addresses assigned to ENIs. |
RequestId | String | The unique request ID, generated by the server, will be returned for every request (if the request fails to reach the server for other reasons, the request will not obtain a RequestId). RequestId is required for locating a problem. |
This example shows you how to apply for specified IPv6 addresses for an ENI.
POST / HTTP/1.1
Host: vpc.intl.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: AssignIpv6Addresses
<Common request parameters>
{
"Ipv6Addresses": [
{
"Description": "test2",
"Primary": "false",
"Address": "3402:4e00:20:1202::2"
},
{
"Description": "test1",
"Primary": "false",
"Address": "3402:4e00:20:1202::1"
}
],
"NetworkInterfaceId": "eni-5u5biujl"
}
{
"Response": {
"Ipv6AddressSet": [
{
"Address": "3402:4e00:20:1202::1",
"AddressId": "",
"Primary": false,
"Description": "test1",
"IsWanIpBlocked": false,
"State": "PENDING"
},
{
"Address": "3402:4e00:20:1202::2",
"AddressId": "",
"Primary": false,
"Description": "test2",
"IsWanIpBlocked": false,
"State": "PENDING"
}
],
"RequestId": "4a8d6fc0-bc48-4394-b1f7-2818a217359a"
}
}
This example shows you how to apply for a specified number of IPv6 addresses.
POST / HTTP/1.1
Host: vpc.intl.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: AssignIpv6Addresses
<Common request parameters>
{
"NetworkInterfaceId": "eni-5u5biujl",
"Ipv6AddressCount": 2
}
{
"Response": {
"Ipv6AddressSet": [
{
"Address": "3402:4e00:20:1202:0:8d05:c272:f514",
"AddressId": "",
"Primary": false,
"Description": "",
"IsWanIpBlocked": false,
"State": "PENDING"
},
{
"Address": "3402:4e00:20:1202:0:8d05:c272:f559",
"AddressId": "",
"Primary": false,
"Description": "",
"IsWanIpBlocked": false,
"State": "PENDING"
}
],
"RequestId": "4a8d6fc0-bc48-4394-b1f7-2818a217359a"
}
}
TencentCloud API 3.0 integrates SDKs that support various programming languages to make it easier for you to call APIs.
The following only lists the error codes related to the API business logic. For other error codes, see Common Error Codes.
Error Code | Description |
---|---|
InternalError.ModuleError | Internal module error |
InvalidParameterValue | The parameter value is invalid. |
InvalidParameterValue.Malformed | Invalid input parameter format. |
InvalidParameterValue.Range | The parameter value is not in the specified range. |
InvalidParameterValue.Reserved | The parameter value is retained by the system. |
LimitExceeded | Quota limit is reached. |
LimitExceeded.ActionLimited | Too often API invocations |
LimitExceeded.Address | The number of assigned IP addresses has reached the upper limit. |
MissingParameter | Missing parameter. |
ResourceInUse | The resource is occupied. |
ResourceInUse.Address | The specified IP address is already in use. |
ResourceNotFound | The resource does not exist. |
UnsupportedOperation | Unsupported operation. |
UnsupportedOperation.InvalidState | Invalid resource status. |
UnsupportedOperation.MutexOperationTaskRunning | The resource mutual exclusion operation is being executed. |
UnsupportedOperation.UnassignCidrBlock | IPv6 IP range is not assigned. |
本页内容是否解决了您的问题?