Skip to main content
P

PayPal

@codespar/mcp-paypal Β· v0.1.2

🌐 GlobalPaymentsAuth · OAuth2beta19 tools3 env vars

Global payments + payouts giant. Owns Braintree (separate package). Orders v2 + Payments + Payouts + Subscriptions + Disputes + Webhooks. OAuth2 client_credentials. Sandbox/live toggle.

Get started Β· freeView docs

MIT Β· runs locally with your own credentials

Limitations

  • Hosted calls with a test key are not available: the runtime has not recorded this provider's test behaviour (test venue unclassified).
Package
@codespar/mcp-paypal
Version
0.1.2
npm dist-tag
latest
Category
Payments
Auth
OAuth2
Country
🌐 Global
License
MIT
Transport
stdio Β· streamable-http

Quickstart

Install, set the credentials, make the first call.

Pick your client. The server runs locally over stdio, with your own credentials.

Add the server to your clientOne config entry. No build step, no SDK required.
Set the environment variables3 variables read by this server's code, listed below.
Restart and make the first callThe agent can call any of the 19 tools. Try create_order first.
terminal
# Claude Code claude mcp add paypal -e PAYPAL_CLIENT_ID=… -e PAYPAL_CLIENT_SECRET=… -e PAYPAL_ENV=… -- npx -y @codespar/mcp-paypal@0.1.2 # then: /mcp to confirm the server is connected
Environment variables3 variables
PAYPAL_CLIENT_IDPayPal REST app client id (from developer.paypal.com Apps & Credentials).required
PAYPAL_CLIENT_SECRETPayPal REST app client secret (OAuth2 client_credentials password).requiredsecret
PAYPAL_ENVPayPal environment. 'sandbox' (default, https://api-m.sandbox.paypal.com) or 'live' (https://api-m.paypal.com).optional

Names read from the package code (@codespar/mcp-paypal@0.1.2). Descriptions and flags come from its manifest. Self-hosted, you hold the credentials.

First call democreate_order

"Create a PayPal Order via POST /v2/checkout/orders. Pass intent"

tools/callcreate_orderresult returned

Tools

What your agent can call.

19 tools, as the package's tools/list returns them.

create_order

Create a PayPal Order via POST /v2/checkout/orders. Pass intent ('CAPTURE' or 'AUTHORIZE') and purchase_units (each with an amount object). Returns the order with id, status, and HATEOAS links (including the approve URL for the buyer).

get_order

Fetch a PayPal Order by id via GET /v2/checkout/orders/{id}. Returns the full order including status, purchase_units, and payments collection.

capture_order

Capture payment for an approved order via POST /v2/checkout/orders/{id}/capture. Use after the buyer approves an order with intent=CAPTURE. Returns the captured payment details.

authorize_order

Authorize payment for an approved order via POST /v2/checkout/orders/{id}/authorize. Use after the buyer approves an order with intent=AUTHORIZE. Returns the created authorization (capture later with capture_authorization).

capture_authorization

Capture a previously authorized payment via POST /v2/payments/authorizations/{id}/capture. Pass an amount object for partial captures, or omit to capture the full authorized amount. Set final_capture=true on the last partial capture.

refund_capture

Refund a captured payment via POST /v2/payments/captures/{id}/refund. Pass an amount object for partial refunds, or omit for a full refund. Idempotent via PayPal-Request-Id.

void_authorization

Void (release) an unsettled authorization via POST /v2/payments/authorizations/{id}/void. Use when funds were authorized but will not be captured. Returns 204 No Content on success.

get_payment_details

Fetch a payment object by id via GET /v2/payments/{type}/{id}. type is one of 'authorizations', 'captures', or 'refunds'. Returns the full payment object with status and links.

create_batch_payout

Create a batch payout via POST /v1/payments/payouts. sender_batch_header carries metadata; items is an array of payout_item objects each with recipient_type, amount { currency, value }, receiver, and note. Async β€” poll get_payout to track status.

get_payout

Fetch a payout batch by id via GET /v1/payments/payouts/{batch_id}. Returns batch_header (status, time_created, etc.) and items array with per-item status.

get_payout_item

Fetch a single payout item by id via GET /v1/payments/payouts-item/{item_id}. Use to inspect the status of one recipient inside a batch (UNCLAIMED, SUCCESS, FAILED, etc).

create_subscription

Create a billing subscription via POST /v1/billing/subscriptions. plan_id is the id of a previously created billing plan. Returns the subscription with status (APPROVAL_PENDING) and HATEOAS approve link for the buyer.

Names and descriptions come from the package's tools/list (@codespar/mcp-paypal@0.1.2). A kind (read, write, delete) is shown only when the package annotates its tools or each tool was verified one by one; neither exists for this server yet.

Compatibility

MCP is a protocol. Any client that speaks it can mount this server.

codespar_discover lists this server's tools, but a project with a test key cannot call them yet: the runtime has not recorded what this provider does in test mode, and refuses rather than guess.

Protocol

Any MCP client

stdio Β· streamable-http

Questions

Before you install.

How do I install the PayPal MCP server?

Run npx -y @codespar/mcp-paypal@0.1.2 and add the config block above to your MCP client: Claude Code, Cursor, Claude Desktop, VS Code, or any MCP-compatible client. No build step, no SDK required.

What can my agent do with PayPal?

PayPal exposes 19 tools for payments. Your agent calls them directly; the full list is above.

How does PayPal authenticate, and how are credentials stored?

PayPal uses OAuth2. Self-hosted, you hold the credentials: the server reads them from its environment variables.

How does PayPal handle upstream API changes?

Every server is versioned independently on npm. The command on this page pins 0.1.2, the version whose tools are listed here; your agent keeps running it until you change the version.

Is PayPal open source? How do I report a bug?

Yes. PayPal is MIT-licensed and published on npm as @codespar/mcp-paypal, source on GitHub (link in the Details panel). Report issues on the package repository; security issues go to security@codespar.dev, and we respond within 24 hours.

Start in seconds.

Add the config above, set the variables, and your agent calls the tools.

Start in seconds demo
Add the server to your client with the config above.
Set the environment variables listed above.
Ask your agent for the first call.
PayPal β€” MCP server Β· 19 tools | CodeSpar