const { HttpProvider, Messenger } = require('@harmony-js/network');
const { ChainType, ChainID } = require('@harmony-js/utils');
// create a custom messengerconst customMessenger = new Messenger(
new HttpProvider('http://localhost:9500'),
ChainType.Harmony, // if you are connected to Harmony's blockchain
ChainID.HmyLocal, // check if the chainId is correct
)
How to Create a Massage
const { HttpProvider, Messenger } = require('@harmony-js/network'); const { ChainType, ChainID } = require('@harmony-js/utils'); // create a custom messenger const customMessenger = new Messenger( new HttpProvider('http://localhost:9500'), ChainType.Harmony, // if you are connected to Harmony's blockchain ChainID.HmyLocal, // check if the chainId is correct )