The resource loading... loading...

On how to list and order in bulk on BitMEX only passively (IO example)

Author: The grass, Created: 2019-04-17 15:46:32, Updated: 2019-04-19 15:25:48

Using the IO function, specific parameters are referenced in the BitMEX documentation:https://www.fmz.com/bbs-topic/3666

I'm not going to do anything about it.

var id = exchange.IO("api", "POST", "/api/v1/order", "symbol=XBTUSD&side=Buy&orderQty=1&price=5000&execInst=ParticipateDoNotInitiate")

Listing of lots

var bulk = []
bulk.push({symbol:'XBTUSD', side:'Buy', orderQty:100, price:5000, execInst:'ParticipateDoNotInitiate'})
bulk.push({symbol:'XBTUSD', side:'Buy', orderQty:200, price:5100, execInst:'ParticipateDoNotInitiate'})
var param = "orders=" + JSON.stringify(bulk)
var ids = exchange.IO("api", "POST", "/api/v1/order/bulk", param)
Log(ids)

All orders canceled

exchange.IO("api","DELETE","/api/v1/order/all","symbol=XBTUSD")

Related

More

mztcoinI'm not going to go into the details of how I'm going to do it.

wufuhao100wIf post_only is likely to fail, what value will it return if it fails? Will it cause the robot to stop?

Don't eat spinachHTTP requests POST to /api/futures/v3/order Example request POST/api/futures/v3/order{"client_oid": 12233456, "order_type: 1, "instrument_id"::"BTC-USD-180213","type":"1","price":"432.11","size":"2","match_price":"0"} order_type String No Parameters filled in digit, 0: General assignment (order type not filled in or fill 0 is a general assignment) 1: only do Maker (Post only) 2: complete or immediately cancel (FOK) 3: immediately complete and cancel the remainder (IOC)

wufuhao100wThat's good.

The grassDo you want to directly return the log results, just search the bitmex documentation

wufuhao100wI'm sorry to bother you again, I ordered successfully but I got back a series of messages that are not my order id: This is a list of all the characters that appear in the game, including the characters that appear in the game. How to solve it?

wufuhao100wGood, thank you.

The grassYes, str ((num)

wufuhao100wHi, I tried it and it says TypeError: can only concatenate str (not "int") to str, using python, is it possible to convert order Qty = 1 to a string format of 1 bits and price = 5000 to a string format of 5000 bits?

The grassYes, I'd better check the documentation again and see if anything has changed.

wufuhao100wI just want to ask God, if I'm going to download post_only, I just need to put the code above it. This is a list of all the different ways Exchange.IO is credited in the database. Is it possible to replicate the past, specifically to change the parameters of direction, price and quantity to the desired values?

wufuhao100wGood, thank you.

The grassLook at the documentation of bitemx, there is an introduction of the returned results.