Commit 320537d
spec: authCapture (replaces commerce) (#42)
## Summary
- Adds the **`authCapture`** scheme spec — cross-VM abstract
(`scheme_authCapture.md`) + EVM implementation
(`scheme_authCapture_evm.md`).
- Retires the obsolete `commerce` scheme spec (`scheme_commerce.md` +
`scheme_commerce_evm.md`).
- Spec-only PR — no code changes. The companion @x402r/evm
implementation lands separately in #40.
## Why this is a separate PR
The original PR #40 bundled spec + implementation; this PR carves the
spec out so reviewers can read the protocol surface without wading
through the @x402r/evm code diff. PR #40 is now strictly the
implementation.
## What's in the EVM spec
- `extra` field schema (`captureAuthorizer`, `captureDeadline`,
`refundDeadline`, `feeRecipient`, `min/maxFeeBps`, `autoCapture`,
`assetTransferMethod`)
- Wire format for ERC-3009 and Permit2 payloads
- Spec → on-chain `PaymentInfo` field mapping (preserves canonical
Solidity names so the EIP-712 typehash matches the contract
byte-for-byte)
- Verification + settlement logic
- **Canonical Addresses appendix**: deterministic CREATE2 addresses for
`AuthCaptureEscrow`, `ERC3009PaymentCollector`,
`Permit2PaymentCollector` — same address on every supported EVM chain,
with salt labels so anyone can reproduce
- 14-chain deployed-chain table with per-chain `assetTransferMethod`
constraint (BSC + Tempo are Permit2-only because their canonical stables
lack ERC-3009)
## Test plan
- [ ] Reviewer reads `scheme_authCapture.md` for the abstract scheme
- [ ] Reviewer reads `scheme_authCapture_evm.md` for the EVM
implementation contract
- [ ] Cross-checks the Canonical Addresses table against the upstream
`base/[email protected]` source repo's deploy script
🤖 Generated with [Claude Code](https://claude.com/claude-code)
---------
Co-authored-by: Claude Opus 4.7 (1M context) <[email protected]>1 parent c8f96ad commit 320537d
4 files changed
Lines changed: 402 additions & 324 deletions
File tree
- specs/schemes
- authCapture
- commerce
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
| 9 | + | |
| 10 | + | |
| 11 | + | |
| 12 | + | |
| 13 | + | |
| 14 | + | |
| 15 | + | |
| 16 | + | |
| 17 | + | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
| 22 | + | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
| 29 | + | |
| 30 | + | |
| 31 | + | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
| 38 | + | |
| 39 | + | |
| 40 | + | |
| 41 | + | |
| 42 | + | |
| 43 | + | |
| 44 | + | |
| 45 | + | |
| 46 | + | |
| 47 | + | |
| 48 | + | |
| 49 | + | |
| 50 | + | |
| 51 | + | |
| 52 | + | |
| 53 | + | |
| 54 | + | |
| 55 | + | |
| 56 | + | |
| 57 | + | |
| 58 | + | |
| 59 | + | |
| 60 | + | |
| 61 | + | |
| 62 | + | |
| 63 | + | |
| 64 | + | |
| 65 | + | |
| 66 | + | |
| 67 | + | |
| 68 | + | |
| 69 | + | |
| 70 | + | |
| 71 | + | |
| 72 | + | |
| 73 | + | |
| 74 | + | |
| 75 | + | |
| 76 | + | |
| 77 | + | |
| 78 | + | |
| 79 | + | |
| 80 | + | |
| 81 | + | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
| 85 | + | |
0 commit comments