checkout/checkout-sdk-python

Request: custom response classes

Closed this issue · 2 comments

ResponseWrapper does not provide contextual hints on what fields it has.

Screen Shot 2022-06-08 at 3 00 47 PM

I suggest creating custom response classes for each checkout_sdk.client.Client subclass, or even for each operation.

Hi @aqeelat .
Thanks for you suggestion, however this might be out of the scope for now.
Previously of ResponseWrapper the responses used to be the JSON response from the Client, however for development and debug purposes we decide to provide more information from the http response.
The response wrapper was created for that purpose and we provide a dynamic way to users be able to retrieve the items as objects, however we decide to not map each response at that moment.

We will review the impact and the effort to provide that kind of wrapper, but for now you can refer to API Docs for the specific response object of each client.
https://www.checkout.com/docs

Hi @aqeelat
We did not receive enough feedback to apply custom object wrapper for responses.
I'm going to close this request as won't do for now, but if you need help, please feel free to open or reopen as needed.

Thanks!