@rozoai/checkout 0.1.7 → 0.1.11

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md CHANGED
@@ -2,11 +2,34 @@
2
2
 
3
3
  **English** | [简体中文](docs/README.zh.md) | [日本語](docs/README.ja.md) | [Español](docs/README.es.md)
4
4
 
5
- Pay an **OpenRouter Coinbase Payment Link** with a coin that link cannot take
6
- directly — BTC over Lightning, or USDT/USDC on Solana, BNB Chain, Ethereum,
7
- Polygon, Base or Stellar. A Coinbase Payment Link only accepts USDC on Base;
8
- this routes the coin you actually hold through a bridge, and a funder wallet
9
- settles the invoice for you. No account, no API key, no browser.
5
+ ### When your agent needs to pay OpenRouter (or any Coinbase invoice) with the crypto you already hold
6
+
7
+ OpenRouter crypto top-ups and other Coinbase-hosted invoices settle in USDC on
8
+ Base. This skill pays them from whatever you hold instead, and it does three
9
+ things the official path cannot:
10
+
11
+ - **Pay from the chain you are already on.** USDT or USDC on Solana, BNB Chain,
12
+ Ethereum or Polygon, USDC on Base or Stellar, or BTC over Lightning. Coinbase's
13
+ own direct pay takes USDC on Base.
14
+ - **No Coinbase account.** Pay the deposit address from any wallet or straight
15
+ from an exchange withdrawal. No sign-up, no API key, no browser.
16
+ - **Scriptable.** OpenRouter's crypto credits API (`POST /api/v1/credits/coinbase`)
17
+ now returns `410 Gone`, so top-ups can no longer be automated there. Once you
18
+ have the payment link, paying it is one command an agent or a cron job can
19
+ run: without a terminal it stops for confirmation, so an unattended caller
20
+ reviews the quote and then passes `--yes`.
21
+
22
+ Merchants we have been paid through so far: **OpenRouter, Venice.ai, Porkbun
23
+ and Alchemy**. Any `payments.coinbase.com` link is quoted the same way.
24
+
25
+ Before you pay, know two things:
26
+
27
+ - **The fee is in the live quote.** You pay the full invoice, no discount and no
28
+ markup on it; the bridge and network fee is added to the deposit amount, which
29
+ is shown in the order summary before the deposit address is released. Send
30
+ exactly that amount, nothing more is charged.
31
+ - **Crypto payments to OpenRouter are never refundable.** That is OpenRouter's
32
+ policy, not ours; check the credit amount before you send.
10
33
 
