Easily get up-to-speed with (and integrate) the MetaMask Delegation Toolkit with this demonstration. It includes examples for all the core elements including Delegator Account (ERC-4337) creation, sending User Operations, and the Delegation lifecycle. Example code is provided utilising the Delegator Smart Account.
Note: this template is also designed to complement the documentation.
Note that the package
@codefi/delegator-core-viem
is currently hosted on a private registry. Please get in touch with the team for access at hellogators@consensys.io.
Once configured, you'll be able to install the dependencies (both private and public) via the following:
yarn install
Configuration is provided via environment variables, you may create a .env
file in the root of Hello Gator, including the configuration parameters defined in .env.example
.
Refer to the documentation for further information on configuration.
Start development environment:
yarn dev
Feel free to open an issue or contact the team directly at hellogators@consensys.io.