![Oracle Drags Its Feet in the JavaScript Trademark Dispute](https://cdn.sanity.io/images/cgdhsj6q/production/919c3b22c24f93884c548d60cbb338e819ff2435-1024x1024.webp?w=400&fit=max&auto=format)
Security News
Oracle Drags Its Feet in the JavaScript Trademark Dispute
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
@minhlucvan/n8n-nodes-discord
Advanced tools
nodes to trigger workflows from Discord or send interactive messages. Uses the components API which allows to create dialogs (e.g. attach buttons and wait for the user to click on them)
n8n nodes to trigger workflows from Discord or send interactive messages. Uses the components API which allows to create dialogs (e.g. attach buttons and wait for the user to click on them).
These nodes do not use webhooks but a Discord bot to enable two-way communication. The bot automatically launches into a main process once configured and transmits or receives data from child processes when a node is executed.
n8n-nodes-discord
in Enter npm package name.After installing the node, you can use it like any other node. n8n displays the node in search results in the Nodes panel.
To get started install the package in your n8n root directory:
npm install n8n-nodes-discord
For Docker-based deployments, add the following line before the font installation command in your n8n Dockerfile:
RUN cd /usr/local/lib/node_modules/n8n && npm install n8n-nodes-discord
In order to send, listen to messages, get the list of channels or roles, you need to setup a bot using the Discord Developer Portal.
First, create an application by clicking on New Application in the Developer Portal.
Go to OAuth2 and copy the client ID. On your n8n instance, you will create new Discord App credentials (Credentials > New > Search for "Discord App" > Continue) and paste the Client ID into the corresponding field. Don't close yet the modal.
Get back to the Discord Developer Portal on your created application, go to Bot and click Add Bot. In the Authorization Flow, disable Public Bot. Activate all Privileged Gateway Intents then save your modifications.
Go to OAuth > URL Generator, select the scopes bot and applications.commands, the bot permission administrator then copy the generated URL at the bottom.
Now use this link to add the bot to your Discord server. You need to be logged in to Discord on the browser with the same account where you have Manage Server or Administrator permissions on the server you want to add the bot.
Once your bot is added to your server, you need to get the bot token and add it to your Discord App credentials. Just click on Copy on yout bot page or Reset Token if the button Copy is not visible.
Save your credentials and got to Settings > n8n API, click Create an API Key or select the existing one, copy the key, reopen your Discord App credentials (Credentials > Open), paste the key into the n8n API key field and set your base URL (e.g. https://n8n.example.com/api/v1). Don't forget to save again.
Now you will be able to use the Discord Trigger and Discord Send nodes on your workflows. The first time you setup one of these nodes, it will start the bot.
@bot hello
will be tested on hello
.
/!\ Don't forget to activate your trigger, even if you just want to test it.
Credential for Discord App: If you followed the bot setup guide above, you will be able to select your Discord App credentials to start the bot. If you are already another Discord Trigger (or Send) node, be careful to select the same credentials. It's not meant at the moment to be used with multiple Discord Server.
Replace the trigger placeholder: If active, the message produced by this node will replace the previous placeholder set. It can be a placeholder set by the Discord Trigger node or by another Discord Send node.
Send to the trigger channel: If active, the message produced will be sent to the same channel were the workflow was triggered (but not replace the placeholder if there is one).
Send to: Let you specify the text channels where you want to send the message. Your credentials must be set and the bot running, you also need at least one text channel available. If you do not meet these requirements, make the changes then close and reopen the modal (the channels list is loaded when the modal opens).
Type: Let you choose the type of interaction you want to perform.
Persitent: Available for type prompt. If active the button/select will stay visible even when the workflow is done.
Mention roles: Let you specify roles you want to mention in the message. Your credentials must be set and the bot running, you also need at least one role (apart from @everyone) available. If you do not meet these requirements, make the changes then close and reopen the modal.
Placeholder: Not available for simple messages. The placeholder is a message that will appear in the channel where the button or select prompt is displayed. Three animated dots added to the placeholder indicate that the workflow is running. From another Discord Send node, you can set up a response message which will then take the place of this placeholder.
Bot customizaion: Active this option to customize the bot activity and status.
To help you create and debug your workflow with Discord Trigger/Send nodes, some commands have been registered to the bot.
/logs
: Display the last logs stored in memory (max 100).
/logs 10
: If you specify a number, it will display the number amount last logs./logs clear
: Remove all logs in memory./logs on
: Logs are automatically sent in the current channel./logs off
: Disable logs automatically sent in the channel./clear
: Remove last (max 100) messages in the current channel.
/clear 10
: If you specify a number, it will remove the number amount last messages./test
: Toggle the test mode. Test mode switch the Discord bot on the trigger test url. Useful if you want to see how a workflow is executed and data are passed. Once the test mode is activated, go to the Discord Trigger UI and click on Fetch Test Event then on Discord send a message to trigger the workflow.
/test true
: Activate the test mode./test false
: Disable the test mode.MIT License
Copyright (c) 2023 https://github.com/edbrdi
Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions:
The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software.
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
FAQs
nodes to trigger workflows from Discord or send interactive messages. Uses the components API which allows to create dialogs (e.g. attach buttons and wait for the user to click on them)
The npm package @minhlucvan/n8n-nodes-discord receives a total of 2 weekly downloads. As such, @minhlucvan/n8n-nodes-discord popularity was classified as not popular.
We found that @minhlucvan/n8n-nodes-discord demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Oracle seeks to dismiss fraud claims in the JavaScript trademark dispute, delaying the case and avoiding questions about its right to the name.
Security News
The Linux Foundation is warning open source developers that compliance with global sanctions is mandatory, highlighting legal risks and restrictions on contributions.
Security News
Maven Central now validates Sigstore signatures, making it easier for developers to verify the provenance of Java packages.