Looking to search the documentation instead of operating your account? Use the
hosted docs MCP at https://docs.cashsdk.com/mcp. It's read-only and needs no
credentials.
MCP server
Run @cashsdk/mcp — a stdio MCP server that lets any agent operate your CashSDK account.
@cashsdk/mcp is the official CashSDK Model Context Protocol
server. It's a thin, stateless proxy over the CashSDK REST API: every tool maps
to an API call, using the token you provide. Point any MCP client at it and your
agent can manage catalog, paywalls, customers, webhooks, and store sync.
Install and run#
The server runs over stdio and is launched by your MCP client. You rarely run it by hand — the client spawns it — but you can start it directly to smoke test:
npx -y @cashsdk/mcp
The package is @cashsdk/mcp and the binary is cashsdk-mcp. Using
npx -y means clients always run the latest version with no global install.
Environment variables#
Configuration is entirely through the environment your client passes to the server.
| Variable | Required | Default | Description |
|---|---|---|---|
CASHSDK_TOKEN | Yes | — | A secret key (csk_sk_…) or a setup token (csk_st_…). Authenticates every tool call. |
CASHSDK_API_URL | No | https://api.cashsdk.com | Base URL of the CashSDK Cloud API. |
CASHSDK_APP | No | — | Default app id (app_…) for tools. Every tool also accepts an explicit app argument that overrides this. |
CASHSDK_TOKEN grants API access to your workspace. Treat it like any secret:
scope it to a single app, never commit it, and prefer a setup token
(csk_st_…) — a short-lived, provisioning-scoped credential — over a
long-lived secret key when onboarding.
Client configuration#
Any MCP client uses roughly the same JSON. The exact file differs per client (see the linked pages), but the server block is identical:
{
"mcpServers": {
"cashsdk": {
"command": "npx",
"args": ["-y", "@cashsdk/mcp"],
"env": {
"CASHSDK_TOKEN": "csk_sk_...",
"CASHSDK_APP": "app_...",
"CASHSDK_API_URL": "https://api.cashsdk.com"
}
}
}
}
Tools#
Tools are grouped by what they touch. Each maps directly onto a REST endpoint, so results are the same JSON your backend would receive.
Setup & inspect
| Tool | Description |
|---|---|
get_setup_checklist | Return the live go-live checklist and what's outstanding. |
get_app | Fetch an app's configuration. |
get_catalog | List products, entitlements, and offerings. |
update_app_settings | Change app-level settings. |
get_ios_integration_snippets | Get ready-to-paste iOS integration code. |
Catalog
| Tool | Description |
|---|---|
create_product | Create a product (subscription or one-time). |
create_entitlement | Create an entitlement. |
grant_entitlement | Grant an entitlement to a customer. |
Paywalls & placements
| Tool | Description |
|---|---|
list_templates | List available paywall templates. |
list_paywalls | List existing paywalls. |
create_paywall | Create a paywall from scratch. |
create_paywall_from_template | Create a paywall from a template. |
generate_paywall | Generate a paywall from a natural-language brief. |
list_placements | List placements. |
create_placement | Create a placement that targets a paywall. |
Customers & data
| Tool | Description |
|---|---|
get_customer | Fetch a customer and their entitlements. |
list_transactions | List transactions for an app or customer. |
tail_recent_events | Return the most recent events (purchases, renewals, etc.). |
Campaigns
| Tool | Description |
|---|---|
create_campaign | Create a campaign. |
list_campaigns | List campaigns. |
Keys & webhooks
| Tool | Description |
|---|---|
create_api_key | Create a new API key. |
rotate_api_key | Rotate an existing API key. |
register_webhook_endpoint | Register a webhook endpoint URL. |
send_test_webhook | Send a test event to a webhook endpoint. |
Store sync
| Tool | Description |
|---|---|
sync_catalog_from_app_store | Pull catalog data from the App Store. |
push_catalog_to_app_store | Push your CashSDK catalog to the App Store. |
request_apple_test_notification | Ask Apple to send a test server notification. |