Hi,
I would like to subscribe to logs in nodejs with web3 and using moralis provider. Tried a couple of different ways.
First:
await Moralis.start({
serverUrl: MORALIS_SERVER_URL,
appId: MORALIS_APP_ID,
masterKey: MORALIS_MASTER_KEY,
});
const web3Js = new Web3(Moralis.provider);
// here moralis provider is null
Second:
const web3Js = new Web3(MORALIS_SERVER_URL);
// The current provider doesn't support subscriptions: HttpProvider
Is there a way to get a moralis provider in NodeJS?
Moralis.enableWeb3()
// window is not defined