Connect Discord with MESA
When you're setting up your first workflow with Discord, you will need to create an application and a Bot on Discord before you can enable your workflow.
Follow these steps below on how to connect Discord with MESA.
1. In a separate tab, log in to your Discord account and go to the Applications page within the Developer Portal.
2. Click on New Application on the top right-hand corner.
3. Add the Name of your application and click Create.
4. On the left-hand sidebar, click on OAuth2. Under Redirects, click on Add Redirect and add https://app.getmesa.com/apps/mesa/oauth/redirect-token. Save your changes.
5. On the left-hand sidebar, click on Bot. Then, click on Add Bot in the right-hand corner. When prompted with a modal, click on Yes, do it!
6. You will see that a wild bot has appeared! Within the same Bot page, scroll down until you see Authorization Flow. Enable Requires OAuth2 Code Grant, Presence Intent, and Server Members Intent. Optionally, you could disable Public Bot. Make sure to click on Save Changes afterward.
7. Within the same Bot page, scroll all the way up and locate your Bot's Token. Click on the Copy button to copy the Bot's token.
8. Go back to your MESA workflow and locate your workflow's Discord Step. In your Discord Step, locate the Account Credentials section. Paste the copied value into the Bot Token field in MESA.
9. Almost done! Go back to the Discord's Applications page within the Developer Portal and go back to your newly created Application. On the left-hand sidebar, click on oAuth2. Locate your Applications' Client Information. Click on Copy under the Client ID and the Client Secret.
10. Go back to your MESA workflow and paste these values into the Client ID and Client Secret fields. Then, click on Authenticate with Discord.
11. You will be redirected to a Discord screen that asks which server you'd like to add the Bot to. Select a server and click on Continue. If you have not created a server just yet, you can follow this Discord document.
12. On the next prompted modal, click on Authorize.
13. You are all set! You can re-use this Discord credential for future Discord workflows.
Locate your Channel ID
In specific Discord actions such as Discord Create Channel Message, you will be required to enter a Channel ID.
To locate the Channel ID, login into Discord. Make sure you have Developer Mode enabled. If you don't have Developer Mode enabled, go to your User Settings (gear icon).
On the left-hand sidebar, locate Advanced and toggle Developer Mode on.
Next, locate your server's channel and right-click on the channel. Click on Copy ID and paste that value into your workflow's Discord Step's Channel ID field.
Edit your Discord Message
When using MESA's Discord Create Channel Message Action, you can send any information you'd like in the Discord Message. To edit the Discord Message, you can locate the Content field. Also, you can use MESA's token feature to send specific information from your previous workflow steps.
The following image is from MESA's existing template: Send a Discord message when a tagged Shopify order is purchased.