As I am developing tools I had to get a GraphQL server runnig to query the blockchain and while I was at it I decided to release access to the serve to the community and make a light GraphQL client for it so others could prototype with it as well.
Blockfrost offers a similar service with a a very thorough documentation which I think is very well done, but the one disadvantage is that it is centralized
I also made a repo for the light graphql client so other can deploy it on their relay nodes if they wish to.
The benefit is that if everyone opens up their relays (and there are more than 5000 of them) then the developers can point to any of those relays for data - a swarm of endpoints. So the relays become a gateway to query the blockchain and the API becomes decentralized.
The tool helps answer questions such as the ones below, and does it fairly quickly without any additional set-up:
- how is the 45bn of ADA distributed between reserve, treasury … (aka the ADA Pots) ?
- what the latest block and what is inside?
- what are the protocol parameters this epoch?
- can I see how many transactions and how much in fees was paid last epoch?
- can I have a list of all the stake pools and the pledge and stake for each one?
- how much ADA is currently staked?
- how much ADA does a wallet address have?
- can I see the latest metadata for a specific key?
Here is a link to the tool that answers those questions:
The link to the git repo with the source code:
Use Case: This API is used in the Cardano Rewards Calculator that is described in more detail here on this forum post.
As always feedback is welcomed