Discord Tools icon

Discord Tools

Discord utility tools - Message fetching, user info, and more

Overview

This node operation "Find Duplicate Messages" under the "Moderation" resource connects to a Discord server and fetches messages from a specified text channel within a guild (server). It identifies and returns messages that have duplicate content, helping moderators detect repeated or spammy messages in the channel. This is useful for maintaining chat quality and enforcing community guidelines by spotting repeated messages that may indicate spam or unwanted behavior.

Use Case Examples

  1. A moderator wants to find repeated messages in a specific channel to identify spam or repeated announcements.
  2. A community manager uses this operation to clean up duplicate messages before they clutter the chat.
  3. Automated moderation workflows can use this to flag or delete duplicate messages to keep the chat clean.

Properties

Name Meaning
Guild ID The ID of the Discord server (guild) where the channel is located.
Channel ID The ID of the text channel within the guild to search for duplicate messages.
Additional Options Optional parameters to customize the search, such as including bot messages, filtering messages before or after a specific message ID, case sensitivity, exact text matching, and audit log filters.

Output

JSON

  • id - The ID of the duplicate message.
  • content - The text content of the duplicate message.
  • author
    • id - The ID of the author who sent the duplicate message.
    • username - The username of the author who sent the duplicate message.
  • original
    • id - The ID of the original message that the duplicate matches.
    • author
      * id - The ID of the author of the original message.
      * username - The username of the author of the original message.

Dependencies

  • Discord API access via a bot token credential

Troubleshooting

  • Ensure the bot token credential is valid and has permissions to access the specified guild and channel.
  • Verify that the Guild ID and Channel ID are correct and that the channel is a text-based channel.
  • If no duplicates are found, the output will be an empty array; this means no repeated messages were detected in the fetched message batch.
  • The operation fetches up to 100 messages due to Discord API limits; duplicates outside this range will not be detected.

Links

Discussion