/graphql-primer

An introduction to GraphQL

Primary LanguageTypeScript

GraphQL Primer

GraphQL is an open spec for a flexible API layer. It re-imagines how you query, mutate, and react to data. To best understand the advantages of GraphQL, some context on the shortcomings of APIs need to be observed.

APIs and Protocols

An API is an Application Programming Interface. Put simply, it is a way for two pieces of software talk to each other.

A Protocol defines the way two entities communicate.

Typical web and mobile applications have a three-tier architecture.

  • A front-end: Mobile Application, Website, Desktop Application
  • A back-end: A server or collection of cloud functions
  • Data storage: Databases and file storage

GraphQL builds on top of various protocols to provide a more flexible way to interact with a "backend".

  • generating infrastructure-as-code from schemas - @AWSAmplify

  • creating a content mesh - @GatsbyJS / @TheGuildDev

  • as a native DB query language - @dgraphlabs