Python requests adds params to querystring, where it should be in the body for non-safe HTTP methods (POST/PATCH/DELETE/etc)
Specifications
- API Version: 3.6.0
Describe the issue
See https://github.com/psf/requests/blob/eea3bbf9ac635f465ee6c9903dc57c677952dafd/src/requests/api.py#L19 the params kwargs goes into the query string, whereas the data goes into the body.
I think this is the issue why I get:
Non-existent query parameter "testmode" for this API call. Did you mean: "include"?
When setting testmode to True.
For your reference this is where it goes wrong in the code: https://github.com/mollie/mollie-api-python/blob/f5464e4c3ab352ed874ac5a894f85c80c58df0c2/mollie/api/client.py#L180
Which type of authentication are you using towards the Mollie API?
We use the 'setup_oauth' method (OAuth2Session authentication).
Reopened because https://github.com/mollie/mollie-api-python/pull/361 will be reverted.