Variables
Access Discord context — user, server, channel, and arguments — inside your tag content
{args}, which is specific to
classic Tags. SlashTags receive their input through named slash
command options seeded directly as variables.
Information about the person who invoked the tag or slash command.
<@123456789>
Information about the Discord server where the tag is used.
Information about the channel where the tag was used or where the response will be sent.
<#123456789>
Information about the resolved target — typically a mentioned user
or a message object. In classic Tags this is usually the first
@mention in the arguments. In SlashTags it is the user
or message object provided to a user/message-type slash command
option.
Returns the number of times this tag (or slash tag) has been used since it was created.
args
🔗Returns the full text passed after the tag invocation, or individual words/ranges using index notation.
Compatibility Shims
🔗The Tags cog includes two internal compatibility blocks that silently translate legacy syntax into the standard engine format. You don't need to use these explicitly — they handle old-style references automatically.
{author.name}, {channel.id},
{server.icon}, {guild.name}) into the
engine's parenthesis form. Both styles work.
{0}, {1},
{2}…) into {args(N+1)} calls. The
offset of +1 accounts for the tag name itself occupying index 0.
When the TagScript engine encounters {somename}, it
checks whether it is a known block first. If it is not, it treats it
as a variable lookup. There are two resolution modes:
{=(name):value}, returns its value. If the variable
was never set, returns an
empty string silently.
${name}
If the variable was set, returns its value. If not set, returns
the literal text {name} unchanged
— useful for debugging undefined variables.