Functions
signal(ex, pair)
signal(ex, pair)This function must return None, False, or True.
exExchange
pairName of the pair being traded
Return
Return
Noneif the symbol is not handled by the script. If all scripts returnNonefor the symbol then it will trade based on your settings.Return
Falseif the signal is not present.Return
Trueif the signal is present. This will allow the bot to place trades based on your settings.
update(ex, pair, last, avg, size, target)
update(ex, pair, last, avg, size, target)Since v1.2.2, this function can be used to force the bot to exit its current position and start over.
exExchange
pairName of the pair being traded
lastLast price of the pair
avgAverage price of all entries
sizeCurrent position size
targetCurrent target price
Return
Return
Trueto stay in the position.Return
False(or anything else) to exit the position.
This function should return True by default if you just want status updates sent to Python.
finished()
finished()This function is called when the bot is exiting. Depending on how the bot is closed, it may not be called.
Last updated