
Developers building billing logic, subscription workflows, or payment integrations spend a lot of time in two places at once: the terminal and the Stripe dashboard.
Debugging a failed charge means looking up the payment intent. Validating subscription state means checking the customer record. Testing a refund flow means cross-referencing the original charge. Every one of those lookups is a context switch.
To help your developers query and act on Stripe data directly from their coding session, we'll show you how to connect Stripe with Merge Agent Handler's Stripe MCP server.
Merge Agent Handler connects Claude Code to Stripe's API through a single CLI setup. You install the Merge CLI, authenticate once, and register the connection with one command. Agent Handler manages your Stripe credentials so you don't keep secret keys in your local environment or embed them in your codebase.
Here's the command that registers the connection:
Related: How to use a Stripe MCP in Cursor
Before getting started, you'll need the following:
claude --version to confirm)pipx --version to confirm, or install via pip install pipx)If you want to connect Merge Agent Handler's Stripe MCP with internal or customer-facing agentic products, you can follow the steps in our docs.
Install with pipx: pipx install merge-api

Verify your installation: merge --version

Related: How to use the FactSet MCP in Claude Code
Authenticate the CLI with your Merge Agent Handler account: merge login
Once complete, the CLI can make authorized API requests on your behalf.
The simplest way to register Agent Handler with Claude Code:
Alternatively, register manually:
Verify the connection registered. Open Claude Code and run: /mcp
agent-handler should appear under Local MCPs with a connected status.

Related: A guide to integrating a Stripe MCP with Codex
To confirm the connection is working, open a Claude Code session and try: "List my failed payment intents from the last 7 days and tell me what the most common decline reason is."
On first use, a Magic Link will appear to finish connector authentication.

You should then see a response like the following:

{{this-blog-only-cta}}
In case you have more questions on setting up and using the Stripe MCP in Claude Code, we've addressed several more commonly-asked questions below.
With Stripe connected, Claude Code can:
You can build a self-hosted MCP server that calls Stripe's API directly. For a solo developer working against a test mode account, that's a workable starting point. You store a secret key, write tool schemas for the endpoints you need, and connect it to Claude Code.
The problem is what happens when more than one person needs access, or when you're working against live mode data.
Stripe secret keys carry full account access by default. Sharing them across developers, or handing one to an agent with no access controls on top, means the agent can read customer PII, issue refunds, cancel subscriptions, or pull balance data, whether or not your use case requires it. There's no audit trail of what the agent did, and revoking a key breaks everyone using it.
Merge Agent Handler sits between Claude Code and Stripe. You define exactly which tools each Tool Pack exposes, so a read-only reporting agent never gets a <code class="blog_inline-code">create_refund</code> tool. Every call is logged with the tool name, inputs, and response metadata. And each developer or environment gets its own Registered User with its own scoped credentials, so access is isolated and revocable without touching anyone else's setup.
For teams building agents against live Stripe data, the per-developer credential problem and the lack of access controls are the failure modes that matter. Merge Agent Handler addresses both.
Stripe is the source of truth for revenue data. Every charge, subscription, invoice, and payout lives there, and developers building billing agents, RevOps tooling, or payment debugging workflows need to reach it constantly. Right now that means a browser tab, a Stripe CLI command, or a throwaway script.
With the Stripe MCP connected, Claude Code can query payment intents, pull subscription state, and surface customer billing history without leaving the terminal.
That changes how debugging works: instead of tracing a failed payment across logs, a webhook event, and a manual API call to reconstruct the charge, you can ask Claude Code to pull the payment intent directly and explain what happened.
It also changes how testing works: agents validating billing logic can check live Stripe state mid-session rather than relying on fixtures that may not reflect production behavior.
Use Merge Agent Handler’s 150+ connectors (including Stripe) to power reliable, secure, and powerful agents.