Getting Started
Install
yarn:
yarn add @hatsprotocol/sdk-v1-subgraphnpm:
npm install @hatsprotocol/sdk-v1-subgraphHatsSubgraphClient Initialization
Import and initialize HatsSubgraphClient.
Optionally configure the Subgraph endpoints to use, or use the default ones.
import { HatsSubgraphClient } from "@hatsprotocol/sdk-v1-subgraph";
const hatsSubgraphClient = new HatsSubgraphClient({
config
});Arguments:
{ config?: EndpointsConfig }config- Optional subgraph endpoints configuration. If not provided, then the default, un-gated development endpoints will be used. See theEndpointsConfigtype here.
Last updated