Cardano GraphQL
Check the releases for the latest version.
git clone \
--single-branch \
--branch <VERSION> \
https://github.com/hawkingnetwork/cardano-node-docker.git \
&& cd cardano-node-docker- Build Images
bash build.sh-
Config Explorer Change your server's IP in line 184
- GRAPHQL_API_HOST=192.168.1.219 -
Run docker
docker-compose up -d && docker-compose logs -fUse the GraphQL Playground in the browser at http://localhost:3100/graphql:
{
cardanoDbMeta {
initialized
syncPercentage
}
}or via command line:
curl \
-X POST \
-H "Content-Type: application/json" \
-d '{"query": "{ cardanoDbMeta { initialized syncPercentage }}"}' \
http://localhost:3100/graphqlℹ️ Wait for initialized to be true to ensure the epoch dataset is complete.
{
cardano {
tip {
number
slotNo
epoch {
number
}
}
}
}curl \
-X POST \
-H "Content-Type: application/json" \
-d '{"query": "{ cardano { tip { number slotNo epoch { number } } } }"}' http://localhost:3100/graphql{
"data": {
"cardano": {
"tip": {
"number": 4391749,
"slotNo": 4393973,
"epoch": { "number": 203 }
}
}
}
}For more information, have a look at the Wiki 📖.
| Link | Audience |
|---|---|
| API Documentation | Users of the Cardano GraphQL API |
| Wiki | Anyone interested in the project and our development process |
| Example Queries - Cardano DB Hasura | Users of the Cardano DB Hasura API |