MCP server for Baremetrics Metrics API
Baremetrics MCP Server
An MCP (Model Context Protocol) server for the Baremetrics Metrics API. This server provides tools to query SaaS metrics like MRR, ARR, churn, and more.
Installation
npm install
npm run build
Configuration
Set your Baremetrics API key as an environment variable:
export BAREMETRICS_API_KEY=your_api_key_here
Usage with Claude Desktop
Add to your Claude Desktop configuration (~/Library/Application Support/Claude/claude_desktop_config.json on macOS):
{
"mcpServers": {
"baremetrics": {
"command": "node",
"args": ["/path/to/baremetrics-mcp/dist/index.js"],
"env": {
"BAREMETRICS_API_KEY": "your_api_key_here"
}
}
}
}
Available Tools
list_available_metrics
Lists all available metrics that can be queried from Baremetrics.
show_summary
Get daily summaries with all key metrics for a date range.
Parameters:
start_date(required): Start date in YYYY-MM-DD formatend_date(required): End date in YYYY-MM-DD format
show_metric
Get detailed data for a specific metric over a date range.
Parameters:
metric(required): The metric name (see available metrics below)start_date(required): Start date in YYYY-MM-DD formatend_date(required): End date in YYYY-MM-DD formatcompare_to(optional): Number of days ago to compare to (default: 30)
show_metric_customers
Get the customers that make up a specific metric (e.g., who upgraded, churned).
Parameters:
metric(required): The metric namestart_date(required): Start date in YYYY-MM-DD formatend_date(required): End date in YYYY-MM-DD format
show_metric_plans
Get a breakdown of a metric by plan across a date range.
Parameters:
metric(required): The metric namestart_date(required): Start date in YYYY-MM-DD formatend_date(required): End date in YYYY-MM-DD format
show_cohorts
Get cohort retention data with user and revenue tracking over time.
Available Metrics
active_customers- Currently active customersactive_subscriptions- Currently active subscriptionsactive_trials- Currently active trialsarpu- Average Revenue Per Userarr- Annual Recurring Revenuecancellations- Subscription cancellationschurned_customers- Customers who churnedconverted_trials- Trials that converted to paidcoupons- Coupon usagedowngrades- Subscription downgradesfailed_charges- Failed payment chargesfees- Processing feesltv- Lifetime Valuemrr- Monthly Recurring Revenuemrr_growth_rate- MRR growth ratenet_revenue- Net revenuenet_revenue_churn- Net revenue churnnew_customers- New customers acquirednew_subscriptions- New subscriptionsnew_trials- New trial signupsother_revenue- Other revenue sourcesplan_quantities- Plan quantity changesquick_ratio- Quick ratio (growth efficiency)reactivations- Reactivated subscriptionsrefunds- Refunds issuedrevenue_churn- Revenue churn ratetrial_conversion- Trial conversion rateupgrades- Subscription upgradesuser_churn- User churn rate
Example Usage
Once configured, you can ask Claude things like:
- "Show me my MRR for the last 30 days"
- "What's my churn rate between January and March?"
- "Which customers upgraded last month?"
- "Break down my ARR by plan"
- "Show me cohort retention data"
License
MIT