adyen-go-api-library
adyen-go-api-library copied to clipboard
Dump Request/Response On HTTP Response Code >= 300
Is your feature request related to a problem? Please describe. In dev I just always have debug on. I can't do that in production obviously, but because the API is generated it is actually pretty annoying to dump requests bodies from failed requests. This is particularly annoying when I am seeing 422 errors where the invalid parameters array is also empty.
Describe the solution you'd like Similar to the debug configuration, just an option for dumping reqeusts and responses is the HTTP status code is not 2XX
Describe alternatives you've considered Manually json marshaling each and every input on a returned error. This is a LOT of copy/pasted code.
Additional context Add any other context or screenshots about the feature request here.