The current protocol uses HTTP headers for many things including session parameters, session properties, transaction info, prepared statements, etc. This is problematic for prepared statements due to length limitations on HTTP headers in various clients and servers. It is also makes the protocol harder to following by mixing things across headers and the request / response bodies.
As long as we're changing the protocol, it makes sense to move everything from
headers into the JSON documents. We will add a new endpoint,
application/json with the new request body (instead of just the query
text). The new endpoint will return the new response format.