npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@buzzicra/discord-mcp

v1.0.0

Published

Discord MCP server for Claude Code - Control Discord bots via Model Context Protocol

Downloads

29

Readme

Discord MCP Server

A Model Context Protocol (MCP) server that exposes Discord bot capabilities to Claude.

Features

  • 26 tools covering messaging, channels, servers, members, roles, and moderation
  • Full Discord.js v14 integration
  • TypeScript with strict typing

Prerequisites

  1. Node.js 18+
  2. Discord Bot Token - Create a bot at Discord Developer Portal

Bot Permissions

Your Discord bot needs these permissions:

  • Read Messages/View Channels
  • Send Messages
  • Manage Messages
  • Add Reactions
  • Manage Channels (for channel operations)
  • Kick Members
  • Ban Members
  • Moderate Members (for timeouts)
  • Manage Roles

Required Intents

Enable these Privileged Gateway Intents in the Discord Developer Portal:

  • Server Members Intent
  • Message Content Intent

Installation

# Clone or navigate to the directory
cd discord_mcp

# Install dependencies
npm install

# Build
npm run build

Configuration

Environment Variable

Set DISCORD_BOT_TOKEN in your environment:

export DISCORD_BOT_TOKEN="your-bot-token"

Claude Code MCP Config

Add to your ~/.claude.json or project's .mcp.json:

{
  "mcpServers": {
    "discord": {
      "command": "node",
      "args": ["/path/to/discord_mcp/dist/index.js"],
      "env": {
        "DISCORD_BOT_TOKEN": "your-bot-token"
      }
    }
  }
}

Available Tools

Messaging (6 tools)

| Tool | Description | |------|-------------| | send_message | Send a message to a channel | | get_messages | Get recent messages from a channel | | edit_message | Edit an existing message | | delete_message | Delete a message | | add_reaction | Add reaction to a message | | reply_to_message | Reply to a specific message |

Channels (5 tools)

| Tool | Description | |------|-------------| | list_channels | List all channels in a server | | get_channel | Get channel details | | create_channel | Create a new channel | | delete_channel | Delete a channel | | update_channel | Update channel settings |

Server (3 tools)

| Tool | Description | |------|-------------| | get_server_info | Get server details | | list_servers | List all servers the bot is in | | get_server_stats | Get server statistics |

Members (4 tools)

| Tool | Description | |------|-------------| | list_members | List server members | | get_member | Get member details | | search_members | Search members by username | | get_member_roles | Get roles for a member |

Roles (4 tools)

| Tool | Description | |------|-------------| | list_roles | List all server roles | | add_role | Add role to member | | remove_role | Remove role from member | | create_role | Create a new role |

Moderation (4 tools)

| Tool | Description | |------|-------------| | kick_member | Kick a member from server | | ban_member | Ban a member from server | | unban_member | Unban a user | | timeout_member | Timeout a member |

Usage Examples

Once configured, you can use natural language with Claude:

  • "List all the servers my Discord bot is in"
  • "Send a message to channel 123456789 saying 'Hello!'"
  • "Get the last 10 messages from channel 123456789"
  • "Create a new text channel called 'announcements' in server 987654321"
  • "Timeout user 111222333 for 10 minutes"

Development

# Watch mode for development
npm run dev

# Type checking
npm run typecheck

Troubleshooting

"DISCORD_BOT_TOKEN environment variable is required"

Make sure you've set the token in your MCP config or environment.

"Missing Access" errors

Check that your bot has the required permissions and intents enabled.

Bot not responding to channel operations

Ensure the bot has access to the specific channel and server.

License

MIT