2. What is THE Graph?
The Graph (GRT) seeks to facilitate the seamless exchange of data between
blockchains and applications. The platform is among the first decentralized indexing
and querying software available in the market
The Graph is the indexing and query layer of the
decentralized web. Developers build and publish open APIs,
called subgraphs, that applications can query using
GraphQL. The Graph currently supports indexing data from
Ethereum, IPFS, and PoA with more networks coming soon.
To date, over 10,000 subgraphs have been deployed by
~16,000 developers for applications, such as Uniswap,
Synthetix, Aragon, Gnosis, Balancer, Livepeer, DAOstack,
AAVE, Decentraland, and many others.
The Graph is a query protocol for blockchain data
using GraphQL
3. Q: What problem(s) solved by the
GRAPH?
Traditional way
• https://etherscan.io/
The Blockchain Way
• https://thegraph.com/explorer
A: Access to Blockchain Data
4. Vocabulary
•Graph is a decentralized protocol for indexing and querying data
from blockchains
Graph
•A subgraph defines which data The Graph will index from Ethereum,
and how it will store it. Once deployed, it will form a part of a global
graph of blockchain data.
Subgraph
•GraphQL is a query language for your API, and a server-side runtime
for executing queries using a type system you define for your data.
GraphQL isn't tied to any specific database or storage engine and is
instead backed by your existing code and data.
GraphQL
•Graph (GRT) coin is the native token of the network. Its main use is
coordinating the work on The Graph. GRT is an ERC20 token.
GRT Coin
8. Who is using graph?
DeFi makes up 57% of queried
subgraphs. Meanwhile, 11% of subgraphs serve NFT
marketplaces, arts, and gaming. 7% of subgraphs are
related to cross-chain use cases like synthetic bitcoin
and protocol bridges, signifying an increase in
interoperability between dapps
9. 1 Billion Monthly Queries
10,000+ cryptocurrencies
10% of Google Search Request
11. The Graph Foundation
The Graph Foundation oversees The Graph Network. The
Graph Foundation is overseen by the Technical Council.
Edge & Node is one of the many organizations within The
Graph ecosystem.
Represent: Indexers, Users, Researchers, Backers and Initial Team
Grants
1. The Graph Foundation Operations
2. Grants and Ecosystem Funding
3. Protocol Upgrades
4. Protocol Parameterization
5. Emergency Protocol Operations
14. ROLES AND RESPONSIBILITIES
Consumer
•End-users of The Graph that query subgraphs and pay query fees
Developer
•Create subgraph
Indexer
•Index Data & Serve Queries
•Run Nodes
•Earn query fee
Curator
•Assess and signal Indexers on the subgraphs that should be indexed
•Deposit GRP into bounding curve
•10% of all query fees goes to the Curators
Delegator
•Delegating GRT to Indexers
•Earn a portion of query fees and indexing
21. Query with API
1. Get API KEY
https://thegraph.com/studio/apikeys/
2. Get Query URL
https://gateway.thegraph.com/api/{KEY}/subgraphs/id/0x4bb4c1b0745ef7b4642feeccd0740dec417ca0a0-0
https://thegraph.com/blog/announcing-the-graph-foundation
https://www.notion.so/The-Graph-Foundation-e822e66d7b614fdd899a647f5db51a68
https://streamingfastio.medium.com/the-graph-foundation-awards-60-million-grant-to-streamingfast-to-join-the-graph-as-a-core-e36be45f8d49
Indexers, Users, Researchers, Backers and Initial Team
There were more than 2K Curators from over 90 different countries and over 170 Indexers from more than 50 countries in The Graph’s testnet. The Graph community is globally distributed, with over 4,500 GRT holders from more than 99 different countries world-wide. Delegation can happen by anyone who holds GRT. Today, there are over 5K Delegators on The Graph Network.
https://thegraph.com/explorersubgraph?id=0x4bb4c1b0745ef7b4642feeccd0740dec417ca0a0-0&view=Playground
pairs(first: 5) {
id
name
totalSupply
}
{
dayDatas(first: 5) {
id
txCount
factory {
id
volumeUSD
}
}
}
pairs(orderBy: totalSupply, orderDirection: asc, first: 5) {
id
name
totalSupply
}
{
pairs(orderBy: volumeUSD, orderDirection: desc, skip: 10) {
id
name
totalSupply
volumeUSD
}
}
pairs(where:{id: "0x34d7d7aaf50ad4944b70b320acb24c95fa2def7c"})
{
id
name
totalSupply
volumeUSD
}
{
tokenDayDatas(orderBy: volumeUSD, orderDirection: desc)
{
id
date
token{
id
symbol
}
volumeUSD
priceUSD
}
}