This server advertises the tools below. A tool list is an inventory of what the server can do — it is not a finding, and it is not part of the score.
List the registered apps (app_id + name). Use this first to discover valid app_id values, then pass one to the other tools to scope results to a single product.
List subscriptions/registrations, newest first. Optionally filter by app_id, status, or payment_type. Returns metadata (email, status, plan, amounts). Use get_customer for a single user, or revenue_summary for totals.
Params
app_id
status
payment_type
limit
include_samples
Look up a customer by email. Returns every subscription/registration for that email across apps (or within one app if app_id is given), with full detail: verification, plan, billing period, usage, refunds. Empty when the email is unknown.
Params
email
app_id
List recent paid transactions (excludes free-tier rows), newest first, ordered by payment date. Optionally scope by app_id. Use to review recent sales activity. Amounts are in the transaction currency (cents).
Params
app_id
limit
include_samples
Revenue and subscriber summary in USD cents (normalized from each transaction currency). Returns latest_payments (the MOST RECENT payment summed per customer: a run-rate, NOT lifetime turnover, because amount_paid is overwritten on renewal), refunds, approximate MRR, active/trialing/paid counts, and lifetime_net (the only cumulative total held, accrued per OWNER across all their apps and net of refunds; null when no accrual record exists). lifetime_net counts only charges whose Stripe webhook re
Params
app_id
include_samples
Per-app rollup in USD cents (latest_payments/refunded/MRR + paid customer count), largest refund-adjusted latest payments first. latest_payments sums the most recent payment per customer, so it is a run-rate and NOT lifetime turnover. No lifetime figure is available per app (accrual is recorded per owner). Use to compare products at a glance; use revenue_summary for one app in depth.
Params
include_samples
List referral records (who referred whom, reward coupon code, pending/rewarded status) with what the referred buyer paid, newest first. Use for working out creator commission: a one_time referredPaymentType means referredAmountPaidCents is the whole sale; for a recurring row it is the LATEST payment, not lifetime, so do not commission on it. Optionally scope by app_id and/or status.
Params
app_id
status
limit
include_samples
Monthly per-code affiliate commission report, newest month first: attributed paid revenue (USD cents) and what each creator is owed, from the affiliate payment ledger. A payment counts only within 12 months of that buyer's FIRST attributed payment on the code (the first-year deal), and commission is computed per payment at the % frozen when it landed, so later rate changes never rewrite history. Refunds are NOT netted here: deduct them by hand at payout, like referral rewards. Read-only; payouts
Params
app_id
code
month
limit
include_samples
Recently canceled paid subscriptions (excludes free rows), most recent cancellation first, with what each customer was paying. Use for churn review; list_subscriptions orders by signup date instead.
Params
app_id
limit
include_samples
List discount coupons (code, percent off, expiry, max uses, use count, which paid tiers they apply to). Optionally scope by app_id and/or restrict to currently-active ones (not expired, not maxed out). Read-only: cannot create, edit, or delete coupons.
Params
app_id
active_only
limit
Create a percentage discount coupon for an app. WRITE, human-gated: a real create requires an elicitation-capable client (e.g. Claude Desktop). The human enters the final code, percent, expiry, visibility, and tier scope in a form; those values OVERRIDE the arguments here, which only pre-fill the form message as a proposal. Clients without elicitation are refused UNLESS the deployment sets SPARK_PAY_MCP_ALLOW_UNELICITED_WRITES=1 and the call passes confirm_write:true, which is how Claude Code an
Params
app_id
code
discount_percent
description
expires_at
max_uses
applies_to_tiers
listed
confirm_high_discount
confirm_write
dry_run
Create the SAME discount code across many apps in one call: the portfolio-promo shortcut (e.g. a summer sale on every owned app). WRITE, human-gated: a real create requires an elicitation-capable client; the human enters the coupon terms ONCE in a form (overriding the arguments here) and that one approval covers the whole batch. Clients without elicitation are refused UNLESS the deployment sets SPARK_PAY_MCP_ALLOW_UNELICITED_WRITES=1 and the call passes confirm_write:true, which is how Claude Co
Params
app_ids
code
discount_percent
description
expires_at
max_uses
applies_to_tiers
listed
confirm_high_discount
confirm_write
dry_run
Delete one coupon from an app. WRITE, human-gated: a real delete requires an elicitation-capable client; the human sees the exact coupon (code, percent, redemption count) and must click approve. The model cannot confirm on its own, and confirm_used is only consulted for dry_run previews. Clients without elicitation are refused UNLESS the deployment sets SPARK_PAY_MCP_ALLOW_UNELICITED_WRITES=1 and the call passes confirm_write:true, which is how Claude Code and cron reach these writes; dry_run st
Params
app_id
code
confirm_used
confirm_write
dry_run
Delete the SAME coupon code across many apps in one call: the inverse of bulk_create_coupon, for retiring a portfolio-wide promo. WRITE, human-gated: a real delete requires an elicitation-capable client; the human sees every app the code would be removed from (with per-app redemption counts) and must click approve, and confirm_used is only consulted for dry_run previews. Clients without elicitation are refused UNLESS the deployment sets SPARK_PAY_MCP_ALLOW_UNELICITED_WRITES=1 and the call passes
Params
app_ids
code
confirm_used
confirm_write
dry_run
Show, hide or SCHEDULE an EXISTING coupon on the public pricing pages by setting its `listed` flag and optional `listed_from` start date. WRITE, human-gated: a real write requires an elicitation-capable client and the human sees the code, the discount, which way it is moving and any start date; clients without elicitation pass through, since this only moves a display flag (dry_run works anywhere). These are deliberately the ONLY fields an agent can change on a live coupon: the percent, expiry an
Params
app_id
code
listed
listed_from
dry_run
Mark an EXISTING coupon as a creator's AFFILIATE code at an agreed commission % (the standing deal is 30% of first-year attributed revenue), or clear the mark with percent:null. WRITE, human-gated: a real write requires an elicitation-capable client and the human sees the code and the rate; dry_run works anywhere. From the moment the mark is set, every payment that checks out with the code (and every renewal of a subscription it opened) is recorded in the affiliate ledger at this %, frozen per p
Params
app_id
code
percent
dry_run
List who a coupon was offered to and what they did with it: per-address status (invited / redeemed / revoked), where the invite came from, and the timestamps. Also returns the coupon's own `invite_only` flag -- read that FIRST: when it is false the invite rows are recorded but NOT enforced, and anyone holding the code can still redeem it. Read-only. Use list_coupons for the coupon's terms, invite_to_coupon to add addresses, revoke_coupon_invite to withdraw one.
Params
app_id
code
Add email addresses to a coupon's invite list and, by default, switch the coupon to invite-only so the list is actually enforced. WRITE, human-gated: a real write requires an elicitation-capable client and the human sees every address plus whether the coupon is about to be closed to everyone else; clients without elicitation are refused unless the deployment sets SPARK_PAY_MCP_ALLOW_UNELICITED_WRITES=1 and the call passes confirm_write:true (dry_run works anywhere). Addresses are lowercased and
Params
app_id
code
emails
source
enforce_invite_only
confirm_write
dry_run
Withdraw one address's right to spend a coupon: the targeted block. WRITE, human-gated: a real write requires an elicitation-capable client and the human sees the address and its current status; clients without elicitation are refused unless the deployment sets SPARK_PAY_MCP_ALLOW_UNELICITED_WRITES=1 and the call passes confirm_write:true (dry_run works anywhere). Works on an address that was never invited too, writing a revoked tombstone, so blocking someone does not depend on whether they were
Params
app_id
code
email
reason
confirm_write
dry_run
Step 1 of onboarding a new app onto SparkPay. Recons app_name against existing apps and the rest of the portfolio's plan catalogs, then returns automated findings plus the minimum set of questions that genuinely need a human answer (plan prices, billing model, redirect URLs, trial length, push-webhook opt-in). Pass the answers to create_app_kit next.
Params
app_name
Step 2 of onboarding a new app onto SparkPay. Applies answers.plan_catalog by minting real Stripe prices (same helper /api/apps/sync-plans uses) and registers/updates the app, then returns a downloadable integration kit (lib/spark-pay client + plans.json + sync script + INTEGRATION.md, modeled on still-applying's golden pattern) plus exact post_steps for env vars and secrets. Refuses to overwrite an existing app's plans unless answers.confirm_overwrite is true. Real secrets (a push-mode webhook
Params
app_name
answers
Download an app's live plan catalog: tiers, names, prices, trial, and the machine-readable `limits` that gate features inside the app. This is the source of truth each app repo's `bun run plans:sync` regenerates lib/spark-pay/plans.json from, so diff against this rather than trusting the committed file. Stripe price/product IDs are omitted unless include_stripe_ids is set.
Params
app_id
include_stripe_ids
Change the per-tier numbers an app's catalog gates on: its usage `limits` (default), or, with target:"grants", what ONE purchase of a credit pack adds to the buyer's credits_by_key. Nothing else writes `grants` on an existing plan. It only patches a pack that ALREADY grants something: a non-one-time tier is refused (grants are ignored there), and so is a one-time tier that is not yet a pack, because making one a pack takes it off the tier ladder and collapses the resolved rank of every existing
Params
app_id
updates
mode
target
confirm_write
dry_run
Set an existing tier's display metadata: its name and the two badge flags the public pricing page styles cards from: is_elite (gold/carbon BEST VALUE card with the rainbow title and app icon) and recommended (MOST POPULAR). A tier called "Elite" is NOT styled as elite unless is_elite is actually true on the stored plan; the page reads the flag, never the tier slug, so a catalog whose top tier lacks the flag renders as a plain grey card. Use this to repair that. WRITE, human-gated: the human sees
Params
app_id
tier
name
is_elite
recommended
dry_run
Change what an app's EXISTING tiers charge: the amount, the billing model (one_time vs subscription), or both. WRITE, human-gated at the highest tier: a real write requires an elicitation-capable client, and the human types the tier, billing model and price into a form. Those typed values OVERRIDE the arguments here, which only pre-fill the proposal, so the model cannot move a price on its own. Clients without elicitation are refused UNLESS the deployment sets SPARK_PAY_MCP_ALLOW_UNELICITED_WRIT
Params
app_id
updates
confirm_write
dry_run
Remove a tier from an app's plan catalog. WRITE, human-gated: a real write needs an elicitation-capable client and the human must approve; dry_run previews anywhere. Every other plan tool edits tiers that already exist, so a catalog could grow but never shrink, and collapsing a multi-tier page down to a single offer was a dashboard-only job. Stripe products and prices are deliberately left intact, exactly as update_plan_pricing leaves the old price behind: removing the row stops the plan being o
Params
app_id
tier
dry_run
Mint a credit pack for an app: a one-time plan carrying a `grants` map, which is how SparkPay sells an in-app purchase (a $5 top-up of 500 ai_credits). Buying one adds its grants to the buyer's credits_by_key and leaves their plan row alone, and the status endpoint folds those credits into the resolved plan's limits, so an existing "usage vs limit" gate honours a top-up with no new code in the app. Until this existed, minting a pack needed shell access (`bun scripts/db/add-credit-pack.ts`). WRIT
Params
app_id
tier
name
amount_cents
grants
currency
features
confirm_write
dry_run
Add or remove one buyer's credit-pack credits by hand: goodwill, a support fix, or correcting a refund the webhook could not attribute. Writes only subscriptions.credits_by_key, through the same two statements a real pack purchase uses, so a granted credit is indistinguishable from a bought one afterwards and the refund path can still claw either back. A removal floors at zero rather than going negative. WRITE, human-gated: the human sees the real before -> after balance and must approve; client
Params
app_id
email
grants
mode
confirm_write
dry_run
Guided, stage-chained wizard that configures an app's hosted pricing page end to end: plan billing model + price (with clickable recommendations), plan name and badge (elite/recommended), optional free tier, a seasonal coupon (SUMMER26-style code suggested from the current season), favicon-derived theme color + card style, and FAQ content. WRITE, human-gated per stage: each call runs AT MOST ONE elicitation form and commits only that stage, then returns next_call for the model to continue (stage
Params
app_id
stage
dry_run
tier
domain
price_suggestions
discount_percent
coupon_code
faq_drafts