# Subgraph

## Overview

The SDK is an open source JavaScript client, providing utility functions for fetching data from the [Hats Protocol Subgraphs](/for-developers/v1-subgraphs.md) and is designed to work both in the browser and in Node.js.

{% content-ref url="/pages/ueP5evorHYPtLEgmBD2c" %}
[Getting Started](/for-developers/v1-sdk/subgraph/getting-started.md)
{% endcontent-ref %}

{% content-ref url="/pages/4VC5sGonIBmG2zIf78Bz" %}
[Fetching Hats](/for-developers/v1-sdk/subgraph/fetching-hats.md)
{% endcontent-ref %}

{% content-ref url="/pages/eViws1fSgrvWtPG98JHk" %}
[Fetching Wearers](/for-developers/v1-sdk/subgraph/fetching-wearers.md)
{% endcontent-ref %}

{% content-ref url="/pages/3452M4ahmHjfTyFMuMao" %}
[Fetching Trees](/for-developers/v1-sdk/subgraph/fetching-trees.md)
{% endcontent-ref %}

{% content-ref url="/pages/NcXAPNatBNTsPzQYGtgM" %}
[Misc](/for-developers/v1-sdk/subgraph/misc.md)
{% endcontent-ref %}

{% content-ref url="/pages/pg8eDgunNcJK3PMI2Exz" %}
[Types](/for-developers/v1-sdk/subgraph/types.md)
{% endcontent-ref %}


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.hatsprotocol.xyz/for-developers/v1-sdk/subgraph.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
