Back to Gitlabhq

Helm API

doc/api/packages/helm.md

18.11.22.9 KB
Original Source

{{< details >}}

  • Tier: Free, Premium, Ultimate
  • Offering: GitLab.com, GitLab Self-Managed, GitLab Dedicated

{{< /details >}}

Use this API to interact with Helm package clients.

[!warning] This API is used by the Helm-related package clients such as Helm and helm-push, and is generally not meant for manual consumption.

These endpoints do not adhere to the standard API authentication methods. See the Helm registry documentation for details on which headers and token types are supported. Undocumented authentication methods might be removed in the future.

Download a chart index

[!note] To ensure consistent chart download URLs, the contextPath field in index.yaml responses always uses the numeric project ID, whether you access the API with the project ID or the full project path.

Downloads a specified chart index for a project.

plaintext
GET projects/:id/packages/helm/:channel/index.yaml
AttributeTypeRequiredDescription
idstringyesThe ID or full path of the project.
channelstringyesHelm repository channel.
shell
curl --user <username>:<personal_access_token> \
     --url "https://gitlab.example.com/api/v4/projects/1/packages/helm/stable/index.yaml"

Write the output to a file:

shell
curl --user <username>:<personal_access_token> \
     --url "https://gitlab.example.com/api/v4/projects/1/packages/helm/stable/index.yaml" \
     --remote-name

Download a chart

Downloads a specified chart for a project.

plaintext
GET projects/:id/packages/helm/:channel/charts/:file_name.tgz
AttributeTypeRequiredDescription
idstringyesThe ID or full path of the project.
channelstringyesHelm repository channel.
file_namestringyesChart filename.
shell
curl --user <username>:<personal_access_token> \
     --url "https://gitlab.example.com/api/v4/projects/1/packages/helm/stable/charts/mychart.tgz" \
     --remote-name

Upload a chart

Uploads a specified chart for a project.

plaintext
POST projects/:id/packages/helm/api/:channel/charts
AttributeTypeRequiredDescription
idstringyesThe ID or full path of the project.
channelstringyesHelm repository channel.
chartfileyesChart (as multipart/form-data).
shell
curl --request POST \
     --form '[email protected]' \
     --user <username>:<personal_access_token> \
     --url "https://gitlab.example.com/api/v4/projects/1/packages/helm/api/stable/charts"