0

I have a graph-node running in a EC2 instance. The subgraph has been compiled, created and deployed already and it is running with no issues.

I want to query its status by running the following command:

{ indexingStatuses(subgraphs:["subgraph_hash"])
  { 
    subgraph 
  } 
}

How do I get the subgraph_hash once it's been deployed?

1 Answer 1

0
graph status --node https://api.thegraph.com/index-node/ <DEPLOYED_SUBGRAPH_NAME>

This should work for what you're doing - should output something like this

----------
Subgraph           Subgraph hash
----------
subgraph-name     0x1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef
----------
4
  • Where are you executing that command? I get Error: command status not found and if I check the graph command, there is no status option. Mar 29, 2023 at 3:27
  • COMMANDS add Adds a new datasource to a subgraph. auth Sets the deploy key to use when deploying to a Graph node. build Builds a subgraph and (optionally) uploads it to IPFS. codegen Generates AssemblyScript types for a subgraph. create Registers a subgraph name deploy Deploys a subgraph to a Graph node. init Creates a new subgraph with basic scaffolding. local Runs local tests against a Graph Node environment (using Ganache by default). remove Unregisters a subgraph name test Runs rust binary for subgraph testing. Mar 29, 2023 at 3:27
  • You can use thegraph.com/studio or the CLI
    – VX3
    Apr 22, 2023 at 14:52
  • My subgraph is not deployed to the studio and, again, graph-cli does not have status command: npmjs.com/package/@graphprotocol/graph-cli Apr 24, 2023 at 4:26

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.