查询镜像仓库
更新时间:2026-06-09
接口描述
通过镜像仓库名称查询镜像仓库。
API Explorer
去调试
您可以在 API Explorer 中直接运行该接口,免去您计算签名的困扰。运行成功后,API Explorer 可以自动生成 SDK 代码示例。
请求结构
Plain Text
1 GET /v1/instances/{instanceId}/projects/{projectName}/repositories/{repositoryName} HTTP/1.1
2 Host: ccr.bd.baidubce.com
3 Authorization: authorization string
请求头域
除公共头域外,无其它特殊头域。
请求参数
| 参数名称 | 类型 | 是否必需 | 参数位置 | 描述 |
|---|---|---|---|---|
| instanceId | String | 是 | URL参数 | 实例ID |
| projectName | String | 是 | URL参数 | 命名空间名称 |
| repositoryName | String | 是 | URL参数 | 镜像仓库名 注意:镜像仓库名称允许包含/字符,因此仓库名称建议做base64编码,例如名称是 lib/ubuntu 编码后为 bGliL3VidW50dQ== |
响应头域
除公共头域外,无其它特殊头域。
响应参数
| 参数名称 | 类型 | 描述 |
|---|---|---|
| projectName | String | 命名空间名称 |
| repositoryName | String | 镜像仓库名称 |
| description | String | 镜像仓库描述 |
| repositoryPath | String | 公网访问镜像路径 |
| privateRepositoryPath | String | vpc 内访问镜像路径 |
| tagCount | Integer | 镜像的Tag个数 |
| pullCount | Integer | 镜像拉取次数 |
| creationTime | String | 创建时间 |
| updateTime | String | 更新时间 |
请求示例
Plain Text
1 GET /v1/instances/ccr-4k74gw7d/projects/ns-test/repositories/ubuntu HTTP/1.1
2 Host: ccr.bd.baidubce.com
3 Authorization: bce-auth-v1/687882a4ec614bf788766895ecebb7f5/2022-07-29T06:01:42Z/1800/content-type;host/119caf7a75eae7423aebefca3648374053a0fe3817ae11a1664b33af7d57dfa5
响应示例
Plain Text
1 Content-Type: application/json; charset=utf-8
2 Date: Thu, 28 Jul 2022 03:25:43 GMT
3 X-Bce-Gateway-Region: BJ
4 X-Bce-Request-Id: b42840ec-a200-49c9-86bd-58687b7009bb
5
6{
7 "tagCount": 2,
8 "creationTime": "2022-07-29T02:53:34.289Z",
9 "description": "",
10 "repositoryName": "ubuntu",
11 "pullCount": 0,
12 "updateTime": "2022-07-29T02:53:34.289Z",
13 "repositoryPath": "ccr-4k74gw7d-pub.cnc.bd.baidubce.com/ns-test/ubuntu",
14 "privateRepositoryPath": "ccr-4k74gw7d-vpc.cnc.bd.baidubce.com/ns-test/ubuntu",
15 "projectName": "ns-test"
16}
评价此篇文章
