Template variables
Put these in custom commands, welcome and leave messages, autoresponders, level-up messages and anywhere else the dashboard shows a variable picker. Kovu fills them in when the message is sent.
Basic
Work in every message Kovu sends for you.
| Variable | What it does |
|---|---|
{user} | Mentions the user |
{server} | The server name |
{channel} | The channel name |
{prefix} | The server's command prefix |
Mentions
| Variable | What it does |
|---|---|
{everyone} | Pings @everyone |
{here} | Pings @here |
{@name} | Mentions a user by usernameExample: {@kovu} |
{&role} | Mentions a role by nameExample: {&Gamers} |
{#channel} | Links a channel by nameExample: {#rules} |
User
| Variable | What it does |
|---|---|
{user.id} | The user's ID |
{user.name} | The user's username |
{user.username} | The user's username |
{user.displayname} | Server nickname, global display name or username |
{user.globalname} | The user's global display name |
{user.nick} | The user's server nickname (or display name) |
{user.tag} | username (or name#1234 for legacy accounts) |
{user.idname} | username (ID) |
{user.discrim} | The user's legacy discriminator |
{user.mention} | Mentions the user |
{user.avatar} | URL of the user's avatar |
{user.createdat} | When the account was created |
{user.joinedat} | When the user joined the server |
{user.bot} | "true" if the user is a bot |
Server
| Variable | What it does |
|---|---|
{server.id} | The server's ID |
{server.name} | The server's name |
{server.icon} | URL of the server's icon |
{server.membercount} | Number of members |
{server.ownerid} | The owner's ID |
{server.owner} | Mentions the owner |
{server.createdat} | When the server was created |
{server.boosts} | Number of boosts |
{server.boostlevel} | Boost level (0-3) |
Channel
| Variable | What it does |
|---|---|
{channel.id} | The channel's ID |
{channel.name} | The channel's name |
{channel.mention} | Links the channel |
{channel.topic} | The channel's topic |
Role
| Variable | What it does |
|---|---|
{role} | The role name (where a role is in context) |
{role.id} | The role's ID |
{role.name} | The role's name |
{role.mention} | Mentions the role |
{role.color} | The role's colour as hex |
{role.membercount} | Members with the role |
Time
| Variable | What it does |
|---|---|
{time} | Current time (24 hour) |
{time12} | Current time (12 hour) |
{date} | Current date |
{datetime} | Current date and 24 hour time |
{datetime12} | Current date and 12 hour time |
{timestamp} | Current Unix timestamp (seconds) |
Arguments
What members type after a custom command, like `?hug @kovu`.
| Variable | What it does |
|---|---|
$N | Argument N (1-based)Custom commandsExample: You chose $1 |
$N+ | Argument N and everything after itCustom commandsExample: Reason: $2+ |
Actions
Change what happens when a custom command runs.
| Variable | What it does |
|---|---|
{delete} | Delete the message that triggered the commandCustom commands |
{silent} | Suppress the bot's normal responseCustom commands |
{noeveryone} | Never ping @everyone/@here |
{!command} | Run another bot commandCustom commandsExample: {!role $1 Regulars} |
Restrictions
Decide who and where a custom command works.
| Variable | What it does |
|---|---|
{require:role} | Only members with this role may use it (or serverMod)Custom commandsExample: {require:Staff} |
{require:#channel} | Only usable in this channelCustom commands |
{not:role} | Members with this role may not use itCustom commands |
{not:#channel} | Not usable in this channelCustom commands |
Output
Send the reply somewhere else.
| Variable | What it does |
|---|---|
{respond:#channel} | Send the response to another channelCustom commands |
{dm} | DM the response to the user |
{dm:user} | DM the response to a specific userCustom commands |
Random
Pick something at random each time.
| Variable | What it does |
|---|---|
{choose:a;b;c} | Pick one option at randomExample: {choose:pie;cake;ice cream} |
{choice} | Where the {choose} result is placed |
{chooseN:a;b} | Numbered choose for several independent picksExample: {choose2:red;blue} ... {choice2} |
{choiceN} | Where {chooseN} is placed |