Refgrow

io.github.refgrow由 GitHub 账号 refgrow 发布v1.3.0更新于 Oct 29, 2026

Model Context Protocol server for Refgrow affiliate program management API

已验证STDIO仅桌面金融商业与电商

概览

AI 生成的概览

封装 Refgrow 联盟计划 API,让助手可在对话中管理联盟成员、推荐、转化和优惠券。

可以做什么
  • 列出、查看、创建、更新和删除联盟成员,包括推荐码和合作方标识
  • 列出并查询被推荐用户,也可手动创建推荐记录
  • 列出、查看、创建、更新和删除转化记录,包括标记为已付款
  • 列出、查看、创建、更新和删除优惠券,可关联联盟成员及 Stripe 或 LemonSqueezy
适用场景
适合在 Refgrow 上运营联盟计划、希望直接查询收益、注册量和未付款转化,或完成新增合作方、创建优惠券、标记转化已付款等日常操作而无需打开后台的场景。
运行要求
通过 npm 包 @refgrow/mcp 以 stdio 在本地运行,需要 Node.js 18 及以上。需要 Refgrow 账号及以 rgk_ 开头的 API 密钥,通过环境变量 REFGROW_API_KEY 提供;REFGROW_API_URL 可覆盖 API 基础地址。需能访问 Refgrow API 的网络。
安装前请注意
REFGROW_API_KEY 中的密钥可访问你的联盟计划数据,且生成时仅显示一次。工具可创建、更新和删除联盟成员、转化与优惠券,并可把转化标记为已付款;删除优惠券可能同时从 Stripe 中移除。执行删除或付款相关操作前应先确认。

安装

在 SourceWeft 中

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

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

其他 MCP 客户端

参照 仓库 中的启动说明。

README

@refgrow/mcp

A Model Context Protocol (MCP) server that wraps the Refgrow REST API. This allows AI agents -- Claude Desktop, Cursor, ChatGPT, and other MCP-compatible clients -- to manage your affiliate program directly.

Prerequisites

  • Node.js 18+
  • A Refgrow account with an API key (generated in project settings)
  • API keys start with rgk_

Installation

bash
npm install @refgrow/mcp

Or clone and build from source:

bash
git clone https://github.com/refgrow/refgrow-mcp.gitcd refgrow-mcpnpm installnpm run build

Configuration

The server requires two environment variables:

VariableRequiredDefaultDescription
REFGROW_API_KEYYes--Your Refgrow API key (starts with rgk_)
REFGROW_API_URLNohttps://refgrow.comBase URL of your Refgrow instance

Getting an API Key

  1. Log in to Refgrow
  2. Go to your project settings
  3. Scroll to the API Keys section
  4. Click Generate API Key
  5. Copy the key (it starts with rgk_ and is shown only once)

Usage with Claude Desktop

Add this to your Claude Desktop config file:

macOS: ~/Library/Application Support/Claude/claude_desktop_config.json Windows: %APPDATA%\Claude\claude_desktop_config.json

json
{  "mcpServers": {    "refgrow": {      "command": "npx",      "args": ["-y", "@refgrow/mcp"],      "env": {        "REFGROW_API_KEY": "rgk_your_api_key_here"      }    }  }}

Or if installed globally / from source:

json
{  "mcpServers": {    "refgrow": {      "command": "node",      "args": ["/path/to/packages/mcp-server/dist/index.js"],      "env": {        "REFGROW_API_KEY": "rgk_your_api_key_here"      }    }  }}

Usage with Cursor

In Cursor settings, add an MCP server with:

  • Name: refgrow
  • Command: npx -y @refgrow/mcp
  • Environment: REFGROW_API_KEY=rgk_your_api_key_here

Or add to .cursor/mcp.json in your project root:

json
{  "mcpServers": {    "refgrow": {      "command": "npx",      "args": ["-y", "@refgrow/mcp"],      "env": {        "REFGROW_API_KEY": "rgk_your_api_key_here"      }    }  }}

Usage with Claude Code

Add to your project's .mcp.json:

json
{  "mcpServers": {    "refgrow": {      "command": "npx",      "args": ["-y", "@refgrow/mcp"],      "env": {        "REFGROW_API_KEY": "rgk_your_api_key_here"      }    }  }}

Available Tools

Affiliates

ToolDescription
list_affiliatesList all affiliates with stats (clicks, signups, purchases, earnings)
get_affiliate_detailsGet details for a specific affiliate by email
create_affiliateCreate a new affiliate with optional custom referral code
update_affiliateUpdate affiliate email, referral code, status, or partner slug
delete_affiliateRemove an affiliate from the project

Referrals

ToolDescription
list_referralsList referred users, filterable by affiliate or status
get_referral_detailsGet details for a specific referred user by email
create_referralManually create a referred user record

Conversions

ToolDescription
list_conversionsList conversions with filters for type, affiliate, date range, paid status
get_conversionGet a specific conversion by ID
create_conversionCreate a conversion (signup/purchase) with auto-commission calculation
update_conversionUpdate conversion details or mark as paid
delete_conversionDelete a conversion record

Coupons

ToolDescription
list_couponsList coupon codes with affiliate info
get_couponGet a specific coupon by ID
create_couponCreate a coupon linked to an affiliate (with optional Stripe/LemonSqueezy IDs)
update_couponUpdate coupon details
delete_couponDelete a coupon (also removes from Stripe if linked)

Example Conversations

Once connected, you can ask your AI agent things like:

  • "Show me all active affiliates and their earnings"
  • "Create a new affiliate for [email protected] with referral code PARTNER2025"
  • "List all unpaid conversions from the last 30 days"
  • "How many signups did we get through affiliate referrals this month?"
  • "Create a coupon code SAVE20 linked to affiliate ID 42"
  • "Mark conversion #123 as paid"
  • "Deactivate the affiliate with email [email protected]"

Development

bash
# Install dependenciesnpm install
# Buildnpm run build
# Watch mode for developmentnpm run dev
# Run the server (requires REFGROW_API_KEY env var)REFGROW_API_KEY=rgk_your_key npm start

Documentation

Full setup guide with examples and troubleshooting: https://refgrow.com/docs/mcp-server

REST API reference (for direct HTTP integration): https://refgrow.com/docs/api-reference

License

MIT

来源:README.md,提交 7b4fae2

工具

0
SourceWeft 曾在隔离沙箱中以无凭据方式启动该软件包一次,以列出其工具,但未能完成:服务器未能启动。

版本历史

2
  1. v1.3.0最新Oct 29, 2026
  2. v1.0.3Sep 16, 2026

评分

已满足适用检查项的 40%

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

  • 近 30 天内可连通25 分

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

  • 已声明认证方式10 分

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

  • 已列出工具15 分

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

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

    请在仓库或注册中心条目中声明许可证。