This guide will help you gather everything you need before running the bot.
Important: Never use your main wallet. Create a fresh wallet just for this bot.
Easy option: Use vanity-eth.tk to generate a new wallet instantly in your browser.
- Visit https://vanity-eth.tk/
- Click "Generate" to create a new wallet
- Save both the Address and Private Key securely
- Send some ETH to this address for gas fees (0.01-0.05 ETH should be enough)
You need an RPC endpoint to connect to the blockchain. Free options:
- Visit https://dashboard.alchemy.com/
- Sign up for a free account
- Create a new app
- Select the network you need (e.g., Ethereum Mainnet, Base, Arbitrum)
- Copy the HTTPS URL
- Visit https://chainstack.com/
- Sign up for a free account
- Deploy a node on your desired network
- Copy the endpoint URL
- You need the vault contract address where your shares are stuck
- Example:
0x1234...(starts with 0x, 42 characters) - You can usually find this in the DeFi protocol's interface or from the transaction where you deposited
- You need the Market ID (a 32-byte hex string)
- Example:
0xabcd...(starts with 0x, 66 characters) - Find this on Morpho's interface or block explorer when viewing your position
This is your main wallet address where you want rescued funds sent.
- Use your actual secure wallet address (e.g., hardware wallet, MetaMask main account)
- The bot wallet just performs the rescue; funds go to this owner address
If using Morpho Market Withdraw mode:
- Visit https://www.monarchlend.xyz/tools
- Connect your main wallet (the one with the stuck funds)
- Authorize your bot wallet address to act on your behalf
- Confirm the transaction
Once you have:
- ✅ Bot wallet private key
- ✅ RPC URL
- ✅ Vault/Market address
- ✅ Owner address (your main wallet)
- ✅ Authorization (if using Morpho)
Run pnpm start and the interactive CLI will guide you through the rest!