GraphQL in the SJGAR stack

v0.2 - last updated October 2020

Prerequisite reading

If you want to read why GraphQL is part of the SJGAR stack read the Introducing the SJGAR stack post.


Publicly released as open source in 2015, GraphQL is making a significant impact on how systems are connected in the modern world. One of the uses is serving as a Backend-For-Frontend for modern web and mobile apps. The rich community and tool set with for instance Apollo server and client are giving companies a great chance to get a head start when dealing with state management and server client communication. Because the libraries do the heavy lifting, engineers can focus on creating apps with a stellar user experience and performance.

GraphQL APIs compared with REST APIs

GraphQL APIs can be seen as maturity level 0 REST API. In a nutshell this means that the APIs use JSON that is served over HTTP. It also adds the concept of resources. Instead of creating a separate endpoint for every resource, GraphQL APIs expose a single endpoint to access the different resources.

Queries, Mutations and Subscriptions

A GraphQL endpoint exposes three top level fields:
  • Queries; for retrieving data
  • Mutations; for changing data
  • Subscriptions: for listening to data changes.
The query and mutation offer similar functionality as the CRUD operations REST APIs have. Queries map to GET requests. Mutations handle things like POST, PUT, PATCH and DELETE methods.

Do More and Keep Things Simple

Paragraph to be written


Paragraph to be written

Functions and Types

Paragraph to be written

Apollo Client and Apollo Server

Paragraph to be written


Paragraph to be written

AWS AppSync

Paragraph to be written

AWS Lambda and Apollo Server

Paragraph to be written

Think Service, Not Server

Paragraph to be written

Further reading