diff --git a/examples/auto_moderation/main.go b/examples/auto_moderation/main.go index 66fbbcb..9b617d7 100644 --- a/examples/auto_moderation/main.go +++ b/examples/auto_moderation/main.go @@ -32,6 +32,7 @@ func main() { TriggerType: discordgo.AutoModerationEventTriggerKeyword, TriggerMetadata: &discordgo.AutoModerationTriggerMetadata{ KeywordFilter: []string{"*cat*"}, + RegexPatterns: []string{"(c|b)at"}, }, Enabled: &enabled, diff --git a/structs.go b/structs.go index f2cdc69..9955e89 100644 --- a/structs.go +++ b/structs.go @@ -1427,6 +1427,10 @@ type AutoModerationTriggerMetadata struct { // Substrings which will be searched for in content. // NOTE: should be only used with keyword trigger type. KeywordFilter []string `json:"keyword_filter,omitempty"` + // Regular expression patterns which will be matched against content (maximum of 10). + // NOTE: should be only used with keyword trigger type. + RegexPatterns []string `json:"regex_patterns,omitempty"` + // Internally pre-defined wordsets which will be searched for in content. // NOTE: should be only used with keyword preset trigger type. Presets []AutoModerationKeywordPreset `json:"presets,omitempty"`