GraphQL is a protocol
and a query Interface Definition Language
and a run-time for performing queries with your existing data
GraphQL provides a complete and understandable description of the data in your API, gives clients the power to ask for exactly what they need and nothing more, makes it easier to evolve APIs over time, and enables powerful developer tools.
GraphQL is a data query language developed internally by Facebook in 2012 before being publicly released in 2015
GraphQL provides an alternative to REST and ad-hoc Web Service architectures
GraphQL allows the client to specify the properties of a Resource that is to be provided rather than the properties dictated by an API, schema, Interface Definition Language or the server author.
GraphQL requires a GraphQL Server and a GraphQL Client which use a JSON based GraphQL schema language.
GraphQL query is a string that is sent to a server to be interpreted and fulfilled, which then returns JSON back to the client.
Example GraphQL Request:
Example GraphQL Response:
"name": "Luke Skywalker"
"name": "Han Solo"
"name": "Leia Organa"
GraphQL queries access not just the properties of one resource but also smoothly follow references between them. While typical REST APIs require loading from multiple URLs, GraphQL APIs get all the data your app needs in a single request. Apps using GraphQL can be quick even on slow mobile network connections.
There might be more information for this subject on one of the following: