Discord MCP security: permissions, risky tools and lockdown

Learn what the community mcp-discord server can read and change, which bot permissions and privileged intents it needs, and how to restrict it before an AI agent connects.

On this page

Can a Discord MCP server be locked down to least privilege?

The community barryyip0625/mcp-discord server is not published by Discord, and the supplied facts do not show a built-in per-tool allowlist, read-only mode or admin policy inside the server itself. That means least privilege has to be built outside the server, in the Discord bot's role permissions, its channel overrides and its privileged intents, and in the MCP client that decides which tools the agent may call. Discord's permissions documentation says permissions are set at guild level through roles and can be overridden per channel, so the bot's effective access is the combination of its roles and each channel's overwrites. The supplied facts also do not establish which Discord plan applies to your server, so confirm that in your own account before you rely on any admin feature.

The first lockdown decision is the invite. The README offers an Administrator link (permissions=8) as the recommended quick setup, but Discord's documentation says Administrator bypasses channel overwrites, so a bot invited that way cannot be restricted by channel. Use the custom minimum-permissions link (permissions=52076489808) as the starting point, then review each role the bot holds and remove any permission the chosen tools do not need. Keep the privileged intents off unless a tool needs them. Discord disables Message Content, Guild Members and Guild Presences by default, and the README prerequisites ask for Message Content, Server Members and Presence intents to be enabled, so the reviewer should decide which of those the tools you approve actually depend on. Then restrict the tools the agent may call in the MCP client, since the server's send, edit, delete, role, channel, permission override and webhook tools are all reachable once connected.

Before approval, confirm in your own environment: which Discord plan and admin features your server uses; whether your MCP client supports a tool allowlist or approval prompts for destructive calls; who can change the bot's roles and overrides; and whether your bot token is stored where only the approved host can read it. Test the locked configuration in a non-production server and check that a denied action fails. Discord's permissions documentation is the reference for how roles and overwrites combine, and it should be read alongside the vendor's own documentation for any feature you rely on.

Which controls are built in, configurable or missing

This table compares each control that limits what a Discord MCP server can do, and where that control is set. Read the status column first: controls built in to Discord apply no matter which server is connected, controls set by the organization depend on how the bot is invited and launched, and anything marked not documented must be confirmed with the project before approval. The main takeaway is that the server's own tool list is the control to verify first.

ControlWhere it livesStatus
Bot permissions set at invite timeInvite link permissions value chosen by the admin who adds the botSet by the organization
Administrator invite (permissions=8)Invite link in the mcp-discord README, recommended there for quick setupSet by the organization; grants all permissions and bypasses channel overwrites
Custom minimum-permissions invite (permissions=52076489808)Invite link in the mcp-discord README, limited to the listed permissionsSet by the organization
Privileged intents (Message Content, Server Members, Presence)Discord developer portal; the README prerequisites call for all threeBuilt in to Discord; disabled by default, enabled per app
Channel permission overridesPer-channel overwrites in Discord; the server has tools to set and remove themBuilt in to Discord; changeable through the server's tools
Role-based access in DiscordGuild-level roles, which can be overridden per channelBuilt in to Discord
Stdio versus streamable HTTP transportLaunch configuration of the server; the README lists both transportsSet by the organization
Per-tool allowlist or read-only switchNot described in the project's READMENot documented; confirm with the project before approval

Which mcp-discord tools change who can see and post

The community mcp-discord server exposes tools for messages, roles, channels, permission overrides and webhooks. Each group changes something different in a Discord server, and the access-related groups matter most because they change who can see and post, not only what is said.

Message tools: send, read, edit, delete, search

These tools post, fetch, change and remove channel messages and search across a server. An agent with send and delete can speak in a channel under the bot's identity and remove messages that others posted, which affects moderation records and the trust members place in channel history. Reading tools expose message content to the agent, so the bot's Message Content Intent setting determines how much text it can see. Check which channels the bot can reach before enabling these tools.

mcp-discord README

Role tools: create, edit, delete, assign, remove

Role tools let an agent create roles and attach or detach them from members. Because Discord sets permissions at guild level through roles, a role that grants channel access or posting rights is effectively an access grant. An agent that can assign a role can widen who sees a channel without any channel setting changing. Confirm which permissions the bot's own role holds, since a bot can only manage roles below its highest role.

Discord permissions docs

Channel and category tools for text, forum and voice

These tools create, edit and delete text, forum and voice channels and categories. Deleting a category or channel removes its message history along with it, and creating new channels can place content under categories that inherit existing role settings. An agent with delete rights on structure can remove a space the community relies on in one call. Restrict these tools to a staging server unless the workflow requires them in production.

