Skip to content

Conversation

@onmax
Copy link
Member

@onmax onmax commented Oct 27, 2025

Before: Missing Polygon & gasless tutorials
Expected: Complete OpenGSN v2 implementation

Changes:

  • Section 5: Polygon basics (wallet, POL, ERC20, USDT)
  • Section 6: Gasless transfers (static relay, discovery, fee optimization)
  • Follows Nimiq wallet: HttpClient + HttpWrapper, USDT nonces, MetaTransaction

Preview: https://tutorial-opengsn-gasless.pages.dev


TODO

  • dashes
  • references to @cashlink
  • ci

onmax and others added 10 commits October 27, 2025 12:50
- Section 5: Polygon basics (intro, wallet, POL, USDC)
- Section 6: Polygon & USDC (wallet, mainnet transfers)
- Section 7: Gasless transfers (OpenGSN v2.2.6)
  - Wallet setup, intro, gasful baseline
  - Static relay, relay discovery, optimized fees
  - Following Nimiq wallet implementation patterns
L6 updates:
- use getRequiredRelayGas() from contract
- Uniswap V3 quoter for POL/USDT pricing
- reduce lookback 10h→1h

L7 new:
- USDC EIP-2612 permit approval
- transferWithPermit vs transferWithApproval
- version-based domain separator
@cloudflare-workers-and-pages
Copy link

cloudflare-workers-and-pages bot commented Dec 4, 2025

Deploying with  Cloudflare Workers  Cloudflare Workers

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

Status Name Latest Commit Updated (UTC)
🔵 In progress
View logs
tutorials f4b9177 Dec 16 2025, 04:36 PM

@onmax
Copy link
Member Author

onmax commented Dec 4, 2025

todo

image

- remove @cashlink references
- update relay URL to polygon-relay.fastspot.io
- fix imports and lint errors
- TypedRequestData: use chainId as number, clean EIP712Domain
- Buffer: 20% mainnet (not 10%), remove double-buffer on fee
- LOOKBACK_BLOCKS: 1800 (matches ~1hr at 30 blocks/min)
- Gas limit: 300000 (from cash.link)
- USDC ABI: transferWithPermit 5th param is value not deadline
- Sync _files scaffolds with solution fixes
@onmax onmax merged commit 8aa70c5 into main Dec 16, 2025
1 of 2 checks passed
@onmax onmax deleted the tutorial/opengsn-gasless-usdc branch December 16, 2025 16:36
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.

3 participants