python-kucoin icon indicating copy to clipboard operation
python-kucoin copied to clipboard

Get_Symbols() fail

Open hammerjoe opened this issue 3 years ago • 1 comments
trafficstars

def get_symbols(self):

    return self._get('symbols', False)

Theres an error with the get_symbols call. It doesnt take the optional parameter to get the data for one token and it errors out with "too many parameters given. As per the docs :

GET /api/v1/symbols

PARAMETERS Param Type Description market String [Optional] The trading market.

hammerjoe avatar Jul 15 '22 11:07 hammerjoe

Seems like this lib is a disaster... basics don't work. Example below.... get_ticker & allTickers CODE MIXED. (I've taken out the comments from the lib, so that the Proc is easier to read).

get_ticker Proc: accesses 'market/allTickers' API path. There doesn't seem to be an allTickers Proc. Not gonna bother posting separately, seems this lib is not maintained.

def get_ticker(self, symbol=None):

    data = {}
    tick_path = 'market/allTickers'
    if symbol is not None:
        tick_path = 'market/orderbook/level1'
        data = {
            'symbol': symbol
        }

    return self._get(tick_path, False, data=data)

rhubear25 avatar Aug 19 '22 15:08 rhubear25