CorefinityCorefinityDocs
Open the Control PanelControl Panel
Registry secrets · 3 of 5

Update a registry secret

Changes the fields you send and keeps the rest. A new token replaces the saved one. Anything that changes what the registry is asked with (the registry, the sign-in type, the username or the token) clears verified_at; a new label keeps it.

PUT/api/corestack/environments/{environment}/deploy-secrets/{secret}

Path parameters

environmentintegerRequired

The id of a CoreStack Enterprise environment. Not the same number as a site row id. At least 1.

secretintegerRequired

The id of a registry secret of this environment, as the list answers it. Digits only. At least 1.

Body

auth_typestring

How the registry signs in.

http-basicbearergithub-oauthgitlab-token
labelstring

Up to 255 characters.

registrystring

Up to 255 characters.

secretstring

Up to 4,096 characters.

usernamestring

Up to 255 characters.

Returns

200 The credential after the change.

Fields of the 200 answer
dataobjectRequired

One saved registry credential. Never its token or its username.

Fields
auth_typestringRequired

How the registry signs in.

http-basicbearergithub-oauthgitlab-token
idintegerRequired

At least 1.

kindstringRequired

Always composer on these endpoints.

labelstringRequired

The name you gave the credential.

last4string or nullRequired

The last four characters of the token. Null for a token shorter than 12 characters.

last_used_atstring or nullRequired

When a build last received the credential, in UTC. Format: date-time.

registrystringRequired

The registry's host, in lower case, with its port when that is not 443.

scopestringRequired

Always an empty string for a Composer registry.

verified_atstring or nullRequired

When the registry last accepted the credential, in UTC. Null when it has not been checked since it last changed. Format: date-time.

If it is refused

StatusReasonWhat to do
401noneSend a valid token as Authorization: Bearer <token>.
403company_unavailableYour company is unavailable.
403forbiddenThe person is not allowed to do this.
403scope_requiredUse a token with the scope named in scope.
403two_factor_requiredTurn on two-factor on your account, then send again.
404noneCheck the id. You see only what your account can reach.
409existsIt already exists. Use the existing one.
422secret_invalidChoose how the registry signs in: http-basic, bearer, github-oauth or gitlab-token.
422invalidFix the field named in field; errors says why.
429rate_limitedWait for the seconds in Retry-After.

Reasons are listed by name in Errors and refusals.

The same task elsewhere

curl -X PUT https://manage.corefinity.com/api/corestack/environments/1311/deploy-secrets/318 \
  -H "Authorization: Bearer $COREFINITY_TOKEN" \
  -H "Accept: application/json" \
  -H "Content-Type: application/json" \
  -d '{
    "label": "Harbour & Finch packages"
  }'
{
  "data": {
    "auth_type": "bearer",
    "id": 318,
    "kind": "composer",
    "label": "Harbour & Finch packages",
    "last4": "oken",
    "last_used_at": null,
    "registry": "repo.example.com",
    "scope": "",
    "verified_at": null
  }
}
Try it

Try it is off for this endpointIt has not been cleared for the console. Copy the request and run it yourself when you are sure.

Was this helpful?
Open in ClaudeOpen in ChatGPT