ExuluVariables provides a single get method that reads a named variable from the IMP variables table. If the variable was stored as encrypted (AES-256 via the platform’s variable editor), get decrypts it transparently using NEXTAUTH_SECRET before returning the plaintext value.
Use ExuluVariables inside tools, processors, or any server-side code where you need access to admin-managed secrets (API keys, connection strings, toggle values) without hard-coding them.
API surface
ExuluVariables.get
name in the variables table, decrypts it if the encrypted flag is set, and returns the plaintext value as a string.
The variable name as it appears in Administration → Variables.
The plaintext variable value. Throws with
Variable <name> not found. when the name does not exist.Example
execute:
Notes
- Encryption uses
CryptoJS.AESwithNEXTAUTH_SECRETas the key phrase. Both the platform andgetmust share the same secret. - Unencrypted variables are returned as-is from the database.
ExuluVariablesis a thin convenience wrapper — you can also query thevariablestable directly viapostgresClientwhen you need the full row.
Related
- Administration / Variables: create and manage platform variables.
postgresClient: direct database access.