All Products
Search
Document Center

Container Registry:ListRepoBuildRule

Last Updated:May 27, 2026

Lists the build rules of an image repository.

Try it now

Try this API in OpenAPI Explorer, no manual signing needed. Successful calls auto-generate SDK code matching your parameters. Download it with built-in credential security for local usage.

Test

RAM authorization

No authorization for this operation. If you encounter issues with this operation, contact technical support.

Request parameters

Parameter

Type

Required

Description

Example

InstanceId

string

Yes

The ID of the instance.

cri-kmsiwlxxdcva****

RepoId

string

Yes

The ID of the image repository.

crr-tquyps22md8****

PageNo

integer

No

The page number.

1

PageSize

integer

No

The number of entries to return per page.

30

Response elements

Element

Type

Description

Example

object

The response object.

RequestId

string

The request ID.

42D782C8-E8F6-4A32-BEA0-6A6AC854C22A

Code

string

The response code. A value of success indicates that the request was successful.

success

PageNo

integer

The page number.

1

IsSuccess

boolean

Indicates whether the request was successful. Valid values:

  • true: The request was successful.

  • false: The request failed.

true

PageSize

integer

The number of entries returned per page.

30

TotalCount

string

The total number of build rules.

1

BuildRules

array<object>

The build rules.

object

DockerfileLocation

string

The directory of the Dockerfile.

/

BuildRuleId

string

The ID of the build rule.

crbr-khys0nd3asbe****

PushType

string

The type of the event that triggers the build rule. Valid values:

  • GIT_BRANCH: A code branch is pushed.

  • GIT_TAG: Push source code from a tag.

GIT_BRANCH

PushName

string

Code push-triggered build name

v0.1

ImageTag

string

Image Tag

v0.1

DockerfileName

string

Dockerfile name

Dockerfile

Platforms

array

Image operating system and platform

string

Image operating system and platform

linux/amd64

BuildArgs

array

string

Build argument

http_proxy=127.0.0.1

DestArtifactType

string

Examples

Success response

JSON format

{
  "RequestId": "42D782C8-E8F6-4A32-BEA0-6A6AC854C22A",
  "Code": "success",
  "PageNo": 1,
  "IsSuccess": true,
  "PageSize": 30,
  "TotalCount": "1",
  "BuildRules": [
    {
      "DockerfileLocation": "/",
      "BuildRuleId": "crbr-khys0nd3asbe****",
      "PushType": "GIT_BRANCH",
      "PushName": "v0.1",
      "ImageTag": "v0.1",
      "DockerfileName": "Dockerfile",
      "Platforms": [
        "linux/amd64"
      ],
      "BuildArgs": [
        "http_proxy=127.0.0.1 "
      ],
      "DestArtifactType": ""
    }
  ]
}

Error codes

HTTP status code

Error code

Error message

Description

500 SystemError Unknown error.
403 NoPrivilege Access denied for this user.

See Error Codes for a complete list.

Release notes

See Release Notes for a complete list.