When the repair shop moves, every message telling Camille where to pick up her bike must give the new address. The shop keeps that address once, as a variable, a value a workspace keeps for all its automations. A step reads a variable named shop_address as {{workspace.shop_address}} in a message, and as workspace.shop_address in a condition or an expression.
What happens when its value changes?
A run reads the value its step finds when it reaches it. The shop saves its new address once, and every published automation gives it from its next step on, with no new version.
Who saves a variable?
A workspace member, or their agent, with saveWorkspaceVariable. A variable keeps the type it was first saved with, like an attribute: text, number, boolean, date, list, or schedule. It is never deleted, so a published automation always reads a value of the type it expects. Saving an existing name replaces its value.
How does an automation read opening hours?
Camille writes on Saturday evening, after the shop has closed. A schedule holds weekly slots in one time zone, and dates closed or on special hours. A condition on workspace.opening_hours.isOpen tells whether the shop is open, and {{workspace.opening_hours.nextOpening}} tells Camille when it opens next, in the language the automation answers in, such as Tuesday, November 17 at 9:00 AM. A wait step of type opening holds her run until the shop opens, from Saturday evening to Tuesday morning.
Is a variable secret?
No. The workspace log shows the values runs read, so keep credentials in secrets.
What happens when a variable is missing?
Publishing or testing a draft that reads a variable the workspace does not keep fails, naming the step and the variable.
In the API
Every operation is a REST endpoint and, unless marked REST only, an MCP tool of the same name. The OpenAPI document describes their parameters, payloads, and errors.
- PUT
saveWorkspaceVariableSave a workspace variable
/api/organizations/{organizationId}/workspaces/{workspaceId}/variables/{name} - GET
listWorkspaceVariablesList workspace variables
/api/organizations/{organizationId}/workspaces/{workspaceId}/variables