Skip to content

Commit

Permalink
feat(Constants): update automod-related constants
Browse files Browse the repository at this point in the history
  • Loading branch information
TTtie committed Jun 12, 2024
1 parent 8e682d3 commit 123163f
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 12 deletions.
17 changes: 10 additions & 7 deletions index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -315,17 +315,17 @@ declare namespace Dysnomia {
}

interface AutoModerationTriggerMetadata {
/** valid for KEYWORD */
/** valid for KEYWORD, KEYWORD_PRESET, MEMBER_PROFILE */
allow_list: string[];
/** valid for KEYWORD */
/** valid for KEYWORD, MEMBER_PROFILE */
keyword_filter: string[];
/** valid for MENTION_SPAM */
mention_total_limit: number;
/** valid for MENTION_SPAM */
mention_raid_protection_enabled: boolean;
/** valid for KEYWORD_PRESET */
presets: AutoModerationKeywordPresetType[];
/** valid for KEYWORD */
/** valid for KEYWORD, MEMBER_PROFILE */
regex_patterns: string[];
}
// Channel
Expand Down Expand Up @@ -1980,12 +1980,14 @@ declare namespace Dysnomia {
HOME_SETTINGS_UPDATE: 191;
};
AutoModerationActionTypes: {
BLOCK_MESSAGE: 1;
SEND_ALERT_MESSAGE: 2;
TIMEOUT: 3;
BLOCK_MESSAGE: 1;
SEND_ALERT_MESSAGE: 2;
TIMEOUT: 3;
BLOCK_MEMBER_INTERACTION: 4;
};
AutoModerationEventTypes: {
MESSAGE_SEND: 1;
MESSAGE_SEND: 1;
MEMBER_UPDATE: 2;
};
AutoModerationKeywordPresetTypes: {
PROFANITY: 1;
Expand All @@ -1997,6 +1999,7 @@ declare namespace Dysnomia {
SPAM: 3;
KEYWORD_PRESET: 4;
MENTION_SPAM: 5;
MEMBER_PROFILE: 6;
};
ButtonStyles: {
PRIMARY: 1;
Expand Down
13 changes: 8 additions & 5 deletions lib/Constants.js
Original file line number Diff line number Diff line change
Expand Up @@ -156,13 +156,15 @@ module.exports.AuditLogActions = {
};

module.exports.AutoModerationActionTypes = {
BLOCK_MESSAGE: 1,
SEND_ALERT_MESSAGE: 2,
TIMEOUT: 3
BLOCK_MESSAGE: 1,
SEND_ALERT_MESSAGE: 2,
TIMEOUT: 3,
BLOCK_MEMBER_INTERACTION: 4
};

module.exports.AutoModerationEventTypes = {
MESSAGE_SEND: 1
MESSAGE_SEND: 1,
MEMBER_UPDATE: 2
};

module.exports.AutoModerationKeywordPresetTypes = {
Expand All @@ -175,7 +177,8 @@ module.exports.AutoModerationTriggerTypes = {
KEYWORD: 1,
SPAM: 3,
KEYWORD_PRESET: 4,
MENTION_SPAM: 5
MENTION_SPAM: 5,
MEMBER_PROFILE: 6
};

module.exports.ButtonStyles = {
Expand Down

0 comments on commit 123163f

Please sign in to comment.