Skip to content

AutoModerationRuleCreateOptions ​

typedef · Source

Options used to create an auto moderation rule. Type: Object

Properties ​

name ​

name: string

The name of the auto moderation rule

eventType ​

eventType: AutoModerationRuleEventType

The event type of the auto moderation rule

triggerType ​

triggerType: AutoModerationRuleTriggerType

The trigger type of the auto moderation rule

triggerMetadata ​

optional

triggerMetadata: AutoModerationTriggerMetadataOptions

The trigger metadata of the auto moderation rule This property is required if the following triggerTypes are used:

  • KEYWORD
  • KEYWORD_PRESET
  • MENTION_SPAM

actions ​

actions: Array<AutoModerationActionOptions>

The actions that will execute when the auto moderation rule is triggered

enabled ​

optional

enabled: boolean

Whether the auto moderation rule should be enabled

exemptRoles ​

optional

exemptRoles: Collection<Snowflake, Role> | Array<RoleResolvable>

The roles that should not be affected by the auto moderation rule

exemptChannels ​

optional

exemptChannels: Collection<Snowflake, (GuildChannel|ThreadChannel)> | Array<GuildChannelResolvable>

The channels that should not be affected by the auto moderation rule

reason ​

optional

reason: string

The reason for creating the auto moderation rule

Unofficial software. Not affiliated with or supported by Discord.