Discord permissions docs

Channel permission override tools

These tools set and remove per-channel permission overrides for roles or members. Overrides are the direct control over who can see and post in a specific channel, so this is the group most clearly able to change access. An agent that can grant view or send permissions on a private channel can expose it to roles that were never meant to see it. Discord notes that the ADMINISTRATOR permission bypasses channel overwrites, so the bot's invite permissions decide whether these overrides even apply to it.

Discord permissions docs

Webhook tools: create, edit, delete, use

Webhooks let an external URL post into a channel under a custom name and avatar. An agent that can create a webhook gives an outside system a standing way to post into a server, and one that can use an existing webhook can publish content without the bot appearing in the member list. Webhook URLs are credentials, so anyone holding one can post. Inventory existing webhooks and decide whether the agent may create new ones at all.

mcp-discord README

How bot permissions, intents and overrides decide what the agent can do

The bot's Discord permissions set the ceiling for every MCP tool call. Permissions are set at guild level through roles and can be overridden per channel, and each one is stored as a bitwise integer. When the mcp-discord server calls a tool such as sending a message, editing a channel, assigning a role or setting a channel permission override, Discord checks the bot's effective permissions in that channel. A tool can only succeed if the bot holds the matching permission there. The tool list is therefore a menu of intended actions, while the bot's role grants and channel overwrites decide which of those actions actually work. Before connecting an agent, the reviewer should list the bot's roles in each guild and check each channel's overwrites for that bot or its role.

Administrator is the setting most likely to defeat channel-level restrictions. The README offers an Administrator invite link (permissions=8) as the recommended quick setup. Discord's permissions documentation says the ADMINISTRATOR permission allows all permissions and bypasses channel permission overwrites, so a bot invited with it is not limited by any channel restriction you set. The custom minimum-permissions link (permissions=52076489808) is the alternative to test first. Confirm the integer your invite actually uses, then review the bot's granted permissions in each guild's role settings to verify that Administrator is absent. If a channel is meant to stay read-only for the agent, that protection holds only when Administrator is not present.

Privileged intents widen what the agent can read, so each one needs a reason. Discord lists three privileged intents: Guild Presences, Guild Members and Message Content. They are disabled by default and should be enabled only as needed. Message Content covers message content, embeds, attachments, components and poll fields. Guild Members covers join, leave and update events and listing all members. The README prerequisites call for Message Content Intent and Server Members Intent, and also list Presence Intent, so following the setup as written turns on all three. Ask the team which search, read or member tools they need, disable any intent those tools do not require, and document the decision for the reviewer.

Five decisions to make before the bot joins a server

Each decision below sets how far the bot can see and change a Discord community if an AI agent misuses it. The invite permissions, intents, placement, role and tool approvals, and transport work together, so a weak choice in one area widens the blast radius of the others.

Invite permission set

The README offers an Administrator invite link (permissions=8) as recommended for quick setup, and a custom minimum-permissions link (permissions=52076489808). Discord documents that Administrator grants every permission and bypasses channel permission overwrites, so a bot invited with it ignores the channel restrictions you set. Ask the team to confirm exactly which permissions the custom link grants, and review them against the tools the agent will expose.

Discord permissions docs

Which privileged intents to enable

Message Content, Guild Members and Guild Presences are privileged intents, disabled by default in Discord and to be enabled only as needed. Message Content exposes message text, embeds, attachments and poll fields, so it decides whether the agent can read what members say. The README prerequisites list all three, so ask whether each one is needed for the tools in use and document the reason for each.

Privileged intent guide

Which server and channels the bot joins

The bot can access only the servers it has been added to, so each invite is a decision about scope. Choose a dedicated test or staging server first, and keep production communities separate. Within a server, permission overwrites can keep the bot out of private staff, moderation or announcement channels, but only if the bot lacks Administrator. Map every channel the agent can reach before inviting it.

Dedicated role or inherited roles

Permissions are set through roles at guild level and overridden per channel. A bot with its own managed role can be limited to the permissions it needs, and removing that one role cuts its access at once. A bot that inherits broad staff roles carries their reach with it. Confirm with the Discord admin which role the bot holds, who can change it, and whether role changes are logged in the server audit log.

Which tools the client exposes and approves

The README lists tools that send, edit and delete messages, search messages, manage roles and channels, set permission overrides, and manage webhooks. Those tools can change who sees and posts in a server, so they carry the highest risk. Expose only read tools where possible, require manual approval for any write or delete, and disable role, overwrite and webhook tools unless a named workflow needs them.

