Requesting multiple Krakenex API pairs
I am trying to use the Krakenex python library to query the order book for multiple currency pairs at the same time. When I do this for a single currency, it works, for example:
con = krakenex.API()
con.load_key('kraken.key')
con.query_public('Depth', {'pair':'GNOETH'})
However, if I do this:
con = krakenex.API()
con.load_key('kraken.key')
con.query_public('Depth', {'pair':['GNOETH', 'GNOEUR']})
I receive {'error': ['EQuery:Unknown asset pair']}
. I am assuming the syntax is wrong, but cannot figure out the correct one. This is the first time I use the API and the example provided does not cover enough information.
+3
source to share
2 answers