What problem does it solve?
Enables externally owned accounts (EOAs) on Morph L2 to delegate authority and execute authorized transactions atomically using EIP-7702, removing manual multi-tx workflows and simplifying approve+swap+transfer operations while preserving replay protection and delegation lifecycle control.
Core Features & Use Cases
- Delegation Detection: Inspect an address to determine whether it is delegated (on-chain code prefix and delegate address decoding).
- Offline Authorization Signing: Produce signed authorization objects for delegate contracts without broadcasting transactions.
- Delegated Execution & Atomic Batches: Send single delegated calls or atomically execute multiple calls (approve + swap + transfer) using SimpleDelegation and tx type 0x04.
- Revocation & Safety: Revoke delegations by authorizing address(0) and follow explicit safety rules for confirmation and local key handling.
- Use Case: Retrieve swap calldata from a DEX skill, then execute an atomic approve+swap+transfer in one delegated transaction to reduce front-running and ensure all-or-nothing execution.
Quick Start
Run the provided morph-7702 script from the repository to inspect delegation status or to sign and send delegated calls, supplying a local private key when performing send, batch, or revoke operations.