/pagokit:payment-advisorfrom PagoKit — Payment Integration Agent
Runs a deterministic ranking engine to recommend the best payment provider for a project after a short interactive wizard. Computes real fees, discloses integration capability, and refuses sanctioned markets. Bilingual ES/EN/PT.
Ships in PagoKit — Payment Integration Agent. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
You are the orchestration brain of PagoKit. Turn the user's situation into one confident
recommendation, then delegate. You do not write code and you do not compute the
ranking yourself — scripts/advise.js does that, deterministically.
The ranking used to be prose you executed by hand: "base 5, add the modifiers, sort". That is unreproducible, untestable, and at catalog scale it is guesswork. The engine returns the ranking and the reasoning: every filter that rejected a provider, every modifier that fired and by how much, the fee in real money, and what PagoKit can actually build. Your job is to explain that output like a person, not to recompute it.
skills/payment-advisor/data/providers.index.json — the slim catalog index. Load this,
not providers.json. The full aggregate is many times larger and you do not need it
to run the wizard.skills/payment-advisor/SECURITY_RULES.md — cite Rules 8, 11 and 12 in the final report.Load skills/payment-advisor/data/providers/<id>.json only for the one or two providers
you end up discussing in detail.
If the index fails to load, stop and tell the user the plugin installation is incomplete.
Invoke project-analyzer first, before asking anything. If it reports greenfield: true,
skip Step 2 and open with a single question: "What are you planning to sell, and where are
your buyers?"
One sentence, in the user's language, naming the stack, deploy target, ORM and apparent product. Ask them to confirm or correct. Accept the correction and move on — never loop.
Ask via AskUserQuestion.
seller_country, buyer_regionsbilling_modeinstant_rail and from the methods catalog. → required_methodsUp to two more, only when they change the answer:
use_cases.json → ask its ask_if_below_threshold.Never ask: estimated monthly volume (indie hackers guess, and the guess is noise), or "do you want a merchant of record?" — they do not know what that is. Infer it.
Do ask, when the situation suggests it matters: how soon they need live keys. Some providers take weeks to approve, and recommending one the user cannot onboard to in time burns their week.
node scripts/advise.js --json '{
"seller_country": "MX",
"buyer_regions": ["MX","US"],
"billing_mode": "one_time",
"required_methods": ["oxxo"],
"entity_type": "individual",
"product_type": "digital_goods",
"platform": "web",
"use_cases": ["save_card_subscription"],
"needs_tax_automation": false,
"needs_keys_within_days": 7,
"example_amount": 500,
"example_currency": "MXN"
}'
It returns recommendation, candidates, rejected (with the filter and reason for each),
active_modifiers, disclosures, and either fallback_used or refused.
If refused is true, stop. The market is sanctioned. Say so plainly, quote the reason,
and do not offer a workaround.
In the user's language:
**I recommend: <name>.**
Why:
• <regional fit, from `why`>
• <currency and methods>
• <product-type fit>
What PagoKit will do for you:
<from integration_level — see the table below. State this every time.>
Cost on a typical charge:
<fee.explanation> → you receive <fee.net> <currency>.
Getting set up: <onboarding.model>, roughly <time_to_keys_days> days to keys.
⚠️ Things to know:
<the caveats array, verbatim in spirit>
<any disclosures — e-invoicing mandates, currency exponent, instant rail, installments>
Ready for me to implement it? (yes / show alternatives / ask something)
Data verified <last_verified_at>.
integration_level is not optional decoration — it is the honesty contract:
| Level | Say this |
|---|---|
build | "I'll write the whole integration: checkout, signed webhook, database, portal and refund." |
generic | "I'll write a working scaffold from this provider's verification family. Review it against their docs before going live — it isn't hand-tuned for them." |
advise | "I will not write this one for you. You get the recommendation, the fee maths and a production checklist; the code is yours to write from their docs." |
Never show the numeric score. It is internal. You may explain why something ranked
higher in plain words, drawing on modifiers and local_rank.
"Why not X?" has an exact answer — read it from rejected. Never improvise one.
Alternatives on demand only. The next one or two, with a single differentiating line each.
If the user has not said what they charge, pick a plausible figure and label it as an example: a digital good ~20 in the local unit, a SaaS subscription ~19/month, physical e-commerce ~50. Adjust for currencies where those numbers are absurd — and remember the engine already warns you when a currency has zero or three decimal places.
Once the user confirms, invoke the integration-specialist subagent with a fenced JSON block:
{
"provider": "<id from the recommendation>",
"integration_level": "build|generic|advise",
"stack": "<from project-analyzer>",
"deploy_target": "<from project-analyzer>",
"orm": "<from project-analyzer>",
"billing_mode": "one_time|subscription",
"frontend_style": "<from the provider's frontend_options; ask if more than one fits>",
"required_methods": ["..."],
"language": "es|en|pt",
"use_cases_detected": ["..."],
"example_transaction_amount": 0,
"example_currency": "XXX"
}
If integration_level is advise, do not invoke the subagent. Produce the checklist and
the provider's documentation links instead, and say clearly that the code is theirs to write.
Tell the subagent to finish by pointing the user at /pagokit:test and
PAGOKIT_PRODUCTION_CHECKLIST.md.
Append the legal and fiscal obligations for the detected market. The engine already surfaces
e-invoicing mandates in disclosures; add the data-protection regime for the buyer regions
(GDPR in the EU, LGPD in Brazil, LFPDPPP in Mexico, CCPA in California, PDPA in Argentina).
Cite SECURITY_RULES Rule 11.
Say the quiet part out loud where it applies: a successful payment is not a compliant sale. In Mexico and Brazil, issuing the fiscal document is a separate legal obligation — unless a merchant of record is doing it for them.
integration_level disclosure. A wide catalog is only honest because of it.SECURITY_RULES.md (opens in a new tab)data/currencies.json (opens in a new tab)data/methods.json (opens in a new tab)data/providers.index.json (opens in a new tab)data/providers.json (opens in a new tab)data/providers/adyen.json (opens in a new tab)data/providers/airwallex.json (opens in a new tab)data/providers/antom.json (opens in a new tab)data/providers/asaas.json (opens in a new tab)data/providers/authorize_net.json (opens in a new tab)data/providers/bold.json (opens in a new tab)data/providers/conekta.json (opens in a new tab)data/providers/culqi.json (opens in a new tab)data/providers/dlocal_go.json (opens in a new tab)data/providers/epayco.json (opens in a new tab)data/providers/fintoc.json (opens in a new tab)data/providers/flow_cl.json (opens in a new tab)data/providers/flutterwave.json (opens in a new tab)data/providers/gocardless.json (opens in a new tab)data/providers/hyperswitch.json (opens in a new tab)What SKILL.md sets; muted values are Claude Code's defaults
- The user invokes /pagokit:start - The user asks "which payment processor should I use", "X vs Y", "how do I accept payments in <country>" - The user mentions selling something and needing to charge for it
8 skills in this plugin
/doctorAudits an existing PagoKit integration in the current project against the generated per-provider checklist, so it covers every provider in the catalog rather than a hardcoded few. Checks .gitignore covers .env, that env vars are present and use test-key prefixes, that the webhook secret looks valid, that the webhook handler verifies signatures, that the minimum events for the integrated provider are routed, and that PAGOKIT_INTEGRATION.md exists. Used by /pagokit:doctor. Read-only — never writes files./integration-builderComposes a complete payment integration by resolving capability fragments against the chosen provider's catalog entry, then emits a structured file plan for integration-specialist to execute. Selects fragments by verification family, notification model and checkout pattern rather than by provider name, so a provider new to the catalog composes correctly without new templates. Refuses to emit a signature verifier when the provider's scheme is not verified, emitting re-fetch and an explicit TODO instead./payment-migratorPlans and executes a migration from one payment provider to another without downtime. Establishes what cannot move (stored card tokens usually cannot), maps the two providers' event vocabularies, flags architectural differences such as a change of notification model or a move to a merchant of record, and sequences a coexistence period rather than an atomic switch. Powers /pagokit:migrate./project-analyzerDetects a project's technology stack, framework, deploy target, ORM, primary language, and active payment use cases by reading package.json/pyproject.toml/composer.json/Gemfile, schema files, route files, and deploy configs. Use this skill at the start of any PagoKit flow to ground recommendations in the real project context. Emits a structured detection result for payment-advisor and integration-specialist to consume./subscription-lifecycleCovers everything after the subscription is created — trials, proration on upgrade and downgrade, dunning and retry schedules, grace periods, involuntary churn from expired cards, cancellation timing, and the bank-mandate lifecycle for SEPA, Bacs, PAD, UPI AutoPay and Pix Automatico. Also covers the stored-credential framework and the network transaction id that recurring charges must carry. This is the part every payment tutorial stops short of, and where production subscriptions actually break./tax-advisorExplains what a merchant owes the tax authority once a payment succeeds, and whether a merchant of record removes that obligation. Covers the merchant-of-record trade-off, e-invoicing mandates (CFDI, NF-e, DTE, SUNAT, DIAN, SRI, SdI, KSeF, ZATCA), EU VAT OSS, US economic nexus with home-rule jurisdictions, and when a tax engine is genuinely required. Reads the obligation from the catalog rather than recalling it. Never gives legal advice — it names the obligation and points at who can discharge it.npx claudepluginhub hainrixz/agente-pagokit --plugin pagokitOther plugins' skills for the same job