# Somnia

<a href="https://somnia.chain.love/" class="button primary" data-icon="arrow-up-right">Open Toolbox</a> <a href="https://somnia.chain.love/configurations" class="button primary" data-icon="arrow-up-right">Open Performance</a> <a href="https://somnia.chain.love/rpc" class="button primary" data-icon="arrow-up-right">Open API Management (Subgraphs)</a>

{% hint style="info" %} <img src="https://img.shields.io/badge/Toolbox-Enabled-green" alt="" data-size="original"> <img src="https://img.shields.io/badge/Performance_module-Enabled-green" alt="" data-size="original"> <img src="https://img.shields.io/badge/RPC-not%20supported-lightgrey" alt="" data-size="original"> <img src="https://img.shields.io/badge/Subgraphs-FREE-brightgreen" alt="" data-size="original">
{% endhint %}

Chain.Love on Somnia is a **set of modules** that help you **discover** providers, **monitor** them, and (optionally) **access** RPC/Subgraphs through an API gateway.

## Recommended workflows

* **Discover providers (start here)**: open the [Toolbox](https://somnia.chain.love/) → browse categories (RPC, Indexing, Bridges, Oracles, Wallets, etc.) → shortlist and compare offers.
* **Harden production access**: open [Performance](https://somnia.chain.love/configurations) → set monitoring/notifications → configure routing and failover.
* **Need an RPC/Subgraphs right now**: open [API Management](https://somnia.chain.love/rpc) → use RPC/Subgraphs endpoints (details below).

## Modules on Somnia

### Toolbox (Discovery & comparison)

* **What it is**: a chain-specific marketplace/registry of Web3 services.
* **Key features**:
  * [Discover](https://chain-love.gitbook.io/chain.loves-toolbox/features/discover): browse categories and filter offers
  * [Compare](https://chain-love.gitbook.io/chain.loves-toolbox/features/compare): side-by-side comparison
  * [AI search](https://chain-love.gitbook.io/chain.loves-toolbox/features/ai-search): search across the database (including cross-ecosystem queries)
  * [Widget for docs](https://chain-love.gitbook.io/chain.loves-toolbox/features/widget-for-docs): embed a compact Toolbox view into documentation
  * [Contributing](https://chain-love.gitbook.io/chain.loves-toolbox/contributing/open-source-database): improve the open-source database
* **Open**: `https://somnia.chain.love/`

### Performance (Monitoring & routing)

* **What it is**: a module to manage providers' performance.
* **Key areas**:
  * [Monitoring](https://github.com/Chain-Love/chain.love-docs/blob/main/modules/performance/monitoring/getting-started.md)
  * [Notifications](https://github.com/Chain-Love/chain.love-docs/blob/main/modules/performance/monitoring/notifications.md)
  * [Load balancer](https://github.com/Chain-Love/chain.love-docs/blob/main/modules/performance/load-balancer/getting-started.md)
  * [Performance agreements](https://github.com/Chain-Love/chain.love-docs/blob/main/modules/performance/performance-agreements/getting-started.md)
* **Open**: `https://somnia.chain.love/configurations`

### API Management (Subgraphs)

This module is for **accessing** APIs (Subgraphs). If you’re evaluating providers or comparing options, start with the **Toolbox** section above.

#### Subgraphs (Indexing)

Chain.Love Indexing on Somnia supports both testnet and mainnet networks.

Currently, you can query your subgraphs **by name only**: `https://proxy.somnia.chain.love/subgraphs/name/<SUBGRAPH_NAME>`.

```bash
# Assuming the subgraph name is `somnia-testnet/PrayDotFun`
curl -X POST \
 -H "Content-Type: application/json" \
 -d '{"query":"query MyQuery {\r\n  userScores(first: 10) {\r\n    id\r\n  }\r\n}","variables":{}}' \
 "https://proxy.somnia.chain.love/subgraphs/name/somnia-testnet/PrayDotFun"
```

{% hint style="info" %}
Note that the HTTP path of the query URL is `/subgraphs/name/<SUBGRAPH_NAME>`, different from the format used on Astar.
{% endhint %}


---

# 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://chain-love.gitbook.io/chain-love-docs/blockchains/somnia.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.
