Domain name for API request: vpc.tencentcloudapi.com.
This API is used to create a VPC instance.
A maximum of 100 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.
This document describes the parameters for Signature V1. It's recommended to use the V3 signature, which provides higher security. Note that for Signature V3, the common parameters need to be placed in the HTTP Header. See details.
Parameter Name | Required | Type | Description |
---|---|---|---|
Action | Yes | String | Common parameter. The value used for this API: CreateVpc. |
Version | Yes | String | Common parameter. The value used for this API: 2017-03-12. |
Region | Yes | String | Common parameter. For more information, please see the list of regions supported by the product. |
VpcName | Yes | String | The VPC name. The maximum length is 60 bytes. |
CidrBlock | Yes | String | VPC CIDR blocks, which must fall within the following three private network IP ranges: 10.0.0.0/16, 172.16.0.0/16 and 192.168.0.0/16. |
EnableMulticast | No | String | Whether multicast is enabled. true : Enabled. false : Not enabled. |
DnsServers.N | No | Array of String | DNS address. A maximum of 4 addresses is supported. |
DomainName | No | String | Domain name of DHCP |
Tags.N | No | Array of Tag | Bound tags, such as [{"Key": "city", "Value": "shanghai"}] |
Parameter Name | Type | Description |
---|---|---|
Vpc | Vpc | The VPC object. |
RequestId | String | The unique request ID, which is returned for each request. RequestId is required for locating a problem. |
https://vpc.tencentcloudapi.com/?Action=CreateVpc
&VpcName=TestVPC
&CidrBlock=10.8.0.0/16
&Tags.0.Key=city
&Tags.0.Value=shanghai
&<Common request parameters>
{
"Response": {
"Vpc": {
"VpcId": "vpc-4tboefn3",
"VpcName": "TestVPC",
"CidrBlock": "10.8.0.0/16",
"Ipv6CidrBlock": "",
"IsDefault": false,
"EnableMulticast": false,
"CreatedTime": "2020-09-24 15:57:39",
"EnableDhcp": true,
"DhcpOptionsId": "dopt-5f5lzouo",
"DnsServerSet": [
"183.60.82.98",
"183.60.83.1"
],
"DomainName": "",
"TagSet": [],
"AssistantCidrSet": [
{
"CidrBlock": "172.16.0.0/16",
"AssistantType": 0,
"SubnetSet": []
}
]
},
"RequestId": "680f4013-31a3-440a-bc09-fd9348a90900"
}
}
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 |
---|---|
InvalidParameterValue | Incorrect parameter value. |
InvalidParameterValue.LimitExceeded | The parameter value exceeds the limit. |
InvalidParameterValue.Malformed | Invalid input parameter format. |
InvalidParameterValue.TooLong | Invalid parameter value. The parameter value is too long. |
LimitExceeded | Quota limit is reached. |
MissingParameter | Missing parameter. |
ResourceInsufficient | Insufficient resources. |
ResourceNotFound | The resource does not exist. |
Was this page helpful?