Skip to content
Console
Menu

Getting Started

Authentication

KV Store

Decrypt a key

Decrypts a ciphertext made by Encrypt with this key.

Decrypts a ciphertext made by Encrypt with this key.

  • Path POST https://api.sylphx.com/v1/orgs/acme/projects/shop/envs/production/keys/key:decrypt
  • Scope keys:decrypt
  • Effect read — nothing is written.
  • Collection keys

#Request

FieldTypeWhat it is
namestringThe key to use. Required.
ciphertextbytesThe ciphertext from Encrypt. Required.
additional_authenticated_databytesThe additional authenticated data given to Encrypt.

#Response

FieldTypeWhat it is
plaintextbytesThe plaintext. Never returned again.
key_versionstringThe version that decrypted.

#Errors

Every error arrives in the body Errors describes.

#Examples

curl -X POST "https://api.sylphx.com/v1/orgs/acme/projects/shop/envs/production/keys/key:decrypt" \
  -H "Authorization: Bearer $SYLPHX_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"ciphertext":"…"}'