mcp-discord repository

Transport: local stdio or streamable HTTP

The README says the server supports stdio and streamable HTTP. A stdio server runs as a local process under the user who starts it, so its credentials and network path stay on that workstation. Streamable HTTP is a network service that can be reached by other clients, so it needs its own authentication, network restriction and logging. Confirm which transport is approved, who hosts it, and where the bot token is stored.

Where each control sits between the agent and the server

The diagram starts at the AI client, which launches or reaches the mcp-discord server process over stdio or streamable HTTP. The server authenticates to Discord with the bot token, so the bot's identity carries the permissions granted at invite time. Discord then checks the bot's role permissions, its privileged intents, and any channel overrides before a tool call touches the target server. The organization can restrict access at four points: the invite permission set, the intents enabled in the developer portal, channel overrides, and client-side tool approval. Check each point before the agent connects.

Illustrative flow showing the four points where an organization can restrict the agent.

Gaps the sources do not close and the usual way to cover them

The public sources describe what the mcp-discord server can do and which Discord permissions it asks for, but they do not show every control an organization would want before connecting it to an agent. Each gap below names the usual compensating control and what the reviewer must confirm in their own environment before approval.

No evidence of a tool allowlist

The README lists the tools for messages, roles, channels, permission overrides and webhooks, but the sources supplied do not show a per-tool allowlist or a read-only mode in the server. Without one, every listed tool is reachable by any connected client. The usual compensating control is a wrapper or gateway that exposes only approved tool names, or a fork that removes the tools you do not need. Confirm in the repository and the release you plan to run whether any flag disables tools, and test that a disabled tool returns an error from the server, not just from the client.

Read the README

Destructive tools available once connected

Tools to delete channel messages, delete roles, delete channels and categories, and delete webhooks are part of the server's listed functions. A prompt-injected or confused agent that calls these can remove content that cannot be restored from the server itself. The usual control is a dedicated least-privilege role for the bot that lacks delete rights, combined with a gateway that blocks delete tool names. Ask the vendor or maintainers whether any operation is reversible, and confirm that your Discord backups or export process covers the channels the bot can reach.

Administrator invite bypasses overrides

The README offers an Administrator invite link with permissions set to 8 and calls it recommended for quick setup. Discord's permissions documentation says the ADMINISTRATOR permission bypasses channel permission overwrites, so a bot invited this way is not limited by the channel restrictions you set. The usual control is to invite the bot with the custom minimum-permissions link, or with a role that carries only the permissions the agent needs, and to exclude sensitive channels by denying the bot's role in them. Confirm that no installed bot in your server holds Administrator, because channel exclusions will not hold against it.

Permissions docs

No server-side audit log supplied

The sources supplied do not describe an audit log produced by the mcp-discord server itself. Discord's own audit log records changes made in the server, but it may not show which AI client, prompt or session triggered each action. The usual compensating control is host-side logging of every tool call, with the client identity, tool name, arguments and timestamp, shipped to a store your security team controls. Confirm what the server writes to standard output or files, whether arguments containing message text are logged in clear text, and how long the host retains those logs.

Community project without vendor support

The barryyip0625/mcp-discord server is a community project, not one published by Discord. It is MIT licensed, which permits internal use and modification, but no vendor support path, security advisory channel or service commitment is supplied. The usual control is a documented review: pin a specific commit or release, review the code paths for each tool, assign an internal owner for patches, and schedule a repeat review when the repository changes. Confirm who maintains the project, how vulnerabilities are reported, and whether your legal team accepts an unsupported dependency in the agent path.

Repository

Unknown retention on the MCP host

Message content, member lists and channel structure read by the server pass through the host running it and then into the AI client. The supplied sources do not state what the server caches, stores or retains, or what the connected AI client keeps. The usual control is to run the server on a host you manage, with a short-lived token store, no persistent message cache, and disk encryption, and to route client traffic through the approved client list. Confirm where the server writes data, the retention period of the AI client's conversation history, and whether the Message Content intent is needed for your use case.

Order of work before a Discord agent goes to production

