IBM / openapi-to-graphql

Translate APIs described by OpenAPI Specifications (OAS) into GraphQL
https://developer.ibm.com/open/projects/openapi-to-graphql/
MIT License
1.61k stars 211 forks source link

ability to get http errors headers as sent by openapi resolver #422

Closed devthejo closed 3 years ago

devthejo commented 3 years ago

Hello, first thank you so much for this great tool you built, I need my graphql api to respond with same headers as openapi send to it, and it seem impossible because openapi-to-graphql intercept status code < 200 or > 299. I can't find any workaround for this. Help with this would be very appreciated.

devthejo commented 3 years ago

I finally don't need http headers and I saw that finally the problem was at graphql server level and I can manipulate error like specified here https://www.apollographql.com/docs/apollo-server/data/errors/#masking-and-logging-errors