Does anyone know how to return errors from resolvers? #1077
-
I am currently throwing errors from my resolver with a middleware but I am not sure how to make the response a ex:
If I don't throw the error from the middleware the Thanks for any help! |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment 1 reply
-
Hey @special-character, sorry for the late response. I believe the only way to get a There's a great article talking about that here https://medium.com/@sachee/200-ok-error-handling-in-graphql-7ec869aec9bc |
Beta Was this translation helpful? Give feedback.
Hey @special-character, sorry for the late response. I believe the only way to get a
200
response while returning an error is to model your error at the GraphQL schema level.There's a great article talking about that here https://medium.com/@sachee/200-ok-error-handling-in-graphql-7ec869aec9bc