Domain name for API request: mongodb.tencentcloudapi.com.
This API is used to query price of instance creation. The region
parameter must be passed in this API, otherwise verification will fail. This API allows queries only for purchasable instance specifications.
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: InquirePriceCreateDBInstances. |
Version | Yes | String | Common Params. The value used for this API: 2019-07-25. |
Region | No | String | Common Params. This parameter is not required for this API. |
Zone | Yes | String | Instance region name in the format of ap-guangzhou-2. |
NodeNum | Yes | Integer | Number of primary and secondary nodes per shard. Value range: It can be queried by the DescribeSpecInfo API, and the MinNodeNum and MaxNodeNum parameters are the minimal and maximum value respectively. |
Memory | Yes | Integer | Instance memory size in GB. |
Volume | Yes | Integer | Instance disk size.
|
MongoVersion | Yes | String | Instance version information.
|
MachineCode | Yes | String | Server type. Valid values: HIO (high IO), HIO10G (ten-gigabit high IO) |
GoodsNum | Yes | Integer | Number of instances. Minimum value: 1. Maximum value: 10. |
ClusterType | Yes | String | Instance type. Valid values: REPLSET (replica set), SHARD (sharded cluster), STANDALONE (single-node). |
ReplicateSetNum | Yes | Integer | Number of replica sets. To create a replica set instance, set this parameter to 1; to create a shard instance, see the parameters returned by the DescribeSpecInfo API; to create a single-node instance, set this parameter to 0. |
Period | No | Integer | Instance validity period in months. Valid values: 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 24, 36. |
InstanceChargeType | No | String | |
MongosCpu | No | Integer | |
MongosMemory | No | Integer | |
MongosNum | No | Integer | |
ConfigServerCpu | No | Integer | |
ConfigServerMemory | No | Integer | |
ConfigServerVolume | No | Integer |
Parameter Name | Type | Description |
---|---|---|
Price | DBInstancePrice | Price. |
RequestId | String | The unique request ID, which is returned for each request. RequestId is required for locating a problem. |
https://mongodb.tencentcloudapi.com/?Action=InquirePriceCreateDBInstances
&Zone=ap-guangzhou-4
&NodeNum=3
&Memory=4
&Volume=100
&MongoVersion=MONGO_36_WT
&MachineCode=HIO10G
&GoodsNum=2
&Period=1
&ClusterType=REPLSET
&ReplicateSetNum=1
&<Common request parameters>
{
"Response": {
"Price": {
"DiscountPrice": 1340,
"OriginalPrice": 1340,
"UnitPrice": 670
},
"RequestId": "fb8b4646-389d-44cc-ab8c-98c081cbdad3"
}
}
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 | Internal error |
InvalidParameter | Parameter error |
InvalidParameter.PermissionDenied | The current subaccount has no permission to perform this operation. |
InvalidParameterValue.MachineTypeError | Incorrect model. |
InvalidParameterValue.MongoVersionError | The instance version is incorrect. |
InvalidParameterValue.ReplicaSetNumError | Incorrect number of replica sets (shards). |
InvalidParameterValue.SpecNotOnSale | Incorrect purchasable specification. |
InvalidParameterValue.ZoneClosed | Instances are not purchasable in this AZ. |
InvalidParameterValue.ZoneError | Invalid availability zone |
Was this page helpful?