(self, orders)
return self._curl_bitmex(api='order/bulk', postdict={'orders': orders}, verb='POST')
Create multiple orders.
Create multiple orders.
Create multiple orders .
def create_bulk_orders(self, orders):
        """Create multiple orders."""
        for order in orders:
            order['clOrdID'] = self.orderIDPrefix + base64.b64encode(uuid.uuid4().bytes).decode('utf-8').rstrip('=\n')
            order['symbol'] = self.symbol
            order['execInst'] = 'ParticipateDoNotInitiate'
        return self._curl_bitmex(api='order/bulk', postdict={'orders': orders}, verb='POST')
def create_bulk_orders ( self , orders ) : for order in orders : order [ 'clOrdID' ] = self . orderIDPrefix + base64 . b64encode ( uuid . uuid4 ( ) . bytes ) . decode ( 'utf-8' ) . rstrip ( '=\n' ) order [ 'symbol' ] = self . symbol order [ 'execInst' ] = 'ParticipateDoNotInitiate' return self . _curl_bitmex ( api = 'order/bulk' , postdict = { 'orders' : orders } , verb = 'POST' )