> SpecStream is the live web data engine for teams and agents. This is the Markdown copy of https://specstream.ai/docs/integrations/9router. Every page, with what SpecStream does and costs: https://specstream.ai/llms.txt

# 9router

Set one environment variable, and 9router's built-in SearXNG provider searches the live web through the SpecStream Search API. There is no SearXNG server to run, and the coding tools behind 9router keep calling /v1/search as before.

[SpecStream for 9routerAgent frameworks & builders](https://specstream.ai/integrations/9router.md)

## What you need

-   9router 0.5.30 or later. That release added `SEARXNG_URL`.
-   A SpecStream API key. New accounts start with $10 of credit, no card. [Create an account](https://specstream.ai/signup?utm_source=9router).

1.  1

    ## 1. Get a SpecStream key

    [Get your key](https://specstream.ai/workspace/search?route=searxng&utm_source=9router&utm_medium=howto) on the Search API screen of your SpecStream workspace.

2.  2

    ## 2. Start 9router with SEARXNG\_URL set

    9router's SearXNG provider sends no key, so the key goes in the address. Set `SEARXNG_URL` to this address, with your key in place of `YOUR_SPECSTREAM_KEY`:

    `https://api.specstream.ai/searxng/YOUR_SPECSTREAM_KEY/search`

    9router uses the address as it is when it ends in `/search`. It reads the variable when it starts, so recreate the container with the new flag. Your providers, keys and combos stay in `$HOME/.9router`. With the npm install, start it as `SEARXNG_URL=... 9router`, or put the line in the `.env` you start it with.

    The address holds your key. Keep it in an env file or a secret, not in a script you share.

    Docker

    ```bash
    docker rm -f 9router
    docker run -d \
      --name 9router \
      -p 20128:20128 \
      -v "$HOME/.9router:/app/data" \
      -e DATA_DIR=/app/data \
      -e SEARXNG_URL="https://api.specstream.ai/searxng/YOUR_SPECSTREAM_KEY/search" \
      decolua/9router:latest
    ```

3.  3

    ## 3. Run a search

    Send a search to 9router with `searxng` as the model. A new install has **Require API key** on, so send a 9router key from **Endpoint & Key** in the dashboard as the Bearer token:

    Terminal

    ```bash
    curl -X POST http://localhost:20128/v1/search \
      -H "Authorization: Bearer YOUR_9ROUTER_KEY" \
      -H "Content-Type: application/json" \
      -d '{"model":"searxng","query":"9router release notes","max_results":5}'
    ```

4.  4

    ## 4. Use it in a combo

    In the dashboard, open **Media Providers**, then **Web Fetch & Search**. Under **Web Search**, select **Create Combo** and add SearXNG. It needs no connection. Put it first, and the providers after it take over when a search fails.

    The `9router-web-search` skill calls the same `/v1/search` endpoint, so a coding agent with the skill searches through the combo or through `searxng` directly.

## What 9router sends

Each search is `GET https://api.specstream.ai/searxng/<key>/search` with `q`, `format=json` and `categories=general`, plus `language`, `time_range` and `pageno` when the request has them. The Search API answers in SearXNG's JSON shape: `results[].title`, `url` and `content`. 9router reads them as `title`, `url` and `snippet` and keeps the first `max_results`, 5 when the request names none. `publishedDate` is null on most results.

A request with `search_type` `news` goes out as `categories=news` and gets web results.

We ran the `decolua/9router` image (version 0.5.116) with this setting on November 12, 2026. Its search reached the Search API at this address with the key from `SEARXNG_URL`.

## Why not run SearXNG yourself

The default `SEARXNG_URL` is `http://localhost:8888/search`: a SearXNG server you install, keep running and configure to answer in JSON. With the SpecStream address there is no server to run, and the results come from the most accurate web search API on SimpleQA Verified and WideSearch. The scores and the method are on [the benchmarks page](https://specstream.ai/benchmarks.md).

## Web fetch

9router's **Web Fetch** providers (Firecrawl, Jina Reader, Tavily and Exa) call their own fixed addresses, and no setting moves them. Pages a search finds are read by the provider you connect there, not by SpecStream. To read pages with the [Extract API](https://specstream.ai/extract-api.md), call it from your own code.

## Cost

Each search is one Search API call at $5 per 1,000 searches of up to 10 results. It comes out of your balance, with no quote and no approval. 9router asks for one page of results, so every search is billed at the base price, and a search that returns no results costs nothing. New accounts start with $10 of credit, no card.

## Turn it off

Recreate the container without `SEARXNG_URL`, and 9router goes back to `http://localhost:8888/search`. To end the key's access, revoke it under **Agents & API** in your SpecStream workspace. Questions go to [support@specstream.ai](mailto:support@specstream.ai).

## More

[SpecStream for 9router](https://specstream.ai/integrations/9router.md) covers what it does in 9router on one page. Every other tool has its guide in [Connect your tools](https://specstream.ai/docs/integrations.md). You see the most a request can cost before it starts, and the matches are paid from your balance. [Billing](https://specstream.ai/docs/billing.md) has the details. For help, email [support@specstream.ai](mailto:support@specstream.ai).
