Skip to content

fix(cli-sdk): add multi-chain gas support, refuel, and receipt verification#45

Merged
arein merged 2 commits intomainfrom
feat/swidge-refuel-and-receipt-verification
Mar 10, 2026
Merged

fix(cli-sdk): add multi-chain gas support, refuel, and receipt verification#45
arein merged 2 commits intomainfrom
feat/swidge-refuel-and-receipt-verification

Conversation

@arein
Copy link
Member

@arein arein commented Mar 10, 2026

Summary

  • Expand EVM chain support from 3 to 8 chains with per-chain gasToken and gasCost rankings
  • Add automatic gas refuel before cross-chain bridges — detects when destination chain has no native gas and bridges a small amount first
  • Add on-chain receipt verification after send-transaction — reports confirmed/reverted with gas usage
  • Export rpcUrl, waitForReceipt, and TxReceipt for downstream CLI consumers (e.g. hyperliquid-cli fund command)
  • Smart source chain selection: prefer cheapest gas chains with sufficient balance
  • Use per-chain gas token names (POL, HYPE, etc.) instead of hardcoded "ETH"
  • Add Hyperliquid (HyperEVM, eip155:999) to default EVM chain aliases

Test plan

  • pnpm build passes across all 5 packages
  • walletconnect swidge tested end-to-end (ETH→USDC cross-chain)
  • walletconnect send-transaction receipt verification tested (confirmed + reverted cases)
  • Refuel logic tested (auto-bridge gas to destination chain)
  • TTY prompt path for refuel (interactive y/n)
  • Non-TTY pipe mode auto-refuel

🤖 Generated with Claude Code

arein and others added 2 commits March 10, 2026 17:25
…cation

- Expand EVM_CHAINS from 3 to 8 chains with gasToken and gasCost fields
- Add automatic destination gas refuel before cross-chain bridges
- Use _isRefuel flag to prevent recursive refuel operations
- Add on-chain receipt verification after send-transaction (confirmed/reverted)
- Export rpcUrl, waitForReceipt, and TxReceipt for use by CLI consumers
- Prefer cheapest gas chains when selecting bridge source
- Use per-chain gas token names instead of hardcoded "ETH"
- Add Hyperliquid (HyperEVM) to default EVM chain aliases

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
@arein arein merged commit 4d091c0 into main Mar 10, 2026
2 of 3 checks passed
@github-actions github-actions bot mentioned this pull request Mar 10, 2026
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