OneSignal / onesignal-node-api

OneSignal Node Client
Other
30 stars 17 forks source link

[Bug]: Extend APIException to give more details #71

Open ankursethi27 opened 10 months ago

ankursethi27 commented 10 months ago

What's on your mind?

The SDK uses ApiException for sending API exceptions but clients can only read string from this object. Clients should be able to easily get fields such as HTTP status code, headers, body, message, etc. that are generic to all requests. Status Code is specially useful for emitting metrics and quickly debugging.

API exception should have fields corresponding to them e.g. status_code, body, etc.

Code of Conduct

jannisringwald commented 6 months ago

+1