@blockrun/clawrouter 0.12.271 → 0.12.272

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
@@ -455,8 +455,11 @@ identically, and the tier now describes only endpoint weight.
455
455
  | Wallet — Base | **$0.0085** |
456
456
 
457
457
  Measured 2026-09-05: the API-key rate from the account ledger, the wallet rates
458
- from the x402 challenge, which quotes the price before anything is signed. On the
459
- wallet rail that quote is always authoritative.
458
+ from the x402 challenge, which quotes the price before anything is signed. That
459
+ quote is authoritative for the rail that issued it — the key rail issues no 402,
460
+ and the wallet quote includes a transaction fee account credit does not pay, so
461
+ the two are not interchangeable. Solana being cheaper than Base is deliberate
462
+ (the $0.001 is Base's transaction fee), not drift.
460
463
 
461
464
  **Usage (HTTP):**
462
465
 
@@ -660,11 +663,36 @@ npx @blockrun/clawrouter
660
663
  **3. Check it, and switch back whenever**
661
664
 
662
665
  ```bash
663
- clawrouter status # names the mode, the gateway, and the masked key
666
+ clawrouter status # names the mode, the gateway, the masked key and your credit
664
667
  clawrouter doctor # verifies the key against the gateway (401 = revoked or mistyped)
668
+ clawrouter reconcile # diff your local usage journal against BlockRun's billing ledger
665
669
  clawrouter logout # delete the key and go back to paying from the wallet
666
670
  ```
667
671
 
672
+ **Checking your bill without opening a dashboard.** `clawrouter reconcile`
673
+ compares what ClawRouter recorded locally against `GET /v1/usage` — BlockRun's
674
+ authoritative ledger — joined on the gateway's own request id:
675
+
676
+ ```
677
+ BlockRun reconciliation — last 7 days
678
+
679
+ Gateway charged: $12.41 (438 settled calls)
680
+ Journal recorded: $12.41
681
+ Matched: 438, of which 0 disagree on amount
682
+ ```
683
+
684
+ Three outcomes are worth acting on. **Amount mismatches** mean the local price
685
+ table has drifted from the gateway's. **Charged but not in this machine's
686
+ journal** is the one to look at hardest: money left the account for a call this
687
+ machine did not make — expected if the same key is used on another machine or by
688
+ another BlockRun product, and worth investigating if not. Exit code `2` in that
689
+ case, so a scheduled check can alert on it. Rows still **pending pricing** are
690
+ excluded from the totals rather than counted as $0.
691
+
692
+ Your per-call sum will always be less than your card statement by exactly the
693
+ top-up fees, which are charged at purchase and never appear as ledger rows. That
694
+ gap is arithmetic, not a discrepancy.
695
+
668
696
  **Using it directly, without ClawRouter.** The same key works against
669
697
  `api.blockrun.ai` from any OpenAI or Anthropic SDK — `Authorization: Bearer` for
670
698
  OpenAI clients, `x-api-key` for Anthropic ones: