Allows AI agents to manage affiliate programs, including affiliates, referrals, conversions, and coupons via the Refgrow REST API.
Also known as refgrow/refgrow-mcp, refgrow-mcp, @refgrow/mcp
- Stars
- 2
- Tools
- 18
- Downloads, 30 days
- —
- Latest version
- 1.3.0
- Last commit
- Oct 29, 2026
- License
- —
What is Refgrow MCP?
Refgrow allows AI agents to manage affiliate programs, including affiliates, referrals, conversions, and coupons via the Refgrow REST API. It exposes 18 tools, such as list_affiliates, get_affiliate_details, create_affiliate.
Summary generated from the project's README
About Refgrow MCP server
Managing affiliate programs through an AI agent is what this server enables for developers and program managers. By wrapping the Refgrow REST API, it allows compatible clients like Claude Desktop, Cursor, and Claude Code to interact directly with your affiliate data. Users can perform administrative tasks such as tracking conversions, managing coupons, and overseeing affiliate performance without leaving their coding or chat environment.
To use this server, you must provide a Refgrow API key starting with the rgk_ prefix via the REFGROW_API_KEY environment variable. You can also specify a custom REFGROW_API_URL if you are not using the default instance. The server provides specific tools for handling different aspects of your program, including list_affiliates for viewing performance stats, create_coupon for generating affiliate-linked codes, and update_conversion for marking transactions as paid. This setup turns your AI client into a functional dashboard for your entire referral ecosystem.
What you can do with it
- 1Monitor affiliate performanceAsk your AI to retrieve a list of all affiliates along with their specific clicks, signups, and total earnings.
- 2Manage conversion recordsInstruct the agent to find and update specific conversion entries, such as marking a purchase as paid.
- 3Generate new affiliate couponsHave the AI create a new coupon code that is specifically linked to a particular affiliate.
- 4Onboard new partnersUse the agent to register a new affiliate in the system with a custom referral code.
Written from the project's README. Every use case is checked against a quote from it.
How to install Refgrow MCP
Formats verified 10 Nov 2026Add to CursorAdd to GooseInstall Refgrow MCP in Claude Code
$ claude mcp add --env 'REFGROW_API_KEY=<YOUR_REFGROW_API_KEY>' refgrow-mcp -- npx -y @refgrow/mcpInstall Refgrow MCP in Cursor
~/.cursor/mcp.json
{
"mcpServers": {
"refgrow-mcp": {
"command": "npx",
"args": [
"-y",
"@refgrow/mcp"
],
"env": {
"REFGROW_API_KEY": "<YOUR_REFGROW_API_KEY>"
}
}
}
}Install Refgrow MCP in VS Code
.vscode/mcp.json
{
"servers": {
"refgrow-mcp": {
"type": "stdio",
"command": "npx",
"args": [
"-y",
"@refgrow/mcp"
],
"env": {
"REFGROW_API_KEY": "<YOUR_REFGROW_API_KEY>"
}
}
}
}Install Refgrow MCP in VS Code CLI
$ code --add-mcp '{"name":"refgrow-mcp","type":"stdio","command":"npx","args":["-y","@refgrow/mcp"],"env":{"REFGROW_API_KEY":"<YOUR_REFGROW_API_KEY>"}}'Install Refgrow MCP in Claude Desktop
claude_desktop_config.json
{
"mcpServers": {
"refgrow-mcp": {
"command": "npx",
"args": [
"-y",
"@refgrow/mcp"
],
"env": {
"REFGROW_API_KEY": "<YOUR_REFGROW_API_KEY>"
}
}
}
}Install Refgrow MCP in Codex
$ codex mcp add refgrow-mcp --env 'REFGROW_API_KEY=<YOUR_REFGROW_API_KEY>' -- npx -y @refgrow/mcpInstall Refgrow MCP in Codex config.toml
~/.codex/config.toml
[mcp_servers.refgrow-mcp] command = "npx" args = ["-y", "@refgrow/mcp"] [mcp_servers.refgrow-mcp.env] REFGROW_API_KEY = "<YOUR_REFGROW_API_KEY>"
Install Refgrow MCP in Gemini CLI
$ gemini mcp add -s user -e 'REFGROW_API_KEY=<YOUR_REFGROW_API_KEY>' refgrow-mcp npx -- -y @refgrow/mcpInstall Refgrow MCP in Gemini settings.json
~/.gemini/settings.json
{
"mcpServers": {
"refgrow-mcp": {
"command": "npx",
"args": [
"-y",
"@refgrow/mcp"
],
"env": {
"REFGROW_API_KEY": "<YOUR_REFGROW_API_KEY>"
}
}
}
}Refgrow MCP tools 18
Detected from the READMElist_affiliatesget_affiliate_detailscreate_affiliateupdate_affiliatedelete_affiliatelist_referralsget_referral_detailscreate_referrallist_conversionsget_conversioncreate_conversionupdate_conversion
| list_affiliates | — | |
| get_affiliate_details | — | |
| create_affiliate | — | |
| update_affiliate | — | |
| delete_affiliate | — | |
| list_referrals | — | |
| get_referral_details | — | |
| create_referral | — | |
| list_conversions | — | |
| get_conversion | — | |
| create_conversion | — | |
| update_conversion | — |
Show all 18 toolsShow fewer tools
delete_conversionlist_couponsget_couponcreate_couponupdate_coupondelete_coupon
| delete_conversion | — | |
| list_coupons | — | |
| get_coupon | — | |
| create_coupon | — | |
| update_coupon | — | |
| delete_coupon | — |
Configuration
REFGROW_API_KEYRequiredSecretYour Refgrow API key (starts with rgk_)
REFGROW_API_URLRefgrow API base URL
| Name | Description | |
|---|---|---|
| REFGROW_API_KEY | Your Refgrow API key (starts with rgk_) | RequiredSecret |
| REFGROW_API_URL | Refgrow API base URL |
Automated checks
Ran Nov 13, 2026Full report →Passed our automated checks. That is not a security audit: read the code and give the server the narrowest access it needs. How checks work · What to fix for more points
- Source repository linked and reachablePass
- Open source license (OSI)No licenseFinding
- Commit or release in the last yearPass
- Package name not close to a popular packagePass
- Remote endpoint uses HTTPSNot checked
- Destructive tools are labelledNot checked
- No hidden instructions to the modelPass
- No critical advisory in the package or its dependenciesPass
README
View on GitHub@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
npm install @refgrow/mcp
Or clone and build from source:
git clone https://github.com/refgrow/refgrow-mcp.git
cd refgrow-mcp
npm install
npm run build
Configuration
The server requires two environment variables:
| Variable | Required | Default | Description |
|---|---|---|---|
REFGROW_API_KEY |
Yes | -- | Your Refgrow API key (starts with rgk_) |
REFGROW_API_URL |
No | https://refgrow.com |
Base URL of your Refgrow instance |
Getting an API Key
- Log in to Refgrow
- Go to your project settings
- Scroll to the API Keys section
- Click Generate API Key
- 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
{
"mcpServers": {
"refgrow": {
"command": "npx",
"args": ["-y", "@refgrow/mcp"],
"env": {
"REFGROW_API_KEY": "rgk_your_api_key_here"
}
}
}
}
Or if installed globally / from source:
{
"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:
{
"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:
{
"mcpServers": {
"refgrow": {
"command": "npx",
"args": ["-y", "@refgrow/mcp"],
"env": {
"REFGROW_API_KEY": "rgk_your_api_key_here"
}
}
}
}
Available Tools
Affiliates
| Tool | Description |
|---|---|
list_affiliates |
List all affiliates with stats (clicks, signups, purchases, earnings) |
get_affiliate_details |
Get details for a specific affiliate by email |
create_affiliate |
Create a new affiliate with optional custom referral code |
update_affiliate |
Update affiliate email, referral code, status, or partner slug |
delete_affiliate |
Remove an affiliate from the project |
Referrals
| Tool | Description |
|---|---|
list_referrals |
List referred users, filterable by affiliate or status |
get_referral_details |
Get details for a specific referred user by email |
create_referral |
Manually create a referred user record |
Conversions
| Tool | Description |
|---|---|
list_conversions |
List conversions with filters for type, affiliate, date range, paid status |
get_conversion |
Get a specific conversion by ID |
create_conversion |
Create a conversion (signup/purchase) with auto-commission calculation |
update_conversion |
Update conversion details or mark as paid |
delete_conversion |
Delete a conversion record |
Coupons
| Tool | Description |
|---|---|
list_coupons |
List coupon codes with affiliate info |
get_coupon |
Get a specific coupon by ID |
create_coupon |
Create a coupon linked to an affiliate (with optional Stripe/LemonSqueezy IDs) |
update_coupon |
Update coupon details |
delete_coupon |
Delete 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 partner@example.com 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 old-partner@example.com"
Development
# Install dependencies
npm install
# Build
npm run build
# Watch mode for development
npm 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
Refgrow MCP questions
How do I add Refgrow MCP to Claude Code?
Run claude mcp add --env 'REFGROW_API_KEY=<YOUR_REFGROW_API_KEY>' refgrow-mcp -- npx -y @refgrow/mcp in your terminal. Add --scope user to make it available in every project.
How do I add Refgrow MCP to Cursor?
Open ~/.cursor/mcp.json and add the server under mcpServers, using the Cursor config shown in the install section above.
What tools does Refgrow MCP provide?
It exposes 18 tools, including list_affiliates, get_affiliate_details, create_affiliate, update_affiliate, delete_affiliate.
What environment variables are required?
The server requires the REFGROW_API_KEY environment variable, which must start with 'rgk_'.