11
34
  ```bash
12
35
  npx @rozoai/checkout pay <coinbase-link>
@@ -33,7 +56,7 @@ npx @rozoai/checkout pay <coinbase-link> --with usdt-solana
33
56
  | Base | `usdc-base` | `8453` | 6 decimals |
34
57
  | Solana | `usdt-solana` `usdc-solana` | `900` | SPL; native SOL not supported |
35
58
  | Stellar | `usdc-stellar` | `1500` | `MEMO_TEXT` memo required — shown in the deposit block |
36
- | Bitcoin Lightning | `btc-lightning` | `lightning` | BOLT11; amounts in satoshis |
59
+ | Bitcoin Lightning | `btc-lightning` | `lightning` | BOLT11; amounts in satoshis. Any wallet that can pay an invoice works, including Cashu/ecash wallets — the mint melts your ecash into the Lightning payment. |
37
60
 
38
61
  Native gas coins (SOL, BNB, ETH, MATIC) and on-chain BTC are not accepted.
39
62
 
@@ -52,13 +75,31 @@ already hold and pay from wherever it already lives.
52
75
  address plus `receiverMemo`, so whatever you send from — exchange or wallet —
53
76
  must let you set a memo. Omit it and the payment is lost.
54
77
  - **Lightning pays an invoice, not an address.** Scan or paste
55
- `deposit.lnInvoice`; there is no address to send to.
78
+ `deposit.lnInvoice`; there is no address to send to. A Cashu/ecash wallet
79
+ works here too — paying the invoice melts the ecash on your behalf, and this
80
+ route settles against ROZO's own Lightning node rather than a third-party
81
+ swap, so no special handling is needed on our side.
56
82
  - **Only `--send` needs a private key**, read from `ROZO_CHECKOUT_EVM_KEY` or
57
83
  `ROZO_CHECKOUT_SOL_KEY`, and it covers EVM chains and Solana only. Everything
58
84
  else is keyless.
59
85
 
60
86
  ## Use it from your agent
61
87
 
88
+ Install it as a skill, or just run the CLI:
89
+
90
+ ```text
91
+ # Claude Code
92
+ /plugin marketplace add RozoAI/rozo-checkout-skill
93
+ /plugin install rozo-checkout@rozo
94
+
95
+ # OpenClaw / ClawHub
96
+ clawhub install rozo-checkout
97
+
98
+ # Any agent that can run a shell: review the quote, then pay unattended
99
+ npx @rozoai/checkout quote <coinbase-link>
100
+ npx @rozoai/checkout pay <coinbase-link> --with usdt-solana --yes
101
+ ```
102
+
62
103
  The payload is the same everywhere: the one-liner above, or point the agent at
63
104
  [llms.txt](llms.txt). Agents and scripts should always pass `--with` — the
64
105
  picker only appears on a terminal, and there is deliberately no default coin. **Paying from your own wallet never needs a key.** Only
@@ -70,6 +111,8 @@ environment (or a gitignored `.env`) still works for unattended automation.
70
111
  <details>
71
112
  <summary><b>Set up a local wallet for <code>--send</code></b> — .env template and per-wallet export steps</summary>
72
113
 
114
+ You very likely do not need any of this: the default path needs no key, and for Stellar the `stellar-agent-wallet` skill sends with its own key handling — this `.env` setup is only for unattended EVM/Solana automation with a dedicated low-balance hot wallet.
115
+
73
116
  **None of this is needed for the default path.** Paying from your own wallet
74
117
  needs no key and no configuration, and works with wallets that can never be
75
118
  used here — including hardware wallets and exchange accounts.
@@ -269,7 +312,7 @@ Stellar and Lightning are Mode A only.
269
312
  <summary><b>Terminal — no agent at all</b> — run the scripts step by step</summary>
270
313
 
271
314
  Drive each step yourself. The bundles are self-contained; nothing to install
272
- beyond Node 18+.
315
+ beyond Node 20.18+.
273
316
 
274
317
  ```bash
275
318
  git clone https://github.com/RozoAI/rozo-checkout-skill && cd rozo-checkout-skill
@@ -343,6 +386,12 @@ The full list of what this refuses to do, and why, is in
343
386
 
344
387
  ## Changelog
345
388
 
389
+ - **0.1.11**: each order now carries `attribution.client`
390
+ (`rozo-checkout-skill/<version>`) so skill-created orders can be told apart
391
+ from the web checkout. Installable as a Claude Code plugin
392
+ (`/plugin marketplace add RozoAI/rozo-checkout-skill`). README and skill
393
+ description rewritten around paying Coinbase invoices from the crypto you
394
+ already hold.
346
395
  - **0.1.3** — fixes found by the first real payment. The built bundles no
