Contains the entities and dependencies to populate a subgraph for Magma protocol.
You need to run a Graph Node locally.
- Clone Graph Node:
git clone https://github.com/magma-fi/subgraph.git、 - Start your local graph node
- Deploy the subgraph to your Graph Node:
cd subgraph && yarn deploy-local - Open Graph Node graphql API instance in your browser:
http://127.0.0.1:8000/subgraphs/name/'subgraphname'
Having done all of the above, if you make subgraph code changes you'll need to run the following:
- Recompile local changes:
yarn prepare:subgraph && yarn build:subgraph - Redeploy local changes:
cd packages/subgraph && yarn deploy-local