0
Follow
0
Followers
okex的原生API,通过type字段 1:开多 2:开空 3:平多 4:平空 就能实现各种交易了。
但通过发明者量化的API怎么写呢?
是下面这样吗?
开多
exchange.SetDirection("buy")
exchange.Buy(Price, Amount)
平多
exchange.SetDirection("closebuy")
exchange.Sell(Price, Amount)
开空
exchange.SetDirection("sell")
exchange.sell(Price, Amount)
平空
exchange.SetDirection("closesell")
exchange.buy(Price, Amount)
Related Recommendations
The grid trading strategyPython streamlined multi-variety MACD trending strategy frameworkin main TypeError: IO() takes at most 3 arguments (5 given)symbol not setGetTicker: 400: {"code": 2, "data": {}, "message": "invalid params"}gateio getdepth 502Decrypt: Secret key decrypt failedGetOrders: 400: {"code":-1121,"msg":"Invalid symbol."}HTTP 403 errorBitcoin trading by using bots
Comment
All comments (3)