This sequence turns a community Discord MCP server from an open-ended connection into a bounded one, with each permission, intent and tool choice decided and checked before any agent reaches a live community.

  1. Define allowed actions and channels

    The security or community owner, with the engineering lead, writes down which servers, channels and actions the agent may touch. Separate reading from posting, and list what is out of bounds, such as moderation, role changes, webhooks and channels holding member data or staff discussion. Done means a short written scope that names each tool family the team is willing to expose, and a list of excluded channels. Confirm the scope against the tool list in the mcp-discord README before you configure anything.

  2. Create a dedicated bot identity

    Create a separate Discord application and bot for the agent so its actions are attributable and revocable without affecting staff accounts or other integrations. Invite it with a custom link that requests only the permissions the scope in the previous step needs, rather than the Administrator option (permissions=8), which bypasses channel overwrites. Done means the bot appears in the server member list under its own name, and the invite link and granted permissions are recorded in your change log.

  3. Enable only the privileged intents the tools need

    Discord disables Message Content, Guild Members and Presence intents by default, and the mcp-discord prerequisites list all three as enabled. Enable each intent only if a chosen tool depends on it, and record the reason. Message Content covers message bodies, embeds, attachments and poll fields, so it is the most sensitive one to turn on. Done means a written table that maps each enabled intent to the specific tool that needs it, with unused intents switched off.

  4. Scope channel overrides and exclude sensitive channels

    Discord permissions are set through roles at guild level and can be overridden per channel. For each channel in scope, grant the bot only the permissions it needs, and deny access in every channel outside scope, including private, staff and member-data channels. Then check the effective permissions by opening each channel's settings with the bot's role selected. Done means you can show that the bot cannot read or post in any excluded channel, and that its permissions in in-scope channels match the written scope.

  5. Decide which tools the client may call

    In the MCP client, list every tool the server advertises and mark each as allowed, approval-required or blocked. Blocking is the default for role creation and editing, role assignment, channel and category deletion, permission override changes, and webhook creation or deletion, because these can change who sees and posts in the server. Done means a signed-off allowlist, and a check that the client shows only the allowed tools when the agent starts, so the policy is enforced by configuration rather than by instructions to the model.

  6. Test destructive tools in a disposable server

    Before any production use, run the agent against a throwaway Discord server that copies the real channel layout and roles but holds no real member data. Exercise each tool marked allowed or approval-required, including message deletion, channel deletion and permission changes, and confirm the bot's actual effect matches the scope. Include prompt injection tests, such as a message in an allowed channel that asks the agent to post or delete elsewhere. Done means a written test log with each result, plus a list of any tool that exceeded the scope and how it was blocked or removed.

What a security reviewer asks to see and where it comes from

This table lists what a reviewer should ask for before approving the community mcp-discord server, the evidence to request, and where each answer comes from. Read it as a checklist: the Discord permissions and privileged intent guides settle the bot questions, while the repository and the live deployment settle the rest.

Reviewer questionEvidence to requestSource
Which permission integer and invite link was used for the bot?The exact invite URL and its permissions value, with a note on whether Administrator (8) or a custom set was chosen. The README calls Administrator the recommended quick setup option.Discord permissions guide; mcp-discord README
Which privileged intents are enabled, and why is each needed?A written justification for Message Content, Server Members and Presence intents, tied to specific tools. Confirm each is disabled when no tool needs it.Discord privileged intent guide; mcp-discord README prerequisites
Which tools does the MCP client actually see?The tool list from the running server version, with each tool marked read, write or delete, and any tools disabled by configuration.mcp-discord README tool lists
Which channels and roles can the bot reach?A channel-by-channel permission export showing role assignments and overrides that apply to the bot's role.Discord permissions guide; server audit of roles
Where does the server run, and over which transport?Host location, whether it runs stdio locally or streamable HTTP on a server, network exposure, and who can reach the endpoint.mcp-discord README transports section
Which license and version of the community repository is deployed?The pinned commit or release tag in use, a copy of the MIT License text, and a record of who reviewed the code.mcp-discord repository on GitHub
Who approves destructive tools before an agent uses them?A written approval rule covering role deletion, channel deletion, permission overrides and webhook changes, plus the human sign-off step and logs.Organization policy; confirm with the deployment owner

Questions buyers ask before approving a Discord MCP server

Can the Discord MCP server be set to read-only?

The sources supplied for this review do not show a read-only mode in the mcp-discord server, so treat read-only as unconfirmed until you check. Review the repository's configuration options and tool list, then test the setup in a non-production Discord server and confirm that send, edit, delete, role and webhook tools are not reachable. The practical control that does not depend on the server is the bot's own permissions: a bot invited without send, manage roles, manage channels, manage webhooks or manage messages permissions cannot perform those actions in Discord, whatever the agent requests. Ask the vendor or maintainers to confirm in writing whether any read-only mode exists before you rely on one.

What does an Administrator invite change for a Discord bot?

