> ## Documentation Index
> Fetch the complete documentation index at: https://docs.tryhamsa.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Custom Variables

> Workflow-level variables for flow and single-prompt agents

Custom variables are defined at the **workflow level** and are available to all nodes (flow agent) or to the single prompt (single-prompt agent). They are ideal for configuration, defaults, and passing caller-specific data.

## Characteristics

* **Scope**: Global to the workflow (all nodes in flow agent; entire prompt in single-prompt agent)
* **Where to define**: Variables panel at workflow level
* **Default values**: Any supported data type
* **Reference syntax**: `{{variable_name}}`
* **Single-prompt agents**: Custom variables are exposed as `params` in the agent configuration

## When to Use

* Values that change per deployment (e.g. business name, support email)
* Default messages or responses
* State or configuration shared across the flow
* **Single-prompt agents**: Any data you want to pass into the prompt as parameters

## Example Use Cases

```
business_name: "Acme Corporation"
support_email: "support@acme.com"
max_retry_attempts: 3
is_after_hours: false
```

## Flow Builder vs Single Prompt Agents

| Aspect            | Flow Builder Agent                  | Single Prompt Agent                                                 |
| ----------------- | ----------------------------------- | ------------------------------------------------------------------- |
| Available         | All nodes, including global         | Entire prompt                                                       |
| Definition        | Variables panel                     | Variables panel (stored as `params`)                                |
| Usage             | `{{variable_name}}` in node configs | `{{variable_name}}` in prompt; custom vars become `params`          |
| Conditional logic | Flow transitions, router nodes      | `{{#if variable_name}}` in prompt (e.g. `{{#if enable_transfers}}`) |

In single prompt agents, custom variables are the **only** user-defined variables; there are no extracted or static variables. See [Single Prompt Agent Variables](./availability-and-context#single-prompt-agent-variables) for availability, configuration examples, and when to upgrade to Flow Builder. See [Template Syntax & Naming](./syntax-and-naming) for naming and syntax.
