JDA
JDA copied to clipboard
Introducing auto moderation
Pull Request Etiquette
- [x] I have checked the PRs for upcoming features/bug fixes.
- [x] I have read the contributing guidelines.
Changes
- [x] Internal code
- [x] Library interface (affecting end-user code)
- [x] Documentation
- [ ] Other: _____
Closes Issue: NaN
Description
Discord introduced auto moderation and the addition of it in the docs can be found here https://discord.com/developers/docs/change-log#auto-moderation.
Example
To create an auto mod rule you would do
AutoModerationRule rule = AutoModerationRule.MessageSend.preset("name", TriggerType.KEYWORD).setKeywordPresets(KeywordPresetType.SLURS, KeywordPresetType.PROFANITY).build();
or
AutoModerationRule rule = AutoModerationRule.MessageSend.keyword("name", TriggerType.KEYWORD).setKeyword("butts", "*cats").build();
and then
guild.createAutoModerationRule(ruke).queue();
Got the point, and will clean it up tomorrow or today
Please do not add the message content intent in this PR. It is completely out of scope.
@Chew @CheesyGamer77 Can you re review this pr please.
There's a button to request a re-review...
There's a button to request a re-review...
I press and nothing happens. Only works for Minn.
@Chew can you do another review please.
Dead PR ?
@MinnDevelopment Planning on working on this pr now. Is there any point or shall I wait
I won't have time to look into automod any time soon. But we might be interested in making a new PR from scratch in the future. Can't make any promises right now.
Thank you for your effort, but we've decided on a different design. This PR will be superseded by #2429.