Variables
Variables are placeholders that Ticket Tool fills in when it sends a message. Write {{user.mention}} in an intro message and the member who opened the ticket gets pinged. This page lists every variable and where it works.
Syntax
- Double braces
{{ticket.number}}are the standard form. If the value doesn't exist, the placeholder is removed, so members never see raw braces. - Single braces
{ticket.number}also work in messages, panels and flows. If the value doesn't exist, the text stays as you typed it, which keeps ordinary braces in your prose intact. - Names are case-sensitive:
{{responses.Email}}and{{responses.email}}are different variables. - Show text only when a value is present, or only when it matches, with conditional blocks.
Conditional blocks
Wrap text in {{#if …}} and {{/if}} to show it only when the check is true. They work wherever variables do: flow messages, the category intro message, close messages, panels and the localization strings that take variables.
| Write | Shows the text when |
|---|---|
{{#if custom.size}}…{{/if}} | custom.size has a value |
{{#unless custom.size}}…{{/unless}} | custom.size is empty |
{{#if ticket.priority == "HIGH"}}…{{/if}} | The priority is HIGH. Case is ignored |
{{#if ticket.priority != "LOW"}}…{{/if}} | The priority is anything but LOW |
{{#if custom.size == custom.default_size}}…{{/if}} | Two variables hold the same value |
{{#if custom.email || responses.Email}}…{{/if}} | Either variable has a value |
Empty values, false, 0, no and off count as false; anything else is true. Put quotes around text you compare with, so it is never mistaken for a variable name.
Add {{else}} to show something when the check is false:
{{#if roblox.name}}Roblox account: {{roblox.name}}{{else}}No Roblox account linked.{{/if}}
Blocks can sit inside each other, and each {{else}} belongs to the block it is in. Nesting is also how you require two things at once:
{{#if custom.product == "Hoodie"}}{{#if custom.size}}Hoodie, size {{custom.size}}{{else}}Hoodie, size not picked{{/if}}{{/if}}
A block removes only what is between its tags. To hide a whole line, put the line break inside the block, before {{/if}}, or a blank line is left behind:
Product: {{custom.product}}
{{#if custom.size}}Size: {{custom.size}}
{{/if}}Delivery: {{custom.delivery}}
A check can only test for a value, equal or not equal. For "contains", a number range or a pattern, branch with a Condition node in a flow instead.
Fallback values
Give a variable a fallback with ||. The first side that has a value is used, and text in quotes is used as it is:
| Write | Shows |
|---|---|
{{custom.size || "One size"}} | The size, or One size when none was saved |
{{custom.nickname || user.username}} | The saved nickname, or the member's username |
{{custom.a || custom.b || "none"}} | The first of the two with a value, or none |
A fallback without quotes is always read as a variable name, so a missing one shows nothing rather than its name.
Fallbacks work in single braces too. {custom.size || "One size"} shows the size or One size, and is the safer choice in a panel or a localization string, where a bare {custom.size} would otherwise appear as typed when there's no value. Without a quoted fallback, a single-brace token whose variables are all empty still stays as typed.
Where variables work
| Where | What it can use |
|---|---|
| Category intro message and the opening DM | User, ticket and server, placeholders, flow answers, and the category's lookups |
| Closed message, closed and added DMs | What that field's Variables button lists, usually {{user.mention}}, {{ticket.number}} and {{category.name}} |
| Panel embed | {{guild.name}}, the channel it is posted in ({{channel.name}}, {{channel.mention}}) and placeholders. No ticket exists there yet. |
| Channel naming pattern | {{ticket.number}}, {{ticket.status}}, {{ticket.priority}}, {{user.username}}, {{user.id}}, {{category.name}}, {{guild.name}} |
| Support flows | Everything that exists at that step, plus the flow variables |
| Localization strings | What each string's Variables button lists |
User, ticket and server
{{user.mention}}: Mentions the member. In an intro message, the ticket opener; in a flow, whoever started it, or the opener for an automation flow{{user.username}},{{user.id}}: Their Discord username and user ID{{user.displayName}}: Their Discord display name in a flow someone started. In intro messages it is the username{{ticket.number}}: Ticket number, such as42{{ticket.status}}: Current status, such asOPEN{{ticket.priority}}: Current priority, such asHIGH(flows and channel names){{ticket.link}}: A link straight to the ticket channel, useful in a DM{{category.name}}: The ticket's category{{guild.name}},{{guild.id}}: Your server's name and ID{{channel.name}},{{channel.mention}}: The ticket channel, or for a panel, the channel it is posted in{{ticket.creator.mention}}: The ticket opener (flows only){{ticket.claimedBy.mention}}: The staff member who claimed it, empty until someone does (flows only)
Ticket activity
Flows that run inside a ticket can also read what has happened in it so far.
{{ticket.lastMessage.mention}}: Mentions whoever spoke last{{ticket.lastMessage.content}}: The text of that message, empty for an attachment only{{ticket.lastStaffReply.mention}}: Mentions the staff member who replied most recently{{ticket.staffReplied}}:trueonce any staff member has replied{{ticket.messageCount}}: How many messages people have sent, not counting the bot
Each person variable also has .username and .id forms. {{ticket.lastMessage}} skips the bot's own messages and anonymous dashboard replies, so anonymous replies stay anonymous.
{{ticket.lastMessage.content}} is the right input for an AI node that should judge only what was just said. Leave an AI node's input blank and it reads the last ten messages instead.
These work in flows started by a click inside a ticket too, which is how a workflow button reaches the ticket's opener rather than the staff member who pressed it. They are empty in a flow that creates the ticket, because no ticket exists yet at that point.
Custom placeholders
Define your own server-wide values, such as a docs link or a store URL, in the Custom Placeholders card under Settings → Automation. Use one as {{placeholder.name}} in intro messages, panels and flows.
Flow variables
{{responses.Field label}}: An answer from a form or select menu, keyed by the field's label{{options.name}}: A custom command option{{inputs.name}}: A value passed in by the flow that called this one{{custom.name}}: A value saved by a Set Variable step{{aiOutputs.name}}: Output saved by an AI step{{api.name}}: A field saved from an API Request response{{_apiStatus}}: The last API Request's HTTP status, or0when the request failed to connect{{panel.name}}: The panel the flow was started from{{source.user.mention}},{{source.user.id}}: Who posted the message whose button started this flow{{source.responses.Field label}}: An answer that person gave before the message was posted
The right-click context commands add {{options.target_user}}, {{options.target_user_id}}, {{options.target_user_mention}} and, for a message, {{options.target_message_content}}, {{options.target_message_link}} and {{options.target_message_id}}. When the command opens a ticket directly, the same values reach the intro message as {{responses.target_user}} and so on.
The source.* variables let a public message, such as a listing or sign-up post, hand off to a fresh flow for whoever presses its button. They are kept for 90 days after the message is posted. See Buttons that start another flow.
Saving your own values
A Set Variable step stores a value under a name you pick, and every later step in the run can use it. Its value can include other variables, so it can save a fixed label or build one from earlier answers:
| Set Variable step | Later steps read |
|---|---|
product = Hoodie | {{custom.product}} → Hoodie |
plan = {{responses.Plan Type}} | {{custom.plan}} → whatever the member picked |
order = {{custom.product}}, {{custom.delivery}} | {{custom.order}} → Hoodie, Express |
Put one behind each button of a menu and the flow remembers which one was pressed, across as many menus as you like, then reports them all in one message or branches on them with a Condition. Build an order menu walks through a full example.
Linked accounts, lookups and bans
These fill in when a ticket opens: Steam whenever the opener shared an account, the rest when the category has that lookup turned on. They work in the intro message, the opening DM and the ticket's flows, and are empty when the lookup is off, finds nothing, or doesn't answer within 4 seconds. All of them need the Community or Pro plan, except Custom HTTP lookups, which need Pro.
Steam
From a Steam account the opener linked and shared with your server. Check {{steam.linked}} in a flow condition before relying on the rest.
{{steam.linked}}:truewhen a Steam account is shared with this server{{steam.id}},{{steam.name}},{{steam.url}}: SteamID64, display name and profile link{{steam.created}},{{steam.age_days}}: Account creation date (YYYY-MM-DD) and age in days{{steam.public}}: Whether the profile is public{{steam.vac_banned}},{{steam.vac_bans}}: Whether it has a VAC ban, and how many{{steam.game_bans}},{{steam.days_since_last_ban}}: Number of game bans, and days since the most recent ban{{steam.trade_banned}},{{steam.community_banned}}: Whether the account is trade or community banned{{steam.games_owned}}: Games owned (public profiles only){{steam.hours}}: Total hours played, orhiddenfor a private profile
Roblox and Custom HTTP
From the category's Lookups card.
{{roblox.linked}}:truewhen the opener has a Roblox account linked through Bloxlink{{roblox.name}},{{roblox.display_name}}: Roblox username and display name{{roblox.id}},{{roblox.url}}: Roblox user ID and profile link{{roblox.created}},{{roblox.age_days}}: Account creation date and age in days{{roblox.verified}}: Whether the account has Roblox's verified badge{{roblox.banned}}: Whether Roblox reports the account as banned{{lookup.name}}: A value mapped from your Custom HTTP lookup
Minecraft
From your server's Minecraft plugin, for an opener who linked a Minecraft account in game. The name and UUID come from the link even when the plugin doesn't answer; the rest are empty then.
{{minecraft.linked}}:truewhen a Minecraft account is shared with your server{{minecraft.verified}}:trueonly when your own server's plugin verified the link{{minecraft.name}},{{minecraft.uuid}}: Minecraft username and UUID{{minecraft.url}}: NameMC profile link{{minecraft.online}},{{minecraft.server}}: Whether they are on your server now, and which backend{{minecraft.first_seen}},{{minecraft.last_seen}}: When they first joined and were last seen (YYYY-MM-DD)
FiveM, Garry's Mod, Rust and CS2
From that game's plugin on your server. Each game has its own prefix: fivem, gmod, rust or cs2. Garry's Mod, Rust and CS2 need a Steam account the opener shared with your server; FiveM finds the player by their Discord account.
{{gmod.linked}}:truewhen there is someone to look up (always for FiveM){{gmod.name}}: In-game name{{gmod.steam_id}},{{gmod.url}}: SteamID64 and Steam profile link (FiveM: only if reported){{gmod.online}},{{gmod.server}}: Whether they are on your server now, and which one{{gmod.first_seen}},{{gmod.last_seen}}: When they first joined and were last seen{{gmod.details}}: Extra lines from the plugin, such as rank, job or playtime
Bans
From the category's Ban Lookup. A flow that reads them also gets them before any ticket exists, such as an appeal form on a panel, checked against whoever started it. The intro message is visible to the opener, so keep ban reasons out of it unless you mean to share them.
{{bans.count}}: How many sources report a ban, empty if none could be checked{{bans.any}}:truewhen any source reports a ban, empty if none could be checked{{bans.source.banned}}: Whether that source reports a ban{{bans.source.reason}}: The ban reason{{bans.source.created}}: When the ban started{{bans.source.expires}}: When it ends, ornever{{bans.source.actor}}: Who issued it, when the source says{{bans.source.status}}:checked,unavailable,no_accountornot_set_up. It readsclaimedwhen the account was linked on another server and isn't verified here, and the fields above then stay empty
Replace source with discord, battlemetrics, roblox, steam, minecraft, fivem, gmod, rust or cs2, as in {{bans.discord.banned}}.
Seeing every variable while you debug
When a flow message comes out wrong, put {{all_variables}} in a step and run it. It prints every variable available at that point, one per line:
ticket.number = 42
responses.Email = alice@example.com
api.login.token = «redacted: looks like a credential»
custom._apiStatus = 200
That gives you the exact spelling, so a wrong guess like {{responses.email}} becomes an obvious {{responses.Email}}.
- Values that look like credentials are hidden, both by name (
token,password,api_key,authorization) and by shape, while ordinary IDs stay readable. - It stays empty inside Send Webhook and API Request steps, so your run's data cannot leave through it.
- The output is capped, and long values are shortened.
Take it out when you are done
Use it in a private or staff-only step. Left in a message the opener can see, it shows them form answers and internal values.