api-error-handler icon indicating copy to clipboard operation
api-error-handler copied to clipboard

Express error handlers for JSON APIs

Results 13 api-error-handler issues
Sort by recently updated
recently updated
newest added

I really like the feature that sets response status code from property `status` of the error thrown. It should be documented!

Hello everyone, I am still using this library as of today and I was wondering ? Is this repo dead ? Because I see many good ideas in pull requests...

This feature has been requested a few times and attempted in several PRs such as: #1 #2 #5 #12 Most recently something like this was requested in #11 I read...

Hi guys. Can we do this? Otherwise tests become messy. ```js if (process.env.NODE_ENV === "test") { // no `stack` in the response } ```

Take a callback function and execute it at the end? I am having a case that I want to log out the error message in console. It will be easy...

Trying to figure out how to best expose additional properties added to errors thru the http-errors package. Basically, what I'm trying to do is something like this: ```js const express...

Opening for early feedback. @jonathanong I would like a way to surpress the `console.error` call since I've already sent the error to Sentry, and my logs follow a json format....

I thought this would be a nice way to handle the "stack" issue. I.e. you were already thinking about making the stack optional, but in reality, it's something they may...