Logic Variable Agent
import { LogicVariable } from "@fstnetwork/loc-logic-sdk";
Read a local environment variable (not to be confused with local storage data or secrets in agent configurations). These variable can be set via Studio or CLI, which are useful for configuring a data process' behavior without modifying the logic code.
info
Logic variables can be set in Studio by the Add Configuration window while editing a linked logic of a data process.
Availability
- ✓ Generic logic
- ✓ Aggregator logic
Read Local Variable
LogicVariable.get(name: string): string | null
Parameter | Description |
---|---|
name | Logic variable name |
Returns a string or null
if the variable name does not exist.
Example
const answer = LogicVariable.get("answer-to-life-universe-everything");