All Products
Search
Document Center

Container Registry:ListRepoSyncTask

Last Updated:Dec 16, 2025

Queries image synchronization tasks in an image repository.

Debugging

You can run this interface directly in OpenAPI Explorer, saving you the trouble of calculating signatures. After running successfully, OpenAPI Explorer can automatically generate SDK code samples.

Authorization information

The following table shows the authorization information corresponding to the API. The authorization information can be used in the Action policy element to grant a RAM user or RAM role the permissions to call this API operation. Description:

  • Operation: the value that you can use in the Action element to specify the operation on a resource.
  • Access level: the access level of each operation. The levels are read, write, and list.
  • Resource type: the type of the resource on which you can authorize the RAM user or the RAM role to perform the operation. Take note of the following items:
    • For mandatory resource types, indicate with a prefix of * .
    • If the permissions cannot be granted at the resource level, All Resources is used in the Resource type column of the operation.
  • Condition Key: the condition key that is defined by the cloud service.
  • Associated operation: other operations that the RAM user or the RAM role must have permissions to perform to complete the operation. To complete the operation, the RAM user or the RAM role must have the permissions to perform the associated operations.
OperationAccess levelResource typeCondition keyAssociated operation
cr:GetRepositorySyncget
*Repository
acs:cr:{#regionId}:{#accountId}:repository/{#instanceid}
    none
none

Request parameters

ParameterTypeRequiredDescriptionExample
InstanceIdstringYes

The instance ID.

cri-kmsiwlxxdcva****
RepoNamespaceNamestringNo

The name of the namespace to which the repository belongs.

ns
RepoNamestringNo

The repository name.

test
TagstringNo

The image tag.

nginx
PageNointegerNo

The page number.

1
PageSizeintegerNo

The number of entries per page.

30
SyncRecordIdstringNo

The ID of the synchronization task record, which is the same as SyncBatchTaskId in the response.

Note If an image meets multiple synchronization rules and multiple synchronization tasks are generated for the image, these synchronization tasks use the same SyncBatchTaskId.
crsr-7lph66uloi6h****

Response parameters

ParameterTypeDescriptionExample
object
RequestIdstring

The request ID.

7640819A-FB5B-4E25-A227-97717F62****
Codestring

The HTTP status code.

success
PageNointeger

The page number.

1
IsSuccessboolean

Indicates whether the request is successful.

true
PageSizeinteger

The number of entries per page.

30
TotalCountstring

The total number of the queried synchronization tasks.

1
SyncTasksarray<object>

The queried synchronization tasks.

SyncTasksobject
ModifedTimelong

The time when the synchronization task was last modified.

1572839133000
SyncRuleIdstring

The ID of the synchronization rule.

crsr-7lph66uloi6h****
SyncTaskIdstring

The ID of the synchronization task.

rst-4kfd7fk6pohk****
TaskStatusstring

The status of the synchronization task.

SUCCESS
CreateTimelong

The time when the synchronization task was created.

1572839126000
SyncBatchTaskIdstring

The ID of the image synchronization batch tasks, which is the same as the value of SyncRecordId in the request.

Note If an image meets multiple synchronization rules and multiple synchronization tasks are generated for the image, these synchronization tasks use the same SyncBatchTaskId.
15DEEB56-9271-4FDD-AC4D-C3A5CC2C****
CrossUserboolean

Indicates whether the synchronization task is performed across Alibaba Cloud accounts. Valid values:

  • true: The image synchronization task is performed across accounts.
  • false: The image synchronization task is performed within the same account.

Default value: false.

true
SyncTransAccelerateboolean

Indicates whether the synchronization transfer acceleration feature is enabled for the synchronization task.

true
TaskTriggerstring

The policy that is configured to trigger the synchronization task. Valid values:

  • PASSIVE: automatically triggers the synchronization task.
  • INITIATIVE: manually triggers the synchronization task.

Default value: PASSIVE.

PASSIVE
ImageFromobject

The information about the source image.

RepoNamespaceNamestring

The namespace to which the repository belongs.

test
InstanceIdstring

The instance ID.

cri-kmsiwlxxdcva****
ImageTagstring

The image tag.

v0.1
RepoNamestring

The repository name.

test
RegionIdstring

The region ID.

cn-shanghai
ImageToobject

The information about the destination image.

RepoNamespaceNamestring

The namespace to which the repository belongs.

test
InstanceIdstring

The instance ID.

cri-k77rd2eo9zttneqo
ImageTagstring

The image tag.

v0.1
RepoNamestring

The repository name.

test
RegionIdstring

The region ID.

cn-shenzhen
TaskIssuestring

The error message that is returned if the synchronization task fails.

Note The system uses this parameter to return an error message if the synchronization task fails.

Valid value:

  • OSS_POLICY_UNAUTHORIZED: Container Registry is not granted permissions to access Object Storage Service (OSS).
  • TAG_CONFLICT: The destination repository contains an image that has the same tag as the source image, and image tag immutability is enabled for the destination repository.
  • UNSUPPORTED_FORMAT: The manifest or config format of the image to be synchronized is not supported.
  • INTERNAL_ERROR: The synchronization task failed due to internal issues on the server.
  • NETWORK_ERROR: The synchronization task failed due to unstable network connection.
  • DATA_LENGTH_EXCEEDED: The manifest or config of the image is oversized.
NETWORK_ERROR

Examples

Sample success responses

JSONformat

{
  "RequestId": "7640819A-FB5B-4E25-A227-97717F62****",
  "Code": "success",
  "PageNo": 1,
  "IsSuccess": true,
  "PageSize": 30,
  "TotalCount": 1,
  "SyncTasks": [
    {
      "ModifedTime": 1572839133000,
      "SyncRuleId": "crsr-7lph66uloi6h****",
      "SyncTaskId": "rst-4kfd7fk6pohk****",
      "TaskStatus": "SUCCESS",
      "CreateTime": 1572839126000,
      "SyncBatchTaskId": "15DEEB56-9271-4FDD-AC4D-C3A5CC2C****",
      "CrossUser": true,
      "SyncTransAccelerate": true,
      "TaskTrigger": "PASSIVE",
      "ImageFrom": {
        "RepoNamespaceName": "test",
        "InstanceId": "cri-kmsiwlxxdcva****",
        "ImageTag": "v0.1",
        "RepoName": "test",
        "RegionId": "cn-shanghai"
      },
      "ImageTo": {
        "RepoNamespaceName": "test",
        "InstanceId": "cri-k77rd2eo9zttneqo",
        "ImageTag": "v0.1",
        "RepoName": "test",
        "RegionId": "cn-shenzhen"
      },
      "CustomLink": true,
      "TaskIssue": "NETWORK_ERROR"
    }
  ]
}

Error codes

HTTP status codeError codeError message
403NoPrivilegeAccess denied for this user.
500SystemErrorUnknown error.

For a list of error codes, visit the Service error codes.

Change history

Change timeSummary of changesOperation
2024-11-25The Error code has changed. The response structure of the API has changedView Change Details