How to Connect an AI Chatbot with Discord in 2026 (Step-by-Step)
Learn how to connect a WhisperChat AI chatbot to Discord in 2026 with this seven-step guide for setup, slash commands, security, and support.
If you run a Discord community, you already know the shape of the problem.
Your #help channel is 80% the same five questions. New members ask them because scrolling up is impossible and nobody reads #faq. Your mods answer the same thing over and over until they burn out and stop answering at all.
You can't fix that with a pinned message. You fix it by letting people ask, and getting an instant answer.
This guide shows you how to connect a WhisperChat AI chatbot to your Discord server. Seven steps, about ten minutes, and - this is the part that's changed since the old days - no gateway bot to host. Nothing runs on your machine.
What this actually is
Not a keyword bot. Not a moderation bot with a canned FAQ command.
This is your real chatbot - the one on your website - answering from the same trained knowledge base, triggered by a slash command.
Which means:
- One knowledge base for everything. Discord answers run through the same retrieval pipeline as your website widget. Train once; every channel stays in sync.
- Each channel keeps its own thread of context. Follow-up questions work like they do in a normal conversation.
- Sources come attached. When the answer came from crawled pages, up to three source links get appended.
- It works in DMs too. The command is registered globally, so it also works in a direct message with the bot once you share a server with it.
- You can lock it down by server. Leave the allowed-server list empty to answer anywhere it's added, or list specific server IDs to restrict it.
- Everything is logged. Discord questions show up in your dashboard History, Insights and Leads with Discord as the source.
Before you start
- A trained WhisperChat chatbot. Discord answers come from the same knowledge base as your website widget, so train it first or it'll just say it doesn't know.
- A Discord account plus Manage Server permission on the server you want the bot in. If you're not the owner, you'll need that permission before step 6.
- The Premium plan. Discord is a Premium integration.
Nothing to install or host. WhisperChat receives Discord's interactions directly.
The setup, in seven steps
Two tabs: the Discord Developer Portal and your chatbot's Deploy page in WhisperChat. Keep both open - you'll switch between them twice.
Step 1 - Create a Discord application
Open the Discord Developer Portal and click New Application.
The name and avatar you set here are exactly what your members see when the bot answers, so spend the extra thirty seconds on them. A bot called "Application 1" with a default avatar doesn't inspire much confidence in the answers.

Step 2 - Copy the bot token
Open the Bot tab, press Reset Token, and copy the token.
Read that carefully: Discord shows the token exactly once. If you close the page without copying it, you don't recover it - you reset it again and get a new one. Have somewhere to paste it before you click.
Step 3 - Copy the public key
Go to General Information and copy the Public Key.
WhisperChat uses this to verify the Ed25519 signature Discord puts on every request. That's what makes it impossible for a forged interaction to reach your chatbot.

Step 4 - Connect it in WhisperChat
Switch tabs. Open your dashboard → the chatbot → Deploy → find the Discord card → press Connect.
Paste in:
- the bot token
- the public key
Then pick your slash command name. The default is /ask, which is fine for most servers. If /ask is already taken by another bot in your server, change it now - something like /support or /docs works.
Press Connect Discord. WhisperChat validates the token against Discord's API and registers the slash command for you.

Step 5 - Register the Interactions Endpoint URL
Still in that dialog, copy the Interactions Endpoint URL. It looks like:
https://api.whisperchat.ai/discord/interactions/<id>?secret=<secret>
Paste it into the Developer Portal under General Information → Interactions Endpoint URL, then save.
Discord immediately posts a signed test request to it, so saving only succeeds once everything is wired up correctly. If it saves, you're good. If it doesn't, something in steps 2–4 is off.
⚠️ That URL contains a secret that authorises requests to your chatbot. Treat it like a password - keep it out of screenshots, shared docs and support tickets.

Step 6 - Invite the bot to your server
Press Invite to server and pick the server.
The invite asks for two permissions only - Send Messages and Read Message History - plus the slash-command scope:
67584 // Send Messages (2048) + Read Message History (65536)
If you've ever had to review a bot invite that demanded Administrator, this one should be a relief. It can't kick, ban, manage roles or edit your server. It can post and it can read history in channels it's in. That's the whole permission set.

Step 7 - Ask it something
Type your command in any channel the bot can see:
/ask What are your pricing plans?
Discord shows "App is thinking…" while the answer is generated, then replaces it with the reply and the pages it came from.

