Tags

{user} Tags

{user.mention;user;allow_mention}

Returns a string with a user mention.

NameTypeDefaultDescription
userUser?context UserThe user to mention.
allow_mentionbooleantrueWhether to ping the user with this mention

{user.id;user}

Returns the ID of a user.

NameTypeDefaultDescription
userUser?context UserThe user to get the ID of.

{user.username;user}

Returns the username of a user.

NameTypeDefaultDescription
userUser?context UserThe user to get the username of.

{user.bot;user}

Returns a boolean whether a user is a bot account.

NameTypeDefaultDescription
userUser?context UserThe user to check.

{user.tag;user}

Returns the tag of a user with the username and discriminator, for example DracoClaw#0065.

NameTypeDefaultDescription
userUser?context UserThe user to get the tag of.

{user.discriminator;user}

Returns the discriminator of a user, which is the four digits at the end of the username.

NameTypeDefaultDescription
userUser?context userThe user to get the discriminator of.

{user.avatar;user}

Returns the avatar URL of a user. Their server avatar will take priority if they have one.

NameTypeDefaultDescription
userUser?context UserThe user to get the avatar of.

{user.roles;member}

Returns an array of IDs for all the roles of a user.

NameTypeDefaultDescription
memberMember?context MemberThe user to get the roles of.

{choose;{user.roles}} // A random role the user has

{user.nickname;member}

Returns the display name of a user. This will be their nickname if they have one set and their username otherwise.

NameTypeDefaultDescription
memberMember?context MemberThe user to get the nickname of.

{user.joinedAt;member}

Returns a timestamp for the join date of a user that can be used with {time}.

NameTypeDefaultDescription
memberMember?context MemberThe member to check.

{user.createdAt;user}

Returns a timestamp for the creation date of a user's Discord account that can be used with {time}.

NameTypeDescription
userUser?The user to check.

{user.edit nick mute deaf channel;member}

Note

This tag is part of the Mutate User expensive group.

Edits a user.

NameTypeDefaultDescription
nickstring?The user's new nickname. Leave empty to clear.
muteboolean?Whether the user will be server muted in voice channels.
deafboolean?Whether the user will be server deafened in voice channels.
channelChannel?The new channel to move the user to if they are in voice channel.
memberMember?context MemberThe user to edit.

{user.addrole;role;member;reason}

Note

This tag is part of the Mutate User expensive group. This tag is marked Dangerous and must be enabled in Advanced Settings.

Gives a user a role.

NameTypeDefaultDescription
roleRoleThe role to add to the user.
memberMember?context MemberThe user to give the role to.
reasonstring?The reason for the action.

{user.removerole;role;member;reason}

Note

This tag is part of the Mutate User expensive group.

Removes a role from a user.

NameTypeDefaultDescription
roleRoleThe role to remove from the user.
memberMember?context MemberThe user to remove the role from.
reasonstring?The reason for the action.

{user.colour;member}

Gets a user's colour based on their highest non-default (#99aab5) role.

NameTypeDefaultDescription
memberMember?context MemberThe Member to check.

{user.hasPermission;permissions;member}

Checks whether a user has the given permissions.

NameTypeDefaultDescription
permissionsbigintThe permission to check for. Can be a permissions number or name (e.g. create_instant_invite)
memberMember?context MemberThe member to check the permissions of.

A full list of permissions can be seen here.

{user.level;user}

Gets the level of a user.

NameTypeDefaultDescription
userUser?context UserThe user to get the level of.

{user.xp;user;scoped}

NameTypeDefaultDescription
userUser?context UserThe user to get the XP of.
scopedbooleanfalseWhether to get XP on the current level or total XP. The default is total XP.

{user.setXP;xp;target;add;sync}

Note

This tag is part of the Mutate User expensive group.

Sets the users XP to the given amount.

NameTypeDefaultDescription
xpnumberThe amount of XP to set.
targetUser?context UserThe user to set the XP of.
addbooleanfalseWhether to add the XP to their existing total.
syncbooleanfalseWhether to sync level rewards for the user.

{user.setLevel;level;target;add;sync}

Note

This tag is part of the Mutate User expensive group.

Sets the users level to the given amount.

NameTypeDefaultDescription
levelnumberThe amount of levels to set
targetUser?context UserThe user to set the level of.
addbooleanfalseWhether to add the levels to their existing total.
syncbooleanfalseWhether to sync level rewards for the user.

{user.nextLevel;user}

Gets the next level the user will become.

NameTypeDefaultDescription
userUser?context UserThe user to get the next level of.

{user.nextLevelXP;user}

Get the XP required for the users next level.

NameTypeDefaultDescription
userUser?context UserThe user to get the next level XP of.

{user.remainingXP;user}

Gets the amount of XP a user needs to level up to the next level.

NameTypeDefaultDescription
userUser?context UserThe user to get the remaining XP of.

{user.rank;user}

Gets the rank of a user.

NameTypeDefaultDescription
userUser?context UserThe user to get the rank of.

{user.reward;filter;first;raw}

Returns the reward the user achieved by levelling up. Returns nothing if there was no reward. This tag is only available in level-up scripts and cannot be used elsewhere.

NameTypeDefaultDescription
filterstringachievedThe kind of reward to return. One of achieved, entitled, added, removed, existing.
firstbooleantrueWhether to return only the first reward in the filtered list. Some levels can have multiple rewards.
rawbooleanfalseWhether to return a raw rewards object with more information about the reward. The object looks something like { level, roleId, stack }

As an example, you could set your level-up notification to this

{if;{user.reward};Congratulations {user.mention}! You levelled up to level {user.level} and got the {role.mention allow_mention=false;{user.reward}} role!}

Which would send a level-up message only if the user got a new role.

{user.kick;target;reason;noDM;returnCaseId;moderator}

Kicks a user from the server.

NameTypeDefaultDescription
targetUserThe user to kick.
reasonstringThe reason for the kick.
noDMbooleanfalseWhether to send the user a DM about the kick.
returnCaseIdbooleanfalseWhether to return the case ID of the kick.
moderatorUser?bot userThe moderator who is kicking.

{user.ban;target;reason;noDM;purgeDays;returnCaseId;moderator;duration}

Bans a user from the server.

NameTypeDefaultDescription
targetUserThe user to ban.
reasonstringThe reason for the ban.
noDMbooleanfalseWhether to send the user a DM about the ban.
purgeDaysnumber0The number of days of messages to delete from the user.
returnCaseIdbooleanfalseWhether to return the case ID of the ban.
moderatorUser?bot userThe moderator that bans the user.
durationnumber?permanentThe duration of the ban in milliseconds.

{user.warn;target;reason;noDM;returnCaseId;moderator;duration}

Warns a user.

NameTypeDefaultDescription
targetUserThe user to warn.
reasonstringThe reason for the warn.
noDMbooleanfalseWhether to send the user a DM about the warn.
returnCaseIdbooleanfalseWhether to return the case ID of the warn.
moderatorUser?bot userThe moderator who is warning.
durationstring?The duration of the warn (ex 1d), permanent by default.

{user.caseCount;member;type}

Gets the amount of cases a user has.

NameTypeDefaultDescription
memberMember?context MemberThe member to get case count from.
typestring?The type of cases to count. One of Mute, Unmute, Kick, Ban, Unban, Warning.

{user.setRoles;roles;member}

Note

This tag is part of the Bulk Edit expensive group.

Sets the roles of a user.

NameTypeDefaultDescription
rolesRole[]An array of roles to set for the user.
memberMember?context MemberThe member to set the roles of.