spree-payments

spree-payments is a skill for Claude Code from spree/agent-skills. It costs 106 tokens per session (2,540 once invoked), scanned A, original, MIT.

A guide to payments in Spree Commerce, an open-source online-store system. It covers payment methods such as Stripe, Adyen, PayPal, store credit, and gift cards, along with charges, refunds, and payment states.

In plain words
What is it for?
Use it to add gateways, troubleshoot failed payments, manage payment sessions and refunds, and work with store credit or gift cards.
Why use it?
It makes the relationships and state changes between an order, its payment method, and the actual charge easier to handle correctly.

Skill for Claude Code

Written for Claude Code: shipped in a Claude Code plugin.

Part of the spree plugin — 26 skills, 2 commands, 1 agent, 2 hooks shipped together

Good fit Use it to add gateways, troubleshoot failed payments, manage payment sessions and refunds, and work with store credit or gift cards.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/spree/agent-skills/spree-payments
Install

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.

Any agent
npx skills add spree/agent-skills --skill spree-payments
Clone the repo
git clone --depth 1 https://github.com/spree/agent-skills

Made for: Claude Code.

Or install spree, the plugin that ships this one along with the rest of its 26 skills, 2 commands, 1 agent, 2 hooks.

Wrote 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.

agentmods badge for spree-payments

README.md
[![agentmods](https://agentmods.dev/badge/skills/spree/agent-skills/spree-payments/github.svg)](https://agentmods.dev/skills/spree/agent-skills/spree-payments)
Your own site
<a href="https://agentmods.dev/skills/spree/agent-skills/spree-payments"><img src="https://agentmods.dev/badge/skills/spree/agent-skills/spree-payments/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for spree-payments

Your own site · 80×15
<a href="https://agentmods.dev/skills/spree/agent-skills/spree-payments"><img src="https://agentmods.dev/badge/skills/spree/agent-skills/spree-payments.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 106 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,540 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe.
Origin original No closer match found in the catalogue.
Token cost

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.

ModelPer sessionOnce invoked
Fable 5.1 $0.00106 $0.02540
Opus 5 $0.00053 $0.01270
Sonnet 5 $0.00021 $0.00508
Haiku 4.5 $0.00011 $0.00254

Measured 9d ago against content hash bc3b56e3286d, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-09, from the pricing page.

Security

Grade A, and why

spree-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 9d 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.

skills/spree-payments/SKILL.md · 201 lines

How it starts

The opening of the file, as written. The whole thing — 201 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Spree Payments

Commands below use the Spree CLI form (spree …, Docker). On a classic Rails app without the CLI (typical pre-5.4), use the native mapping in the spree-project skill — bin/rails / bundle exec rake from the app root, paths without the backend/ prefix.

Payments in Spree are layered:

PaymentMethod   — the configured way to pay (Stripe, Adyen, PayPal, store credit, …)
  ↓
Payment         — the actual charge against an Order via a PaymentMethod
  ↓
source          — the Payment's polymorphic source: a CreditCard, StoreCredit, or Spree::PaymentSource (wallets/accounts)

(A PaymentSession is not a payment source — it links to the Payment via the gateway transaction id, response_code/external_id.)

A single Order can have multiple Payments (e.g. store credit or a gift card combined with a card payment), each with its own state. Creating a new non-store-credit payment auto-invalidates any other payment still in the checkout state (store credit payments are spared), so splitting an order across multiple cards at checkout isn't supported.

Payment state machine

checkout  →  processing  →  pending  →  completed
        ↘              ↘            ↘
         invalid        failed       void
State What it means
checkout Payment created during cart phase; no money moved yet
processing Gateway call in flight
pending Authorized but not captured (auth/capture flow, e.g. credit card pre-auth)
completed Captured — money has actually moved
failed Gateway returned an error during processing
void Cancelled — usually before capture, but completed payments can also be voided (gateway permitting)
invalid Superseded — a newer payment was added to the order (old checkout payments are auto-invalidated), or the source is unsupported by the gateway

Transitions are events: started_processing, pend, complete, failure, void, invalidate. After-callbacks fire payment.completed / payment.voided events. See the spree-events-webhooks skill.

Read the full file on GitHub · 201 lines

Changes

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.

  1. 9d ago First seen · 201 lines · 106 tokens per session scan A bc3b56e3286d

Subscribe to this mod's changes

spree-payments is a skill published in the GitHub repository spree/agent-skills (4 stars, last pushed 2mo ago), licensed MIT. It adds 106 tokens to every session and 2,540 once invoked, about $0.0005 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.

Related

Other skills, from other repositories

asc-ppp-pricing

Set territory-specific pricing for subscriptions and in-app purchases using current asc setup, pricing summary, price import, and price schedule commands. Use when adjusting prices by country or implementing localized PPP strategies.

rorkai/app-store-connect-cli-skills · 45 tokens

stripe

Stripe API integration with managed OAuth. Manage customers, subscriptions, invoices, products, prices, and payments. Use this skill when users want to process payments, manage billing, or handle subscriptions with Stripe. For other third party apps, use the api-gateway skill (https://clawhub.ai/byungkyu/api-gateway).…

CraftOS-dev/CraftBot · 79 tokens

etsy-pricing-strategy

Etsy pricing — cost calculation, competitor pricing, perceived value, shipping cost integration, sales and coupons.

nexscope-ai/eCommerce-Skills · 26 tokens

amazon-wholesale-sourcing

Wholesale product sourcing — supplier discovery, negotiation, MOQ optimization, margin analysis.

nexscope-ai/Amazon-Skills · 20 tokens

ai-slop

Operational rubric that turns "don't make AI slop" into observable properties, severity levels, evidence requirements, and repair actions for interface design. Use as the reference rubric when building or reviewing marketing sites, product interfaces, dashboards, portfolios, or e-commerce pages, especially alongside…

waybarrios/opencode-power-pack · 61 tokens

payment-processor

Skill "payment-processor" from Signal-Execution-Labs/forex-trading-ai-agent, covering payment processor skill, supported services, capabilities, view balances and get all balances.

Signal-Execution-Labs/forex-trading-ai-agent · 0 tokens