question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

bithumb.fetch_balance() returns 400 Bad Request / 5100 Error Code

See original GitHub issue
import ccxt
import time

bithumb = ccxt.bithumb({
    "apiKey": "xxx",
    "secret": "xxx",
    "verbose": True,
})

print(bithumb.fetch_balance())

Returns error : cxt.base.errors.ExchangeNotAvailable: bithumb POST https://api.bithumb.com/info/balance 400 Bad Request {“status”:“5100”,“message”:"Bad Request.(Request Time:reqTimexxxxxx…)

Issue Analytics

  • State:closed
  • Created 6 years ago
  • Comments:10 (6 by maintainers)

github_iconTop GitHub Comments

1reaction
crypt2commented, Nov 14, 2017
https://api.bithumb.com/info/balance POST https://api.bithumb.com/info/balance 
Request: {'Api-Key': 'XXX', 'Api-Sign': 'XXX', 'Api-Nonce': '1510616584', 'User-Agent': 'ccxt/1.10.87 (+https://github.com/ccxt-dev/ccxt) Python/3.6.0', 'Accept-Encoding': 'gzip, deflate'} endpoint=%2Finfo%2Fbalance&currency=ALL
Traceback (most recent call last):
  File "/Users/xxx/Desktop/Crypto/scripts/trading/ccxt2/ccxt/python/ccxt/base/exchange.py", line 300, in fetch
    response = opener.open(request, timeout=int(self.timeout / 1000))
  File "/Users/xxx/ENTER/lib/python3.6/urllib/request.py", line 532, in open
    response = meth(req, response)
  File "/Users/xxx/ENTER/lib/python3.6/urllib/request.py", line 642, in http_response
    'http', request, response, code, msg, hdrs)
  File "/Users/xxx/ENTER/lib/python3.6/urllib/request.py", line 570, in error
    return self._call_chain(*args)
  File "/Users/xxx/ENTER/lib/python3.6/urllib/request.py", line 504, in _call_chain
    result = func(*args)
  File "/Users/xxx/ENTER/lib/python3.6/urllib/request.py", line 650, in http_error_default
    raise HTTPError(req.full_url, code, msg, hdrs, fp)
urllib.error.HTTPError: HTTP Error 400: Bad Request

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "test-bithumb.py", line 10, in <module>
    print(bithumb.fetch_balance())
  File "/Users/xxx/Desktop/Crypto/scripts/trading/ccxt2/ccxt/python/ccxt/bithumb.py", line 77, in fetch_balance
    }, params))
  File "/Users/xxx/Desktop/Crypto/scripts/trading/ccxt2/ccxt/python/ccxt/bithumb.py", line 234, in request
    response = self.fetch2(path, api, method, params, headers, body)
  File "/Users/xxx/Desktop/Crypto/scripts/trading/ccxt2/ccxt/python/ccxt/base/exchange.py", line 259, in fetch2
    return self.fetch(request['url'], request['method'], request['headers'], request['body'])
  File "/Users/xxx/Desktop/Crypto/scripts/trading/ccxt2/ccxt/python/ccxt/base/exchange.py", line 316, in fetch
    self.handle_rest_errors(e, e.code, message if message else text, url, method)
  File "/Users/xxx/Desktop/Crypto/scripts/trading/ccxt2/ccxt/python/ccxt/base/exchange.py", line 344, in handle_rest_errors
    self.raise_error(error, url, method, exception if exception else http_status_code, response)
  File "/Users/xxx/Desktop/Crypto/scripts/trading/ccxt2/ccxt/python/ccxt/base/exchange.py", line 241, in raise_error
    details,
ccxt.base.errors.ExchangeNotAvailable: bithumb POST https://api.bithumb.com/info/balance 400 Bad Request  {"status":"5100","message":"Bad Request.(Request Time:reqTime1510616584\/nowTime1510616543496)"}
Read more comments on GitHub >

github_iconTop Results From Across the Web

How to Fix a 400 Bad Request Error (Causes and Fixes) - Kinsta
The 400 (Bad Request) status code indicates that the server cannot or will not process the request due to something that is perceived...
Read more >
HTTP error 400: how to fix it? - Debug Bar
In this guide, we'll explain each cause of the 400 bad request error and tell you how to fix the problem. Are you...
Read more >
How to Fix a 400 Bad Request Error - YouTube
Learn how to resolve the 400 bad request error with five simple methods. Build your website with Hostinger web hosting today ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found