The classic Order Bot recreated in HaasScript!
I tried my best to keep the code simple, yet professional.
The bot settings only contain an InputTable where you can build your orders. Unfortunately, due to limiting factors in HaasScript, orders cannot be reset. In other words, the bots orders are one-time triggers.
Input table order parameters:
For spot markets,
a buy order is set with a Direction value of +
a sell order is set with a Direction value of –
For leverage markets,
go long order is set with a Direction value of L+ and exit long with L-
go short order is set with a Direction value of S+ and exit short with S-
Trade amount is set in BASE value, which means, that if you are
trading BTC/USDT, the amount is then set as BTC.
< means “Lower Than” trigger price
> means “Higher Than” trigger price
Stop-Loss example (see default settings):
– “buy” order is set to trigger at price 62000.
– “sl” order is set to trigger when price “Less Than” 61800,
but is allowed to be monitored only After “buy” order
and Before “sell” order. “sl” is also set to be a market order.
– “sell” order is set to trigger at price 63000, but only After “buy”
order has completed.
All parameters with * are optional. Leave them empty when not used.
- This topic was modified 1 year, 7 months ago by .
- This topic was modified 7 months ago by . Reason: fixed a bug that occurred on first update cycle
- This topic was modified 6 months, 3 weeks ago by . Reason: fixed bot not able to trade leverage hedge
- This topic was modified 6 months, 1 week ago by . Reason: speed improvements
Earn Up to 2,000 $BMEX Tokens Promotion Type: contest Expires: July 31, 2023Fire up your trade bots and earn up to 2,000 $BMEX, $BTC, free subscriptions, and more.