v1

latestOpenAPI 3.1.02026-07-26157321426.3 KB

Upserts a secret in a team

Creates a new secret or updates an existing secret if one with the provided name already exists. The name and creation date of the created or updated secret is returned. This secret belongs to the specified team

post/v1/teams/{team_id}/secrets

Request body

namestring required

Name of the new or existing secret

valuestring required

Value of the secret

Example request

{
  "name": "my_secret",
  "value": "my_secret_value"
}

Response

idstring required

Stable identifier for the secret. Unchanged across rotation.

created_atstring date-time required

Time the secret was created in ISO 8601 format

namestring required

Name of the secret

team_namestring required

Name of the team the secret belongs to

Example response

{
  "id": "3kZ9xqd"
}