Skip to content

Verify a Gateway notification

Gateway mode can turn selected Discord events into MCP notifications/resources/updated signals. The current implementation is useful for experiments, but it is not a complete live-resource system: the URI patterns are not returned by resources/list, cannot be fetched with resources/read, and the server advertises subscription capability even when Gateway mode is inactive.

Subscription URISignal source
discord://guild/{guild_id}/infoGuild update
discord://guild/{guild_id}/members/onlinePresence update, debounced
discord://channel/{channel_id}/typingTyping start, debounced
discord://voice/{guild_id}/stateVoice state update
discord://guild/{guild_id}/audit-log/recentAudit-log polling fallback

These URIs are notification keys, not readable resource documents.

  1. Install Gateway support with the CLI.

    Terminal window
    npm install -g @discord-mcp/cli discord.js

    discord.js must be resolvable from the same installation as the CLI.

  2. Enable required intents.

    The Gateway client requests Guilds, Guild Voice States, and Guild Presences. Enable the Presence intent for the bot in the Developer Portal when testing online-member signals.

  3. Start with Gateway mode.

    Terminal window
    discord-mcp serve --gateway

    In normal client use, add --gateway to the generated server arguments. If Gateway startup fails, discord-mcp logs a warning and continues REST-only; confirm the log before proceeding.

  4. Subscribe through a capable MCP client.

    Use an exact URI containing the real Discord ID:

    {
    "method": "resources/subscribe",
    "params": {
    "uri": "discord://voice/111122223333444455/state"
    }
    }
  5. Trigger and observe one event.

    Join or leave a voice channel in the test guild. A working path emits:

    {
    "method": "notifications/resources/updated",
    "params": {
    "uri": "discord://voice/111122223333444455/state"
    }
    }

    The notification contains the URI only. Use a matching REST tool to fetch current state if your workflow needs data after the signal.

  6. Unsubscribe when finished.

    {
    "method": "resources/unsubscribe",
    "params": {
    "uri": "discord://voice/111122223333444455/state"
    }
    }

For a client without subscriptions-or until this feature is hardened-poll the narrowest read-only Discord tool at a conservative interval and respect rate limits. Keep event-driven and polling paths behind the same application interface so the transport choice can change.

See Client compatibility, Gateway architecture, and Troubleshooting.