automodRule := modify_automod_rule(Args{server_id: trigger.server_id, rule_id: "..."})
send_text_message(Args{
channel_id: trigger.channel_id,
message_content: "Rule ID: " + automodRule.rule_id,
})
Modify AutoMod Rule
Modify an existing auto moderation rule.
Inputs
Server the rule belongs to.
ID of the rule to modify.
New name for the rule.
New event context for the rule.
New trigger type.
Comma-separated keywords to match against.
Comma-separated regex patterns to match against.
Pre-defined wordsets to use.
Comma-separated words that should not trigger the rule.
Max unique role and user mentions allowed per message.
Whether the rule is enabled.
Comma-separated role IDs exempt from the rule.
Comma-separated channel IDs exempt from the rule.
Action to take when the rule is triggered.
Channel for alert messages (used with Send Alert Message).
Timeout duration in seconds (used with Timeout).
Custom message shown when a message is blocked (used with Block Message).
Outputs
ID of the modified rule.
ID of the server.
Name of the rule.
User who created the rule.
Whether the rule is enabled.
Event type.
Trigger type.
Use this block in our visual flow editor. Bots are hosted 24/7 for free on inventor.bot.
Advanced Documentation
This documentation can be useful when using code mode. View as Markdown
modify_automod_ruleInputs
| Field | InventScript name | Value |
|---|---|---|
| Server ID | server_id | |
| Rule ID | rule_id | |
| Name | name | |
| Event Type | event_type | "Message Send", "Member Update" |
| Trigger Type | trigger_type | "Keyword", "Spam", "Keyword Preset", "Mention Spam", "Member Profile" |
| Keyword Filter | keyword_filter | |
| Regex Patterns | regex_patterns | |
| Presets | presets | "Profanity", "Sexual Content", "Slurs" |
| Allow List | allow_list | |
| Mention Total Limit | mention_total_limit | |
| Enabled | enabled | "true", "false" |
| Exempt Roles | exempt_roles | |
| Exempt Channels | exempt_channels | |
| Action Type | action_type | "Block Message", "Send Alert Message", "Timeout" |
| Action Channel ID | action_channel_id | |
| Action Duration (Seconds) | action_duration_seconds | |
| Action Custom Message | action_custom_message |
Outputs
| Field | InventScript name | Value |
|---|---|---|
| Rule ID | rule_id | |
| Server ID | server_id | |
| Name | name | |
| Creator ID | creator_id | |
| Enabled | enabled | |
| Event Type | event_type | |
| Trigger Type | trigger_type |