Reference · Tools
Discord
Manage messages, channels, and members on Discord servers, or send messages via webhooks. Supports file attachments via binary data.
The Discord node lets you send messages, manage channels, and control server members through the Discord REST API. You can build workflows that post alerts with file attachments to a channel, assign roles when a user completes an action, or mirror content from another service into Discord. Three credential types are supported: Bot Token, OAuth2, and Webhook.
- Node type
- Action (binary)
- Parameters
- 40
- Outputs
- Output, Error
- Credentials
- Discord Bot API , Discord OAuth2 API , Discord Webhook
Discord
Manage messages, channels, and members on Discord
Overview
The Discord tool interacts with the Discord REST API to manage server resources. It supports three connection types: Bot Token (full API access), OAuth2 (same as Bot Token with easier installation), and Webhook (send messages to a specific channel). Resources include Message (send, get, get many, delete, react), Channel (create, get, get many, update, delete), Member (get many, role add, role remove), and Webhook (send). Message send supports file attachments from binary data, and embeds can be defined via fields or raw JSON.
Category: Communication
Tool Name: discord
Version: 1
Appearance: Icon: si-discord | Color: #5865F2
Node Type
Action (Binary) — handles file/binary data operations
Input / Output
| Direction | Port(s) |
|---|---|
| Input | Input |
| Output | Output, Error |
Credentials
This tool requires Discord Bot API, Discord OAuth2 API, Discord Webhook credentials. See the Credentials Guide for setup instructions.
Configure the one that matches the Connection Type you select on the node.
Resources
| Resource | Value |
|---|---|
| Channel | channel |
| Message | message |
| Member | member |
The resource selector is hidden when Connection Type is webhook — a webhook can only send messages.
Operations
| Resource | Operation | Value | Description |
|---|---|---|---|
| Message | Delete | deleteMessage | Delete a message in a channel |
| Message | Get | get | Get a message in a channel |
| Message | Get Many | getAll | Retrieve the latest messages in a channel |
| Message | React with Emoji | react | React to a message with an emoji |
| Message | Send | send | Send a message to a channel, thread, or member |
| Channel | Create | create | Create a new channel |
| Channel | Delete | deleteChannel | Delete a channel |
| Channel | Get | get | Get a channel |
| Channel | Get Many | getAll | Retrieve the channels of a server |
| Channel | Update | update | Update a channel |
| Member | Get Many | getAll | Retrieve the members of a server |
| Member | Role Add | roleAdd | Add a role to a member |
| Member | Role Remove | roleRemove | Remove a role from a member |
| Webhook | Send a Message | sendLegacy | Send a message to a channel using the webhook |
Parameters
The Message, Channel and Member operations are available with the botToken and oAuth2 connection types. The webhook connection type offers only Send a Message.
Message: Send
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
| Send To | options | No | channel | Send message to a channel or DM to a user. |
Options: channel, user | ||||
| Channel ID | string | Yes | — | The ID of the channel to send the message to. Supports expressions. (shown when Send To is channel) |
| User ID | string | Yes | — | The ID of the user to send a direct message to. Supports expressions. (shown when Send To is user) |
Message (content) | string | No | — | The content of the message (up to 2000 characters). Supports expressions. |
Options (sendOptions) | collection | No | {} | Extra send settings. |
| — Flags | multiOptions | No | [] | Message flags. |
Options: SUPPRESS_EMBEDS, SUPPRESS_NOTIFICATIONS | ||||
| — Message to Reply to | string | No | — | Fill this to make your message a reply. Add the message ID. |
| — Text-to-Speech (TTS) | boolean | No | false | Whether to have a bot reading the message directly in the channel. |
| Embeds | fixedCollection | No | {} | Rich embeds to attach to the message. Add one entry per embed. |
| — Input Method | options | No | fields | Whether to build the embed from individual fields or supply it as raw JSON. |
Options: fields (Enter Fields), json (Raw JSON) | ||||
| — Value | json | No | ={} | The complete embed object as JSON. (shown when Input Method is json) |
| — Description | string | No | — | Embed description text. (shown when Input Method is fields) |
| — Author | string | No | — | Embed author name. (shown when Input Method is fields) |
| — Color | string | No | — | Color code (hex, e.g. #FF0000). (shown when Input Method is fields) |
| — Timestamp | string | No | — | ISO8601 timestamp. (shown when Input Method is fields) |
| — Title | string | No | — | Embed title. (shown when Input Method is fields) |
| — URL | string | No | — | URL the embed title links to. (shown when Input Method is fields) |
| — Image URL | string | No | — | Large image shown in the embed. (shown when Input Method is fields) |
| — Thumbnail URL | string | No | — | Small image shown beside the embed. (shown when Input Method is fields) |
| — Video URL | string | No | — | Video shown in the embed. (shown when Input Method is fields) |
| Files | fixedCollection | No | {} | Files to attach to the message. Add one entry per file. |
| — Input Data Field Name | string | No | data | The name of the binary property containing the file data to send. |
Message: Get
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
| Channel ID | string | Yes | — | The ID of the channel the message is in. Supports expressions. |
| Message ID | string | Yes | — | The ID of the message. Supports expressions. |
Options (messageGetOptions) | collection | No | {} | Response shaping options. |
| — Simplify | boolean | No | true | Whether to return a simplified version of the response. |
Message: Get Many
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
| Channel ID | string | Yes | — | The ID of the channel to read messages from. Supports expressions. |
| Return All | boolean | No | false | Whether to return all results or limit the number. |
| Limit | number | No | 50 | Max number of results to return. (shown when Return All is false) |
Options (messageGetOptions) | collection | No | {} | Response shaping options. |
| — Simplify | boolean | No | true | Whether to return a simplified version of the response. |
Message: Delete
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
| Channel ID | string | Yes | — | The ID of the channel the message is in. Supports expressions. |
| Message ID | string | Yes | — | The ID of the message to delete. Supports expressions. |
Message: React with Emoji
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
| Channel ID | string | Yes | — | The ID of the channel the message is in. Supports expressions. |
| Message ID | string | Yes | — | The ID of the message to react to. Supports expressions. |
| Emoji | string | Yes | — | The emoji to react with (Unicode character or custom emoji format). |
Channel: Create
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
Name (channelName) | string | Yes | — | The name of the channel to create. Supports expressions. |
| Type | options | Yes | 0 | The type of channel to create. |
Options: 0 (Guild Text), 2 (Guild Voice), 4 (Guild Category) | ||||
Options (channelCreateOptions) | collection | No | {} | Extra channel settings applied at creation. |
| — Age-Restricted (NSFW) | boolean | No | false | Whether the channel is marked age-restricted. |
| — Bitrate | number | No | 8000 | Bitrate for voice channels (8000-96000). |
| — Parent Category ID | string | No | — | Parent category channel ID. |
| — Position | number | No | 1 | Sort position of the channel in the server list. |
| — Rate Limit Per User | number | No | 0 | Slowmode seconds. |
| — Topic | string | No | — | Channel description (0-1024 characters). |
| — User Limit | number | No | 0 | Voice channel user limit (0 = no limit). |
Channel: Get
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
| Channel ID | string | Yes | — | The ID of the channel. Supports expressions. |
Channel: Get Many
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
| Return All | boolean | No | false | Whether to return all channels or limit. |
| Limit | number | No | 50 | Max number of results to return. (shown when Return All is false) |
Options (channelGetAllOptions) | collection | No | {} | Filtering options for the channel list. |
| — Filter by Type | multiOptions | No | [] | Return only channels of these types. |
Options: 0 (Guild Text), 2 (Guild Voice), 4 (Guild Category) |
Channel: Update
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
| Channel ID | string | Yes | — | The ID of the channel to update. Supports expressions. |
Name (channelUpdateName) | string | No | — | New channel name (leave empty to keep current). |
Options (channelUpdateOptions) | collection | No | {} | Channel settings to change. |
| — Age-Restricted (NSFW) | boolean | No | false | Whether the channel is marked age-restricted. |
| — Bitrate | number | No | 8000 | Bitrate for voice channels (8000-96000). |
| — Parent Category ID | string | No | — | Parent category channel ID. |
| — Position | number | No | 1 | Sort position of the channel in the server list. |
| — Rate Limit Per User | number | No | 0 | Slowmode seconds. |
| — Topic | string | No | — | Channel description (0-1024 characters). |
| — User Limit | number | No | 0 | Voice channel user limit (0 = no limit). |
Channel: Delete
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
| Channel ID | string | Yes | — | The ID of the channel to delete. Supports expressions. |
Member: Get Many
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
| Return All | boolean | No | false | Whether to return all members or limit the number. |
| Limit | number | No | 50 | Max number of results to return. (shown when Return All is false) |
| After | string | No | — | The ID of the user after which to return the members. |
Options (memberGetAllOptions) | collection | No | {} | Response shaping options. |
| — Simplify | boolean | No | true | Whether to return a simplified version (user, roles, permissions only). |
Member: Role Add
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
| User ID | string | Yes | — | The ID of the member to change. Supports expressions. |
| Role IDs | string | Yes | — | Comma-separated list of role IDs to add or remove. |
Member: Role Remove
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
| User ID | string | Yes | — | The ID of the member to change. Supports expressions. |
| Role IDs | string | Yes | — | Comma-separated list of role IDs to add or remove. |
Webhook: Send a Message
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
Message (content) | string | No | — | The content of the message (up to 2000 characters). Supports expressions. |
Options (webhookOptions) | collection | No | {} | Extra webhook send settings. |
| — Avatar URL | string | No | — | Override webhook avatar. |
| — Flags | multiOptions | No | [] | Message flags. |
Options: SUPPRESS_EMBEDS, SUPPRESS_NOTIFICATIONS | ||||
| — Text-to-Speech (TTS) | boolean | No | false | Whether to have a bot reading the message directly in the channel. |
| — Username | string | No | — | Override webhook display name. |
| — Wait | boolean | No | false | Whether to wait for the message to be created before returning its response. |
| Embeds | fixedCollection | No | {} | Rich embeds to attach to the message. Add one entry per embed. |
| — Input Method | options | No | fields | Whether to build the embed from individual fields or supply it as raw JSON. |
Options: fields (Enter Fields), json (Raw JSON) | ||||
| — Value | json | No | ={} | The complete embed object as JSON. (shown when Input Method is json) |
| — Description | string | No | — | Embed description text. (shown when Input Method is fields) |
| — Author | string | No | — | Embed author name. (shown when Input Method is fields) |
| — Color | string | No | — | Color code (hex, e.g. #FF0000). (shown when Input Method is fields) |
| — Timestamp | string | No | — | ISO8601 timestamp. (shown when Input Method is fields) |
| — Title | string | No | — | Embed title. (shown when Input Method is fields) |
| — URL | string | No | — | URL the embed title links to. (shown when Input Method is fields) |
| — Image URL | string | No | — | Large image shown in the embed. (shown when Input Method is fields) |
| — Thumbnail URL | string | No | — | Small image shown beside the embed. (shown when Input Method is fields) |
| — Video URL | string | No | — | Video shown in the embed. (shown when Input Method is fields) |
| Files | fixedCollection | No | {} | Files to attach to the message. Add one entry per file. |
| — Input Data Field Name | string | No | data | Binary property name containing the file to send. |
All Operations
| Parameter | Type | Required | Default | Description |
|---|---|---|---|---|
| Connection Type | options | No | botToken | How the node authenticates with Discord. |
Options: botToken (manage messages, channels, and members on a server), oAuth2 (same features as Bot Token with easier bot installation), webhook (send messages to a specific channel) | ||||
| Server (Guild) ID | string | Yes | — | The ID of the Discord server (guild). Find it by right-clicking the server icon with Developer Mode enabled. (hidden when Connection Type is webhook) |
| Max Concurrency | number | No | 5 | Maximum number of items to process concurrently. Keep low for Discord rate limits. |
Output Data
The Discord response is merged into the item JSON — the incoming fields pass through and binary data is forwarded. Single-record operations produce one output item per input item; the Get Many operations fan out to one output item per record.
| Resource / Operation | Output |
|---|---|
Message / send | The created message — id, channel_id, author, content, timestamp and the rest of the message record |
Message / get | The message record. With Simplify on (the default), only id, channel_id, author, content, timestamp and type |
Message / getAll | One item per message, newest first, simplified to the same six fields unless Simplify is off |
Message / deleteMessage | success: true |
Message / react | success: true |
Channel / create | The created channel — id, name, type, guild_id and its settings |
Channel / get | The channel record |
Channel / getAll | One item per channel in the server, after the type filter and limit are applied |
Channel / update | The updated channel record |
Channel / deleteChannel | The deleted channel record as Discord returned it |
Member / getAll | One item per member. With Simplify on (the default), only user, roles and permissions |
Member / roleAdd | success: true |
Member / roleRemove | success: true |
Webhook / sendLegacy | The message record when the Wait option is on; Discord returns no body otherwise |
Reference a field downstream by expression, e.g. {{ $json.id }}.
Usage Examples
- Send a Discord message with a file attachment
- Send a message to a Discord channel
- Get messages from a Discord channel
- Create a new Discord channel
- Add a role to a Discord member
- Send a message via Discord webhook
- React to a Discord message with an emoji
Example Configuration
Send a message with a rich embed:
{
"type": "discord",
"parameters": {
"authentication": "botToken",
"guildId": "123456789012345678",
"resource": "message",
"operation": "send",
"sendTo": "channel",
"channelId": "987654321098765432",
"content": "Hello Discord!",
"sendOptions": {
"tts": false,
"flags": []
},
"embeds": {
"values": [
{
"inputMethod": "fields",
"title": "Notification",
"description": "This is an embedded message",
"color": "3447003",
"timestamp": "2024-01-01T12:00:00Z"
}
]
}
}
}
Send a message with a file taken from the item’s binary data:
{
"type": "discord",
"parameters": {
"authentication": "botToken",
"guildId": "123456789012345678",
"resource": "message",
"operation": "send",
"sendTo": "channel",
"channelId": "987654321098765432",
"content": "File attachment example",
"files": {
"values": [
{ "inputFieldName": "data" }
]
}
}
}
Send a direct message to a user:
{
"type": "discord",
"parameters": {
"authentication": "botToken",
"guildId": "123456789012345678",
"resource": "message",
"operation": "send",
"sendTo": "user",
"userId": "{{ $json.discordUserId }}",
"content": "Your report is ready."
}
}
Read the latest 50 messages in a channel:
{
"type": "discord",
"parameters": {
"authentication": "botToken",
"guildId": "123456789012345678",
"resource": "message",
"operation": "getAll",
"channelId": "987654321098765432",
"returnAll": false,
"limit": 50,
"messageGetOptions": {
"simplify": true
}
}
}
React to a message:
{
"type": "discord",
"parameters": {
"authentication": "botToken",
"guildId": "123456789012345678",
"resource": "message",
"operation": "react",
"channelId": "987654321098765432",
"messageId": "111222333444555666",
"emoji": "👍"
}
}
Create a text channel inside a category:
{
"type": "discord",
"parameters": {
"authentication": "botToken",
"guildId": "123456789012345678",
"resource": "channel",
"operation": "create",
"channelName": "new-text-channel",
"channelType": "0",
"channelCreateOptions": {
"topic": "A new channel for discussions",
"nsfw": false,
"rate_limit_per_user": 5,
"parent_id": "555666777888999000"
}
}
}
List the server’s text and voice channels:
{
"type": "discord",
"parameters": {
"authentication": "botToken",
"guildId": "123456789012345678",
"resource": "channel",
"operation": "getAll",
"returnAll": true,
"channelGetAllOptions": {
"filter": [0, 2]
}
}
}
Give a member two roles:
{
"type": "discord",
"parameters": {
"authentication": "botToken",
"guildId": "123456789012345678",
"resource": "member",
"operation": "roleAdd",
"userId": "777888999000111222",
"roleIds": "333444555666777888,999000111222333444"
}
}
Post through a webhook with a custom name and avatar:
{
"type": "discord",
"parameters": {
"authentication": "webhook",
"operation": "sendLegacy",
"content": "Hello from webhook!",
"webhookOptions": {
"username": "Custom Bot Name",
"avatar_url": "https://example.com/avatar.png",
"tts": false,
"wait": true
},
"embeds": {
"values": [
{
"inputMethod": "fields",
"title": "Webhook Notification",
"color": "16711680",
"description": "This message was sent via webhook"
}
]
}
}
}
Error Handling
| Mode | Behavior |
|---|---|
| stop | Halts workflow on first error |
| continue | Skips failed items, passes successful ones through |
| errorPort | Routes failed items to Error output port |
Tips
Send messages with file attachments, manage channels, and manage members on Discord servers via Bot Token, OAuth2, or Webhook.
Choosing a connection type
- Bot Token — full access to messages, channels and members on a server. The bot must already be invited to the server and hold the permissions the operation needs.
- OAuth2 — the same feature set, with an install flow that makes adding the bot to a server easier.
- Webhook — the lightest option, but it can only post messages to the one channel the webhook belongs to. The resource selector and Server (Guild) ID disappear when you pick it.
Attachments
- Add one Files entry per file and name the binary property that holds it —
datais the usual name for a single upstream file. Check the previous node’s Binary Data panel for the exact names, which are case-sensitive. - Attachments are uploaded with the message itself, so text, embeds and files all arrive in a single post.
Notes
- IDs come from Discord’s Developer Mode. Turn it on in Discord’s Advanced settings, then right-click a server, channel, message or user to copy its ID.
- Messages are capped at 2000 characters by Discord; put longer content in an embed or a file attachment.
- Simplify is on by default for Message: Get, Message: Get Many and Member: Get Many. Turn it off when you need fields the trimmed shape leaves out, such as attachments, reactions or nicknames.
- Embeds and Files accept several entries — add one per embed or file.
- Raw JSON embeds let you use any embed feature Discord supports, including fields and footers that the individual inputs do not cover.
- Webhook: Wait changes the output. With Wait off, Discord acknowledges without returning the message, so nothing lands on the item; turn it on when a downstream node needs the message ID.
- Keep Max Concurrency low. Discord rate-limits aggressively per bot and per channel.
Frequently asked questions
Which credential type should I use — Bot Token, OAuth2, or Webhook?
Use Bot Token or OAuth2 if you need to manage messages, channels, or members — they give full API access. OAuth2 is the same feature set but has an easier install flow for adding the bot to a server. Webhook is the simplest option but is limited to posting messages to the single channel the webhook was created for; it cannot manage channels or members.
How do I send a file attachment with a message?
Add a Files entry under the message options and enter the binary property name that holds your file — typically `data` for a single file from an upstream node. Check the previous node's Binary Data panel for the exact property name, which is case-sensitive. The text, embeds, and file all post in the same message.
Why does the Webhook: Send operation return nothing useful downstream?
By default, Discord acknowledges a webhook post without returning the message object, so no data lands on the output item. Turn on the Wait option if a downstream node needs the message ID or any other field from the posted message.
My message content is over 2000 characters — what should I do?
Discord enforces a 2000-character limit on message text. Put longer content in an embed or attach it as a file. Embeds support a Raw JSON option that gives you access to all Discord embed features, including fields and footers that the individual form inputs don't expose.
My workflow is hitting Discord rate limits. What can I do?
Discord rate-limits aggressively per bot and per channel. Keep the Max Concurrency setting low on this node to avoid triggering those limits. Spreading requests across time with a delay or throttle node upstream can also help.
Build with the Discord node
Drop it into a workflow, wire it to an agent, or call it on a schedule. You'll need Discord Bot API credentials first.
Open BusyBotLast updated . Spotted something wrong? Tell us.