Discord
The Discord connector allows AI agents to read server messages, search conversation history, and post messages or reactions — all through the Discord API using OAuth 2.0. Your credentials are stored encrypted in MCPGate's vault and are never exposed to the AI client.
User OAuth token
Tool reference#
The Discord connector exposes 7 tools: 5 read and 2 write.
| Tool | Category | Description |
|---|---|---|
| discord_list_guilds | read | List servers the user is a member of |
| discord_list_channels | read | List channels in a server |
| discord_read_messages | read | Read messages from a channel |
| discord_search_messages | read | Search messages in a guild or channel |
| discord_get_user | read | Get information about a Discord user |
| discord_send_message | write | Send a message to a channel |
| discord_add_reaction | write | Add a reaction emoji to a message |
Common guardrail recipes#
Read-only access#
Enable only the five read tools and deny discord_send_message and discord_add_reaction. This is safe for agents that monitor or summarise Discord conversations without posting anything.
Restrict to specific channels#
Apply the allow_values template to discord_send_message and target the channel_id field. Provide a list of channel IDs the agent is permitted to post to. Any attempt to post to other channels will be denied.
Block mass pings#
Apply the keyword_block template to discord_send_message and add @everyone and @here to the blocked keyword list. This prevents the AI from triggering notifications for the entire server.
Troubleshooting#
- Channel not accessible — The agent can only read channels that your Discord account has permission to view. Private channels require an explicit role assignment.
- Search returns no results — Discord message search is only available in servers where you have the correct permissions. Community servers may restrict search.
- Send message fails in read-only channels — Some channels are configured as announcement or read-only channels.
discord_send_messagewill fail if your account does not have the Send Messages permission in that channel.