That's the setup. Seven steps, no code.
How it works underneath
You don't need this to use the bot, but if you're the person approving a new app in a community server, this is the part worth reading.
Every request is verified twice. The endpoint URL carries a per-chatbot secret - a request without it is rejected with a 403 before anything else happens. On top of that, Discord signs each interaction with Ed25519, and WhisperChat verifies that signature against your app's public key, answering 401 if it doesn't match.
Answers arrive as a follow-up. Discord requires an acknowledgement within 3 seconds, which is far less than retrieval and generation take. So WhisperChat immediately replies "deferred" - that's the "App is thinking…" state you see - then posts the real answer as a follow-up using the interaction token.
Retries never double-answer. If an acknowledgement is missed, Discord re-delivers the same interaction. Each interaction ID is claimed in an idempotency log, so a redelivery is acknowledged but never generates or bills for a second answer.
Replies fit Discord's limits. Discord caps a message at 2,000 characters. Answers are rendered as Discord-flavoured markdown and trimmed to fit, with the source links reserved out of that budget so they never get cut off.
Privacy and credentials
Two secrets are involved: your bot token and your endpoint URL.
Your bot token stays server-side. It's never sent back to the browser - the dialog shows a masked placeholder. Leaving the field empty keeps whatever's already saved.
The Interactions Endpoint URL contains a secret. Anyone holding it can reach your chatbot's endpoint. Keep it out of screenshots and shared documents. This is the one people leak accidentally, usually by posting a screenshot of the Discord settings page in a help channel.
Disconnecting deletes the registered slash command from your Discord application and clears the stored token. The bot stays in your servers until you remove it there, but it stops responding immediately.
Problems you might hit
Discord won't save the Interactions Endpoint URL. It sends a signed test request before saving. If it fails, the public key in step 3 is probably wrong or was pasted with a missing character. Recopy it, reconnect in WhisperChat, try again.
"This command is already registered" / the slash command doesn't appear. Another bot may own the same command name in your server. Reconnect with a different command name. Also give Discord a minute - global commands can take a moment to appear in the picker.
I lost my bot token. Reset it in the Bot tab and reconnect in WhisperChat with the new one. Discord only shows a token once, so this is normal, not a mistake.
The bot doesn't respond in a channel. Check it has access to that channel. It needs Send Messages and Read Message History there.
I can't DM the bot. The command is global, but you need to share a server with the bot first. Once you do, DMs work.
It answers "I don't know" to everything. Not a Discord problem. Test the same question in your website widget - you'll get the same answer. The knowledge base needs the content.
Does this use my message allowance?
Yes. Each answered question costs one message from your plan, exactly like a widget conversation, with the same multiplier for premium models.
When your subscription credits run out, a small daily grace allowance applies before the bot starts declining questions.
One detail for community owners: a member's Discord handle is stored as the conversation's display name only. It's an identity, not contact details someone submitted, so a Discord question doesn't turn into a lead.
A practical note for community owners
The bot doesn't replace your mods. It handles the boring 80% so your mods can handle the interesting 20%.
Two things I'd suggest before you announce it:
Test it in a private channel first. Ask it the fifteen questions your community actually asks, and see what comes back. If the answers are thin, that's a knowledge base problem - fix it before your members see it, not after.
Tell people what it's for. A one-line pin in #help - "use /ask for anything about pricing, setup or policies" - does more for adoption than any announcement. People need to know the command exists.
And use the allowed-server list if you're in multiple servers. Leaving it empty means it answers anywhere the bot gets added, which is fine until someone adds it somewhere you didn't expect.
FAQ
Do I need to host anything or run a Discord gateway bot? No. WhisperChat receives Discord's interactions directly over HTTPS. Nothing runs on your side.
Can I change the slash command name after setup? Yes - reconnect with the new name and WhisperChat re-registers it.
Does the bot read every message in my server? No. It only receives slash-command interactions. It isn't listening to your channels.
Can one Discord app serve several chatbots? Each connection ties one Discord app to one chatbot. For a second chatbot, create a second Discord application.
Can I use the same bot in several servers? Yes. Leave the allowed-server list empty to answer everywhere, or list specific server IDs to restrict it.
Why can't I message the bot directly straight away? Discord requires you to share a server with the bot before DMs work. Join a server it's in and try again.
Do Discord conversations appear in my analytics? Yes. They're logged with Discord as the source and show up in History, Insights and Leads.
What permissions does the bot actually need? Send Messages and Read Message History, plus the slash-command scope. Nothing else.
Wrapping up
Seven steps and you've turned your #help channel from a repetitive grind into something that mostly answers itself.
The setup is the easy part now. What decides whether this works is what's in the knowledge base behind it - the bot is only ever as good as what you've trained it on. Get that right and /ask becomes the most-used command in your server.
Open your dashboard to get started, or read thefull Discord integration docs for the complete reference.