Skip to content
GitHub

Set a secret's values: a new revision, rolled out unless `rollout` is false.

PUT
/api/v1/projects/{project}/environments/{environment}/secrets/{secret}
curl --request PUT \
--url https://example.com/api/v1/projects/example/environments/example/secrets/example \
--header 'Content-Type: application/json' \
--data '{ "data": { "additionalProperty": "example" }, "rollout": true }'
project
required
string

Project name

environment
required
string

Environment short name

secret
required
string

Secret name

Media typeapplication/json
object
data
required

Key → UTF-8 value. Replaces the whole secret with a new revision.

object
key
additional properties
string
rollout

Roll the new value out to the apps that reference the secret.

boolean
Examplegenerated
{
"data": {
"additionalProperty": "example"
},
"rollout": true
}
Media typeapplication/json
object
name
required
string
keys
required

Key names only; values are never returned.

Array<string>
created_at
string | null
storage
required

Where a secret’s values are kept.

string
Allowed values: encrypted cluster
revision

The current revision of an encrypted secret.

integer | null format: int64
revoked
required

The current revision is revoked: set a new value before deploying.

boolean
updated_at
string | null
rollouts

The runs that roll a new value out, after a change.

Array<object>

One app’s rollout of a new secret value.

object
app
required
string
run

The rotation run; None when the app could not take one now.

string | null format: uuid
approvals_required
required
integer format: int32
skipped

Why there is no run.

string | null
Example
{
"storage": "encrypted"
}
Media typeapplication/json

Problem Details body.

object
code
required

Stable machine-readable code, e.g. forbidden.

string
title
required

Short human readable title.

string
status
required

HTTP status.

integer format: int32
detail

Details, if safe to expose.

string | null
Example
{
"code": "forbidden"
}

The environment is being deleted, or the name is a registry login

Media typeapplication/json

Problem Details body.

object
code
required

Stable machine-readable code, e.g. forbidden.

string
title
required

Short human readable title.

string
status
required

HTTP status.

integer format: int32
detail

Details, if safe to expose.

string | null
Example
{
"code": "forbidden"
}
Media typeapplication/json

Problem Details body.

object
code
required

Stable machine-readable code, e.g. forbidden.

string
title
required

Short human readable title.

string
status
required

HTTP status.

integer format: int32
detail

Details, if safe to expose.

string | null
Example
{
"code": "forbidden"
}
Media typeapplication/json

Problem Details body.

object
code
required

Stable machine-readable code, e.g. forbidden.

string
title
required

Short human readable title.

string
status
required

HTTP status.

integer format: int32
detail

Details, if safe to expose.

string | null
Example
{
"code": "forbidden"
}