Skip to content

Support USDC Paymaster#18

Merged
johnson86tw merged 15 commits intomainfrom
feat/usdc-paymaster
Aug 1, 2025
Merged

Support USDC Paymaster#18
johnson86tw merged 15 commits intomainfrom
feat/usdc-paymaster

Conversation

@johnson86tw
Copy link
Member

@johnson86tw johnson86tw commented Jul 29, 2025

  • USDC Paymaster Addresses
  • useTxModal is a store, while usePaymaster and useUsdcPaymaster are composables.
  • TxModal only imports useTxModal; useTxModal depends on and exports usePaymaster, and usePaymaster depends on and exports useUsdcPaymaster.
  • Added TransactionStatus.PreparingPaymaster: when the user selects the USDC paymaster but does not have allowance, they must sign a permit signature to use the USDC paymaster. In this state, the "estimate gas" button is not shown. Only after the user signs the permit signature does the TxModal state switch to Initial, at which point the "estimate" button appears.
  • When TxModal opens, we set the entrypoint address supported by the currently selected account into the blockchain store.
  • Even if the account is not yet deployed, the USDC paymaster can still be used; however, the permit signature cannot be verified because the account is not deployed.
  • The USDC paymaster is only available on supported chains according to the entrypoint version.
  • The design of sign1271 is somewhat inelegant—only Kernel requires an extra typed data wrapper. All other contracts can simply use the formatSignature approach.

@cloudflare-workers-and-pages
Copy link

cloudflare-workers-and-pages bot commented Jul 29, 2025

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Preview URL Updated (UTC)
✅ Deployment successful!
View logs
samanager a1534c5 Commit Preview URL

Branch Preview URL
Aug 01 2025, 02:38 AM

@johnson86tw johnson86tw force-pushed the feat/usdc-paymaster branch from fb8276d to a7e402c Compare July 31, 2025 10:46
@johnson86tw johnson86tw merged commit 08a0633 into main Aug 1, 2025
1 check passed
@johnson86tw johnson86tw deleted the feat/usdc-paymaster branch August 1, 2025 02:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant