Reddit Ads MCP

io.github.mkerchenski由 GitHub 账号 mkerchenski 发布v1.1.1更新于 Oct 24, 2026

MCP server for the Reddit Ads API. List accounts, campaigns, ads, and pull reports.

已验证STDIO仅桌面数据与分析商业与电商

概览

AI 生成的概览

以只读方式访问 Reddit Ads API,让助手列出广告账户、广告系列、广告组、广告并获取效果报告。

可以做什么
这是一个本地运行的 C# MCP 服务器,封装 Reddit Ads API,只提供只读工具。包含 ListAccounts、ListCampaigns、ListAdGroups、ListAds、GetPerformanceReport(可自定义日期范围、字段和细分)以及 GetDailyPerformance,用于获取最近 N 天的展示量、点击量、花费、CTR、CPC 和 eCPM。所有工具都接受可选的 accountId 参数,省略时使用 REDDIT_ACCOUNT_ID 指定的默认账户。
适用场景
适合让助手在不打开广告后台的情况下查看 Reddit 广告结构或汇总广告系列效果。适用于围绕账户、广告系列、广告组和广告的报告与核查类问题;它不会创建或修改任何内容。
运行要求
通过 stdio 在本地运行,需 .NET 10(dotnet tool install -g RedditAdsMcp)或从源码构建。需要一个拥有有效 Reddit Ads 广告主账户的 Reddit 账号、一个 Reddit Ads API 应用,以及环境变量 REDDIT_CLIENT_ID、REDDIT_CLIENT_SECRET、REDDIT_REFRESH_TOKEN 和 REDDIT_ACCOUNT_ID。需要访问 Reddit Ads API 的网络连接。
安装前请注意
需要以环境变量形式提供密钥 REDDIT_CLIENT_SECRET 和 REDDIT_REFRESH_TOKEN,以及 REDDIT_CLIENT_ID 和 REDDIT_ACCOUNT_ID。刷新令牌在被撤销前长期有效,应按长期凭证对待。配置过程涉及公开的 HTTPS 重定向 URI;README 建议使用由包作者维护的回调页面来显示授权码,并说明也可以改用你自己控制的任意 HTTPS 地址。

安装

在 SourceWeft 中

  1. 打开 控制台中的 Reddit Ads MCP,将其添加到工作区。
  2. 为需要使用其工具的对话启用该服务。

Desktop only,通过 STDIO。 STDIO 服务会启动本地进程,因此需要 SourceWeft 桌面宿主。

其他 MCP 客户端

参照 仓库 中的启动说明。

README

RedditAdsMcp

[NuGet] [Build]

A C# MCP (Model Context Protocol) server for the Reddit Ads API. Provides read-only tools for listing accounts, campaigns, ad groups, ads, and pulling performance reports.

Built with .NET 10 and the official ModelContextProtocol SDK.

Available Tools

ToolDescription
ListAccountsList all Reddit ad accounts accessible with current credentials
ListCampaignsList campaigns for an account
ListAdGroupsList ad groups, optionally filtered by campaign
ListAdsList ads, optionally filtered by ad group
GetPerformanceReportGet a performance report with custom date range, fields, and breakdowns
GetDailyPerformanceConvenience wrapper — last N days of impressions, clicks, spend, CTR, CPC, eCPM

All tools accept an optional accountId parameter. If omitted, the default account from REDDIT_ACCOUNT_ID is used.

Prerequisites

  1. A Reddit account with an active Reddit Ads advertiser account
  2. .NET 10 SDK

Install

Option A: Install as a dotnet tool (recommended)

bash
dotnet tool install -g RedditAdsMcp

Then configure Claude Code (see Step 5b below).

Option B: Clone and build from source

bash
git clone https://github.com/mkerchenski/RedditAdsMcp.gitcd RedditAdsMcpdotnet build

Then configure Claude Code (see Step 5a below).

Setup

1. Create a Reddit Ads API App

  1. Go to ads.reddit.com
  2. In the left sidebar, click Developer Applications (under your account/business settings)
  3. Click Create a new app and fill in:
