Allow setting the default responseHandler at a higher level
See original GitHub issueBecause of #2354 (which is addressed in #2363, pending feedback), we have resorted to adding a custom responseHandler
to each and every endpoint definition.
This gets tedious, and it’s easy for one of the several developers on our team to miss a case until we run into a run-time PARSING_ERROR
when we get a "text/plain"
response.
It would be very convenient to be able to set the default responseHandler
across all endpoints in the options to createApi
.
Issue Analytics
- State:
- Created a year ago
- Comments:6 (3 by maintainers)
Top Results From Across the Web
The responseHandler should respect Content-Type headers
I believe the default responseHandler should be a little more ... Allow setting the default responseHandler at a higher level #2385.
Read more >fetchBaseQuery - Redux Toolkit
Handling non-standard Response status codes. By default, fetchBaseQuery will reject any Response that does not have a status code of 2xx and ...
Read more >Pass value to Apache Httpclient Response Handler
Hi I am using apache http client and i was wondering of it is possible top have a generic response hande.
Read more >DecompressingHttpClient (Apache HttpClient 4.5.13 API)
Executes HTTP request using the default context and processes the response using the given response handler. Implementing classes are required to ensure that ......
Read more >Error Handling for REST with Spring - Baeldung
Solution 1: the Controller-Level @ExceptionHandler ... It will also allow us to implement a uniform exception handling mechanism in our REST ...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
I added a PR for that today - #2823
But it’s part of
fetchBaseQuery
.createApi
doesn’t have any concept of response handlers.Merged into the 1.9 branch