Skip to content

Variables

A Collection of the most used Message Template variables


Member#

A variables that prints some useful information about the member that invokec that command or event (for example, level up announcement).

Variable Description
{{member}} Mention
{{member.id}} Unique Identifier
{{member.mention}} Mention
{{member.nickname}} Nickname on the server or original name
{{member.tag}} Full tag in the format Nickname#1234
{{member.name}} Name
{{member.discriminator}} Descriminator (4 digits after #)
{{member.joinedAt}} Join date and time
{{member.createdAt}} Registration date and time
{{member.status}} Status (Online, Idle, DnD, Offline) with emoji icon
{{member.bio}} Bio specified in !bio
{{member.avatarUrl}} Avatar URL
{{member.rank.level}} Member level
{{member.rank.remainingExp}} Remaining EXP until next level
{{member.rank.levelExp}} Total EXP required for current level
{{member.rank.levelCurrentExp}} Member's EXP on current level
{{member.rank.totalExp}} Total EXP member earned
{{member.rank.rank}} Member's rank position
{{member.rank.cookies}} Amount of cookies member have
{{member.rank.voiceActivity}} Voice Activity duration

Guild#

A variables that prints some useful information about your server.

Variable Description
{{guild}} Name
{{guild.owner}} Owner mention
{{guild.id}} Unique identifier
{{guild.name}} Name
{{guild.iconUrl}} Icon URL
{{guild.afkTimeout}} AFK timeout for voice channels (in minutes)
{{guild.afkChannel}} AFK Voice Channel
{{guild.memberCount}} Amount of Members
{{guild.createdAt}} Creation date and time
{{guild.boostCount}} Amount of active boosts

Channel#

A variables that prints some useful information about the target channel of message template (will not work for DM messages).

Variable Description
{{channel}} Mention
{{channel.id}} Unique identifier
{{channel.name}} Name
{{channel.mention}} Mention
{{channel.topic}} Description (Topic)
{{channel.position}} Position number in channel list (1 is top of the list)
{{channel.createdAt}} Creation date and time

Message#

A variables that prints some useful information about the source message.

Variable Description
{{message}} Message Content ({{message.contentRaw}})
{{message.id}} Unique identifier
{{message.contentRaw}} The raw textual content of this message.
{{message.contentDisplay}} The textual content of this message in the format that would be shown to the Discord client.
{{message.contentStripped}} The textual content of this message in the format that would be shown to the Discord client and all the markdown stripped.
{{message.author}} Message author
{{message.createdAt}} Creation date and time
{{message.mentionedMembers[0]}} The first mentioned member. Count starts from 0, enter 1 for second, etc.
{{message.mentionedRoles}} List of mentioned roles
{{message.mentionedRoles[0]}} The first mentioned role. Count starts from 0, enter 1 for second, etc.
{{message.mentionedChannels}} List of mentioned text channels
{{message.mentionedChannels[0]}} The first mentioned channel. Count starts from 0, enter 1 for second, etc.
{{message.attachments}} List of attachments
{{message.attachments[0]}} The first attachment. Count starts from 0, enter 1 for second, etc.

Member Ranking#

Additional Member Ranking variables.

Variable Description
{{rolesAdded}} List of role-rewards added
{{rolesRemoved}} List of role-rewards removed

Custom Commands#

Additional variables for custom commands.

Variable Description
{{arguments}} The text entered with the command. For example, for the command !command Hello There! arguments would be Hello There!
{{arguments.get(N)}} Get an argument entered with the command. Arguments split by whitespace so you should insert its position number as N:
  • {{arguments.get(1)}} for first argument;
  • {{arguments.get(2)}} for second, etc;
  • {{arguments.range(N,M)}} Get a range of arguments. For example, {{arguments.range(2,5)}} will print arguments starting from second to fifth.
    {{arguments.after(2)}} Get all arguments starting from second. Pick your number.
    {{arguments.before(4)}} Get arguments starting from first to the fourth. Pick your number.

    Auto-Moderation#

    These variables are used in Auto-Moderation Filters for violation notifications. Each filter has its own set of variables:‌

    Variable Description
    {{infraction.linkUrl}} Detected link

    Invites Filter#

    Variable Description
    {{infraction.inviteUrl}} Detected invite link discord.gg/<code>
    {{infraction.inviteCode}} Detected invite code

    Bad Words Filter#

    Variable Description
    {{infraction.word}} Detected bad word

    Repeated Text Filter#

    Variable Description
    {{infraction.count}} Amount of messages triggered

    Caps Lock Filter#

    Variable Description
    {{infraction.percent}} Uppercase characters percent in the message

    Emotes Filter#

    Variable Description
    {{infraction.count}} Amount of emotes detected

    Mentions Filter#

    Variable Description
    {{infraction.mentionType}} Type of detected excessive mentions
    {{infraction.count}} Amount of excessive mentions detected

    Zalgo Filter#

    Variable Description
    {{infraction.percent}} Percentage of Zalgo-characters to the whole message

    Subscriptions#

    These variables are used in Subscriptions for announcement messages:

    Twitch#

    Variable Description
    {{channel}} Channel name
    {{channel.url}} Channel URL
    {{stream}} Stream title
    {{game}} Playing game name

    Trovo.live#

    Variable Description
    {{channel}} Channel name
    {{channel.url}} Channel URL
    {{stream}} Stream title

    YouTube#

    Variable Description
    {{channel}} Channel name
    {{channel.url}} Channel URL
    {{video}} Video title
    {{video.url}} Video URL

    VK#

    Variable Description
    {{post}} Page URL of the post