Formatting variables
Formatting variables let April insert Discord values into messages, embeds, image URLs, and supported editor fields.
Legacy message variables
Section titled “Legacy message variables”Welcome, leaver and custom commands can supply user and server context to single-brace variables. Other features supply their own context. Generic managed embeds use an empty formatter and do not supply welcome-style user or server values; do not rely on {user} or {guild} resolving there.
Example:
Welcome {user.mention} to {guild}. You are member {memberCount.ordinal}.Different pages expose different data. Use variables offered for the specific feature and check the actual result; a preview alone does not establish delivery. Sign in and select a server you can manage to edit its messages. April needs access and send/embed permissions in the destination channel; role hierarchy matters only for features that change roles. See hierarchy.
Common user variables
Section titled “Common user variables”| Variable | Meaning |
|---|---|
{user} | Username |
{user.mention} | Discord user mention |
{user.status.color} | Hex color for the user’s current status |
{user.discriminator} | Discord discriminator when available |
{user.avatar} | User avatar URL |
{user.avatar.rounded} | User avatar URL for image templates |
{user.fullname} | Username in this formatter |
{user.id} | Discord user ID |
{user.created} | Full user creation date |
{user.created.date} | User creation date |
{user.created.ago} | Relative user creation time |
{user.created.time} | User creation time |
{user.joined} | Full server join date |
{user.joined.date} | Server join date |
{user.joined.ago} | Relative server join time |
{user.joined.time} | Server join time |
Guild and channel variables
Section titled “Guild and channel variables”| Variable | Meaning |
|---|---|
{guild} | Server name |
{memberCount} | Approximate member count |
{memberCount.ordinal} | Member count as an ordinal value |
{guild.id} | Discord server ID |
{guild.created.ago} | Relative server creation time |
{guild.created.date} | Server creation date |
{guild.created.time} | Server creation time |
{guild.icon} | Server icon URL |
{channel} | Channel name |
{channel.id} | Discord channel ID |
{channel.mention} | Discord channel mention |
{channel.created} | Full channel creation date |
{channel.created.date} | Channel creation date |
{channel.created.time} | Channel creation time |
{channel.created.ago} | Relative channel creation time |
{channel.nsfw} | Whether the channel is marked NSFW |
{channel.topic} | Channel topic |
Level variables
Section titled “Level variables”Use these in level-up messages, rank-card designs, and level-related templates where the page offers them.
| Variable | Meaning |
|---|---|
{user.level} | User level in the server |
{user.xp} | XP in the current level |
{user.xpRatio} | Current-level progress from 0 to 1 |
{user.nextLevel} | XP required for the next level |
{user.totalXp} | Total accumulated XP |
Log variables
Section titled “Log variables”Log events can expose before/after values when Discord sends both states.
| Variable | Meaning |
|---|---|
{before.user} | Previous username |
{before.user.nickname} | Previous server nickname |
{before.user.avatar} | Previous avatar URL |
{before.user.fullname} | Previous full user value |
{after.user} | Updated username |
{after.user.nickname} | Updated server nickname |
{after.user.avatar} | Updated avatar URL |
{after.user.fullname} | Updated full user value |
{before.channel} | Previous channel name |
{before.channel.id} | Previous channel ID |
{before.channel.nsfw} | Previous NSFW state |
{before.channel.topic} | Previous channel topic |
{after.channel} | Updated channel name |
{after.channel.id} | Updated channel ID |
{after.channel.nsfw} | Updated NSFW state |
{after.channel.topic} | Updated channel topic |
Some log events also add event-specific values such as message content or changed roles. Use the variable buttons shown on that event’s configuration page.
Stream monitor variables
Section titled “Stream monitor variables”Twitch notifications can use:
| Variable | Meaning |
|---|---|
{stream.channel} | Streamer display name |
{stream.avatarUrl} | Streamer avatar URL |
{stream.url} | Twitch channel URL |
{stream.viewerCount} | Viewer count |
{stream.started.ago} | Relative stream start time |
{stream.type} | Stream type |
{stream.length} | Stream duration |
{stream.title} | Stream title |
{stream.preview} | Stream thumbnail URL |
{stream.game} | Game or category |
YouTube notifications can use {stream.channel.name}, {stream.channel}, {stream.url}, {stream.started.ago}, and {stream.title}.
Random values
Section titled “Random values”Custom commands and other legacy message templates can use random number variables:
{random.1-100}{random.1-100} returns an integer in the inclusive range. Use a lower bound below the upper bound.
Editor workspace variables
Section titled “Editor workspace variables”Editor V2 bindings use Liquid-style output syntax instead:
| Variable | Example use |
|---|---|
{{ user }} | Render the selected user into text |
{{ guild }} | Render the server name into text |
{{ channel }} | Render a channel value into text |
Editor V2 bindings are configured from the workspace inspector. Single-brace values such as {user} are not valid in Editor V2 bindings.
URL values
Section titled “URL values”Image and icon variables must resolve to valid URLs. For example, {user.avatar}, {guild.icon}, and {stream.preview} are suitable for image URL fields when the feature supports them.

Local preview: use the suggestion menu to insert a supported variable.
Use a variable
Section titled “Use a variable”- Open the appropriate feature’s message editor and select a supported variable from its picker, or type its exact spelling.
- For a welcomer, add
Welcome {user.mention} to {guild}.to the public message and save it. - Run the feature’s test where available and check the output; a test preview is not a real member event. If the value is missing, verify the feature supplies that context.
Check and troubleshoot
Section titled “Check and troubleshoot”For example, add Welcome {user.mention} to {guild}. to an enabled welcomer and use its test command, then check a real event separately when appropriate. Reopen the feature to change or remove the text, or disable its message there. If the editor is loading, wait; if saving fails, check access and input lengths and retry. If a value remains literal or unexpected, check that the feature supplies that context and that the spelling matches the picker. Check destination permissions if delivery fails. See message composition.
Before setup, see sign in and select a server. For maintainers, see the administration technical record.