I want to programmatically intercept RPC requests made by Metamask. This is useful because I want to alert myself if the domain or the smart contract looks suspicious.
I have checked Metamask API but there doesn’t seem to be such a feature. I also check Metamask Snaps but this doesn’t seem to be available there as well.
Snaps is a part of MetaMask Flask which allows developers to build plugins within MetaMask. This is a feature that you can develop yourself as a Snaps plugin.