Domain name for API request: postgres.tencentcloudapi.com.
This API is used to clone an instance by specifying a backup set or a point in time.
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: CloneDBInstance. |
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. |
DBInstanceId | Yes | String | ID of the original instance to be cloned. |
SpecCode | Yes | String | Purchasable specification ID, which can be obtained through the SpecCode field in the returned value of the DescribeProductConfig API. |
Storage | Yes | Integer | Instance storage capacity in GB. |
Period | Yes | Integer | Valid period in months of the purchased instance. Valid values: 1 , 2 , 3 , 4 , 5 , 6 , 7 , 8 , 9 , 10 , 11 , 12 , 24 , 36 . This parameter is set to 1 when the pay-as-you-go billing mode is used. |
AutoRenewFlag | Yes | Integer | Renewal flag. Valid values: 0 (manual renewal), 1 (auto-renewal). Default value: 0 . |
VpcId | Yes | String | VPC ID. |
SubnetId | Yes | String | ID of a subnet in the VPC specified by VpcId . |
Name | No | String | Name of the purchased instance. |
InstanceChargeType | No | String | Instance billing mode. Valid values: PREPAID (monthly subscription), POSTPAID_BY_HOUR (pay-as-you-go). |
SecurityGroupIds.N | No | Array of String | Security group ID. |
ProjectId | No | Integer | Project ID. |
TagList.N | No | Array of Tag | The information of tags to be bound with the purchased instance. This parameter is left empty by default. |
DBNodeSet.N | No | Array of DBNode | This parameter is required if you purchase a multi-AZ deployed instance. |
AutoVoucher | No | Integer | Whether to automatically use vouchers. Valid values: 1 (yes), 0 (no). Default value: 0 . |
VoucherIds | No | String | Voucher ID list. |
ActivityId | No | Integer | Campaign ID. |
BackupSetId | No | String | Basic backup set ID. |
RecoveryTargetTime | No | String | Restoration point in time. |
Parameter Name | Type | Description |
---|---|---|
DealName | String | Order ID. Note: this field may return null , indicating that no valid values can be obtained. |
BillId | String | Bill ID. Note: this field may return null , indicating that no valid values can be obtained. |
RequestId | String | The unique request ID, which is returned for each request. RequestId is required for locating a problem. |
https://postgres.tencentcloudapi.com/?Action=CloneDBInstance
&DBInstanceId=postgres-abcd1234
&SpecCode=cdb.pg.z1.2g
&Storage=10
&Period=1
&InstanceChargeType=prepaid
&AutoVoucher=0
&AutoRenewFlag=1
&DBNodeSet.0.Role=Primary
&DBNodeSet.0.Zone=ap-guangzhou-3
&DBNodeSet.1.Role=Standby
&DBNodeSet.1.Zone=ap-guangzhou-3
&RecoveryTargetTime=2021-12-25 01:27:35
&VpcId=vpc-2ot3acw1
&SubnetId=subnet-ppv9iw34
&<Common request parameters>
{
"Response": {
"RequestId": "6ace8140-6b9e-4e81-a8ad-ef3f92b2aa90",
"DealName": "20211225711000768276461",
"BillId": "20211225711000768276471"
}
}
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 |
---|---|
AuthFailure.UnauthorizedOperation | Authentication failed. |
FailedOperation.CamAuthFailed | CAM authentication failed. |
FailedOperation.CamSigAndAuthError | Authentication failed. Please try again later. If the problem persists, please contact customer service. |
FailedOperation.CdbCgwConnectError | Failed to get project information. Please try again later. If the problem persists, please contact customer service. |
FailedOperation.DatabaseAccessError | Failed to access database management service. Please try again later. If the problem persists, please contact customer service. |
FailedOperation.FailedOperationError | Operation failed. Please try again later. |
FailedOperation.GetSubnetError | Failed to query VPC subnets. |
FailedOperation.GetVpcInfoError | Failed to query VPC information. Please try again later. If the problem persists, please contact customer service. |
FailedOperation.QuerySpecError | Failed to query specifications. Please try again later. If the problem persists, please contact customer service. |
FailedOperation.QueryVpcFailed | Failed to query VPC. |
FailedOperation.QueryVpcFalied | Failed to get VPC details. |
InvalidParameterValue.IllegalProjectId | Invalid ProjectId . |
InvalidParameterValue.IllegalRegion | Invalid Region parameter. |
InvalidParameterValue.IllegalZone | Invalid Zone parameter. |
InvalidParameterValue.InvalidParameterValueError | Incorrect parameter value |
InvalidParameterValue.InvalidZoneIdError | Invalid availability zone. |
OperationDenied.CamDeniedError | This operation cannot be performed. |
Was this page helpful?