johnalbertini14-glitch/openclaw-skills / skills/0xbreadguy/megaeth-ai-developer-skills
megaeth-developer
VerifiedEnd-to-end MegaETH development playbook (Feb 2026). Covers wallet operations, token swaps (Kyber Network), eth_sendRawTransactionSync (EIP-7966) for instant receipts, JSON-RPC batching, real-time mini-block subscriptions, storage-aware contract patterns (Solady RedBlackTreeLib), MegaEVM gas model, WebSocket keepalive, bridging from Ethereum, and debugging with mega-evme. Use when building on MegaETH, managing wallets, sending transactions, or deploying contracts.
| File | Kind | Size |
|---|---|---|
| SKILL.md | skill md | 4.5 KB |
| _meta.json | config | 300 B |
| frontend-patterns.md | markdown | 6.4 KB |
| gas-model.md | markdown | 3.6 KB |
| resources.md | markdown | 5.4 KB |
| rpc-methods.md | markdown | 9.0 KB |
| security.md | markdown | 4.5 KB |
| smart-contracts.md | markdown | 10.3 KB |
| storage-optimization.md | markdown | 3.4 KB |
| testing.md | markdown | 3.8 KB |
| wallet-operations.md | markdown | 7.6 KB |
resources.md
View on GitHub# Resources
## Official Documentation
- **MegaETH Docs**: https://docs.megaeth.com
- **Real-time API**: https://docs.megaeth.com/realtime-api
- **Testnet Guide**: https://docs.megaeth.com/testnet
- **Frontier (Mainnet)**: https://docs.megaeth.com/frontier
## Source Code
- **MegaEVM**: https://github.com/megaeth-labs/mega-evm
- **MegaEVM Spec (MiniRex)**: https://github.com/megaeth-labs/mega-evm/blob/main/specs/MiniRex.md
## Token List
**Official:** https://github.com/megaeth-labs/mega-tokenlist
The canonical source for verified token addresses, symbols, decimals, and logos on MegaETH. Use this repo to:
- Look up token contract addresses
- Get token metadata (name, symbol, decimals)
- Access official token logos
- Verify token legitimacy
## Tools
### Warren Deploy (On-Chain Websites)
Deploy websites and files permanently on MegaETH using SSTORE2:
- **Skill**: https://clawdhub.ai/planetai87/warren-deploy
- **Website**: https://megawarren.xyz
- **Install**: `clawdhub install warren-deploy`
Features:
- SSTORE2 bytecode storage (cheap reads)
- Automatic chunking for large files (up to 500KB)
- MegaETH-specific gas estimation
- Stress test workflows
### mega-evme CLI
Transaction replay and debugging:
```bash
git clone https://github.com/megaeth-labs/mega-evm
cd mega-evm/bin/mega-evme
cargo build --release
```
### Gas Profiler
Opcode-level gas analysis:
https://github.com/megaeth-labs/mega-evm/blob/main/scripts/trace_opcode_gas.py
## Block Explorers
| Network | Explorer |
|---------|----------|
| Mainnet | https://mega.etherscan.io |
| Testnet | https://megaeth-testnet-v2.blockscout.com |
| Uptime | https://uptime.megaeth.com |
## RPC Providers
| Provider | Type | Notes |
|----------|------|-------|
| MegaETH | Public | Rate limited |
| Alchemy | Managed | Geo-distributed |
| QuickNode | Managed | Geo-distributed |
**Mainnet**: `https://mainnet.megaeth.com/rpc`
**Testnet**: `https://carrot.megaeth.com/rpc`
## Standards
### EIP-6909 (Minimal Multi-Token)
Simplified alternative to ERC-1155 — no callbacks, minimal interface, granular approvals:
https://eips.ethereum.org/EIPS/eip-6909
**Why use on MegaETH:**
- Single contract for multiple tokens (fewer SSTORE operations)
- No mandatory callbacks (less gas)
- Solady provides gas-optimized implementation
### EIP-7966 (eth_sendRawTransactionSync)
Synchronous transaction submission with immediate receipt:
https://ethereum-magicians.org/t/eip-7966-eth-sendrawtransactionsync-method/24640
**Note:** MegaETH originally created `realtime_sendRawTransaction`. The `eth_sendRawTransactionSync` method was later standardized as EIP-7966. MegaETH proxies both — they are functionally equivalent. Use `eth_sendRawTransactionSync` for cross-chain compatibility.
Supported in:
- viem (native)
- wagmi (native)
- ethers.js (via custom provider)
## Indexers
### Envio HyperSync
High-performance historical data queries:
https://docs.envio.dev/docs/HyperSync/overview
Recommended for:
- Large `eth_getLogs` queries
- Historical trade data
- Event indexing
## Libraries
### Solady
Gas-optimized Solidity utilities:
https://github.com/Vectorized/solady
Key for MegaETH:
- `RedBlackTreeLib` — storage-efficient mappings
- `SafeTransferLib` — optimized token transfers
### viem
TypeScript Ethereum library:
https://viem.sh
MegaETH chain config:
```typescript
import { defineChain } from 'viem';
export const megaeth = defineChain({
id: 4326,
name: 'MegaETH',
nativeCurrency: { name: 'Ether', symbol: 'ETH', decimals: 18 },
rpcUrls: {
default: { http: ['https://mainnet.megaeth.com/rpc'] }
}
});
```
## DEX Aggregator
### Kyber Network
MegaETH uses Kyber Network for token swaps:
- **Aggregator API**: `https://aggregator-api.kyberswap.com/megaeth/api/v1`
- **Docs**: https://docs.kyberswap.com/kyberswap-solutions/kyberswap-aggregator
Features:
- Best-route across multiple DEXs
- MEV protection
- Gas-optimized execution
## Bridges
### Canonical Bridge (OP Stack)
Ethereum ↔ MegaETH:
| Contract | Address (Ethereum) |
|----------|-------------------|
| L1StandardBridgeProxy | `0x0CA3A2FBC3D770b578223FBB6b062fa875a2eE75` |
| OptimismPortalProxy | `0x7f82f57F0Dd546519324392e408b01fcC7D709e8` |
Simple ETH bridge: Send ETH directly to L1StandardBridgeProxy.
## Predeployed Contracts (MegaETH)
| Contract | Address |
|----------|---------|
| WETH9 | `0x4200000000000000000000000000000000000006` |
| Multicall3 | `0xcA11bde05977b3631167028862bE2a173976CA11` |
| High-Precision Timestamp | `0x6342000000000000000000000000000000000002` |
| MEGA Token | `0x28B7E77f82B25B95953825F1E2eA0E36c1c29861` |
See OP Stack docs for full predeploy list.
## Security
### Auditors
Recommended by MegaETH team:
- **Spearbit**: https://spearbit.com
- **Cantina**: https://cantina.xyz
### Monitoring
Consider runtime monitoring for:
- Unusual gas patterns
- Failed transaction spikes
- Storage cost anomalies
## Community
- **Discord**: (contact MegaETH team)
- **Twitter**: @megaeth_labs
## Quick Reference
```bash
# Check balance
cast balance <address> --rpc-url https://mainnet.megaeth.com/rpc
# Send transaction
cast send <to> --value 0.01ether --rpc-url https://mainnet.megaeth.com/rpc
# Call contract
cast call <contract> "method(args)" --rpc-url https://mainnet.megaeth.com/rpc
# Get gas price (always 0.001 gwei)
cast gas-price --rpc-url https://mainnet.megaeth.com/rpc
# Deploy with Foundry
forge script Deploy.s.sol --rpc-url https://mainnet.megaeth.com/rpc --broadcast --skip-simulation
```
Related skills
| Skill | Stars | Updated | Works with | Status | Install |
|---|---|---|---|---|---|
| writing-skillsobra/superpowersUse when creating new skills, editing existing skills, or verifying skills work before deployment | Stars: 322k | Updated | Claude CodeCodex | Verified | Install |
| xlsxanthropics/skillsUse this skill any time a spreadsheet file is the primary input or output. This means any task where the user wants to: open, read, edit, or fix an existing .xlsx, .xlsm, .xltx, .csv, or .tsv file (e.g., adding columns, computing formulas, formatting, charting, cleaning messy data); create a new spreadsheet from scratch or from other data sources; or convert between tabular file formats. Trigger especially when the user references a spreadsheet file by name or path — even casually (like "the xlsx in my downloads") — and wants something done to it or produced from it. Also trigger for cleaning or restructuring messy tabular data files (malformed rows, misplaced headers, junk data) into proper spreadsheets. The deliverable must be a spreadsheet file. Do NOT trigger when the primary deliverable is a Word document, HTML report, standalone Python script, database pipeline, or Google Sheets API integration, even if tabular data is involved. | Stars: 198k | Updated | Claude CodeCodex | Verified | Install |
| shipping-and-launchaddyosmani/agent-skillsPrepares production launches. Use when preparing to deploy to production, or when asking what needs to be in place before shipping. Use when you need a pre-launch checklist, when setting up monitoring, when planning a staged rollout, or when you need a rollback strategy. | Stars: 119k | Updated | Claude CodeCodex | Verified | Install |
| childhoodthedotmack/claude-memBabysit a shipped release after merge, publication, or deployment. Verify published packages, production behavior, installed plugins, and late CI or user reports until the observation window is clean; use babysit for PR readiness before release. | Stars: 118k | Updated | Claude CodeCodex | Verified | Install |