Creates an image synchronization task.
Debugging
Request parameters
Parameter | Type | Required | Example | Description |
---|---|---|---|---|
Action | String | Yes | CreateRepoSyncTask |
The operation that you want to perform. Set the value to CreateRepoSyncTask. |
InstanceId | String | Yes | cri-hpdfkc6utbaq**** |
The ID of the source instance. |
RegionId | String | Yes | cn-beijing |
The ID of the region where the source instance resides. |
RepoId | String | Yes | crr-iql7jalx4g0**** |
The ID of the image repository on the source instance. |
Tag | String | Yes | tag1 |
The tag of the source instance image. |
TargetInstanceId | String | Yes | cri-ibxs3piklys3**** |
The ID of the destination instance. |
TargetNamespace | String | Yes | ns1 |
The namespace of the destination instance. |
TargetRegionId | String | Yes | cn-hangzhou |
The ID of the region where the destination instance resides. |
TargetRepoName | String | Yes | repo1 |
The image repository name of the destination instance. |
TargetTag | String | Yes | tag1 |
The image tag of the destination instance. |
TargetUserId | String | No | 12345*** |
The ID of the account to which the destination instance belongs. |
Override | Boolean | No | true |
Specifies whether to overwrite an existing image. Valid values:
|
Response parameters
Parameter | Type | Example | Description |
---|---|---|---|
Code | String | success |
The return value. |
IsSuccess | Boolean | true |
Indicates whether the operation is successful. |
RequestId | String | 8F8A0BA6-7F06-4BAE-B147-10BD6A25**** |
The ID of the request. |
SyncTaskId | String | rst-gbch330f0c**** |
The ID of the synchronization task. |
Examples
Sample requests
http(s)://[Endpoint]/?Action=CreateRepoSyncTask
&InstanceId=cri-hpdfkc6utbaq****
&RegionId=cn-beijing
&RepoId=crr-iql7jalx4g0****
&Tag=tag1
&TargetInstanceId=cri-ibxs3piklys3****
&TargetNamespace=ns1
&TargetRegionId=cn-hangzhou
&TargetRepoName=repo1
&TargetTag=tag1
&<Common request parameters>
Sample success responses
XML
format
<IsSuccess>true</IsSuccess>
<RequestId>8F8A0BA6-7F06-4BAE-B147-10BD6A25****</RequestId>
<SyncTaskId>rst-gbch330f0c****</SyncTaskId>
<Code>success</Code>
JSON
format
{
"IsSuccess": true,
"RequestId": "8F8A0BA6-7F06-4BAE-B147-10BD6A25****",
"SyncTaskId": "rst-gbch330f0c****",
"Code": "success"
}
Error codes
For a list of error codes, visit API Error Center.