Mod Logs
Last updated Sep 27, 2026Open in dashboard

Mod Logs - Variables

Every log type is posted from its own message template, so you can change what each entry says and how it looks. To edit one:

  1. Open Mod Logs and edit a log channel (or click Add Channel).
  2. On the Log Types tab, click the pencil icon next to the log type.
  3. Edit the template in the dialog that opens. The change applies to every channel that logs this type.

The Templates page lists them too. In a template, write a variable in braces, for example {user.mention}, and add filters with a pipe, for example {reason | default(No reason)}.

TemplateSlugVariable groups
Mod Log - Bot Alert@modlog.bot.alertServer, Alert, Channel, Item, Timestamp
Mod Log - Automation Rule Fired@modlog.bot.automationsServer, Rule, Trigger, Conditions, Actions, Match, Timestamp
Mod Log - Bot Command Used@modlog.bot.commandServer, User, Timestamp, Channel, Command
Mod Log - DM Failed@modlog.bot.dm_failedServer, User, Timestamp, DM Info
Mod Log - Bot Added@modlog.guild.bot_addServer, Moderator, Bot, Timestamp
Mod Log - Channel Created@modlog.guild.channel_createServer, Channel, Moderator, Timestamp
Mod Log - Channel Deleted@modlog.guild.channel_deleteServer, Channel, Moderator, Timestamp
Mod Log - Channel Updated@modlog.guild.channel_updateServer, Channel (Mod Log - Channel Updated), Moderator, Timestamp
Mod Log - Emoji Added@modlog.guild.emoji_createServer, Emoji, Moderator, Timestamp
Mod Log - Emoji Removed@modlog.guild.emoji_deleteServer, Emoji, Moderator, Timestamp
Mod Log - Emoji Updated@modlog.guild.emoji_updateServer, Emoji (Mod Log - Emoji Updated), Moderator, Timestamp
Mod Log - Invite Created@modlog.guild.invite_createServer, Moderator, Invite, Timestamp
Mod Log - Invite Deleted@modlog.guild.invite_deleteServer, Moderator, Invite (Mod Log - Invite Deleted), Timestamp
Mod Log - Members Pruned@modlog.guild.pruneServer, Moderator, Prune, Timestamp
Mod Log - Role Created@modlog.guild.role_createServer, Role, Moderator, Timestamp
Mod Log - Role Deleted@modlog.guild.role_deleteServer, Role, Moderator, Timestamp
Mod Log - Role Updated@modlog.guild.role_updateServer, Role (Mod Log - Role Updated), Moderator, Timestamp
Mod Log - Sticker Added@modlog.guild.sticker_createServer, Sticker, Moderator, Timestamp
Mod Log - Sticker Removed@modlog.guild.sticker_deleteServer, Sticker, Moderator, Timestamp
Mod Log - Sticker Updated@modlog.guild.sticker_updateServer, Sticker (Mod Log - Sticker Updated), Moderator, Timestamp
Mod Log - Thread Created@modlog.guild.thread_createServer, Thread, Moderator, Timestamp
Mod Log - Thread Deleted@modlog.guild.thread_deleteServer, Thread, Moderator, Timestamp
Mod Log - Thread Updated@modlog.guild.thread_updateServer, Thread (Mod Log - Thread Updated), Moderator, Timestamp
Mod Log - Server Updated@modlog.guild.updateServer, Moderator, Changes, Timestamp
Mod Log - Webhook Created@modlog.guild.webhook_createServer, Webhook, Moderator, Timestamp
Mod Log - Webhook Deleted@modlog.guild.webhook_deleteServer, Webhook (Mod Log - Webhook Deleted), Moderator, Timestamp
Mod Log - Server Avatar Changed@modlog.member.avatarServer, User, Timestamp, Avatar
Mod Log - Member Joined@modlog.member.joinServer, User, Timestamp, Join Info, Invite (Mod Log - Member Joined), Inviter
Mod Log - Member Joined with Prior Cases@modlog.member.joined_with_casesServer, User, Timestamp, Case Info
Mod Log - Member Left@modlog.member.leaveServer, User, Timestamp, Leave Info
Mod Log - Nickname Changed@modlog.member.nick_changeServer, User, Timestamp, Nickname
Mod Log - Member Data Restored@modlog.member.restoreServer, User, Timestamp, Restore Info
Mod Log - Role Added to Member@modlog.member.role_addServer, User, Timestamp, Role, Moderator
Mod Log - Member Roles Changed@modlog.member.role_changesServer, User, Timestamp, Role Changes, Moderator
Mod Log - Role Removed from Member@modlog.member.role_removeServer, User, Timestamp, Role, Moderator
Mod Log - Username Changed@modlog.member.username_changeServer, User, Timestamp, Username
Mod Log - Bulk Message Delete@modlog.message.bulk_deleteServer, Moderator, Channel, Action, Timestamp
Mod Log - Message Deleted@modlog.message.deleteServer, User, Timestamp, Channel, Message
Mod Log - Message Auto-Deleted@modlog.message.delete_autoServer, User, Timestamp, Channel, Message
Mod Log - Message Deleted (No Cache)@modlog.message.delete_bareServer, User, Moderator, Channel, Message, Timestamp
Mod Log - Message Edited@modlog.message.editServer, User, Timestamp, Channel, Message (Mod Log - Message Edited)
Mod Log - Message Pinned@modlog.message.pinServer, Moderator, Channel, Message (Mod Log - Message Pinned), Timestamp
Mod Log - Message Unpinned@modlog.message.unpinServer, Moderator, Channel, Message (Mod Log - Message Unpinned), Timestamp
Mod Log - Anti-Raid Level Auto-Changed@modlog.mod.antiraid_autoServer, Action (Mod Log - Anti-Raid Level Auto-Changed), Timestamp
Mod Log - Anti-Raid Level Set by Staff@modlog.mod.antiraid_userServer, Moderator, Action (Mod Log - Anti-Raid Level Set by Staff), Timestamp
Mod Log - AutoMod Action@modlog.mod.automodServer, User, Moderator, Case, Timestamp
Mod Log - Ban@modlog.mod.banServer, User, Moderator, Case, Timestamp
Mod Log - Case Created@modlog.mod.case_createServer, User, Moderator, Case, Timestamp
Mod Log - Case Deleted@modlog.mod.case_deleteServer, User, Moderator, Case, Timestamp
Mod Log - Case Updated@modlog.mod.case_updateServer, User, Moderator, Case (Mod Log - Case Updated), Timestamp
Mod Log - Message Censored@modlog.mod.censorServer, User, Timestamp, Channel, Message
Mod Log - Channel Clean@modlog.mod.cleanServer, Moderator, Channel, Action (Mod Log - Channel Clean), Timestamp
Mod Log - Force Ban@modlog.mod.forcebanServer, User, Moderator, Case, Timestamp
Mod Log - Kick@modlog.mod.kickServer, User, Moderator, Case, Timestamp
Mod Log - Mass Ban@modlog.mod.massbanServer, Moderator, Action (Mod Log - Mass Ban), Timestamp
Mod Log - Mass Mute@modlog.mod.massmuteServer, Moderator, Action (Mod Log - Mass Mute), Timestamp
Mod Log - Mass Unban@modlog.mod.massunbanServer, Moderator, Action (Mod Log - Mass Unban), Timestamp
Mod Log - Message Spam@modlog.mod.message_spamServer, User, Moderator, Case (Mod Log - Message Spam), Timestamp
Mod Log - Mute@modlog.mod.muteServer, User, Moderator, Case, Timestamp
Mod Log - Mute Expired@modlog.mod.mute_expiredServer, User, Timestamp, Case (Mod Log - Mute Expired, Mod Log - Mute on Rejoin)
Mod Log - Mute on Rejoin@modlog.mod.mute_rejoinServer, User, Timestamp, Case (Mod Log - Mute Expired, Mod Log - Mute on Rejoin)
Mod Log - Note@modlog.mod.noteServer, User, Moderator, Case, Timestamp
Mod Log - Spam Detected@modlog.mod.other_spamServer, User, Moderator, Case (Mod Log - Spam Detected), Timestamp
Mod Log - Soft Ban@modlog.mod.softbanServer, User, Moderator, Case, Timestamp
Mod Log - Timed Ban@modlog.mod.timed_banServer, User, Moderator, Case, Timestamp
Mod Log - Timed Mute@modlog.mod.timed_muteServer, User, Moderator, Case, Timestamp
Mod Log - Temp Ban Removed@modlog.mod.timed_unbanServer, User, Moderator, Case, Timestamp
Mod Log - Timed Unmute@modlog.mod.timed_unmuteServer, User, Moderator, Case, Timestamp
Mod Log - Unban@modlog.mod.unbanServer, User, Moderator, Case, Timestamp
Mod Log - Unmute@modlog.mod.unmuteServer, User, Moderator, Case, Timestamp
Mod Log - Warning@modlog.mod.warnServer, User, Moderator, Case, Timestamp
Mod Log - Force Voice Disconnect@modlog.voice.force_disconnectServer, User, Timestamp, Channel, Moderator
Mod Log - Force Voice Move@modlog.voice.force_moveServer, User, Timestamp, Voice, Moderator
Mod Log - Voice Channel Join@modlog.voice.joinServer, User, Timestamp, Channel
Mod Log - Voice Channel Leave@modlog.voice.leaveServer, User, Timestamp, Channel
Mod Log - Voice Channel Move@modlog.voice.moveServer, User, Timestamp, Voice
Mod Log - Stage Instance Created@modlog.voice.stage_createServer, Stage, Moderator, Timestamp
Mod Log - Stage Instance Ended@modlog.voice.stage_deleteServer, Stage, Moderator, Timestamp
Mod Log - Stage Instance Updated@modlog.voice.stage_updateServer, Stage (Mod Log - Stage Instance Updated), Moderator, Timestamp

