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) #1113

Closed as not planned
@frittentheke

Description

@frittentheke

This is somewhat a mix of feature request and discussion ....

I was 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 reads as if there is no support / adoption of non-2xx responses (https://github.com/spring-projects/spring-graphql/blob/36bfd40d66494987931d68142a0e26b6f7d156c2/spring-graphql-docs/modules/ROOT/pages/transports.adoc#http) yet and one would need to implement this by overriding handlers or other custom code?

Metadata

Metadata

Assignees

No one assigned

    Labels

    in: webIssues related to web handlingstatus: supersededIssue is superseded by another

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions