diff --git a/Dockerfile b/Dockerfile new file mode 100644 index 0000000..e36e464 --- /dev/null +++ b/Dockerfile @@ -0,0 +1,22 @@ +# Generated by https://smithery.ai. See: https://smithery.ai/docs/config#dockerfile +FROM node:lts-alpine + +# Set working directory +WORKDIR /app + +# Copy package files +COPY package.json package-lock.json ./ + +# Install dependencies without running scripts +RUN npm install --ignore-scripts + +# Copy source code +COPY . . + +# Build the TypeScript code +RUN npm run build + +# Expose any port if needed (Not required for stdio deployment) + +# Default command to run the MCP server +CMD ["node", "build/index.js"] diff --git a/README.md b/README.md index 0dd667c..dbed8bf 100644 --- a/README.md +++ b/README.md @@ -1,5 +1,4 @@ # MCP-Discord - [![smithery badge](https://smithery.ai/badge/@barryyip0625/mcp-discord)](https://smithery.ai/server/@barryyip0625/mcp-discord) A Discord MCP (Model Context Protocol) server that enables AI assistants to interact with the Discord platform. @@ -49,6 +48,15 @@ MCP-Discord provides the following Discord-related functionalities: ## Installation +### Installing via Smithery + +To install mcp-discord for Claude Desktop automatically via [Smithery](https://smithery.ai/server/@barryyip0625/mcp-discord): + +```bash +npx -y @smithery/cli install @barryyip0625/mcp-discord --client claude +``` + +### Manual Installation ```bash # Clone the repository git clone https://github.com/barryyip0625/mcp-discord.git @@ -151,4 +159,4 @@ npm run dev ## License -[MIT License](https://github.com/barryyip0625/mcp-discord?tab=MIT-1-ov-file) +MIT License diff --git a/smithery.yaml b/smithery.yaml new file mode 100644 index 0000000..643df1e --- /dev/null +++ b/smithery.yaml @@ -0,0 +1,23 @@ +# Smithery configuration file: https://smithery.ai/docs/config#smitheryyaml + +startCommand: + type: stdio + configSchema: + # JSON Schema defining the configuration options for the MCP. + type: object + required: + - discordToken + properties: + discordToken: + type: string + description: Discord bot token. Obtain this from the Discord Developer Portal. + commandFunction: + # A JS function that produces the CLI command based on the given config to start the MCP on stdio. + |- + (config) => ({ + command: 'node', + args: ['build/index.js'], + env: { DISCORD_TOKEN: config.discordToken } + }) + exampleConfig: + discordToken: YOUR_DISCORD_BOT_TOKEN