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.

Beta Notice

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 npx command

Step 1: Configure Your Client

Find your AI client below and follow the instructions to register the Memberstack MCP Server.

Run this command in your terminal:

claude mcp add memberstack --scope user npx mcp-remote https://mcp.memberstack.com/mcp
💡 Tip:

The --scope user flag makes the server available globally across all your projects.

Step 2: Authenticate with Memberstack

  1. After configuring your client, start a new conversation.
  2. Your client will detect the new server and prompt you to authenticate. A browser window will open.
  3. Log in with your Memberstack dashboard credentials to authorize the connection.

Security Note

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 and 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.

⚠️ Important:

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:

  1. Run the following command in your terminal:
rm -rf ~/.mcp-auth
  1. 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

  1. List apps: "List my Memberstack apps"
  2. Select an app: "Switch to the 'My Awesome Site' app"
  3. Check environment: "What is my current Memberstack environment?"
  4. Switch if needed: "Switch to SANDBOX for testing"

Uses: listApps, switchApp, getMemberstackEnvironment, switchMemberstackEnvironment

Workflow 2: Creating a Member in a Test Environment

  1. Confirm SANDBOX: "Make sure I am in the SANDBOX environment"
  2. Create a member: "Create a new member with email test@example.com and password 'SecurePassword123'"
  3. Add a plan: "Find the 'Free Tier' plan and add it to test@example.com"
  4. 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

  1. Create a content group: "Create a gated content group called 'Pro Articles'"
  2. Add a protected URL: "Add the URL '/pro/*' to the 'Pro Articles' group"
  3. Link a plan: "Grant access to the 'Pro Articles' group for anyone on the 'Pro Membership' plan"
  4. Verify: "Show me the configuration for the 'Pro Articles' content group"

Uses: createRestrictedUrlGroup, createRestrictedUrl, linkPlansToRestrictedUrlGroup

Troubleshooting Common Issues

Memberstack tools don't appear in my client

Solution: 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).

"Unauthorized" or "Bearer token required" errors

Solution: 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.

"npx: command not found"

Solution: 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.

Created a member but can't find them

Solution: You are likely in the wrong environment. Ask, "What Memberstack environment am I in?" and use switchMemberstackEnvironment to toggle between LIVE and SANDBOX.

"Requires Paid Subscription" error

Solution: 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.

"No app context" or "App ID required"

Solution: 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.

CategoryTools
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

What's Next?

Now that you have the MCP server set up, you might want to:

Need Help?

Having trouble getting your login working? We're here to help!

Thank you for choosing Memberstack 🙏