To use the Skara RestRequest interface to interact with certain REST APIs, we need to extend the ability for how authorization is handled. It's currently possible to supply a lambda that adds an authorization header. I would like this lambda to have access to the Request.Builder so that it's able to read existing headers.
It's also common, at least among cloud providers, to require a SHA-256 hash of any contents (of a POST or PUT) in a header. The name of that header varies among providers however. I'm adding an optional field in the QueryBuilder to declare a header name for such a SHA-256 hash, with the RestRequest will automatically fill in if set.
To support other implementations of pagination, I'm adding another FunctionalInterface for supplying a function for creating a HttpRequest.Builder for any "next" link in a HttpResponse. This has a default implementation based on the current next link logic, which can now be overridden.
It's also common, at least among cloud providers, to require a SHA-256 hash of any contents (of a POST or PUT) in a header. The name of that header varies among providers however. I'm adding an optional field in the QueryBuilder to declare a header name for such a SHA-256 hash, with the RestRequest will automatically fill in if set.
To support other implementations of pagination, I'm adding another FunctionalInterface for supplying a function for creating a HttpRequest.Builder for any "next" link in a HttpResponse. This has a default implementation based on the current next link logic, which can now be overridden.