Create a new secret value

Owner-only, write-only. Creates a new encrypted secret value under a name. The name must match ^[A-Z][A-Z0-9_]*$ (the same charset a {{secret:NAME}} reference uses, so a settable name is always referenceable); values are capped at 8 KiB. The value is never echoed back. Returns 409 secret_already_exists if a secret with the same name already exists for this scope; use PUT to replace it. Requires the owner's user token; app/render tokens are rejected.

post/app/{id}/secrets

Request

  • Base URL: https://charm.ing
  • URL: https://charm.ing/app/{id}/secrets
  • Auth: HTTP bearer

Request body

namestring required

Env-var-shaped secret name (referenceable via {{secret:NAME}}).

valuestring required

Plaintext secret value (max 8 KiB). Stored encrypted; never returned.

Response

Secret stored.

oktrue required

Changes

No recorded changes to this operation across all 1 revision of this API.