Skip to main content

Default Variables

The following blocks will be present and accessible as defaults when running any tag.

Meta Variables

Meta variables reference meta attributes about the tag invocation.

Args Block

The {args} block represents the arguments passed after the tag name when invoking a tag. If no parameter is passed, it returns all the text after the invocation name. If an index is passed, it will split the arguments into a list by the given splitter, and return the word at the index. The default splitter is a " ".

Usage: {args([index]):[splitter]}

Payload: splitter

Parameter: index

Example:

note

In the following example, assume the tag's name is argstag and the message content is [p]argstag When life gives you lemons, make lemonade.

{args}
# When life gives you lemons, make lemonade
{args(1)}
# When life gives you lemons
{args(2):,}
# make lemonade

Uses Block

The {uses} block returns the number of times a tag has been used.

Usage: {uses}

Payload: None

Parameter: None

Example:
{uses}
# 1

Discord Object Variables

These blocks reference Discord objects from the tag invocation context.

Author Block

The {author} block with no parameters returns the tag invoker's full username and discriminator, but passing the attributes listed below to the block payload will return the attribute instead.

Aliases: {user}

Usage: {author([attribute])}

Payload: None

Parameter: attribute, None

AttributeDescription
idAuthor's Discord ID
nameAuthor's username
nickAuthor's nickname, if they have one, else their username
avatarA link to author's avatar
discriminatorAuthor's discriminator
created_atAuthor's account creation date
timestampAuthor's account creating date as a UTC timestamp
joined_atDate author joined the server
mentionAuthor's ping/mention
botWhether author is a bot or not
colorAuthor's top role's hex color
top_roleAuthor's top role
roleidsList of author's role IDs

Target Block

The {target} block follows the same usage and has the same attributes as the Author Block, but it's defaults to the mentioned, or the tag author.

Usage: {target}

Aliases: {member}

Channel Block

The {channel} block with no parameters returns the channel's full name but passing the attributes listed below to the block payload will return the attribute instead.

Usage: {channel([attribute])}

Payload: None

Parameter: attribute, None

AttributeDescription
idChannel's ID
nameChannel's name
created_atChannel's creation date
timestampChannel's creation date as a UTC timestamp
nsfwWhether the channel is nsfw or not
mentionChannel's ping mention
topicChannel's topic

Server Block

The {server} block with no parameters returns the server's name but passing the attributes listed bellow to the block payload will return the attribute instead.

Usage: {server([attribute])}

Aliases: guild

Payload: attribute, None

AttributeDescription
idServer's ID
nameServer's name
iconServer's icon
created_atServer's creation date
timestampServer's creation date as UTC timestamp
member_countServer's member count
botsNumber of bots in the server
humansNumber of humans in the server
randomA random member from the server