MCP Server
The Memberstack MCP (Model Context Protocol) Server connects AI tools like Claude directly to your Memberstack projects. This enables you to use natural language to interact with your members, subscription plans, data tables, and gated content.
The Memberstack MCP Server is currently in beta. Features and functionality may change based on user feedback. Please report any issues or suggestions to our support team.
What Can You Do with the MCP Server?
Manage Members
Create, update, search, and export member data in both LIVE and SANDBOX environments.
Work with Data Tables
Build custom database structures, define fields, and manage records using natural language.
Configure Plans
Set up pricing, access rules, and logic for your subscription tiers.
Control Gated Content
Define which URLs are protected and which plans grant access.
Search Knowledge
Perform semantic searches across Memberstack's documentation, guides, and resources.
Switch Contexts
Seamlessly move between multiple apps and toggle between SANDBOX and LIVE environments.
The MCP server provides approximately 68 specialized tools that understand the Memberstack data model, handle multi-project contexts, and respect environment boundaries.
Installation & Setup
Prerequisites
- An MCP-compatible client (e.g., Claude Code, Cursor, Codex, Claude Desktop, Cline)
- An active Memberstack account with dashboard access
- Node.js installed on your machine to use the
npxcommand
Step 1: Configure Your Client
Find your AI client below and follow the instructions to register the Memberstack MCP Server.
claude mcp add memberstack --scope user npx mcp-remote https://mcp.memberstack.com/mcpcodex mcp add memberstack -- npx mcp-remote https://mcp.memberstack.com/mcp{
"mcpServers": {
"memberstack": {
"command": "npx",
"args": [ "mcp-remote", "https://mcp.memberstack.com/mcp" ]
}
}
}{
"mcpServers": {
"memberstack": {
"command": "npx",
"args": [ "mcp-remote", "https://mcp.memberstack.com/mcp" ]
}
}
}{
"mcpServers": {
"memberstack": {
"command": "npx",
"args": [ "mcp-remote", "https://mcp.memberstack.com/mcp" ]
}
}
}mcpServers:
memberstack:
command: npx
args:
- mcp-remote
- https://mcp.memberstack.com/mcpClaude Code: The --scope user flag makes the server available globally across all your projects.
Cursor: Check Cursor's documentation for the exact location of the MCP configuration file.
Claude Desktop: On macOS, the config file is typically located at ~/Library/Application Support/Claude/claude_desktop_config.json.
Other clients: Add the JSON configuration to your client's mcpServers configuration, or use YAML if your client uses it (like some Continue.dev setups).
Step 2: Authenticate with Memberstack
- After configuring your client, start a new conversation.
- Your client will detect the new server and prompt you to authenticate. A browser window will open.
- Log in with your Memberstack dashboard credentials to authorize the connection.
The server uses OAuth 2.1 with PKCE. Your credentials are never shared with the AI client; authentication happens directly with Memberstack.
Step 3: Verify the Connection
Test your connection by asking your AI assistant:
"List my Memberstack apps"
The assistant should use the listApps tool and show you the Memberstack projects you have access to.
Core Concepts
Apps (Projects)
An App in Memberstack is a complete project or workspace. It contains its own members, plans, data tables, and settings. You must select an app context before performing most operations.
Key Tools: listApps, switchApp, currentApp
Environments (LIVE vs. SANDBOX)
Each app has two isolated environments:
SANDBOX
- A free testing environment for development.
- Uses Stripe test data.
- Does not affect your live members or charge real payments.
LIVE
- The production environment with real members and payments.
- Requires a paid Memberstack subscription for most features.
Always verify your active environment to avoid accidentally modifying production data. Ask "What is my current environment?"
Key Tools: getMemberstackEnvironment, switchMemberstackEnvironment
Authentication & Sessions
After you authenticate via OAuth, the MCP server maintains your session, including your active app and environment. To log out or switch Memberstack accounts, you must clear your local session token.
To log out and re-authenticate:
- Run the following command in your terminal:
rm -rf ~/.mcp-auth- Restart your client and start a new conversation.
Key Tool Groups
The MCP server's ~68 tools are organized into logical groups. Here's an overview of what each group can do.
App & Environment Management
Navigate your Memberstack account, list projects, switch between them, and toggle between SANDBOX and LIVE environments.
Tools: listApps, switchApp, switchMemberstackEnvironment
Member Management
Create, update, and delete members, manage plan assignments, update metadata, and handle bulk operations like imports and exports.
Tools: createMemberEmailPassword, getMembers, updateMember, addFreePlan, exportMembers, deleteMember
Subscription Plan Management
Create and manage subscription plans and pricing. Define plan details, create prices in Stripe, import existing Stripe products, and configure plan logic.
Tools: createPlan, getPlans, createPrice (requires LIVE mode), importStripeProduct
Data Tables
Build and manage custom databases within Memberstack. Create tables, define fields, and manage records. Perfect for member profiles, directories, or custom content.
Tools: createDataTable, createDataTableField, createDataRecord, getDataRecords
Gated Content
Control access to your website's content. Create content groups, protect specific URLs (including wildcards like /pro-content/*), and link subscription plans to grant access.
Tools: createRestrictedUrlGroup, createRestrictedUrl, linkPlansToRestrictedUrlGroup
Knowledge Search
Perform semantic searches across the entire Memberstack knowledge base, including help articles, blog posts, and developer docs.
Key Tool: memberstackKnowledgeSearch
Common Workflows & Examples
Workflow 1: First-Time Setup
- List apps: "List my Memberstack apps"
- Select an app: "Switch to the 'My Awesome Site' app"
- Check environment: "What is my current Memberstack environment?"
- Switch if needed: "Switch to SANDBOX for testing"
Uses: listApps, switchApp, getMemberstackEnvironment, switchMemberstackEnvironment
Workflow 2: Creating a Member in a Test Environment
- Confirm SANDBOX: "Make sure I am in the SANDBOX environment"
- Create a member: "Create a new member with email test@example.com and password 'SecurePassword123'"
- Add a plan: "Find the 'Free Tier' plan and add it to test@example.com"
- Verify creation: "Show me the details for the member with email test@example.com"
Uses: switchMemberstackEnvironment, createMemberEmailPassword, addFreePlan, getMembers
Workflow 3: Setting Up a Gated Content Rule
- Create a content group: "Create a gated content group called 'Pro Articles'"
- Add a protected URL: "Add the URL '/pro/*' to the 'Pro Articles' group"
- Link a plan: "Grant access to the 'Pro Articles' group for anyone on the 'Pro Membership' plan"
- Verify: "Show me the configuration for the 'Pro Articles' content group"
Uses: createRestrictedUrlGroup, createRestrictedUrl, linkPlansToRestrictedUrlGroup
Troubleshooting Common Issues
Fully quit and restart your client (Claude Desktop, VS Code, etc.). Ensure your JSON or YAML configuration file has no syntax errors and is saved in the correct directory. If you used a CLI, verify the installation with the client's list command (e.g., claude mcp list).
Your authentication session may have expired. Run rm -rf ~/.mcp-auth in your terminal to clear the session. Restart your client and re-authenticate using the OAuth prompt.
Node.js is not installed or not in your system's PATH. Install the latest LTS version from nodejs.org, then restart your terminal and client.
You are likely in the wrong environment. Ask, "What Memberstack environment am I in?" and use switchMemberstackEnvironment to toggle between LIVE and SANDBOX.
Certain tools that interact with Stripe (like createPrice or importStripeProduct) require a paid Memberstack subscription and must be run in the LIVE environment with Stripe connected.
You need to select which Memberstack project you are working on. Use listApps to see your available projects, then use switchApp with the desired App ID.
Complete Tool Reference
Here is a compact list of all available tools, organized by category.
| Category | Tools |
|---|---|
| App & Environment (4) | listApps, switchApp, getMemberstackEnvironment, switchMemberstackEnvironment |
| Knowledge & Context (3) | memberstackKnowledgeSearch, currentUser, currentApp |
| Data Tables (14) | getDataTable, getDataTables, getDataTableField, getDataRecord, getDataRecords, createDataTable, updateDataTable, deleteDataTable, createDataTableField, updateDataTableField, deleteDataTableField, createDataRecord, updateDataRecord, deleteDataRecord |
| Plans & Pricing (9) | getPlans, getPlan, createPlan, updatePlan, deletePlan, createPrice, updatePrice, importStripeProduct, updatePlanLogic |
| Gated Content (14) | getContentGroups, getContentGroup, createRestrictedUrl, updateRestrictedUrl, deleteRestrictedUrl, createRestrictedUrlGroup, updateRestrictedUrlGroup, deleteRestrictedUrlGroup, linkRestrictedUrlsToRestrictedUrlGroup, detachRestrictedUrlsFromRestrictedUrlGroup, linkPlansToRestrictedUrlGroup, detachPlansFromRestrictedUrlGroup, createCustomContent, updateCustomContent, deleteCustomContent |
| Members (16) | getMember, getMembers, getMembersCount, getMemberEvents, createMemberEmailPassword, updateMember, updateMemberAuth, deleteMember, addFreePlan, removeFreePlan, removeOneTimePlan, createStripeCustomer, generateMemberPassword, importMembers, exportMembers, updateMemberNote |
| Teams (4) | getTeam, getTeamMembers, removeTeamMember, regenerateTeamInviteToken |
| Custom Fields (4) | getCustomFields, createCustomField, updateCustomField, deleteCustomField |