Updated on 2024-04-19 GMT+08:00

Querying the Image Repository List

Function

Query the image repository list.

URI

GET /v2/manage/repos

Table 1 Query parameters

Parameter

Mandatory

Type

Description

namespace

No

String

Organization name. An organization name contains 1 to 64 characters. It must start with a lowercase letter and end with a lowercase letter or digit. Only lowercase letters, digits, periods (.), underscores (_), and hyphens (-) are allowed. Periods, underscores, and hyphens cannot be placed next to each other. A maximum of two consecutive underscores are allowed.

name

No

String

Image repository name.

category

No

String

Repository type. The value can be app_server, linux, framework_app, database, lang, arm, or other.

limit

No

String

Number of returned records. Parameters offset and limit should always be used together.

offset

No

String

Start index. Parameters offset and limit should always be used together.

order_column

No

String

Sorting by column. You can set this parameter to updated_at (sorting by update time). Parameters order_column and order_type should always be used together.

order_type

No

String

Sorting type. You can set this parameter to desc (descending sort) or asc (ascending sort). Parameters order_column and order_type should always be used together.

filter

No

String

Pass at least one of the following filter parameters:

namespace: organization name. It supports fuzzy match.

name: image repository name. It supports fuzzy match.

category: image repository type. The value can be app_server, linux, framework_app, database, lang, arm, or other.

limit: number of returned records.

offset: the start index.

Parameters offset and limit should always be used together.

order_column: sorting by column. It can be set to name, updated_time, or tag_count.

order_type: sorting type. It can be set to desc (descending order) or asc (ascending order).

Parameters order_column and order_type should always be used together.

Request

  • Request parameters

    N/A

  • Example request
    GET https://{Endpoint}/v2/manage/repos?filter=center::self|namespace::group|name::busybox

Response

  • Response parameters
    Table 2 Response header parameter description

    Parameter

    Type

    Description

    Content-Range

    String

    Offset (Start index) – Count (Number of records on the current page)/Total (Total number of records)

    If the offset and limit parameters are transferred in the request, Content-Range will be added to the response header.

    Table 3 Response body parameter description

    Parameter

    Type

    Description

    [Array element]

    Array of objects

    Image repository list.

    Table 4 [Array element] parameters description

    Parameter

    Type

    Description

    name

    String

    Image repository name.

    category

    String

    Image repository type. The value can be app_server, linux, framework_app, database, lang, arm, or other.

    description

    String

    Image repository description.

    size

    Integer

    Total size of the images in an image repository.

    is_public

    Boolean

    Whether the image is a public image. The value can be true or false.

    num_images

    Integer

    Number of image tags in an image repository.

    num_download

    Integer

    Download times.

    created_at

    String

    Time when an image repository is created. It is the UTC standard time.

    updated_at

    String

    Time when an image repository is updated. It is the UTC standard time.

    logo

    String

    (Reserved field) Image repository logo address.

    url

    String

    (Reserved field) URL of the image repository logo.

    path

    String

    External Docker pull address. The format is {Repository address}/{Namespace name}/{Repository name}.

    internal_path

    String

    Internal Docker pull address. The format is {Repository address}/{Namespace name}/{Repository name}.

    domain_name

    String

    Domain name.

    namespace

    String

    Organization name.

    tags

    Array of strings

    Image tag list.

    status

    Boolean

    (Reserved field) Status.

    total_range

    Integer

    Total number of records.

  • Example response
    [
        {
            "name": "busybox",
            "category": "linux",
            "description": "this is a busybox repository",
            "size": 200977474,
            "is_public": false,
            "num_images": 2,
            "num_download": 0,
            "created_at": "2021-06-10T03:24:44.784402Z",
            "updated_at": "2021-06-10T03:40:59.199352Z",
            "logo": "",
            "url": "",
            "path": "{Repository address}/group/busybox",
            "internal_path": "{Repository address}/group/busybox",
            "domain_name": "root",
            "namespace": "group",
            "tags": [
                "latest",
                "log"
            ],
            "status": false,
            "total_range": 1
        }
    ]

Status Code

Status Code

Description

200

Request successful.

400

Request error. Error information is returned.

401

Authentication failed.

500

Internal error. Error information is returned.

Error Codes

For details, see Error Codes.