Domain name for API request: dts.intl.tencentcloudapi.com.
This API is used to create a sync task.
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: CreateSyncJob. |
Version | Yes | String | Common Params. The value used for this API: 2021-12-06. |
Region | Yes | String | Common Params. For more information, please see the list of regions supported by the product. |
PayMode | Yes | String | Billing mode. Valid values: PrePay (monthly subscription); PostPay (pay-as-you-go). Currently, DTS at Tencent Cloud International is free of charge. |
SrcDatabaseType | Yes | String | Source database type, such as mysql , cynosdbmysql , tdapg , tdpg , and tdsqlmysql . |
SrcRegion | Yes | String | Source database region, such as ap-guangzhou . |
DstDatabaseType | Yes | String | Target database type, such as mysql , cynosdbmysql , tdapg , tdpg , tdsqlmysql , and kafka . |
DstRegion | Yes | String | Target database region, such as ap-guangzhou . |
Specification | No | String | Sync task specification, such as Standard . |
Tags.N | No | Array of TagItem | Tag information |
Count | No | Integer | The number of sync tasks purchased at a time. Value range: [1, 10]. Default value: 1 . |
AutoRenew | No | Integer | Auto-renewal flag, which takes effect if PayMode is PrePay . Valid values: 1 (auto-renewal enabled); 0 (auto-renewal disabled). Default value: 0 . |
InstanceClass | No | String | Sync link specification, such as micro , small , medium , and large . Default value: medium . |
JobName | No | String | Sync task name |
ExistedJobId | No | String | ID of the existing task used to create a similar task |
Parameter Name | Type | Description |
---|---|---|
JobIds | Array of String | Sync task IDs |
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 create a sync task.
POST / HTTP/1.1
Host: dts.intl.tencentcloudapi.com
Content-Type: application/json
X-TC-Action: CreateSyncJob
<Common request parameters>
{
"Count": 1,
"Specification": "Standard",
"PayMode": "PrePay",
"DstDatabaseType": "mysql",
"DstRegion": "ap-guangzhou",
"SrcDatabaseType": "mysql",
"SrcRegion": "ap-guangzhou",
"ExistedJobId": "sync-xascasas"
}
{
"Response": {
"JobIds": [
"sync-eivc87yk"
],
"RequestId": "03a378be-372a-478b-beb7-19e4dd5027e2"
}
}
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.AuthFailureError | Authentication failed. |
AuthFailure.UnauthorizedOperationError | The current user is not allowed to perform this operation as the authentication failed. |
FailedOperation.FailedOperationError | The operation failed. |
InternalError.InternalErrorError | An internal error occurred. |
InternalError.InternalInnerCommonError | An error occurred while accessing the internal component. |
InternalError.InternalTradeError | Failed to call the billing service. |
InternalError.NotEnoughMoneyError | The account balance is insufficient. |
InternalError.UnknownError | An unknown internal error occurred. |
InvalidParameterValue.InvalidParameterValueError | The parameter is invalid. |
OperationDenied.BizOperationDeniedError | The operation was denied as the condition was not met. |
OperationDenied.NotEnoughMoneyError | The account balance is insufficient. |
OperationDenied.OperationDeniedError | The operation was denied. |
Was this page helpful?