Beispiel #1
0
    def _buy(self, amount, bid):
        ''' Places a buy for a number of an asset at the indicated price (0.00000503 for example)
            :param amount: string
            :param bid: float
            :param ticker: string
        '''
        query_parameters = getQueryParameters(BUY, self.ticker, amount, bid)
        response = self._create_signed_request(query_parameters)

        return response['success']
Beispiel #2
0
 def _sell(self, amount, ask):
     ''' Places a sell for a number of an asset at the indicated price (0.00000503 for example)
         :param amount: string
         :param ask: float
         :param ticker: string
     '''
     query_parameters = getQueryParameters(SELL, self.coin, amount, ask)
     log.info(query_parameters)
     response = self._create_signed_request(query_parameters)
     log.info(response)
     return response['success']