Alert

VariableDescription
{alert.message}Alert message content
{alert.level}Alert level (info, warning, error)
{alert.source}Module or subsystem that raised the alert (e.g. sticky, automations)
{alert.detail}Additional detail text (empty if not provided)

Channel

VariableDescription
{channel.mention}Channel mention (#name)
{channel.name}Channel name
{channel.id}Channel ID
{channel.type}Channel type (text, voice, thread, forum, stage, etc.)

Item

VariableDescription
{alert.item.type}Type label for the affected item (e.g. Sticky, Template, Rule)
{alert.item.id}ID of the affected item (empty if not applicable)

Timestamp

VariableDescription
{timestamp}Unix timestamp integer - use as <t:{timestamp}:f>, <t:{timestamp}:R>, etc.

Rule

VariableDescription
{rule.id}Rule ID
{rule.name}Rule name
{rule.description}Rule description (empty if not set)

Trigger

VariableDescription
{trigger.type}Raw trigger type key (e.g. on_member_join)
{trigger.label}Human-readable trigger description
{trigger.user.id}ID of the user who triggered the rule (empty if none)
{trigger.user.mention}Mention of the user who triggered the rule
{trigger.user.name}Username of the triggering user
{trigger.user.display_name}Display name of the triggering user
{trigger.channel.id}Channel ID where the trigger fired (empty if none)
{trigger.channel.mention}Mention of the channel where the trigger fired
{trigger.channel.name}Name of the channel where the trigger fired
{trigger.message.id}ID of the triggering message (empty if not a message trigger)
{trigger.message.content}Content of the triggering message, up to 500 characters
{trigger.message.jump_url}Jump link to the triggering message

Conditions

VariableDescription
{conditions.result}Condition check result (always 'passed' at fire time)
{conditions.total}Total number of conditions configured on the rule

Actions

VariableDescription
{actions.status}Overall action result: success, partial, or failed
{actions.run}Number of actions that succeeded
{actions.total}Total number of actions configured on the rule
{actions.summary}The rule's actions, comma separated
{actions.failed}The actions that failed, each with why (empty when all succeeded)
{actions.failed_count}How many actions failed (empty when none did)

Match

VariableDescription
{match.summary}What the conditions (or the spam threshold) matched, on one line (empty when nothing was recorded)

User

VariableDescription
{user.mention}User mention (<@id>)
{user.name}Username
{user.display_name}Display name (nickname or username)
{user.tag}username#discriminator (or just username)
{user.id}User ID
{user.avatar}User avatar URL
{user.roles}Comma-separated role mentions (empty if @everyone only). Supports {join:} list syntax.
{user.top_role}Highest role mention (empty if no extra roles)
{user.top_role_name}Highest role name (empty if no extra roles)

Command

VariableDescription
{command.name}Command name (without /)
{command.args}Command arguments summary

DM Info

VariableDescription
{dm.context}Context for what DM was attempted (e.g. ban notification)

Moderator

VariableDescription
{mod.mention}Moderator mention
{mod.name}Moderator username
{mod.display_name}Moderator display name
{mod.tag}Moderator username#discriminator or username
{mod.id}Moderator ID
{mod.roles}Moderator comma-separated role mentions. Supports {join:} list syntax.
{mod.top_role}Moderator highest role mention
{mod.top_role_name}Moderator highest role name

Bot

VariableDescription
{bot.mention}Bot mention
{bot.name}Bot username
{bot.display_name}Bot display name
{bot.id}Bot user ID
{bot.tag}Bot username#discriminator or username

Channel (Mod Log - Channel Updated)

VariableDescription
{channel.mention}Channel mention (#name)
{channel.name}Channel name
{channel.id}Channel ID
{channel.type}Channel type (text, voice, thread, forum, stage, etc.)
{before.name}Previous channel name
{after.name}Updated channel name
{before.topic}Previous channel topic
{after.topic}Updated channel topic

Emoji

VariableDescription
{entity.name}Entity name (emoji, sticker, etc.)
{entity.id}Entity ID

Emoji (Mod Log - Emoji Updated)

VariableDescription
{entity.name}Entity name (emoji, sticker, etc.)
{entity.id}Entity ID
{before.name}Previous emoji name
{after.name}Updated emoji name

Invite

VariableDescription
{invite.code}Invite code
{invite.channel}Invite channel mention
{invite.channel_name}Invite channel name
{invite.max_uses}Max uses (∞ if unlimited)
{invite.max_age}Expiry duration (never if permanent)
{invite.is_temporary}Whether invite grants temporary membership (yes/no)

Invite (Mod Log - Invite Deleted)

VariableDescription
{invite.code}Invite code
{invite.channel}Invite channel mention
{invite.channel_name}Invite channel name

Prune

VariableDescription
{count}Number of members pruned
{days}Inactivity threshold in days

Role

VariableDescription
{role.mention}Role mention (<@&id>)
{role.name}Role name
{role.id}Role ID
{role.color}Role color as hex string (e.g. #5865F2)
{role.position}Role position index (higher = more powerful)

Role (Mod Log - Role Updated)

VariableDescription
{role.mention}Role mention (<@&id>)
{role.name}Role name
{role.id}Role ID
{role.color}Role color as hex string (e.g. #5865F2)
{role.position}Role position index (higher = more powerful)
{before.name}Previous role name
{after.name}Updated role name
{before.color}Previous role color
{after.color}Updated role color

Sticker

VariableDescription
{entity.name}Entity name (emoji, sticker, etc.)
{entity.id}Entity ID

Sticker (Mod Log - Sticker Updated)

VariableDescription
{entity.name}Entity name (emoji, sticker, etc.)
{entity.id}Entity ID
{before.name}Previous sticker name
{after.name}Updated sticker name

Thread

VariableDescription
{channel.mention}Channel mention (#name)
{channel.name}Channel name
{channel.id}Channel ID
{channel.type}Channel type (text, voice, thread, forum, stage, etc.)
{thread.parent}Parent channel mention

Thread (Mod Log - Thread Updated)

VariableDescription
{channel.mention}Channel mention (#name)
{channel.name}Channel name
{channel.id}Channel ID
{channel.type}Channel type (text, voice, thread, forum, stage, etc.)
{before.name}Previous thread name
{after.name}Updated thread name
{before.archived}Was thread archived before? (yes = archived, empty = not)
{after.archived}Is thread archived now? (yes = archived, empty = not)
{before.locked}Was thread locked before? (yes = locked, empty = not)
{after.locked}Is thread locked now? (yes = locked, empty = not)
{before.slowmode}Slowmode delay in seconds before the update
{after.slowmode}Slowmode delay in seconds after the update
{before.auto_archive}Auto-archive duration in minutes before the update (60/1440/4320/10080)
{after.auto_archive}Auto-archive duration in minutes after the update (60/1440/4320/10080)
{before.invitable}Could non-moderators invite others before? (yes = invitable, empty = not)
{after.invitable}Can non-moderators invite others now? (yes = invitable, empty = not)

Changes

VariableDescription
{changed_fields}Comma-separated list of changed fields
{before.name}Previous server name
{after.name}Updated server name
{before.description}Previous server description
{after.description}Updated server description
{before.verification_level}Previous verification level
{after.verification_level}Updated verification level

Webhook

VariableDescription
{webhook.name}Webhook name
{webhook.id}Webhook ID
{channel.mention}Channel the webhook is in
{channel.name}Channel name

Webhook (Mod Log - Webhook Deleted)

VariableDescription
{webhook.name}Webhook name
{webhook.id}Webhook ID
{channel.mention}Channel the webhook was in
{channel.name}Channel name

Avatar

VariableDescription
{before.avatar}Previous guild avatar URL (empty if none)
{after.avatar}New guild avatar URL (empty if removed)

Join Info

VariableDescription
{account.age}Account age at join time (e.g. 2d 5h)
{account.created_at}Account creation Unix timestamp - use with Discord timestamp syntax, e.g. <t:{account.created_at}:R>
{join.position}Member join position (e.g. 1,234th member)

Invite (Mod Log - Member Joined)

VariableDescription
{invite.code}Invite code used to join (empty if unknown)
{invite.uses}Total uses of the invite after this join
{invite.max_uses}Max uses allowed (∞ if unlimited)
{invite.channel}Channel the invite points to (mention)
{invite.channel_name}Channel name the invite points to
{invite.is_vanity}Whether the invite is a vanity URL (yes/no)

Inviter

VariableDescription
{inviter.mention}Mention of the user who created the invite
{inviter.name}Username of the invite creator
{inviter.display_name}Display name of the invite creator
{inviter.id}User ID of the invite creator

Case Info

VariableDescription
{case_count}Number of prior moderation cases

Leave Info

VariableDescription
{joined.at}When member joined (Discord timestamp)

Nickname

VariableDescription
{before.nick}Previous nickname (empty if none)
{after.nick}New nickname (empty if cleared)

Restore Info

VariableDescription
{restored.roles}Roles restored on rejoin

Role Changes

VariableDescription
{added_roles}Comma-separated added role mentions (empty if none). Supports {join:} list syntax.
{removed_roles}Comma-separated removed role mentions (empty if none). Supports {join:} list syntax.

Username

VariableDescription
{before.name}Previous username
{after.name}New username
{before.global_name}Previous display name
{after.global_name}New display name

Action

VariableDescription
{count}Number of messages deleted
{bulk_messages_file}File attachment reference for the deleted messages log
{bulk_messages_link}Link to the web archive of the deleted messages

Message

VariableDescription
{message.id}Message ID
{message.content}Message content (empty if not cached)
{message.url}Jump link to the message
{count}Number of items (messages, users, etc.)

Message (Mod Log - Message Edited)

VariableDescription
{message.id}Message ID
{message.url}Jump link to message
{before.content}Previous message content
{after.content}Updated message content

Message (Mod Log - Message Pinned)

VariableDescription
{message.id}Pinned message ID
{user.mention}Original message author mention
{user.display_name}Original message author display name
{user.id}Original message author ID

Message (Mod Log - Message Unpinned)

VariableDescription
{message.id}Unpinned message ID
{user.mention}Original message author mention
{user.display_name}Original message author display name
{user.id}Original message author ID

Action (Mod Log - Anti-Raid Level Auto-Changed)

VariableDescription
{before.level}Previous anti-raid level
{after.level}New anti-raid level
{reason}Reason for level change

Action (Mod Log - Anti-Raid Level Set by Staff)

VariableDescription
{antiraid.level}New anti-raid level
{before.level}Previous anti-raid level
{reason}Reason for level change

Case

VariableDescription
{case.number}Moderation case number
{case_type}Case type (ban, kick, mute, etc.)
{reason}Action reason
{duration}Action duration (e.g. 1h30m)

Case (Mod Log - Case Updated)

VariableDescription
{case.number}Moderation case number
{case_type}Case type (ban, kick, mute, etc.)
{reason}Action reason
{duration}Action duration (e.g. 1h30m)
{before.reason}Previous case reason
{after.reason}Updated case reason

Action (Mod Log - Channel Clean)

VariableDescription
{count}Number of messages deleted
{reason}Text filter the clean used, if any
{bulk_messages_file}File attachment reference for the deleted messages log
{bulk_messages_link}Link to the web archive of the deleted messages

Action (Mod Log - Mass Ban)

VariableDescription
{count}Number of users banned
{reason}Ban reason

Action (Mod Log - Mass Mute)

VariableDescription
{count}Number of users muted
{reason}Mute reason

Action (Mod Log - Mass Unban)

VariableDescription
{count}Number of users unbanned
{reason}Unban reason

Case (Mod Log - Message Spam)

VariableDescription
{case.number}Moderation case number
{case_type}Case type (ban, kick, mute, etc.)
{reason}Action reason
{duration}Action duration (e.g. 1h30m)
{count}Number of messages deleted
{bulk_messages_link}Link to the web archive of the spam messages

Case (Mod Log - Mute Expired, Mod Log - Mute on Rejoin)

VariableDescription
{case.number}Original mute case number

Case (Mod Log - Spam Detected)

VariableDescription
{case.number}Moderation case number
{case_type}Case type (ban, kick, mute, etc.)
{reason}Action reason
{duration}Action duration (e.g. 1h30m)
{count}Messages deleted; for a join raid or thread spam, the members who joined or threads created in the window
{bulk_messages_link}Link to the web archive of the spam messages

Voice

VariableDescription
{before.channel}Previous voice channel mention
{after.channel}New voice channel mention

Stage

VariableDescription
{channel.mention}Stage channel mention
{stage.topic}Stage topic

Stage (Mod Log - Stage Instance Updated)

VariableDescription
{channel.mention}Stage channel mention
{before.topic}Previous stage topic
{after.topic}New stage topic

The shared groups (Server) are listed with the common template variables. Every template also takes the Utility variables.

The shared variables and the filters are listed in the Message Builder guide.