Use Variables in Automations
Use variables to insert values from the automation trigger into action fields such as a GitHub issue number, email subject, or chat prompt.
Variables are useful when you want one automation to adapt automatically to the item that triggered it. Instead of hardcoding a ticket number, repository name, or issue title, you can let the automation pull in the correct value each time it runs. This helps you reuse the same automation setup across many tickets and reduces manual copying.
How Variables Work​
Write variables with double curly braces:
{{variable}}
When the automation runs, the value inside the braces is replaced with data from the trigger or the current workflow state.
This is especially useful when one step needs to pass information into the next step. For example, a GitHub trigger can provide the issue number, and the next action can use that value to post a comment back to the same issue.
Available Variables​
GitHub​
When your automation starts with a GitHub issue trigger, these shortcuts are available:
| Variable | What it means |
|---|---|
{{github:repo}} | The GitHub repository that triggered the automation, in owner/repo format. |
{{github:title}} | The title of the GitHub issue that triggered the automation. |
{{github:body}} | The body text of the GitHub issue that triggered the automation. |
{{github:issue_number}} | The issue number of the GitHub ticket that triggered the automation. |
The shortcut for the issue number is the easiest option for the Comment on GitHub ticket action.
Examples​
Comment on a Github Ticket​
This setup lets your automation comment on the exact GitHub ticket that started the workflow. You do not need to enter a fixed repository or issue number for each automation run. Instead, the action reuses the values from the trigger.
First, create a trigger Github issue created.
Then, add a Comment on GitHub ticket action with this configuration:
| Field | Value |
|---|---|
| Repository | {{github:repo}} |
| Issue number | {{github:issue_number}} |
Reuse Trigger Data in a Prompt or Message​
Example prompt:
Summarize the issue "{{github:title}}" and suggest next steps.
Tips​
- Copy the variable name exactly. Variable names are case-sensitive.
- Keep the
{{and}}braces in place. - Use the GitHub shortcuts when available because they are shorter and easier to read.
- If a variable does not resolve, check that the trigger actually provides that value.
FAQ​
Q: Which variable should I use for the GitHub ticket number?​
Use {{github:issue_number}}.
Q: Can I use variables in action fields other than the GitHub issue number?​
Yes. Variables can be used in string fields such as prompts, subjects, and messages.
Q: Why is my variable showing as plain text instead of a value?​
Check that the variable name is correct and that the automation trigger includes that data.