Graph QL for The Graph

omnipotentblock
1 min readNov 21, 2020

--

The Graph is a decentralized protocol for blockchains where it lets you get faster data for your dapps

This is going to be a big achievement in WEB 3 development.

Graph QL is one of the important languages that you need to understand to interact with the Subgraphs in The Graph

So GRAPH QL is somewhere you ask data to the API and in turn, get the result you might wonder what's so unique here

When you call the traditional communication models like REST you will get all the DATA from the API.

Imagine GRAPHQL like a target-specific data delivery you ask for something and you will get it.

Lets take a analogy of asking nuts in a store

Request:

{
Nuts {
name
}
}

Response :

{
“data”: {
“hero”: {
“name”: “Cashewnuts”
}
}
}

SO Using GRAPHQL is like asking nuts with a assorted tray you will get specific ones which you ask

In case of REST, you will get any sort of NUT and the salesperson doen’t know what you want they will throw what ever they have at you so this is one the major reasons GraphQL is used in several places.

--

--