An AI-powered chatbot for Discord using Spark Engine to handle chat, search, image generation, and video assistance. Uses Llama3.3, DALL-E, Minimax Video-01 and Spark Engine to create the ultimate AI Discord bot for your servers.
✅ AI-Powered Chat – Have dynamic conversations with Spark Engine
🔍 Web Search – Fetch real-time search results
🎨 Image Generation – Create AI-generated images
📽️ Video Generation – Create AI-generated videos
⚡ Easy Deployment – Run locally, with Docker, or host on your own server/hosting provider
- Go to the Discord Developer Portal
- Click "New Application", name your bot, and go to the Bot tab
- Click "Add Bot" → Copy your Bot Token (add it to
DISCORD_BOT_TOKEN
in your.env
)
- Under OAuth2 → Copy Client ID (add it to
DISCORD_CLIENT_ID
in your.env
)
- Select the
bot
tab, and underPrivledged Gateway Intents
toggle onMessage Content Intent
- Scroll down to
applications.commands
, then choose permissions (e.g., Send Messages, Read Messages, etc.) - Go to Spark Engine and create an account
- Create a new project on Spark Engine and upload the
ai-discord-bot.spk
file found at the root of this project
- Copy your Project ID by clicking the "API" button inside your project menu on Spark Engine (add it to
PROJECT_ID
in your.env
). This will be the AI flow that your bot calls, and you can modify it as needed. - Go to Your API Keys and add it to
SPARK_ENGINE_API_KEY
in your.env
. - Once you’ve deployed and run the bot (see below), invite it to your Discord server!
Download & install Node.js (v16 or higher) from nodejs.org.
git clone https://github.com/YOUR-REPO/Spark-Engine-Discord-Bot.git
cd Spark-Engine-Discord-Bot
npm install
Rename .env.example
to .env
and fill in the following values:
DISCORD_BOT_TOKEN=your-bot-token
DISCORD_CLIENT_ID=your-client-id
SPARK_ENGINE_API_KEY=your-api-key
PROJECT_ID=your-spark-engine-project-id
DASHBOARD_USERNAME=admin
DASHBOARD_PASSWORD=admin
npm run start
The bot should now be running! ✅
Open http://localhost:8080 in your browser and enter your DASHBOARD_USERNAME
and DASHBOARD_PASSWORD
. (Defaults are both “admin”.)
docker build -t discordsparkengine .
docker run -p 8080:8080 -v discordsparkengineconfig:/discordsparkengine/configFile discordsparkengine
To keep your bot running 24/7, you’ll need a hosting provider or server that supports a persistent Node.js process. Some popular options include:
- Railway.app
- Fly.io
- Render.com
- Heroku
- AWS EC2 (or other VPS providers)
After setting up your environment variables on your hosting platform, simply run:
npm run start
Or use a process manager like PM2 for production:
npm install pm2 -g
pm2 start index.js
Command | Description |
---|---|
/chat |
General AI chat |
/search |
Perform a web search |
/image |
Generate an AI-powered image |
/video |
Generate an AI-powered video |
This project is licensed under the MIT License.
Now you’re ready to launch your Spark Engine Discord Bot! 🚀