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

# Pi

SpecStream for Pi brings live web data to the Pi agent. Describe what you need, approve the price, and read the records in the session.

[SpecStream for Pi, Coding agents](https://specstream.ai/integrations/pi.md)

## What you need

-   A SpecStream account. You can create one free and spend the included $2.
-   Pi.

1.  1

    ## 1. Install the package

    Install the package from npm. It registers SpecStream's server, `https://api.specstream.ai/mcp`, with Pi's built-in MCP support and adds the skills. To try it for a single run first, start Pi with `pi -e npm:@specstream/pi-package` instead.

    Terminal

    ```bash
    pi install npm:@specstream/pi-package
    ```

2.  2

    ## 2. Sign in to SpecStream

    Run the login command. Your browser opens SpecStream. Sign in and approve access, and Pi stores the token and refreshes it. Inside a session, `/mcp` shows the connection and lets you sign in or out.

    Terminal

    ```bash
    pi mcp login specstream
    ```

3.  3

    ## 3. Ask Pi

    Describe the records you want, then name the fields to bring back. For example:

    In Pi

    ```text
    Find independent bookstores in Oregon with a website and a phone number.
    ```

## Tools and skills

In Pi, SpecStream's tools are named `mcp__specstream__<tool>`. The ones every request passes through stay in view: `compile`, `quote_capacity_work`, `authorize_capacity_work`, `get_find`, and `list_find_rows`. The rest load when needed through `tool_search`.

Skills load when the task calls for them, or when you name them.

| Skill | What it does |
| --- | --- |
| `/skill:specstream-compile` | Puts your request in SpecStream's terms before any work starts. |
| `/skill:specstream-review-work` | Fetches the price and its expiry. |
| `/skill:specstream-approve-work` | Runs the work after you approve its price. |
| `/skill:specstream-continue-work` | Reads all the rows, sends them on to HubSpot, Salesforce, Airtable, Notion, Excel, or Sheets, and brings back more, refreshes, or monitors. |

## Add only the server

To skip the skills, add the server on its own with `pi mcp add specstream --url https://api.specstream.ai/mcp`, then run `pi mcp login specstream`. That writes the server to `~/.pi/agent/mcp.json`. A server of the same name in `mcp.json` takes precedence over the one the package registers.

## Use an API key

For servers and CI, create a key under **API keys** in **Agents & API**. Give it read, prepare, or execute access, its projects, an expiry, and a spending limit. [How keys and limits work](https://specstream.ai/docs/account.md#keys).

Export it before you start Pi: `export SPECSTREAM_API_KEY=YOUR_SPECSTREAM_API_KEY`. With the variable set, the extension sends `Authorization: Bearer ${SPECSTREAM_API_KEY}`. Pi fills the value in from your environment, so the package never writes the key to a file.

## What the package reads

The extension reads one environment variable, `SPECSTREAM_API_KEY`, only to decide whether to send that header. Requests and price approvals reach `api.specstream.ai` over HTTPS, and results return the same way.

## Limits and cost

Reading a request is free, and so is its price. You approve an exact maximum before paid work begins. Results run from 5 cents to $1 each, set by the kind of work. See [pricing](https://specstream.ai/pricing.md).

## Disconnect

Sign out from `/mcp` inside Pi. From SpecStream's side, revoke the app in Settings, or revoke the key in **Agents & API**. The package page is on [pi.dev (opens in a new tab)](https://pi.dev/packages/@specstream/pi-package). For help, email [support@specstream.ai](mailto:support@specstream.ai).

## More

[SpecStream for Pi](https://specstream.ai/integrations/pi.md) covers what it does in Pi 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).
