Skip to main content
Glama

reddit-mcp-server

Reddit MCP 服务器⚙️

模型上下文协议 (MCP) 提供用于获取和创建 Reddit 内容的工具。

图像

🧑‍💻 关于

https://www.linkedin.com/feed/update/urn:li:activity:7328864060534419457/

图像

🔧 可用工具(功能)

只读工具(客户端凭证):

  • get_user_info(username) -获取详细的用户分析和参与度洞察

  • get_top_posts(subreddit, time_filter, limit) - 获取并分析热门帖子

  • get_subreddit_stats(subreddit) - 获取全面的 subreddit 分析

  • get_trending_subreddits() - 获取热门 subreddits 列表

读写工具(用户凭证):

  • create_post(subreddit, title, content, flair, is_self) - 创建优化帖子

  • reply_to_post(post_id, content, subreddit) - 添加包含参与度洞察的回复

  • reply_to_comment(comment_id, content, subreddit) - 添加策略性回复

🔌 安装

  1. git clone https://github.com/alexandros-lekkas/reddit-mcp-server

  2. 在此创建 Reddit 应用程序

图像

确保选择“脚本”!

  1. 复制客户端 ID 和客户端密钥

  2. 根据.env.example创建.env文件

使用您的REDDIT_CLIENT_IDREDDIT_CLIENT_SECRET执行此操作

如果您想写帖子,您需要包含您的REDDIT_USERNAMEREDDIT_PASSWORD (不用担心,我不会窃取它们😜)

  1. 使用npm run dev运行并打开检查服务器( http://127.0.0.1:6274/

图像

  1. 如果连接正常,请将其添加到您的 MCP 配置中(对于 Cursor 或 Claude,取决于您使用的代理)

"mcpServers": { "reddit": { "command": "node", "args": [ "C:\\path\\to\\reddit-mcp-server\\build\\index.js" // Replace this with your local path to build/index.js ], "env": { "REDDIT_CLIENT_ID": "😜", "REDDIT_CLIENT_SECRET": "😜", "REDDIT_USERNAME": "😜", "REDDIT_PASSWORD": "😜" }, "autoApprove": [ "get_reddit_post", "get_top_posts", "get_user_info", "get_subreddit_info", "get_trending_subreddits", "create_post", "reply_to_post" ] // You don't need to add this, but it makes it so that you don't have to keep clicking approve } }

(确保用实际密钥替换环境变量,而不是😜表情符号)

📚 致谢

  • 这些工具的灵感和实现,均由 Arindam200 开发的Python Reddit MCP Server提供。目前,该仓库只是 Python 实现的 Node.js 移植版本。

  • 感谢Eugene Sh提供的关于如何构建 MCP 服务器的教程(该教程可作为此实现的参考)。

-
security - not tested
A
license - permissive license
-
quality - not tested

local-only server

The server can only run on the client's local machine because it depends on local resources.

reddit-mcp-服务器

  1. 🧑‍💻 关于
    1. 🔧 可用工具(功能)
      1. 🔌 安装
        1. 📚 致谢

          Related MCP Servers

          • -
            security
            A
            license
            -
            quality
            MCP server that enables interaction with Reddit, allowing users to read trending posts, analyze discussions, create posts, add comments, and vote on content through Claude and Cursor.

          View all related MCP servers

          MCP directory API

          We provide all the information about MCP servers via our MCP API.

          curl -X GET 'https://glama.ai/api/mcp/v1/servers/alexandros-lekkas/reddit-mcp-server'

          If you have feedback or need assistance with the MCP directory API, please join our Discord server