Skip to content

Deploy Agent to Discord#

Beta Feature

Deployments are experimental and currently in private beta. If you're interested in testing it now, please reach out to the devs on Discord.

Users who have been granted access to the deployment beta will notice a "Deployments" section in each Agent's settings. Through this interface, you can deploy your agent to either Discord or Telegram.

To deploy your agent to Discord, follow these steps.

Create Application in Discord#

You will first need to create a new application in the Discord Developer Portal.

Select 'New Application'

Give your application a name (e.g. "My Agent") and click "Create". For convenience, you can give it the same name as your agent.

In "General Information" upload your agent's profile image to App Icon. Click 'Save' to save the changes.

Discord deployment settings. Give it a profile image

Now click "Bot" on the left sidebar to set up the bot.

Click "Reset Token" to generate a new token and copy it somewhere safe. In one of the next steps, you will need to paste this token into Eden.

Click 'Reset Token' to generate a new token and copy it somewhere safe.

Token Security

If you ever reset or revoke the token, your bot will stop working. You can always generate a new token and paste it again into Eden.

On the same page, scroll down to "Privileged Gateway Intents" and make sure to select the presence, server members, and message content intents. Your bot will not be able to send or receive messages without these permissions, so make sure to select them and click "Save Changes".

Allowlist

Now let's set up your agent in Eden. Go to your agent's deployment settings, select Discord, and paste the Discord Token you copied earlier into the "Token" field.

Select Bot scope.

Next you'll have to setup which channels your agent will be active in. The easiest way to do this is to first activate "developer mode" in discord:

  1. Go to user settings
  2. Search for "developer" and activate the developer mode in advanced settings

Copy Channel ID.

Copy Channel ID.

Finally, add channel IDs to "Allowed Channels" to permit your bot to post messages in that channel. To get the channel ID of any channel in Discord, right click the channel name in Discord and select "Copy ID" or "Copy Channel ID". It's good practice to add the channel name as a label so you remember later which ones you've already added.

Copy Channel ID.

Once you're done, click "Deploy."

Once it's done, the deployments page will show the status of the deployment. If it is successful, you will now see a section that says "Invite Bot to Server". Click to copy this link, paste it into a browser, and add the bot to your server:

Click to copy this link, paste it into a browser, and add the bot to your server.

Test Your Agent#

If your deployment was successful, your bot will show as "Online" in the sidebar of your Discord server.

Your bot will show as 'Online' in the sidebar of your Discord server.

Go to one of the channels where the bot is allowed to send messages and try mentioning it in a message. If it responds, you're all set!

Common Issues

A common issue is allowlisting your bot to a channel where it does not have permission to send messages. If it doesn't respond, check the permissions of the channel and make sure the bot has "Send Messages" permissions.

Also, when deploying a bot to a private channel you may need to manually add it as a member in discord:

  1. Right click the channel and click "Edit Channel"

Edit channel

  1. Go to permissions and add members and add your bot

Add permissions

Troubleshooting#

Bot Not Responding#

  • Check that the bot token is correct and hasn't been reset
  • Verify the bot has "Send Messages" permissions in the channel
  • Ensure the channel is in the "Allowed Channels" list
  • Check that the bot is online in your server

Permission Issues#

  • Make sure all required Gateway Intents are enabled
  • Verify the bot has proper permissions in your Discord server
  • Check that the bot role has the necessary permissions

Deployment Failures#

  • Verify your Discord application is properly configured
  • Check that the bot token is valid and not expired
  • Ensure all required settings are saved in Discord

Best Practices#

Security#

  • Keep your bot token secure and don't share it publicly
  • Use the minimum required permissions for your bot
  • Regularly rotate your bot token if needed

Channel Management#

  • Start with a few test channels before deploying widely
  • Use descriptive labels for channel IDs in Eden
  • Monitor bot activity to ensure appropriate behavior

User Experience#

  • Set clear expectations for what your bot can do
  • Provide helpful error messages when things go wrong
  • Consider rate limiting to prevent spam

Next Steps#

Once your Discord bot is working:

  1. Test Basic Functionality - Ensure your agent responds appropriately
  2. Configure Advanced Settings - Set up custom behaviors and responses
  3. Monitor Performance - Track usage and identify areas for improvement

Need help? Join our Discord community for support and tips from other users.