Skip to main content

Update Container Registry

Update an existing container registry configuration. This endpoint allows you to modify the name, URL, username, or password of a registry.

Endpoint

PUT /container-registries/{id}

Authentication

Requires API token with container-registries:write scope.

Path Parameters

ParameterTypeRequiredDescription
idstring (UUID)YesContainer Registry ID

Request Body

All fields are optional - only provide the fields you want to update.

{
"name": "Updated Registry Name",
"url": "newregistry.azurecr.io",
"username": "new-username",
"password": "new-password-or-token"
}

Fields

FieldTypeRequiredDescription
namestringNoNew registry configuration name
urlstringNoNew registry URL
usernamestringNoNew username for authentication
passwordstringNoNew password or access token

Response

Success Response (200 OK)

{
"id": "550e8400-e29b-41d4-a716-446655440000",
"name": "Updated Registry Name",
"url": "newregistry.azurecr.io",
"username": "new-username",
"companyIdRef": "770e8400-e29b-41d4-a716-446655440002",
"createdBy": "user-123",
"modifiedBy": "user-456",
"createdAt": "2024-01-15T10:30:00Z",
"updatedAt": "2024-01-16T14:20:00Z"
}

Error Responses

404 Not Found

{
"code": "NOT_FOUND",
"message": "Container registry not found",
"request_id": "/api/v1/{company_id}/container-registries/{id}",
"timestamp": "2024-01-16T14:20:00Z"
}

409 Conflict

{
"code": "CONFLICT",
"message": "Container registry with this name already exists",
"request_id": "/api/v1/{company_id}/container-registries/{id}",
"timestamp": "2024-01-16T14:20:00Z"
}

Example Requests

Update Registry Name Only

curl -X PUT "https://api.thevenin.cloud/{company_id}/container-registries/550e8400-e29b-41d4-a716-446655440000" \
-H "Authorization: Bearer tvn_your_api_token_here" \
-H "Content-Type: application/json" \
-d '{
"name": "Production Azure Registry"
}'

Update Credentials

curl -X PUT "https://api.thevenin.cloud/{company_id}/container-registries/550e8400-e29b-41d4-a716-446655440000" \
-H "Authorization: Bearer tvn_your_api_token_here" \
-H "Content-Type: application/json" \
-d '{
"username": "new-service-account",
"password": "new-access-token-here"
}'

Update All Fields

curl -X PUT "https://api.thevenin.cloud/{company_id}/container-registries/550e8400-e29b-41d4-a716-446655440000" \
-H "Authorization: Bearer tvn_your_api_token_here" \
-H "Content-Type: application/json" \
-d '{
"name": "New Registry Name",
"url": "newregistry.azurecr.io",
"username": "new-username",
"password": "new-password"
}'

Impact on Applications

  • Applications using this registry will automatically use the updated credentials once they are updated (change of image, tag, resources, etc)
  • This typically won't affect users since the image is already stored in the local registry
  • No manual intervention required, the transition happens seamlessly during the next application update