Example code snippets to query the chain via the peggy api.
import { ChainGrpcPeggyApi } from '@injectivelabs/sdk-ts' import { getNetworkEndpoints, Network } from '@injectivelabs/networks' const endpoints = getNetworkEndpoints(Network.Testnet) const chainGrpcPeggyApi = new ChainGrpcPeggyApi(endpoints.grpc) const moduleParams = await chainGrpcPeggyApi.fetchModuleParams() console.log(moduleParams)
Last updated 9 months ago