#1
https://github.com/dingmaotu/mql4-lib
#2
https://github.com/dingmaotu/mql-zmq
<MetaTrader Data>\MQL4\Include\Mql\<mql4-lib content>
<MetaTrader Data>\MQL4\<mql-zmq content>
<MetaTrader Data>\MQL4\Library\MT4\<content>
to
<MetaTrader Data>\MQL4\Libraries\<content>
<MetaTrader Data>\MQL4\Library
<MetaTrader Data>\MQL4\Experts\MetaTrader4Bridge.mq4
MetaTrader4Bridge.mq4
expertimport MetaTrader4 from "metatrader4";
const mt4 = new MetaTrader4({
apiKey: "CHANGEME",
reqUrl: "tcp://127.0.0.1:5555",
pullUrl: "tcp://127.0.0.1:5556"
});
mt4.onConnect(() => {
console.log("Connected");
mt4.getAccountInfo().then((account) => {
console.log(account);
});
mt4.getLastCandles("EURUSD").then((candles) => {
console.log(candles);
});
});
mt4.connect();
This project has deficiency: https://github.com/bonnevoyager/node-mt4-zmq-bridge so I developed it and published this new repository.