Skip to content

Support / adoption of GraphQL over HTTP spec 2.0 (e.g. non 2xx-Status Code for errors with application/graphql-response+json) #4334

@frittentheke

Description

@frittentheke

This is somewhat a mix of feature request and discussion ....
one which I also kicked off in spring-projects/spring-graphql#1113 // spring-projects/spring-graphql#783

I was just wondering about your take and support of the upcoming 2.0 revision of the GraphQL over HTTP spec , especially in regards to status codes.

The appropriate section about the application/graphql-response+json response type (https://graphql.github.io/graphql-over-http/draft/#sec-application-graphql-response-json) states:

If the GraphQL response does not contain the data entry then the server MUST reply with a 4xx or 5xx status code as appropriate.
The GraphQL specification indicates that the only situation in which the GraphQL response does not include the data entry is one in which the errors entry is populated.

Currently it seems as if there is no support / adoption of non-2xx HTTP response codes in graphql-js yet?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions