Domain name for API request: vpc.intl.tencentcloudapi.com.
This API (InquiryPriceAllocateAddresses) is used to query the price of purchasing EIPs.
A maximum of 2 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: InquiryPriceAllocateAddresses. |
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. |
InternetChargeType | No | String | EIP billing method.
|
InternetMaxBandwidthOut | No | Integer | The EIP outbound bandwidth cap, in Mbps.
|
AddressChargePrepaid | No | AddressChargePrepaid | A required billing parameter for an EIP billed by "BANDWIDTH_PREPAID_BY_MONTH". When the EIP is billed by "BANDWIDTH_PREPAID_BY_MONTH" this parameter is required. For other scenarios, it can be ignored. |
AddressType | No | String | EIP type. Default value: EIP.
|
Parameter Name | Type | Description |
---|---|---|
Price | InternetPrice | EIP price |
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 inquire about an elastic IP billed by hourly traffic.
POST / HTTP/1.1
Host: vpc.intl.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: InquiryPriceAllocateAddresses
<Common request parameters>
{
"AddressType": "EIP",
"InternetMaxBandwidthOut": "1",
"InternetChargeType": "TRAFFIC_POSTPAID_BY_HOUR"
}
{
"Response": {
"Price": {
"AddressPrice": {
"ChargeUnit": "HOUR",
"UnitPrice": 0.8,
"DiscountPrice": 0.8
}
},
"RequestId": "90d508a8-9ee8-4220-9c8e-9faeedce3ab4"
}
}
This example shows you how to inquire about an elastic IP billed by hourly bandwidth.
POST / HTTP/1.1
Host: vpc.intl.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: InquiryPriceAllocateAddresses
<Common request parameters>
{
"AddressType": "EIP",
"InternetMaxBandwidthOut": "1",
"InternetChargeType": "BANDWIDTH_POSTPAID_BY_HOUR"
}
{
"Response": {
"Price": {
"AddressPrice": {
"UnitPrice": 0.063,
"DiscountPrice": 0.063,
"ChargeUnit": "HOUR"
}
},
"RequestId": "ebc826be-ec1a-4522-b08f-8da3fe5adedc"
}
}
This example shows you how to inquire about Elastic IP in monthly bandwidth billing mode.
POST / HTTP/1.1
Host: vpc.intl.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: InquiryPriceAllocateAddresses
<Common request parameters>
{
"AddressChargePrepaid": {
"Period": 1
},
"AddressType": "EIP",
"InternetChargeType": "BANDWIDTH_PREPAID_BY_MONTH",
"InternetMaxBandwidthOut": 1
}
{
"Response": {
"Price": {
"AddressPrice": {
"OriginalPrice": 20,
"DiscountPrice": 20
}
},
"RequestId": "136605f0-ca35-4d22-9b77-e053168fa25f"
}
}
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 |
---|---|
FailedOperation.InvalidRegion | Unsupported region. |
InvalidAccount.NotSupported | This account is not supported. |
InvalidParameterValue.BandwidthOutOfRange | The bandwidth exceeds the limit. |
InvalidParameterValue.Combination | Invalid input parameters |
InvalidParameterValue.UnavailableZone | This availability zone is unavailable. |
UnsupportedOperation.ActionNotFound | The port does not exist. |
UnsupportedOperation.UnsupportedRegion | The service is not available in this country/region. |
Was this page helpful?