Commet
  • Pricing
Log InTry out

Getting Started

AI Onboarding

AI Tools

MCP Server

Agent Skills

Commet SkillsBilling Best Practices SkillPricing Models SkillSubscription Patterns Skill
System status
DocumentationKnowledge BaseBuild with AIAPI ReferenceWebhooks

MCP Server

Use the MCP Server to manage billing infrastructure.

What is an MCP Server?

MCP is an open protocol that standardizes how applications provide context to LLMs. Among other benefits, it provides LLMs tools to act on your behalf.

What can Commet's MCP Server do?

Commet's MCP server gives your AI agent native access to the full Commet platform through a single integration. You can manage all aspects of your billing infrastructure using natural language.

  • Organizations — List, create, switch, and get the current organization
  • Catalog — Create and manage plans, prices, features, add-ons, promo codes, and regional prices
  • Customers — Create and update customers
  • Subscriptions — Revert scheduled cancellations
  • Data — Query revenue, subscriptions, invoices, and usage with read-only SQL
  • Docs — Search the live Commet documentation
  • API Keys — Create and delete API keys for the SDK

As an example, you could use this to create a full billing setup, manage plans and features, inspect customer subscriptions, or review invoices and usage data.

Prerequisites

The MCP endpoint is the same for sandbox and live data:

https://commet.co/mcp

OAuth uses the authenticated user's active organization. API key authentication uses the organization that created the key.

To use it, you'll need to:

  • Create a Commet account
  • Have an MCP-compatible client (Cursor, Claude Code, Claude Desktop, etc.)

Browser-based clients can use OAuth with no API key. If your client runs in CI, on a server, or anywhere browser login is not possible, pass a Commet API key in the x-api-key header.

Switch to a sandbox organization when experimenting or setting up billing for the first time. Operations on a live organization affect real customers immediately.

How to use the MCP Server

Choose your preferred client below.

Open the command palette and choose "Cursor Settings" > "MCP" > "Add new global MCP server".

{
  "mcpServers": {
    "commet": {
      "url": "https://commet.co/mcp"
    }
  }
}
claude mcp add --transport http commet https://commet.co/mcp

Open Claude Desktop settings > "Developer" tab > "Edit Config".

{
  "mcpServers": {
    "commet": {
      "url": "https://commet.co/mcp"
    }
  }
}
codex mcp add commet --url https://commet.co/mcp

The command opens the browser for OAuth authentication. Once complete, verify with:

codex mcp list

Add the following to your VS Code settings.json:

{
  "mcp": {
    "servers": {
      "commet": {
        "type": "http",
        "url": "https://commet.co/mcp"
      }
    }
  }
}

Add the following to ~/.gemini/settings.json:

{
  "mcpServers": {
    "commet": {
      "httpUrl": "https://commet.co/mcp"
    }
  }
}

Add the following to opencode.json:

{
  "mcp": {
    "commet": {
      "type": "remote",
      "url": "https://commet.co/mcp"
    }
  }
}
{
  "mcpServers": {
    "commet": {
      "serverUrl": "https://commet.co/mcp"
    }
  }
}

API key authentication

For clients that cannot open browser login, add an x-api-key header:

claude mcp add --transport http commet https://commet.co/mcp --header "x-api-key: ck_xxxxxxxxx"

For JSON-based clients:

{
  "mcpServers": {
    "commet": {
      "url": "https://commet.co/mcp",
      "headers": {
        "x-api-key": "ck_xxxxxxxxx"
      }
    }
  }
}

API-key sessions authenticate as the user who created the key and use the organization that created the key. Create the key from a sandbox organization when experimenting.

Available Tools

The MCP server exposes the following tools once connected:

Organizations

ToolDescription
list_organizationsList all organizations you have access to, including live orgs and their sandboxes
get_current_organizationGet the currently active organization context
switch_organizationSwitch the active organization context
create_organizationCreate a new organization for the authenticated user

switch_organization and create_organization work on OAuth sessions only — API-key sessions are pinned to the key's organization. The switch takes effect on the next message.

Catalog

ToolDescription
create_planCreate a pricing plan. Paid plans must include at least one price; free plans take none
update_planUpdate a plan's name or description
delete_planSoft-delete a plan. Existing subscriptions continue billing normally
toggle_plan_visibilityToggle a plan between public and private. Private plans are hidden but existing subscriptions keep access
add_plan_priceAdd a base price to a plan for another billing interval. Configure Markets and selectable variants through the API or dashboard
update_plan_priceUpdate a base catalog price or trial; included credits/balance allocations update on their next reset
add_plan_featureAdd a feature to a plan, configured per the plan's consumption model
remove_plan_featureRemove a feature from a plan. Active subscriptions keep their current-period snapshot until renewal
create_featureCreate a feature: boolean (on/off), usage (usage-based), or seats (per-user)
update_featureUpdate a feature's name, description, or unit name
delete_featureSoft-delete a feature. Remove it from all plans and archive its add-on first
create_addonCreate a purchasable add-on linked to one feature with its own pricing
update_addonUpdate an add-on's name, description, pricing, or usage limits
delete_addonArchive (soft-delete) an add-on. Cannot archive one with active subscriptions
create_promo_codeCreate a single-discount Offer and its percentage or fixed-amount Promo Code together
toggle_promo_codeToggle a promo code between active and inactive. Inactive codes cannot be redeemed at checkout
set_regional_pricesSet an exchange rate for a plan + currency and auto-calculate regional prices
remove_regional_pricesRemove all regional prices for a plan + currency

Customers

ToolDescription
create_customerCreate a customer. Idempotent on externalId — returns the existing customer if already created
update_customerUpdate a customer's billing email, name, timezone, address, external ID, or metadata

Subscriptions

ToolDescription
uncancel_subscriptionRevert a scheduled cancellation before the subscription is fully canceled

Data & Docs

query_billing_data is the read path. Instead of one tool per entity, the agent writes read-only SQL — automatically scoped to your organization, SELECT only, max 100 rows per query, 5-second timeout.

ToolDescription
query_billing_dataRun read-only SQL over your billing data: revenue, subscriptions, customers, invoices, usage, plans
search_docsSearch the live Commet documentation by semantic query

API Keys

ToolDescription
create_api_keyCreate an API key for the SDK. The plaintext key is shown only once
delete_api_keyPermanently delete an API key. Applications using it immediately lose access

How is this guide?

AI Onboarding

Everything you need to onboard your AI agent to Commet.

Commet Skills

Give AI agents expert-level billing knowledge with Agent Skills.

On this page

What is an MCP Server?
What can Commet's MCP Server do?
Prerequisites
How to use the MCP Server
API key authentication
Available Tools
Organizations
Catalog
Customers
Subscriptions
Data & Docs
API Keys