Helm Chart Management Interface
Prerequisites
- Successfully [Create Enterprise Edition Instance](CCR/Enterprise Edition API Reference/Enterprise Edition Instance APIs.md).
- Each instance must contain at least one namespace. For detailed information, refer to [Manage Namespace](CCR/Enterprise Edition API Reference/Namespace APIs.md).
Query Helm chart list
API description
Retrieve the list of chart packages from the Helm chart registry within the specified namespace.
Request structure
1GET /v1/instances/{instanceId}/projects/{projectName}/charts?pageNo={pageNo}&pageSize={pageSize}&chartName={chartName} HTTP/1.1
2Host: ccr.bd.baidubce.com
3Authorization: authorization string
Request headers
There are no special headers required beyond the common headers.
Request parameters
| Parameter name | Types | Required or not | Parameter location | Description |
|---|---|---|---|---|
| instanceId | String | Yes | Path | CCR instance ID |
| projectName | String | Yes | Path | Namespace name |
| chartName | String | No | Query | Chart name, supporting fuzzy query |
| pageNo | Integer | No | Query | Current page, defaulting to 1 |
| pageSize | Integer | No | Query | Record count per page, defaulting to 10 |
Response headers
There are no special headers required beyond the common headers.
Response parameters
| Parameter name | Types | Description |
|---|---|---|
| total | String | Result record count |
| pageNo | String | Current page number |
| pageSize | String | Records count per page |
| items | List<[HelmChart](CCR/Enterprise Edition API Reference/Appendix.md#HelmChart)> | Helm chart result list |
Request example
1GET /v1/instances/ccr-4k74gw7d/projects/ns-test/charts HTTP/1.1
2Host: ccr.bd.baidubce.com
3Authorization: bce-auth-v1/123456/2022-08-01T08:26:41Z/1800/host/0a859ce949951fe15a4eb6874a9765f9e8a6f7147f206cf47e270c34c862b8c6
Response example
1HTTP/1.1 200 OK
2Content-Type: application/json; charset=utf-8
3Date: Mon, 01 Aug 2022 08:26:41 GMT
4X-Bce-Gateway-Region: BJ
5X-Bce-Request-Id: 6cee2df3-0505-4044-9f12-65db07ebbcd7
6
7{
8 "total": 2,
9 "pageNo": 1,
10 "pageSize": 2,
11 "items": [
12 {
13 "created": "2022-08-01T06:39:05.756871973Z",
14 "deprecated": false,
15 "home": "",
16 "icon": "",
17 "latestVersion": "0.3.0",
18 "name": "helm-demo",
19 "totalVersions": 3,
20 "updated": "0001-01-01T00:00:00Z"
21 },
22 {
23 "created": "2022-08-01T07:13:54.692336735Z",
24 "deprecated": false,
25 "home": "",
26 "icon": "",
27 "latestVersion": "0.2.0",
28 "name": "helm-test",
29 "totalVersions": 2,
30 "updated": "0001-01-01T00:00:00Z"
31 }
32 ]
33}
Upload Helm chart file
API description
Upload a chart package to the Helm chart registry.
Request structure
1POST /v1/instances/{instanceId}/projects/{projectName}/charts HTTP/1.1
2Host: ccr.bd.baidubce.com
3Authorization: authorization string
4Content-Length: <ContentLength>
5Content-Type: multipart/form-data
6Content-Disposition: form-data; name="chart"; filename="{chart}"
7Content-Disposition: form-data; name="prov"; filename="{prov}"
Request headers
There are no special headers required beyond the common headers.
Request parameters
| Parameter name | Types | Required or not | Parameter location | Description |
|---|---|---|---|---|
| instanceId | String | Yes | Path | CCR instance ID |
| projectName | String | Yes | Path | Namespace name |
| chart | File | Yes | Body | Compressed package of Chart file, only supporting .tgz format. |
| prov | File | No | Body | Chart provenance file. If the chart file is signed, the provenance file shall be uploaded. |
Response headers
There are no special headers required beyond the common headers.
Response parameters
| Parameter name | Types | Description |
|---|---|---|
| success | Boolean | Whether file upload succeeded |
| result | String | Result information |
Request example
1GET /v1/instances/instances-test/projects/ns-test/repositories/ubuntu/tags?tagName=18.051&pageNo=1&pageSize=10 HTTP/1.1
2Host: ccr.bd.baidubce.com
3Authorization: bce-auth-v1/123456/2022-08-01T08:26:41Z/1800/host/0a859ce949951fe15a4eb6874a9765f9e8a6f7147f206cf47e270c34c862b8c6
4Content-Length: 802
5Content-Type: multipart/form-data
6Content-Disposition: form-data; name="chart"; filename="helm-test-0.2.0.tgz"
Response example
1HTTP/1.1 200 OK
2Content-Type: application/json; charset=utf-8
3Date: Mon, 01 Aug 2022 08:26:41 GMT
4X-Bce-Gateway-Region: BJ
5X-Bce-Request-Id: 6cee2df3-0505-4044-9f12-65db07ebbcd7
6
7{
8 "result":null,
9 "success":true
10}
Delete Helm charts in batch
API description
Delete multiple chart packages from the Helm chart registry in batch.
Request structure
1DELETE /v1/instances/{instanceId}/projects/{projectName}/charts HTTP/1.1
2Host: ccr.bd.baidubce.com
3Authorization: authorization string
4{
5 "items": {items}
6}
Request headers
There are no special headers required beyond the common headers.
Request parameters
| Parameter name | Types | Required or not | Parameter location | Description |
|---|---|---|---|---|
| instanceId | String | Yes | Path | CCR instance ID |
| projectName | String | Yes | Path | Namespace name |
| items | List<String> | Yes | Body | Chart name array |
Response headers
There are no special headers required beyond the common headers.
Response parameters
No response parameters
Request example
1DELETE /v1/instances/ccr-4k74gw7d/projects/ns-test/charts HTTP/1.1
2Host: ccr.bd.baidubce.com
3Authorization: bce-auth-v1/123456/2022-08-01T08:26:41Z/1800/host/0a859ce949951fe15a4eb6874a9765f9e8a6f7147f206cf47e270c34c862b8c6
4{
5 "items": [
6 "helm-test2",
7 "helm-test3"
8 ]
9}
Response example
1HTTP/1.1 200 OK
2Content-Type: application/json; charset=utf-8
3Date: Mon, 01 Aug 2022 08:26:41 GMT
4X-Bce-Gateway-Region: BJ
5X-Bce-Request-Id: 6cee2df3-0505-4044-9f12-65db07ebbcd7
Delete Helm charts
API description
Remove the specified chart packages from the Helm chart registry.
Request structure
1DELETE /v1/instances/{instanceId}/projects/{projectName}/charts/{chartName} HTTP/1.1
2Host: ccr.bd.baidubce.com
3Authorization: authorization string
Request headers
There are no special headers required beyond the common headers.
Request parameters
| Parameter name | Types | Required or not | Parameter location | Description |
|---|---|---|---|---|
| instanceId | String | Yes | Path | CCR instance ID |
| projectName | String | Yes | Path | Namespace name |
| chartName | String | Yes | Path | Chart name |
Response headers
There are no special headers required beyond the common headers.
Response parameters
No response parameters available.
Request example
1DELETE /v1/instances/ccr-4k74gw7d/projects/ns-test/charts/helm-test HTTP/1.1
2Host: ccr.bd.baidubce.com
3Authorization: bce-auth-v1/123456/2022-08-01T08:26:41Z/1800/host/0a859ce949951fe15a4eb6874a9765f9e8a6f7147f206cf47e270c34c862b8c6
Response example
1HTTP/1.1 200 OK
2Content-Type: application/json; charset=utf-8
3Date: Mon, 01 Aug 2022 08:26:41 GMT
4X-Bce-Gateway-Region: BJ
5X-Bce-Request-Id: 6cee2df3-0505-4044-9f12-65db07ebbcd7
Query Helm chart version list
API description
Retrieve version lists for specific charts from the Helm chart registry.
Request structure
1GET /v1/instances/{instanceId}/projects/{projectName}/charts/{chartName}/versions?pageNo={pageNo}&pageSize={pageSize}&chartVersion={chartVersion} HTTP/1.1
2Host: ccr.bd.baidubce.com
3Authorization: authorization string
Request headers
There are no special headers required beyond the common headers.
Request parameters
| Parameter name | Types | Required or not | Parameter location | Description |
|---|---|---|---|---|
| instanceId | String | Yes | Path | CCR instance ID |
| projectName | String | Yes | Path | Namespace name |
| chartName | String | Yes | Path | Chart name |
| chartVersion | String | No | Query | Chart version No., supporting fuzzy query |
| pageNo | Integer | No | Query | Current page, defaulting to 1 |
| pageSize | Integer | No | Query | Record count per page, defaulting to 10 |
Response headers
There are no special headers required beyond the common headers.
Response parameters
| Parameter name | Types | Description |
|---|---|---|
| total | String | Virtual private cloud domain name |
| pageNo | String | Current page number |
| pageSize | String | Records count per page |
| items | List<[HelmChartVersion](CCR/Enterprise Edition API Reference/Appendix.md#HelmChartVersion)> | Chart version result list |
Request example
1GET /v1/instances/ccr-4k74gw7d/projects/ns-test/charts/helm-test/versions HTTP/1.1
2Host: ccr.bd.baidubce.com
3Authorization: bce-auth-v1/123456/2022-08-01T08:26:41Z/1800/host/0a859ce949951fe15a4eb6874a9765f9e8a6f7147f206cf47e270c34c862b8c6
Response example
1HTTP/1.1 200 OK
2Content-Type: application/json; charset=utf-8
3Date: Mon, 01 Aug 2022 08:26:41 GMT
4X-Bce-Gateway-Region: BJ
5X-Bce-Request-Id: 6cee2df3-0505-4044-9f12-65db07ebbcd7
6
7{
8 "total": 2,
9 "pageNo": 1,
10 "pageSize": 5,
11 "items": [
12 {
13 "apiVersion": "v2",
14 "appVersion": "1.16.0",
15 "deprecated": false,
16 "description": "A Helm chart for Kubernetes",
17 "engine": null,
18 "home": "",
19 "icon": null,
20 "name": "helm-test",
21 "sources": [],
22 "version": "0.2.0",
23 "created": "2022-08-16T07:14:26.854394381Z",
24 "digest": "56d2e2ab42167c5bf7e28e4e8c73a87df43b8a48aa4bd3afb36a275566b77ae3",
25 "removed": false,
26 "urls": [
27 "helm-test-0.2.0.tgz"
28 ],
29 "maintainers": null
30 },
31 {
32 "apiVersion": "v2",
33 "appVersion": "1.16.0",
34 "deprecated": false,
35 "description": "A Helm chart for Kubernetes",
36 "engine": null,
37 "home": "",
38 "icon": null,
39 "name": "helm-test",
40 "sources": [],
41 "version": "0.1.0",
42 "created": "2022-08-16T07:13:54.692336735Z",
43 "digest": "bcf2ee71d357fc466b9f31d326f5aac41bae8c06d770114d4cfd99b6982c68a9",
44 "removed": false,
45 "urls": [
46 "helm-test-0.1.0.tgz"
47 ],
48 "maintainers": null
49 }
50 ]
51}
Download Helm chart package
API description
Download a chart package from the Helm chart registry.
Request structure
1GET /v1/instances/{instanceId}/projects/{projectName}/charts/download/{filename} HTTP/1.1
2Host: ccr.bd.baidubce.com
3Authorization: authorization string
Request headers
There are no special headers required beyond the common headers.
Request parameters
| Parameter name | Types | Required or not | Parameter location | Description |
|---|---|---|---|---|
| instanceId | String | Yes | Path | CCR instance ID |
| projectName | String | Yes | Path | Namespace name |
| filename | String | Yes | Path | Helm chart file name. Check the chart file name from the URLs field in the response results of the [Helm Chart Version List](CCR/Enterprise Edition API Reference/Appendix.md#HelmChartVersion). |
Response headers
There are no special headers required beyond the common headers.
Response parameters
The response is a binary file stream with no additional parameters.
Request example
1GET /v1/instances/ccr-4k74gw7d/projects/ns-test/charts/download/helm-test-0.1.0.tgz HTTP/1.1
2Host: ccr.bd.baidubce.com
3Authorization: bce-auth-v1/123456/2022-08-01T08:26:41Z/1800/host/0a859ce949951fe15a4eb6874a9765f9e8a6f7147f206cf47e270c34c862b8c6
Response example
1HTTP/1.1 200 OK
2Content-Type: application/x-tar
3Date: Mon, 01 Aug 2022 08:26:41 GMT
4X-Bce-Gateway-Region: BJ
5X-Bce-Request-Id: 6cee2df3-0505-4044-9f12-65db07ebbcd7
6Transfer-Encoding:chunked
Delete Helm chart version in batch
API description
Delete chart versions from the Helm chart registry in bulk.
Request structure
1DELETE /v1/instances/{instanceId}/projects/{projectName}/charts/{chartName}/versions HTTP/1.1
2Host: ccr.bd.baidubce.com
3Authorization: authorization string
4
5{
6 "items": {items}
7}
Request headers
There are no special headers required beyond the common headers.
Request parameters
| Parameter name | Types | Required or not | Parameter location | Description |
|---|---|---|---|---|
| instanceId | String | Yes | Path | CCR instance ID |
| projectName | String | Yes | Path | Namespace name |
| chartName | String | Yes | Path | Chart name |
| items | List<String> | Yes | Body | Chart version No. array |
Response headers
There are no special headers required beyond the common headers.
Response parameters
No response parameters available.
Request example
1DELETE /v1/instances/ccr-4k74gw7d/projects/ns-test/charts/helm-test/versions HTTP/1.1
2Host: ccr.bd.baidubce.com
3Authorization: bce-auth-v1/123456/2022-08-01T08:26:41Z/1800/host/0a859ce949951fe15a4eb6874a9765f9e8a6f7147f206cf47e270c34c862b8c6
4
5{
6 "items": [
7 "0.4.0",
8 "0.3.0"
9 ]
10}
Response example
1HTTP/1.1 200 OK
2Content-Type: application/json; charset=utf-8
3Date: Mon, 01 Aug 2022 08:26:41 GMT
4X-Bce-Gateway-Region: BJ
5X-Bce-Request-Id: 6cee2df3-0505-4044-9f12-65db07ebbcd7
Delete Helm chart version
API description
Remove the specified version of a chart package from the Helm chart registry.
Request structure
1DELETE /v1/instances/{instanceId}/projects/{projectName}/charts/{chartName}/versions/{chartVersion} HTTP/1.1
2Host: ccr.bd.baidubce.com
3Authorization: authorization string
Request headers
There are no special headers required beyond the common headers.
Request parameters
| Parameter name | Types | Required or not | Parameter location | Description |
|---|---|---|---|---|
| instanceId | String | Yes | Path | CCR instance ID |
| projectName | String | Yes | Path | Namespace name |
| chartName | String | Yes | Path | Chart name |
| chartVersion | String | Yes | Path | Chart version No. |
Response headers
There are no special headers required beyond the common headers.
Response parameters
No response parameters available.
Request example
1DELETE /v1/instances/ccr-4k74gw7d/projects/ns-test/charts/helm-test/versions/0.2.0 HTTP/1.1
2Host: ccr.bd.baidubce.com
3Authorization: bce-auth-v1/123456/2022-08-01T08:26:41Z/1800/host/0a859ce949951fe15a4eb6874a9765f9e8a6f7147f206cf47e270c34c862b8c6
Response example
1HTTP/1.1 200 OK
2Content-Type: application/json; charset=utf-8
3Date: Mon, 01 Aug 2022 08:26:41 GMT
4X-Bce-Gateway-Region: BJ
5X-Bce-Request-Id: 6cee2df3-0505-4044-9f12-65db07ebbcd7
