We built a Discord bot that queries a database and creates Jira tickets. No workflow graph. No if/else branches. The LLM read the message, decided what to do, and called the right MCPs. Five minutes on the Aerostack side.
I've seen a lot of "how to make a discord bot" tutorials. They all start the same way: install Node.js, npm install discord.js, write 80 lines of boilerplate, set up a VPS, pray the process stays alive. Then you get a bot that responds to !ping with pong. That's it. The no-code alternatives (MEE6, Carl-bot) give you preset commands — useful for moderation, but useless the moment you need to touch your actual data.
This guide shows a different path. We're going to use Aerostack's ai chatbot builder to create a Discord bot that's LLM-powered (no preset commands), connects to your real tools and database via MCP, requires zero bot code, and comes with hosting included. The same bot definition also runs on Telegram, WhatsApp, and Slack. You pick the channel.
What You'll Build
A Discord bot that responds to natural language, queries your database, creates Jira tickets, or calls any other tool you connect — without writing a single line of bot code. Here's what the conversation looks like:
@ErrorBot what errors happened in the last hour?
→ Found 3 errors: connection timeout at 14:32, auth failure at 14:47, null pointer at 15:01. Want me to create a Jira ticket for any of these?
Create a ticket for the auth failure.
→ Done. Created PROJ-1247: Auth failure in login service. We didn't program the "ask if they want a ticket" branch. The LLM saw the Jira MCP in its tool list and decided it was relevant. That's the difference between a bot with preset commands and an AI bot with real tools.
How to Make a Discord Bot: Code vs No-Code
The SERP for "how to make a discord bot" is almost entirely code-first tutorials. Here's why that matters, and where Aerostack fits:
| Code-first (discord.js / discord.py) | Aerostack (no bot code) | |
|---|---|---|
| Setup time | 30–60 min (install, code, deploy) | 5 min (wizard) |
| Bot logic | You write every command handler | LLM decides what to do |
| Hosting | You manage a VPS / Replit / Render | Included (no server) |
| Connect to DB / APIs | Write SDK calls yourself | Add an MCP (no code) |
| Multi-channel | Separate codebase per platform | One definition, 4 channels |
| Best for | Custom commands, deep Discord API usage | AI bots that use your real tools |
If you need slash commands with complex Discord UI components (select menus, modals, buttons), discord.js still wins. If you want an AI bot that answers questions from your database and calls your tools, Aerostack is the faster path. Looking for drag-and-drop command builders? The discord bot maker comparison covers no-code alternatives side by side.
Prerequisites
Before you touch the Aerostack dashboard, you need:
- A Discord account
- A Discord server where you have admin rights (to invite the bot)
- An Aerostack account
Step 1: Create Your Bot on the Discord Developer Portal
Every Discord bot — whether it's discord.js or Aerostack — starts here. This step is unavoidable and takes about 5 minutes. Discord's developer portal has changed layouts a few times; these steps are current as of 2026.
Discord Developer Portal setup
- Create a new application
Go to discord.com/developers/applications and click "New Application" in the top right. Give it a name; this becomes your bot's display name. On the General Information page, copy two values you'll need later: the Application ID and the Public Key.
- Add a Bot and enable Message Content Intent
Click "Bot" in the left sidebar. Click "Add Bot" and confirm. Scroll down to "Privileged Gateway Intents" and enable Message Content Intent, which allows the bot to read message text in channels. Without it, your bot sees events but can't read what users typed.
- Reset Token and copy it
Still on the Bot page, click "Reset Token". Confirm the prompt. Copy the token immediately. Discord shows it only once. If you navigate away without copying it, you'll need to reset again.
- Set permissions and generate an invite URL
Click "OAuth2" in the left sidebar, then "URL Generator". Under Scopes, check both "bot" and "applications.commands". Under Bot Permissions, check: Send Messages, Read Message History, Use Slash Commands, Manage Messages. Copy the generated URL at the bottom and open it in a new tab. Select your server and authorize.
Step 2: Connect Discord to Aerostack (The Fast Part)
Now the Aerostack part. Log into the dashboard and start a new bot. The wizard walks you through five decisions. For Discord, it looks like this:
Aerostack bot wizard: Discord path
- Pick a template (or start from scratch)
Aerostack offers templates for common bot types (error detective, customer support, data analyst). Pick one to get a pre-tuned system prompt, or select "Blank" and write your own. The system prompt is the single biggest lever you have over bot behavior. We'll come back to this.
- Select Discord as your channel
The platform step shows all four supported channels: Telegram, Discord, WhatsApp, Slack, and API-only. Select Discord. The same bot definition works on any channel; this isn't a separate codebase per platform.
- Paste your three Discord credentials
The wizard asks for three fields from the Developer Portal: Application ID (from General Information), Public Key (from General Information), and Bot Token (from the Bot page, the one you copied after Reset Token). Aerostack uses the Public Key to verify Ed25519 signatures on incoming webhooks so you know the request actually came from Discord.
Application ID: 1234567890123456789 Public Key: f1d88f5b1e4a... Bot Token: MTk4NjIyNDgzNDU3... - Connect an MCP workspace (your tools)
This is where the bot gets its brain. Link your bot to an MCP workspace: a hosted collection of MCP servers and their encrypted secrets. The bot automatically gets access to every tool in that workspace. No code changes to add or remove tools.
- Go Live
Click "Go Live". Aerostack automatically registers the Interactions Endpoint URL on your Discord application and registers /ask and /reset slash commands. No manual webhook setup in the Developer Portal. Your bot is live. Go to your server and try /ask followed by any question.
Step 3: Give It a Brain: MCP Workspaces and Tools
A workspace is a container for MCP servers. It holds your secrets (encrypted at rest), manages access, and gives the bot a single gateway to all your tools. You browse the registry, add the MCPs your bot needs, then configure each one's credentials in the workspace secrets panel. When I first set this up, I pointed the workspace at our Postgres MCP and the Jira MCP. No gateway code required.
For the error-detective bot from the example above, the workspace has two MCPs:
Query your PostgreSQL database from any AI agent. Exposes query, list_tables, describe_table tools. Add your connection string once — the LLM never sees raw credentials.
Create issues, search tickets, and get details from Jira. Needs your Atlassian email and API token. One workspace secret — works across any bot that has this workspace.
Secrets are encrypted before they hit storage. At runtime, the gateway decrypts the relevant secrets and injects them into the MCP request. The LLM only ever sees tool schemas: names, descriptions, and parameter types. Raw credentials are never exposed.
{
"mcpServers": {
"aerostack-workspace": {
"command": "npx",
"args": [
"-y",
"https://mcp.aerostack.dev/ws/your-workspace-slug"
]
}
}
} {
"mcpServers": {
"aerostack-workspace": {
"command": "npx",
"args": [
"-y",
"https://mcp.aerostack.dev/ws/your-workspace-slug"
]
}
}
} Replace 'your-workspace-slug' with your workspace slug from the Aerostack dashboard. All MCPs in the workspace are accessible through this single URL.
Making It a True Discord AI Bot (Not Just Preset Commands)
In our experience, here's the thing about "discord ai bot" searches: most results give you a bot that wraps an OpenAI API call and returns a chat response. That's not actually an AI bot with tools: it's a chatbot. The difference matters when you want it to do something, not just say something. See our deeper breakdown of what makes a genuine Discord AI bot different from a chatbot wrapper.
A true AI Discord bot needs three things: an LLM that can reason, tools it can call (not just text it can generate), and a feedback loop so it can check its own tool results and decide what to do next. That's what the MCP connection provides. The LLM gets a list of available tools, decides which to call based on the user's message, sees the result, and responds (or chains another tool call).
The system prompt is our primary control surface over this loop. For example:
You are an error detective bot for the engineering team.
When users ask about errors or incidents:
1. Query the database MCP for recent error logs.
2. Summarize what you find — include timestamps and error types.
3. Ask if they want a Jira ticket for any of the errors.
When users ask to create a ticket:
1. Call the Jira MCP create_issue tool with the error details.
2. Return the ticket key (e.g., PROJ-1247).
Keep responses concise. Always explain what queries you ran. Change this prompt without redeploying. Add a rule like "never create high-priority tickets without explicit confirmation" or "always assign to the on-call engineer." The bot adjusts immediately. This is the part that no discord.js bot can do without touching code.
Extending the Bot: More Channels, More Tools
Once the Discord bot is live, adding more channels is not a new bot — it's a new platform selection on the same bot. The same workspace, system prompt, and MCP tools work on Slack or Telegram. Your on-call engineer can query the same error bot in whichever platform they prefer.
Adding more tools is equally mechanical: browse the registry, add the MCP to the workspace, configure its secrets. The LLM picks it up automatically on the next request. No code deploy required. Common additions for engineering bots: GitHub (search issues, create PRs), PagerDuty (acknowledge incidents), Notion (create runbooks), Datadog (query metrics).
The Real Time Cost (Being Honest)
The 5 minutes is honest for the Aerostack side. I timed this. The real time goes into credential gathering:
- Discord Developer Portal: 5 min (application + enable Message Content Intent + Reset Token + OAuth invite URL). If it's your first time, budget 10. Discord's portal is powerful but not intuitive.
- Database MCP: if you're using a hosted MCP from the registry, it's quick: add it, configure the connection string. If you're deploying a custom MCP that wraps an internal API, that's a separate task. Either way: create a read-only database user with SELECT permissions on only the tables the bot needs. Never give it your production admin credentials.
- Jira API token: 2–3 min. Atlassian account → Security → Create API token. Straightforward.
Total from zero: 15–30 minutes depending on whether your MCPs already exist in the registry. That's not because Aerostack is slow — it's because third-party credential gathering is friction we can't eliminate on your behalf.
Troubleshooting
Bot is online but doesn't respond to messages
"Token was reset" error in Aerostack
Slash commands (/ask, /reset) are not showing up
Bot responds but tool calls are failing
"Invalid permissions" when inviting the bot
Frequently Asked Questions
How to make a Discord bot: common questions
Do I need to know how to code to make a Discord bot with Aerostack?
No. The Aerostack bot wizard requires zero coding: you pick a template, select Discord, paste your credentials from the Discord Developer Portal, and click Go Live. You do need to gather credentials from Discord's Developer Portal (Application ID, Public Key, Bot Token), but that's clicking through a web UI, not writing code.
Can my Discord bot read from my database?
Yes. Add a database MCP server to your workspace (Aerostack hosts PostgreSQL, MySQL, and others in the registry), then configure the connection string as a workspace secret, and the bot can run queries. The LLM decides when to call the database tool based on what the user asks. Your credentials are encrypted and never exposed to the LLM.
Do I need to host the Discord bot myself?
No. Hosting is included with Aerostack. When you click Go Live, Aerostack registers the webhook endpoint with Discord and handles all incoming interactions. There's no server to manage, no process to keep alive, no Replit or Render account needed.
Is Aerostack free to get started?
Aerostack has a free tier for getting started. Check the pricing page for current limits on bot activity, workspace MCP count, and message volume. The free tier is enough to build and test a bot like the one in this tutorial.
Can the same bot run on Telegram, WhatsApp, and Slack too?
Yes. One bot definition in Aerostack supports four channels: Discord, Telegram, WhatsApp, and Slack, plus an API-only mode. The system prompt, MCP workspace, and AI model are shared. You select the channel at bot creation time, and the same logic runs on whichever platform your users are on.
How is this different from a Discord bot maker or drag-and-drop builder?
A Discord bot maker gives you preset command flows — you pick triggers and responses from a menu. Aerostack's approach is different: the LLM reasons about what to do based on the message, then calls real tools (database queries, API calls) using MCP. There's no command tree to build. The bot understands intent and acts on it.
What's the fastest way to make a Discord bot that actually does something useful?
The fastest path to a useful Discord bot in 2026: create a Discord application (5 min on the Developer Portal), set up an Aerostack account, connect Discord, add a database or tool MCP to your workspace, and write a system prompt describing what the bot should do. You can have a working bot that queries your database in under 20 minutes total — most of that time is Discord credential setup.
The hardest part of how to make a Discord bot in 2026 is still the Discord Developer Portal — not because it's technically complex, but because the layout has changed enough times that every tutorial has screenshots from three years ago. Our side genuinely is 5 minutes once you have your credentials.
The bigger shift is moving from "write every command handler" to "describe what the bot should do". The system prompt replaces the switch statement. The MCP workspace replaces the SDK integrations. The LLM handles the routing that would have been 200 lines of conditional logic.