Last updated
Last updated
Build An Interactive Discord Bot
This guide will walk you through setting up and using the Skillful AI Discord bot integration. Our Discord integration allows you to create AI-powered Discord bots that can interact with users, generate images, and leverage all of Skillful AI's capabilities.
Step 1: Prerequisites
Go to
Click "New Application"
Navigate to the "Bot" section
Click "Add Bot"
Enable Privileged Intents:
MESSAGE CONTENT INTENT
SERVER MEMBERS INTENT
PRESENCE INTENT
Copy your bot token
for an API key
Step 2: Installation
Using a code editor like Visual Studio Code, we can create a new project with:
Step 3: Basic Setup
Create an index.js
script and copy the below into it. The basic setup will disable ProActive Mode by default, but enable everything else you need to interact with your AI Agent.
Step 4: Run the Bot
Run your bot to start the application:
Basic Usage
You can interact with your agent in a few different ways:
The bot responds to direct mentions:
The bot will respond to direct replies.
If ProActive Mode has been enabled in the constructor, your bot will dynamically jump into conversations and reply to users.
Debug Mode
Enable debug logging:
Debug mode shows:
Message processing
Engagement decisions
Error details
Connection status
Error Handling
Best Practices
Environment Variables
Proper Shutdown
Error Monitoring
Troubleshooting
Invalid Token
Verify token in Discord Developer Portal
Check for token format issues
Ensure intents are enabled
Connection Issues
Check internet connection
Verify Discord API status
Check for rate limiting
Permission Issues
Verify bot has required permissions
Check channel permissions
Verify intent settings
For more help, join our .