gdax-python-api
gdax-python-api copied to clipboard
cancel_order fails "Bad Request"
If you try to cancel an order through this API you get a 400 Bad Request error
I managed to track it down to the payload that is being used to authenticate the request. This is used to generate headers for the request.
headers = self._auth_headers(path, method='DELETE', body=json_data)
In a delete request the variable json_data is empty. I believe this is why the headers fail. By setting the json_data value to "{}" (empty json) then it works