Creates an image synchronization task based on a manual synchronization rule.

Debugging

OpenAPI Explorer automatically calculates the signature value. For your convenience, we recommend that you call this operation in OpenAPI Explorer. OpenAPI Explorer dynamically generates the sample code of the operation for different SDKs.

Request parameters

Parameter Type Required Example Description
Action String Yes CreateRepoSyncTaskByRule

The operation that you want to perform. Set the value to CreateRepoSyncTaskByRule.

InstanceId String Yes cri-hpdfkc6utbaq****

The ID of the instance.

RegionId String Yes cn-shanghai

The ID of the region.

RepoId String Yes crr-hnoq7j93or3k****

The ID of the image repository.

SyncRuleId String Yes crsr-o8n4dijbumgq****

The ID of the synchronization rule.

Tag String Yes 1.24

The version of the image that you want to synchronize.

Response parameters

Parameter Type Example Description
Code String success

The return value.

IsSuccess Boolean true

Indicates whether the operation is successful. Valid values:

  • true: successful.
  • false: failed.
RequestId String 17A4C658-AE8F-4A08-821F-EDCB5FC74EE8

The ID of the request.

SyncTaskId String rst-biu4u4pm4it5****

The ID of the synchronization task.

Examples

Sample requests

http(s)://[Endpoint]/?Action=CreateRepoSyncTaskByRule
&InstanceId=cri-hpdfkc6utbaq****
&RegionId=cn-shanghai
&RepoId=crr-hnoq7j93or3k****
&SyncRuleId=crsr-o8n4dijbumgq****
&Tag=1.24
&<Common request parameters>

Sample success responses

XML format

<IsSuccess>true</IsSuccess>
<RequestId>17A4C658-AE8F-4A08-821F-EDCB5FC74EE8</RequestId>
<SyncTaskId>rst-biu4u4pm4it5****</SyncTaskId>
<Code>success</Code>

JSON format

{
    "IsSuccess": true,
    "RequestId": "17A4C658-AE8F-4A08-821F-EDCB5FC74EE8",
    "SyncTaskId": "rst-biu4u4pm4it5****",
    "Code": "success"
}

Error codes

For a list of error codes, visit API Error Center.