AutoModerationRuleBuilder.keyword constructor

AutoModerationRuleBuilder.keyword(
  1. {required String name,
  2. required AutoModerationEventType eventType,
  3. required List<AutoModerationActionBuilder> actions,
  4. bool? isEnabled,
  5. List<Snowflake>? exemptRoleIds,
  6. List<Snowflake>? exemptChannelIds,
  7. List<String>? keywordFilter,
  8. List<String>? regexPatterns,
  9. List<String>? allowList}
)

Implementation

AutoModerationRuleBuilder.keyword({
  required this.name,
  required this.eventType,
  required this.actions,
  this.isEnabled,
  this.exemptRoleIds,
  this.exemptChannelIds,
  List<String>? keywordFilter,
  List<String>? regexPatterns,
  List<String>? allowList,
})  : triggerType = TriggerType.keyword,
      metadata = TriggerMetadataBuilder(
        keywordFilter: keywordFilter,
        regexPatterns: regexPatterns,
        allowList: allowList,
      );