Discord Send icon

Discord Send

Sends messages, embeds and prompts to Discord

Overview

This node enables sending various types of messages and interactive prompts to Discord channels. It supports simple text messages, rich embedded messages, interactive button or select dropdown prompts that wait for user responses, and specific actions like removing messages or managing user roles. This flexibility makes it useful for automating Discord server interactions such as announcements, polls, role assignments, and message moderation.

Common scenarios include:

  • Sending announcements or updates with optional rich embeds.
  • Creating interactive workflows where users respond via buttons or dropdowns.
  • Managing user roles automatically based on workflow logic.
  • Cleaning up channels by bulk deleting recent messages.
  • Updating bot status or clearing placeholders in channels.

Properties

Name Meaning
Replace the trigger placeholder If enabled, the message sent will replace a previously set placeholder message (from a Discord Trigger node or another Discord Send node).
Send to the trigger channel If enabled, sends the message to the same channel where the workflow was triggered, without replacing any placeholder.
Send to Select the target text channel to send the message to. Requires valid credentials and bot permissions.
Type Choose the interaction type: Message (simple text), Button Prompt (interactive buttons), Select Prompt (dropdown list), Action (perform an action), or None (no message, just update/clear).
Action When Type is Action, choose the specific action: Remove messages, Add role to user, or Remove role from user.
User ID The Discord user ID to add or remove roles from (required for role management actions).
Which roles Roles to add or remove from the specified user (for role management actions).
How many? Number of last messages to remove when performing Remove messages action (max 150, only messages less than 4 weeks old).
Content Text content of the message or prompt. Cannot be empty for button or select prompts.
Embed Enable creation of rich embedded messages.
Color Color of the embed sidebar (if embed enabled).
Title Title text of the embed.
URL URL linked from the embed title.
Author name Name shown as author in the embed.
Author icon URL or base64 Image URL or base64 string for the author icon in the embed.
Author URL URL linked from the author name in the embed.
Description Description text inside the embed.
Thumbnail URL or base64 Thumbnail image URL or base64 for the embed.
Fields Custom fields inside the embed, each with a title, value, and inline display option.
Image URL or base64 Main image URL or base64 displayed in the embed.
Buttons Up to 5 interactive buttons for Button Prompt type, each with label, return value, and style (Primary, Secondary, Success, Danger).
Select Options for Select Prompt type, each with label, optional description, and return value.
Persistent For button/select prompts, if enabled the prompt stays visible after workflow finishes.
Min select Minimum number of options that must be selected in a persistent select prompt.
Max select Maximum number of options that can be selected in a persistent select prompt.
Message ID ID of the message to update instead of sending a new one (used with persistent prompts).
Footer text Footer text in the embed.
Footer icon URL or base64 Image URL or base64 for the footer icon in the embed.
Displayed date Timestamp to show in the embed.
Timeout Time in seconds the workflow waits for a response on button/select prompts before continuing or stopping. 0 means wait indefinitely.
Restrict to triggering user Only allow the user who triggered the workflow to interact with the prompt.
Restrict to mentioned roles Only allow users with specified roles to interact with the prompt.
Files Attach up to 5 images (png, jpg) to the message by URL or base64.
Mention roles Roles to mention in the message.
Placeholder Placeholder text shown while waiting for a response in button/select prompts, with animated dots indicating workflow running.
Bot customization Enable customizing the bot's activity and status.
Bot activity Text describing the bot's current activity (e.g., "Playing", "Streaming").
Bot activity type Type of bot activity displayed (Playing, Streaming, Listening, Watching).
Bot status Status of the bot (Online, Idle, Do not disturb, Invisible).

Output

The node outputs an array of JSON objects, each representing the result of sending a message or performing an action. Each output item includes:

  • value: The main returned value, e.g., user selection or confirmation.
  • channelId: The ID of the channel where the message or action occurred.
  • userId: The ID of the user interacting or affected.
  • userName: The username of the interacting user.
  • userTag: The full Discord tag of the user.
  • messageId: The ID of the sent or updated message.
  • action: The performed action type (e.g., role added, messages removed).

If the node sends interactive prompts, it waits for user input and returns the user's response in value.

Binary data is not explicitly handled by this node; attachments are referenced by URLs or base64 strings but not output as binary.

Dependencies

  • Requires a valid Discord bot API key credential with appropriate permissions.
  • The bot must be running and connected to the Discord server.
  • The bot needs permission to send messages, manage roles, and delete messages in the target channels.
  • Channels and roles lists are dynamically loaded from Discord via helper methods.
  • No external services beyond Discord API are required.

Troubleshooting

  • Common issues:

    • Missing or invalid API credentials will cause connection errors.
    • Insufficient bot permissions may lead to failures in sending messages, deleting messages, or managing roles.
    • Trying to delete more than 150 messages or messages older than 4 weeks will fail due to Discord API limits.
    • Empty content for button or select prompts will cause validation errors.
    • Specifying a non-existent channel or role will cause errors.
    • Using persistent prompts without providing a message ID to update may create duplicate messages.
  • Error messages:

    • Connection errors indicate invalid or missing API keys.
    • Permission denied errors suggest the bot lacks required Discord permissions.
    • Validation errors for missing required parameters (e.g., user ID for role actions).
    • Timeout errors occur if no user interaction happens within the specified timeout period.
  • Resolutions:

    • Verify and configure correct API credentials.
    • Ensure the bot has necessary permissions on the Discord server.
    • Follow Discord API limits for message deletion.
    • Provide all required inputs according to the chosen operation.
    • Use message IDs correctly when updating persistent prompts.

Links and References

Discussion