Container Repository API¶
ACCESS_TOKEN="..."
API_URL="https://gitlab.example.com/api/v4"
PROJECT_ID="117"
# list container repositories
curl -s --header "PRIVATE-TOKEN: ${ACCESS_TOKEN}" "${API_URL}/projects/${PROJECT_ID}/registry/repositories" \
| jq
REPO_ID="11"
# list tags in repository
curl -s --header "PRIVATE-TOKEN: ${ACCESS_TOKEN}" "${API_URL}/projects/${PROJECT_ID}/registry/repositories/${REPO_ID}/tags" \
| jq -r '.[].name'