Artificial Intelligence · 1 min read
How to Use Custom Values and Variables in Agent Studio
Variables insert real information into your agent automatically. A variable is a placeholder in double curly braces. For example,
Hi {{contact.first_name}} becomes "Hi John" for a contact named John.You can use variables anywhere you type text in Agent Studio, including agent prompts, text generation nodes, tool inputs, message cards, and conditions.
Variable types
| Type | What it holds | Example | | --- | --- | --- | | Account | Your business details. | Business name, phone | | Contact | The current contact's details. | First name, email | | Date and time | The current date and time. | Today's date | | Form submission | Answers from a submitted form. | A form field value | | Custom Values | Reusable values you define. | Support email |
Custom Values
Create custom values once under Settings > Custom Values, then use them anywhere.
For example, create the key
support_email with the value support@yourcompany.com. In your agent, write For help, email {{custom_values.support_email}}. When the email changes, update it once and every agent uses the new value.Insert a variable
- Click into a text field in a node.
- Click the variable picker or type
{{. - Choose the variable.
Tips
- Use custom values for details that change, such as hours, prices, or links.
- Add a fallback in your prompt for when a contact field is empty.
- Test with a real contact to check that values fill in correctly.