Skip to main content

Create/Update Secret

Endpoint: PUT /api/secrets/{key}

Creates or updates a secret in your Conductor cluster.

Path parameters

ParameterDescriptionTypeRequired/ Optional
keyThe secret key name.stringRequired.

Request body

Format the request body with the secret value as a JSON string. For example:

"secretValue"

Response

Returns 200 OK, indicating that the secret value is created or updated.

Examples

Create a secret

Request

curl -X 'PUT' \
'https://<YOUR-SERVER-URL>/api/secrets/someSecret' \
-H 'accept: application/json' \
-H 'X-Authorization: <TOKEN>' \
-H 'Content-Type: application/json' \
-d '"mySecretValue"'

Response

Returns 200 OK, indicating that the secret is created.

Update a secret

Request

curl -X 'PUT' \
'https://<YOUR-SERVER-URL>/api/secrets/someSecret' \
-H 'accept: application/json' \
-H 'X-Authorization: <TOKEN>' \
-H 'Content-Type: application/json' \
-d '"updatedValue"'

Response

Returns 200 OK, indicating that the secret value is updated.