bchavez / Coinbase

:moneybag: A .NET/C# implementation of the Coinbase API.
https://developers.coinbase.com/api/v2
MIT License
170 stars 92 forks source link

Adding support for auto refresh tokens. #41

Closed granthoff1107 closed 5 years ago

granthoff1107 commented 5 years ago

Known issues: Request which cached the original token will throw revoked token exception To fix this instead of globally adding the OAuth Header to the client, we should instead append the header using BeforeCallAsync, so if we update the AccessToken, other cached requests will not throw a revoked token exceotion

granthoff1107 commented 5 years ago

Breaking changes removing accepting all httpstatus codes.

Additionally the global error handling architecture is not complete because sometimes coinbase api will return a 200 with errors instead of throwing bad request,

in the after response we should additionally add error handling by checking if the response contains Errors.