Skip to content

sealSecret

reference
1 min readUpdated

Kind: Function

Source: atloria-monorepo/apps/api/src/documentation/payload-crypto.ts

Seal a secret string. Returns enc:v1:... when a key is set; otherwise returns the plaintext unchanged (key not wired yet — the runner still handles it). Empty / nullish values pass through untouched.

Signature

ts
function sealSecret(plaintext: T): T | string

Parameters

NameType
plaintextT

Returns: T | string

Was this page helpful?

Download as PDF