def create_limit_order(self, order_type, volume, price):
"""
Create a new limit order
:param order_type: 'buy' or 'sell'
:param volume: the volume, in BTC
:param price: the ZAR price per bitcoin
:return: the order id
"""
data = {
'pair': self.pair,
'type': 'BID' if order_type == 'buy' else 'ASK',
'volume': str(volume),
'price': str(price)
}
result = self.api_request('postorder', params=data, http_call='post')
return result
评论列表
文章目录