원클릭으로
morph-7702
EIP-7702 EOA delegation on Morph L2 — batch calls and delegation management via tx type 0x04
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
메뉴
EIP-7702 EOA delegation on Morph L2 — batch calls and delegation management via tx type 0x04
Codex 또는 Claude로 설치 이 Prompt를 복사해 Codex, Claude 또는 다른 어시스턴트에 붙여 넣으면 Skill 페이지를 검토하고 설치를 진행할 수 있습니다.
SOC 직업 분류 기준
AI Agent skill for Morph L2 — wallet, explorer, DEX swap, cross-chain bridge with order management, EIP-8004 agent identity & reputation, alt-fee gas payment, EIP-7702 delegation, and x402 payment protocol
EIP-8004 agent identity and reputation commands for Morph — register agents, query metadata, submit and read feedback
Alt-fee gas payment on Morph L2 — pay gas with alternative ERC20 tokens via tx type 0x7f
Cross-chain swap with JWT auth — quote prices, create orders, submit transactions, track order status across 6 chains
DEX swap execution on Morph L2 — quote and send swaps via Bulbaswap aggregator
On-chain data queries on Morph L2 — address info, transactions, tokens, contracts via Blockscout API
| name | morph-7702 |
| version | 1.0.0 |
| description | EIP-7702 EOA delegation on Morph L2 — batch calls and delegation management via tx type 0x04 |
EOA delegation on Morph Mainnet (Chain ID: 2818) via EIP-7702 (tx type
0x04). All commands output JSON. All amounts use human-readable units (e.g.0.1ETH, not wei).
Use this skill when the user wants to: check EOA delegation status, sign an authorization, send a single call with 7702 delegation, execute an atomic batch of calls via SimpleDelegation, or revoke a delegation.
Decide the mode once via the root SKILL.md and docs/social-wallet-integration.md.
7702-send, 7702-batch, 7702-authorize, 7702-revoke require --private-key (local signing).7702-delegate is read-only — works with any wallet type.The three signing operations in a 7702-batch can each be performed via BGW TEE:
keccak256(0x05 || RLP([chainId, contract, nonce]))) — BGW can sign raw hashes via TEEexecute() digest) — BGW can sign EIP-191 messagesThe agent constructs each hash locally using the formulas in Domain Knowledge, sends to BGW for signing, then assembles and broadcasts the raw transaction manually. This is advanced orchestration — for most SLW users, BGW's native swap flow is simpler.
pip install requests eth_account eth_abi eth_utils
# Run from repository root
python3 scripts/morph_api.py <command> [options]
No API keys required.
7702-delegateCheck whether an EOA has been delegated via EIP-7702.
python3 scripts/morph_api.py 7702-delegate --address 0xYourEOA
7702-authorizeSign a 7702 authorization object offline for a supplied delegate contract. No transaction is sent.
python3 scripts/morph_api.py 7702-authorize --private-key 0xKey --delegate 0xDelegateContract
7702-sendExecute a single delegated call using EIP-7702 (tx type 0x04).
# Simple call
python3 scripts/morph_api.py 7702-send --delegate 0xDelegateContract --to 0xContract --data 0xCalldata --private-key 0xKey
# With ETH value and custom gas
python3 scripts/morph_api.py 7702-send --delegate 0xDelegateContract --to 0xContract --value 0.01 --data 0x --private-key 0xKey --gas 200000
7702-batchAtomically execute multiple calls via an upstream-supplied delegate contract. The primary use case: approve + swap + transfer in a single atomic transaction.
python3 scripts/morph_api.py 7702-batch \
--delegate 0xDelegateContract \
--calls '[{"to":"0xTokenAddr","value":"0","data":"0xApproveCalldata"},{"to":"0xRouterAddr","value":"0","data":"0xSwapCalldata"}]' \
--private-key 0xKey
--calls is a JSON array of {to, value, data} objects. value is in ETH (human-readable). data defaults to 0x if omitted.
7702-revokeRevoke the EIP-7702 delegation. Clears the delegate by authorizing address(0).
python3 scripts/morph_api.py 7702-revoke --private-key 0xKey
7702-send, 7702-batch, or 7702-revoke — show the target, calls, and values before signing.0x7f) are mutually exclusive — cannot use both in a single transaction.7702-revoke clears the delegation — the EOA returns to a normal EOA until re-delegated.7702-authorize is offline — it returns a signed authorization without sending any transaction.--delegate. This skill does not assume a default Morph delegate contract.0xef0100 followed by the 20-byte delegate address.tx_nonce + 1. This is handled automatically by all 7702 commands.tx_nonce is the EOA's standard transaction nonce. delegation_nonce is the SimpleDelegation replay-protection counter, read from the EOA (after delegation) via nonce().0x04: EIP-7702 transactions include an authorizationList in the RLP encoding, enabling temporary or permanent EOA delegation within the transaction.Atomic approve + swap:
dex-quote --recipient 0xEOA (morph-dex skill, get approve + swap calldata)
→ 7702-batch --delegate 0xDelegateContract --calls '[{"to":"token","value":"0","data":"approveData"},{"to":"router","value":"0","data":"swapData"}]'
Check delegation → batch → revoke:
7702-delegate --address 0xEOA (check current status)
→ 7702-batch --delegate 0xDelegateContract --calls '[...]' (execute atomic operations)
→ 7702-revoke (clean up delegation)
One-time delegated call:
7702-send --delegate 0xDelegateContract --to 0xContract --data 0xCalldata (single delegated call; delegation persists until changed or revoked)
dex-quote to get swap calldata, then pass to 7702-batch --delegate <delegate> --calls for atomic approve + swap.0x7f; EIP-7702 uses tx type 0x04. Cannot combine in one transaction.agent-register calldata can be included in a 7702-batch to combine registration with other operations atomically.