Getting it into your agent
One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.
npx agentmods add skills/kouroshez/coding-os/paymentsnpx skills add kouroshez/coding-os --skill paymentsgit clone --depth 1 https://github.com/kouroshez/coding-osWrote this? Show the measurements
A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.
[](https://agentmods.dev/skills/kouroshez/coding-os/payments)<a href="https://agentmods.dev/skills/kouroshez/coding-os/payments"><img src="https://agentmods.dev/badge/skills/kouroshez/coding-os/payments.svg" alt="Measured on agentmods" height="20"></a>What it costs to keep this loaded
Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.
| Model | Per session | Once invoked |
|---|---|---|
| Fable 5 | $0.00200 | $0.02172 |
| Opus 5 | $0.00100 | $0.01086 |
| Sonnet 5 | $0.00040 | $0.00434 |
| Haiku 4.5 | $0.00020 | $0.00217 |
Grade A, and why
payments scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured 4d ago.
A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.
Nothing flagged
None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.
How it starts
The opening of the file, as written. The whole thing — 103 lines — stays where its author put it; the contents beside it link to each section on GitHub.
Payments & Billing — Moving Money Without Losing It
A practical guide to integrating a payment provider such that money is never double-charged, never silently lost, and always reconcilable. Stack-agnostic; recipes target Stripe as the reference provider, with Adyen / Braintree / PayPal noted where the model differs. The governing mindset: a payment bug is a money bug, and money bugs are visible to finance, regulators, and angry customers.
When to Use This Skill
- Wiring a first charge / checkout — payment intents, hosted fields, confirmation flow.
- Handling a provider webhook (
payment_intent.succeeded,charge.refunded,invoice.paid). - Designing a subscription, metered/usage billing, free trial, proration, or dunning flow.
- Making money movement idempotent — a retried request must never charge twice.
- Issuing refunds, handling disputes/chargebacks, partial captures.
- Reconciling provider state against an internal ledger; closing the books.
Skip when: the work is a generic non-money API endpoint (api-design) or generic auth/injection hardening (security-web) with no money movement — those skills own that. This skill is specifically the financial-correctness layer.
The Five Money-Correctness Invariants
These override convenience every time:
- Never trust a client-sent amount. The price is computed server-side from the cart/plan, never read from the request body. A client that POSTs
{"amount": 1}for a $1000 order must be charged $1000. This is the single most exploited payments bug. - Every money mutation is idempotent. A charge/capture/refund call carries an idempotency key derived from the business intent (e.g.
order_id), so a network retry returns the original result instead of moving money again. (api-design owns the generic idempotency-key mechanics; this skill mandates it for money.) - The provider webhook is the source of truth for state, not the API response. The synchronous create-charge response can be lost (timeout) while the charge still succeeds. Treat the charge as
pendinguntil the webhook confirms; reconcile on the webhook. - Money is integer minor units, never a float. Store
amount_cents(or the currency's minor unit) as an integer.0.1 + 0.2 != 0.3in floating point — that rounding error is a regulatory finding. - Every movement is double-entry on an append-only ledger. A charge debits one account and credits another; the ledger is immutable (corrections are reversing entries, never edits). This is what makes reconciliation and audit possible. (db-design owns the ledger schema; this skill owns the discipline.)
What this file has done since we first saw it
Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.
- 4d ago First seen · 103 lines · 200 tokens per session scan A a7c48c5cd720
payments is a skill published in the GitHub repository kouroshez/coding-os (6 stars, last pushed 4d ago), licensed Apache-2.0. It adds 200 tokens to every session and 2,172 once invoked, about $0.0010 per session on Opus 5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-31.
Other skills, from other repositories
txline-sharp-agent
Point an agent at the paywalled TxLINE World Cup odds API with Gecko (one line, no integration code), monitor the feed, and flag sharp implied-probability moves — the signal for a trading tool or an on-chain prediction market. Runs $0 in recorded mode. Use when building a Solana sports-trading agent, a…
financial-memo-writer
Write investment-research memos and articles in a sincere, contrarian, framework-first zh-TW (Taiwan-market) voice. Use when asked to draft, ghost-write, or continue an in-depth analysis (深度分析), a multi-topic weekly market note (週度市場筆記), or a short column/op-ed (短評/專欄), or to rewrite content into a…
sf-knowledge-financial-services-cloud-object-reference
Apply Salesforce knowledge and best practices for Agentforce Financial Services Developer Guide.
sf-knowledge-asl-dev-guide
Apply Salesforce knowledge and best practices for Accounting Subledger Developer Guide.
duanyongping-perspective
段永平的思维框架与表达方式。基于雪球原帖、巴菲特午餐实录、浙大演讲、 8个关键决策记录和完整人生时间线的深度调研, 提炼5个核心心智模型、7条决策启发式和完整的表达DNA。 用途:作为思维顾问,用段永平的视角分析投资决策、企业经营、人生选择等问题。 当用户提到「用段永平的视角」「段永平会怎么看」「段永平模式」「大道视角」时使用。 即使用户只是说「帮我用段永平的角度想想」「如果段永平会怎么做」「切换到大道」也应触发。.
sector-rotation
行业轮动分析——申万行业景气度评分、行业动量排名、产业链传导、估值/盈利/资金流多维比较框架.