specs
specs copied to clipboard
Submitting queries as JSON without URL-encoding them
It is more natural in a REST API to submit a JSON payload as a POST query with Content-Type: application/json rather than to URL-encode it in a queries= parameter as we are currently doing.
We could introduce this change in new version, and perhaps keep URL-encoding for the GET method, since it could still be useful for interactive testing, although the testbench should hopefully decrease the need for this in the future.
Changing this would make it easier to expose OpenAPI profiles (#17) for reconciliation services.
+1 for making the payload application/json which is the normal convention.
I just submitted #33 and I suggest that both changes could be implemented as the same time, as both are breaking changes (though in both cases, a service endpoint could be written to support both the old and the new style).
It is more natural in a REST API to submit a JSON payload as a POST query with
Content-Type: application/jsonrather than to URL-encode it in aqueries=parameter as we are currently doing.
👍 agree as well