347
396
  longer crash with `__filename is not defined` on Node 22+ (the esbuild banner
348
397
  now shims `__filename`/`__dirname` as well as `require`, and every bundle is
@@ -367,3 +416,7 @@ The full list of what this refuses to do, and why, is in
367
416
  ## License
368
417
 
369
418
  MIT.
419
+
420
+ ## Secret scanning
421
+
422
+ Enable the local gitleaks pre-commit hook once per clone: `brew install gitleaks pre-commit && pre-commit install` (config in `.pre-commit-config.yaml`). CI also runs a report-only scan in `.github/workflows/secret-scan.yml`.
@@ -224,6 +224,8 @@ Un archivo de claves o un `.env` no debe ser legible por otros usuarios
224
224
  <details>
225
225
  <summary><b>Configurar una billetera local para <code>--send</code></b> — plantilla .env y pasos de exportación por billetera</summary>
226
226
 
227
+ Muy probablemente no necesites nada de esto: la ruta por defecto no requiere ninguna clave, y para Stellar la skill `stellar-agent-wallet` envía con su propio manejo de claves — esta configuración `.env` es solo para automatización desatendida en EVM/Solana con una billetera caliente dedicada de saldo bajo.
228
+
227
229
  **Nada de esto hace falta para la ruta por defecto.** Pagar desde la propia
228
230
  billetera no necesita clave ni configuración, y funciona con billeteras que aquí
229
231
  nunca se pueden usar, incluidas las de hardware y las cuentas de exchange.
@@ -202,6 +202,8 @@ ROZO_CHECKOUT_EVM_KEYSTORE=~/wallets/hot.json \
202
202
  <details>
203
203
  <summary><b><code>--send</code> 用のローカルウォレット設定</b> — .env テンプレートとウォレット別の書き出し手順</summary>
204
204
 
205
+ おそらくこれらは一切不要です。既定の経路に鍵は不要で、Stellar なら `stellar-agent-wallet` スキルが独自の鍵管理で送金します — この `.env` 設定は、残高を低く抑えた専用ホットウォレットによる EVM/Solana の無人自動化専用です。
206
+
205
207
  **既定の経路ではここに書かれたものは一切不要です。** 自分のウォレットから支払う場合、
206
208
  鍵も設定も要りません。しかもここでは決して使えないウォレット — ハードウェアウォレットや
207
209
  取引所アカウントを含む — でも支払えます。
@@ -217,6 +217,8 @@ not be tracked by git. Both are refused rather than warned about.
217
217
  <details>
218
218
  <summary><b>Set up a local wallet for <code>--send</code></b> — .env template and per-wallet export steps</summary>
219
219
 
220
+ You very likely do not need any of this: the default path needs no key, and for Stellar the `stellar-agent-wallet` skill sends with its own key handling — this `.env` setup is only for unattended EVM/Solana automation with a dedicated low-balance hot wallet.
221
+
220
222
  **None of this is needed for the default path.** Paying from your own wallet
221
223
  needs no key and no configuration, and works with wallets that can never be
222
224
  used here — including hardware wallets and exchange accounts.
@@ -185,6 +185,8 @@ ROZO_CHECKOUT_EVM_KEYSTORE=~/wallets/hot.json \
185
185
  <details>
186
186
  <summary><b>为 <code>--send</code> 配置本地钱包</b> —— .env 模板与各钱包导出步骤</summary>
187
187
 
188
+ 你很可能完全不需要这些:默认路径不需要任何私钥;Stellar 来源可用 `stellar-agent-wallet` skill,它有自己的密钥管理来完成发送 —— 这份 `.env` 配置只用于无人值守的 EVM/Solana 自动化,且应使用余额很低的专用热钱包。
189
+
188
190
  **默认路径不需要这里的任何东西。** 用你自己的钱包付款既不需要私钥也不需要任何配置,
189
191
  而且支持那些在这里根本用不了的钱包 —— 包括硬件钱包和交易所账户。
190
192
 
package/docs/README.es.md CHANGED
@@ -239,6 +239,8 @@ Billetera: cualquier billetera, **sin clave**. Solo `--send` la necesita: firma
239
239
  <details>
240
240
  <summary><b>Configurar una billetera local para <code>--send</code></b> — plantilla .env y pasos de exportación por billetera</summary>
241
241
 
242
+ Muy probablemente no necesites nada de esto: la ruta por defecto no requiere ninguna clave, y para Stellar la skill `stellar-agent-wallet` envía con su propio manejo de claves — esta configuración `.env` es solo para automatización desatendida en EVM/Solana con una billetera caliente dedicada de saldo bajo.
243
+
242
244
  **Nada de esto hace falta para la ruta por defecto.** Pagar desde la propia
243
245
  billetera no necesita clave ni configuración, y funciona con billeteras que aquí
244
246
  nunca se pueden usar, incluidas las de hardware y las cuentas de exchange.
package/docs/README.ja.md CHANGED
@@ -232,6 +232,8 @@ https://checkout.rozo.ai/llms.txt を自分のコンテキストに読み込み
232
232
  <details>
233
233
  <summary><b><code>--send</code> 用のローカルウォレット設定</b> — .env テンプレートとウォレット別の書き出し手順</summary>
234
234
 
235
+ おそらくこれらは一切不要です。既定の経路に鍵は不要で、Stellar なら `stellar-agent-wallet` スキルが独自の鍵管理で送金します — この `.env` 設定は、残高を低く抑えた専用ホットウォレットによる EVM/Solana の無人自動化専用です。
236
+
235
237
  **既定の経路ではここに書かれたものは一切不要です。** 自分のウォレットから支払う場合、
236
238
  鍵も設定も要りません。しかもここでは決して使えないウォレット — ハードウェアウォレットや
237
239
  取引所アカウントを含む — でも支払えます。
package/docs/README.zh.md CHANGED
@@ -214,6 +214,8 @@ node scripts/dist/status.js --rozo-payment-id <uuid> --watch
214
214
  <details>
215
215
  <summary><b>为 <code>--send</code> 配置本地钱包</b> —— .env 模板与各钱包导出步骤</summary>
216
216
 
217
+ 你很可能完全不需要这些:默认路径不需要任何私钥;Stellar 来源可用 `stellar-agent-wallet` skill,它有自己的密钥管理来完成发送 —— 这份 `.env` 配置只用于无人值守的 EVM/Solana 自动化,且应使用余额很低的专用热钱包。
218
+
217
219
  **默认路径不需要这里的任何东西。** 用你自己的钱包付款既不需要私钥也不需要任何配置,
218
220
  而且支持那些在这里根本用不了的钱包 —— 包括硬件钱包和交易所账户。
219
221
 
@@ -0,0 +1,77 @@
1
+ # Review history
2
+
3
+ [← back to the README](../README.md) · [Safety design](safety.md)
4
+
5
+ This tool moves other people's money. It was reviewed adversarially before it
6
+ was written, again after it was written, and again after the first real payment.
7
+ This page is the record of that.
8
+
9
+ ## Design review — 3 rounds, before any code existed
10
+
11
+ The design was written as a plan document and reviewed by an independent model
12
+ with a standing instruction to hunt for anything that could lose funds. No code
13
+ was written until the plan passed with no P0 findings.
14
+
15
+ | Round | Verdict |
16
+ |---|---|
17
+ | 1 | 6 P0, 7 P1, 2 P2 — plan revised |
18
+ | 2 | still had P0s: several round-1 fixes were incomplete, plus one new P0 — plan revised again |
19
+ | 3 | no P0 — implementation began |
20
+
21
+ The P0s were about the plan being wrong regarding the payment rails, not about
22
+ style. Among them: the reuse rule was mis-stated (an existing order is reused
23
+ whenever it is merely unexpired, not only when it is unpaid); the binding
24
+ confirmation was placed before the deposit details existed, so it could not
25
+ bind them; and the payment link could be consumed by another payer between the
26
+ quote and the signature, which needed a re-check immediately before paying.
27
+
28
+ ## Code review — 2 rounds, after implementation
29
+
30
+ | Round | Verdict |
31
+ |---|---|
32
+ | 1 | 8 P0, 10 P1, 5 P2 |
33
+ | 2 | 20 of 23 resolved; 3 residual findings, then fixed |
34
+
35
+ The round-1 P0s were the interesting ones, and each is now a real code path
36
+ with its own error code and tests:
37
+
38
+ - the confirmation gate and the `--send` opt-in were documented but not
39
+ actually enforced
40
+ - the send-once claim was a check-then-act race that two concurrent processes
41
+ could both pass
42
+ - an unreadable `amountReceived` was treated as "no money received" rather than
43
+ as money
44
+ - the post-create comparison ignored security-critical fields when they were
45
+ simply absent
46
+ - payability was not re-proved immediately before signing, and incomplete
47
+ upstream state read as payable
48
+ - deposit instructions were not validated for completeness before being shown
49
+ - provider errors could leak credential-bearing URLs
50
+ - the tracked-secret check failed open when it could not consult git
51
+
52
+ ## First real payment
53
+
54
+ A live payment then settled in about a minute — and surfaced four more defects,
55
+ all fixed in 0.1.3:
56
+
57
+ - the built bundles crashed on newer Node because the bundler's CommonJS shim
58
+ was incomplete; it had never been caught because only `--help` was ever run
59
+ against a built bundle. The test suite now executes every bundle.
60
+ - the Stellar memo type was not stated anywhere, and sending that memo with the
61
+ wrong type loses the payment. It is `MEMO_TEXT`, and the deposit block now
62
+ says so.
63
+ - reusing an existing unpaid order, and asking for a coin that differs from it,
64
+ both read as errors rather than as the ordinary situations they are
65
+ - nothing showed how long an order had left, and a real payment nearly missed
66
+ its window
67
+
68
+ ## What this means for a reader
69
+
70
+ Every finding above is closed, and the behaviours they produced are covered by
71
+ the test suite, which runs entirely offline against recorded fixtures. The full
72
+ list of what this tool refuses to do, and why, is in
73
+ [docs/safety.md](safety.md).
74
+
75
+ The detailed review transcripts are kept internally; they quote source from
76
+ private repositories and so are not published here. The findings themselves are
77
+ summarised above in full — nothing material is omitted.
@@ -0,0 +1,30 @@
1
+ # Security-audit notes for scanners and reviewers
2
+
3
+ What automated scans flag in this skill, and why each pattern is present.
4
+
5
+ ## `env_credential_access` — environment variable read + network send
6
+
7
+ Real and by design, in exactly two places: `send-evm.js` reads
8
+ `ROZO_CHECKOUT_EVM_KEY` (or an encrypted keystore) and `send-sol.js` reads
9
+ `ROZO_CHECKOUT_SOL_KEY`, to sign a transfer the user has already confirmed
10
+ twice (`--confirm` on the order, `--send` on the send). That is the entire
11
+ optional hot-wallet mode ("Mode B" in SKILL.md); the default mode never
12
+ touches a key. Mitigations, all enforced in code, not prose:
13
+
14
+ - keys come from the environment or a named file only — never argv, never
15
+ printed, scrubbed from every output object (`forget()` in `lib/keys.mjs`);
16
+ - a `.env` is only read from the working directory, this tool's own
17
+ `~/.rozo-checkout/.env`, or a path the user names with `--env-file`; a
18
+ generic `~/.env` is never read;
19
+ - sends refuse if any `.env` here is git-tracked, refuse over the $1,100
20
+ per-payment cap, re-verify chain id and token decimals against the RPC, and
21
+ record the send locally before broadcast so the same order cannot pay twice.
22
+
23
+ ## `dangerous_exec` — subprocess execution
24
+
25
+ Removed in 0.1.9. Earlier versions shelled out to `git rev-parse` /
26
+ `git ls-files` for one purpose: refusing to use hot-wallet keys from a
27
+ directory whose `.env` is git-tracked. The check now reads `.git/index`
28
+ directly (`lib/keys.mjs`), so the published bundle contains no
29
+ `child_process` usage at all. The fail-closed contract is unchanged — an
30
+ unparseable index refuses rather than assumes.
package/llms.txt CHANGED
@@ -1,8 +1,10 @@
1
1
  # rozo-checkout
2
2
 
3
- > Pay an OpenRouter Coinbase Payment Link (payments.coinbase.com/payment-links/pl_* or
4
- > /payment-sessions/paymentSession_*) with BTC over Lightning, or USDT/USDC on Solana,
5
- > BNB Chain, Ethereum, Polygon, Base, or Stellar. Public HTTP endpoints, no API key.
3
+ > When your agent needs to pay OpenRouter (or any Coinbase invoice) with the crypto you
4
+ > already hold. Pays a Coinbase Payment Link (payments.coinbase.com/payment-links/pl_* or
5
+ > /payment-sessions/paymentSession_*) with BTC over Lightning, USDT/USDC on Solana,
6
+ > BNB Chain, Ethereum or Polygon, or USDC on Base or Stellar. No Coinbase account, public HTTP
7
+ > endpoints, no API key. Crypto payments to OpenRouter are never refundable.
6
8
  > The payer funds a one-time deposit address; a bridge and a funder wallet settle the
7
9
  > Coinbase link automatically. No discount: you pay the invoice amount, plus the
8
10
  > deposit normally carries a small bridge/source-chain fee on top.
package/package.json CHANGED
@@ -1,8 +1,8 @@
1
1
  {
2
2
  "name": "@rozoai/checkout",
3
- "version": "0.1.7",
3
+ "version": "0.1.11",
4
4
  "type": "module",
5
- "description": "Pay an OpenRouter Coinbase Payment Link with BTC Lightning, or USDT/USDC on Solana, BNB Chain, Ethereum, Polygon, Base or Stellar.",
5
+ "description": "Pay OpenRouter, or any Coinbase invoice, with the crypto you already hold: USDT/USDC on Solana, BNB Chain, Ethereum or Polygon, USDC on Base or Stellar, or BTC over Lightning. No Coinbase account.",
6
6
  "license": "MIT",
7
7
  "author": "Rozo AI",
8
8
  "homepage": "https://github.com/RozoAI/rozo-checkout-skill#readme",
@@ -15,13 +15,29 @@
15
15
  },
16
16
  "keywords": [
17
17
  "openrouter",
18
+ "openrouter-credits",
18
19
  "coinbase",
19
- "x402",
20
- "lightning",
21
- "solana",
22
- "usdt",
20
+ "coinbase-payment-link",
23
21
  "usdc",
24
- "crypto-payments"
22
+ "usdt",
23
+ "solana",
24
+ "bnb-chain",
25
+ "ethereum",
26
+ "polygon",
27
+ "base",
28
+ "stellar",
29
+ "lightning",
30
+ "bitcoin",
31
+ "crypto-payments",
32
+ "agent",
33
+ "ai-agent",
34
+ "agent-skill",
35
+ "claude-skill",
36
+ "claude-code",
37
+ "payments",
38
+ "cli",
39
+ "mcp-free",
40
+ "x402"
25
41
  ],
26
42
  "bin": {
27
43
  "rozo-checkout": "scripts/dist/cli.js"
@@ -35,7 +51,7 @@
35
51
  "LICENSE"
36
52
  ],
37
53
  "engines": {
38
- "node": ">=18"
54
+ "node": ">=20.18.0"
39
55
  },
40
56
  "publishConfig": {
41
57
  "access": "public"
@@ -47,9 +63,13 @@
47
63
  "prepack": "npm run build"
48
64
  },
49
65
  "devDependencies": {
50
- "@solana/spl-token": "^0.4.9",
51
66
  "@solana/web3.js": "^1.95.0",
52
67
  "esbuild": "^0.28.2",
53
68
  "viem": "^2.21.0"
69
+ },
70
+ "overrides": {
71
+ "jayson": {
72
+ "uuid": "^11.1.1"
73
+ }
54
74
  }
55
75
  }