Domain name for API request: mongodb.tencentcloudapi.com.
This API is used to adjust the specification configuration of a TencentDB for MongoDB. The purchasable specifications supported by the API can be obtained through the DescribeSpecInfo 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: ModifyDBInstanceSpec. |
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. |
InstanceId | Yes | String | Instance ID in the format of cmgo-p8vnipr5. It is the same as the instance ID displayed on the TencentDB Console page |
Memory | Yes | Integer | Memory size after instance configuration change in GB. Memory and disk must be upgraded or degraded simultaneously |
Volume | Yes | Integer | Disk size after instance configuration change in GB. Memory and disk must be upgraded or degraded simultaneously. For degradation, the new disk capacity must be greater than 1.2 times the used disk capacity |
OplogSize | No | Integer | Oplog size after instance configuration change in GB, which ranges from 10% to 90% of the disk capacity and is 10% of the disk capacity by default |
NodeNum | No | Integer | Node quantity after configuration modification. The value range is subject to the response parameter of the DescribeSpecInfo API. If this parameter is left empty, the node quantity remains unchanged. |
ReplicateSetNum | No | Integer | Shard quantity after configuration modification, which can only be increased rather than decreased. The value range is subject to the response parameter of the DescribeSpecInfo API. If this parameter is left empty, the shard quantity remains unchanged. |
InMaintenance | No | Integer | Switch time. Valid values: 0 (upon modification completion), 1 (during maintenance time). Default value: 0 . If the quantity of nodes or shards is modified, the value will be 0 . |
Parameter Name | Type | Description |
---|---|---|
DealId | String | Order ID |
RequestId | String | The unique request ID, which is returned for each request. RequestId is required for locating a problem. |
https://mongodb.tencentcloudapi.com/?Action=ModifyDBInstanceSpec
&InstanceId=cmgo-p8vnipr5
&Memory=4
&Volume=250
&<Common request parameters>
{
"Response": {
"RequestId": "d88095e5-50e8-4245-a0cf-993a536f9b20",
"DealId": "7142863"
}
}
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 |
---|---|
InvalidParameter.ZoneClosed | Instances are not purchasable in this AZ. |
InvalidParameterValue.InvalidTradeOperation | Billing error. Corresponding purchase/renewal/configuration change operations are not allowed for the current instance. |
InvalidParameterValue.ModifyModeError | Memory and disk must be upgraded or degraded simultaneously. |
InvalidParameterValue.NotFoundInstance | The instance was not found. |
InvalidParameterValue.OplogSizeOutOfRange | The OplogSize parameter is set incorrectly and should be between 10% and 90% of the disk capacity. |
InvalidParameterValue.SetDiskLessThanUsed | The disk size to be set cannot be less than 1.2 times the used disk capacity. |
InvalidParameterValue.SpecNotOnSale | Incorrect purchasable specification. |
InvalidParameterValue.StatusAbnormal | The instance is in a status where operations are not allowed. |
Was this page helpful?