An Administrator invite gives the bot every permission in the server and bypasses channel permission overwrites, so channel-level restrictions no longer limit it. The mcp-discord README lists an Administrator invite link (permissions=8) as recommended for quick setup. That speed comes at a cost: an agent that can reach the bot can also create or delete roles, change who sees each channel, and post or delete messages anywhere. For a production community, use the custom minimum-permissions link instead, which the README lists with permissions=52076489808, and then add only the permissions your chosen tools need. Confirm the exact effective permissions in the Discord developer portal and server role settings after invite, because the bitwise value is what Discord evaluates.

Does using a Discord bot require a paid Discord plan?

The sources supplied for this review do not state whether creating or running a bot requires a paid Discord plan, so confirm this with Discord directly before budgeting. Check Discord's current developer terms and account requirements, and confirm whether any feature you plan to use, such as privileged intents for large servers, carries a condition. Also confirm the hosting cost of the server process, which is paid to your cloud provider or data center, not to Discord. Ask the implementation partner to show these items as separate lines in the quote so you can see which costs are one-time setup and which recur.

What drives the effort of locking down a Discord MCP server?

Effort rises with four factors: how many Discord servers the bot joins, how many risky tools you keep enabled, how many privileged intents you turn on, and how the host running the server is hardened. Each server needs its own role design, channel overrides and invite review. Keeping destructive tools such as message deletion, role editing and webhook management means more testing of what an agent can do in each channel. Privileged intents for Message Content, Server Members and Presence are disabled by default in Discord, and each one you enable widens what the bot receives, so enable only what a specific tool needs. Host work covers secret storage for the bot token, network exposure if you use streamable HTTP, and logging. Ask for a quote that lists each server, each tool group you intend to keep and each intent separately.

Can our own team lock down the Discord bot without outside help?

Yes, your team can usually handle the permission and channel work without outside help. This includes creating a bot role with minimum permissions, using the custom invite link, applying channel permission overrides, disabling privileged intents you do not need, and keeping the bot out of channels that hold sensitive material. Discord documents permissions as set at guild level through roles and overridden per channel, so these are settings your admins can verify directly. Tool behavior is harder to confirm by reading. We recommend a security test of the running agent setup to check prompt injection, whether a tool can reach channels or actions it should not, and how the bot token is stored and rotated. Your team can run that test internally if it has the skills; an independent test is useful when a reviewer needs evidence.

What does a fixed-scope Discord MCP security review cover?

A fixed-scope review covers the agreed servers, tools and configurations, and the deliverables and timeline are set in writing before work starts. For this server, a DeployOpen AI agent rollout security review would test the setup for prompt injection, tool and file permissions, data exposure, credential handling, and the admin and permission settings in Discord. The output is a findings report with fixes and a retest after changes are made. Scope items to confirm in the written agreement include which Discord servers are in scope, which tools are tested, whether the test runs in a non-production server, and how the bot token is handled during testing. DeployOpen does not issue audit reports or certifications. If a compliance assessor needs formal attestation, that comes from an independent auditor.

How DeployOpen tests and locks down a Discord agent setup

DeployOpen approaches Discord MCP security as a written, fixed-scope review of what the bot token and permissions allow, which tools an agent can reach, and how the setup is locked down before staff connect it to an AI agent. The work covers the community mcp-discord server and the Discord application it depends on.

How we scope

  • Inventory the Discord server, bot application, invite link and the intents each one requests before any testing starts.
  • Agree in writing which tool groups are in scope, including message, role, channel permission and webhook tools.
  • Record which channels, roles and categories the bot must reach and which must stay outside its reach.

How we build

  • Test the server with tool calls that read, send, edit and delete messages to confirm what the agent can actually change.
  • Check whether the bot was invited with Administrator, which bypasses channel overwrites, and compare it with a minimum-permissions invite.
  • Review privileged intents, confirming Message Content, Server Members and Presence are enabled only where a documented need exists.

How we hand over

  • Deliver a findings report that ranks risky tools such as role edits, permission overrides and webhook changes by impact.
  • Provide lockdown steps for the bot role, channel overrides and tool exposure, and document each change made.
  • Run a retest after fixes so the client can confirm that the restricted setup behaves as the written scope describes.

How we support

  • Ongoing support, upgrades and continuous testing are available as retainers when the community server or Discord settings change.
  • Retests can be repeated when staff add new tools, channels or agent clients to the Discord setup.
  • Your security and compliance team keeps the written scope, findings and retest results as review evidence.

Sources and further reading

Talk to our team.

Tell us what you're working on, whether it's a deployment, an audit, a security test or a cyber range. You'll speak with an engineer who can help you scope it.

  • 30-minute call: free, with no obligation.
  • NDA on request: we can sign before you share details.
  • Clear next steps: a scope and plan after the call.