FieldValue
App nameReddit Ads MCP
DescriptionMCP server for Reddit Ads reporting
About urlhttps://github.com/mkerchenski/RedditAdsMcp (or leave blank)
Redirect URIhttps://hurrah.dev/oauth/reddit

Reddit requires a public HTTPS redirect URI (localhost won't work). The URL above is a simple callback page maintained by the package author that displays the authorization code for you to copy — it does not store any data. You can use any HTTPS URL you control instead; just update the redirect URI in Steps 2–3 to match.

  1. Click Create app
  2. Copy your App ID and Secret — you'll need both in the next steps

2. Authorize the App

Open this URL in your browser, replacing YOUR_APP_ID with the App ID from Step 1:

https://www.reddit.com/api/v1/authorize?client_id=YOUR_APP_ID&response_type=code&state=mcp&redirect_uri=https%3A%2F%2Fhurrah.dev%2Foauth%2Freddit&duration=permanent&scope=adsread

Click Allow. You'll be redirected to a page that displays your authorization code — click Copy.

3. Exchange the Code for a Refresh Token

Run this command, replacing the three placeholders with your App ID, Secret, and authorization code:

bash
curl -X POST https://www.reddit.com/api/v1/access_token \  -u "YOUR_APP_ID:YOUR_SECRET" \  -A "ads-mcp/1.0" \  -d "grant_type=authorization_code&code=YOUR_AUTHORIZATION_CODE&redirect_uri=https://hurrah.dev/oauth/reddit"

The redirect_uri must match exactly what you entered in Step 1.

The response JSON contains a refresh_token field. Save it — it's permanent until revoked.

4. Find Your Account ID

  1. Go to ads.reddit.com and click All accounts (top-left dropdown)
  2. Select your business on the left — your ad account appears on the right
  3. The account ID is the value under the account name (e.g. a2_eaf73mplhhps)

5a. Configure Claude Code (from source)

Add to your Claude Code MCP settings (.mcp.json in your project, or ~/.claude/settings.json), replacing the four placeholder values:

json
"reddit-ads": {  "type": "stdio",  "command": "dotnet",  "args": ["run", "--project", "/path/to/RedditAdsMcp", "--no-build"],  "env": {    "REDDIT_CLIENT_ID": "your_app_id",    "REDDIT_CLIENT_SECRET": "your_secret",    "REDDIT_REFRESH_TOKEN": "your_refresh_token",    "REDDIT_ACCOUNT_ID": "your_account_id"  }}

5b. Configure Claude Code (dotnet tool)

json
"reddit-ads": {  "type": "stdio",  "command": "reddit-ads-mcp",  "env": {    "REDDIT_CLIENT_ID": "your_app_id",    "REDDIT_CLIENT_SECRET": "your_secret",    "REDDIT_REFRESH_TOKEN": "your_refresh_token",    "REDDIT_ACCOUNT_ID": "your_account_id"  }}

Verify with /mcp in Claude Code — the reddit-ads server should appear with 6 tools.

Development

bash
dotnet build    # compiledotnet run      # start MCP server on stdiodotnet pack     # create NuGet package

License

MIT

来源:README.md,提交 fe7288a

工具

0
SourceWeft 尚未在沙箱中启动过该软件包,因此其工具未知。

版本历史

1
  1. v1.1.1最新Sep 16, 2026

评分

已满足适用检查项的 50%

该评分衡量此收录条目的完整程度,依据注册中心条目、端点与公开来源计算得出。它不是对服务器本身的评价,也不表示服务器安全或当前可用:可连通性是带日期的检查结果,评分也不包含安装量或用户评价。

  • 近 30 天内可连通25 分

    请保持端点能够响应 MCP 握手;SourceWeft 每 30 天探测一次。

  • 已声明认证方式10 分

    请在注册中心条目中声明凭据请求头,或保持端点能够响应探测,以便判定其认证方式。

  • 已列出工具15 分

    请让服务器在无凭据时响应 tools/list,或发布可在沙箱中无凭据启动的软件包。

  • 描述必需15 分
  • 图标10 分
  • 文档15 分
  • 许可证10 分