Rocket
Import SpecStream into a Rocket app from the APIs panel: one cURL command for web search, one for page reading, and one for Deep Search rows, with your key kept in the environment.
SpecStream for RocketCoding agentsWhat you need
- A Rocket web build task. Rocket imports APIs in the web browser only, not in its mobile app.
- A SpecStream API key. New accounts get $10 of credit on sign-up, no card. Create one.
- 1
1. Create a key and store it in Rocket
In SpecStream, open Agents & API, choose API keys, then Create API key. Give it the
finds:spendscope and a total spending limit: the limit is the most the app can ever spend.In Rocket, click Code in the editor toolbar, open
.envat the root of the project, and add the variable with a placeholder. Then click your task name, Settings, and under Task click Environment. Use the edit icon on the row to put the real key in both the Staging and Production tabs.Never name it with the
NEXT_PUBLIC_prefix. Rocket sends those variables to the browser, and the key must stay on the server..env - 2
2. Open the APIs panel
Click the ... button in the preview toolbar and select APIs. Open the Select an API dropdown and click Add APIs, then choose the cURL tab.
- 3
3. Import web search
Paste this command and click Add API. After the import, map
$SPECSTREAM_API_KEYto the environment variable, so the header readsAuthorization: Bearerand then your key.The reply is
{"data": {...}}.data.answerholds the value when the question has one answer, anddata.sourceslists the pages read, each withurl,titleandsnippet. Each call costs $5 per 1,000 searches of up to 10 results, and a call that returns nothing costs nothing.cURL tab: Search API - 4
4. Import page reading
Add a second API the same way. It reads up to 20 URLs a call and returns each page's main text as Markdown, with its
titleandstatus, indata.results.Each page read costs $0.80 per 1,000 pages. A page that gives no text is not charged.
cURL tab: Extract API - 5
5. Attach a call to a screen
In the APIs panel, choose the route the call belongs to, select the SpecStream API in Select an API, and click Integrate API. Click a container that is always on the screen, not one that appears only after a click.
In the When to call this API? dialog, fill in the three fields as below and click Submit. Rocket writes the integration code.
When to call this API?
Deep Search: rows for tables and enrichment
For a table, such as every company that meets your conditions with the columns you name, import POST /v1/capacity/requests. SpecStream reads the request, prices it, and starts it only when the price is at or below confirm_max_cents. Above it, nothing runs. idempotency_key is 8 to 128 characters, new for each request, so a repeated call returns the run already started.
To see the price first, send confirm_max_cents of 1. The state comes back above_maximum, with the price in maximum_cents. Send that price with a new key to start.
To enrich rows you already have, send them in rows (each company's name, website or domain) and what to bring back in fields.
Read the rows with GET /v1/capacity/requests/YOUR_KEY/rows, imported the same way. Each delivered row costs 5¢, 15¢ or $1, depending on how much it needs. Duplicates and rows a page contradicts are not charged, and a run that finds nothing costs nothing. The key needs the specs:write, finds:write and finds:spend scopes.
Or import the whole API from its OpenAPI spec
Save openapi.json. It is OpenAPI 3.1.0 with one server, https://api.specstream.ai, and Bearer authentication. In Add APIs, choose Swagger, upload the file, and click Submit.
The spec holds every SpecStream endpoint, so the Select an API list gets long. The cURL imports above add only the calls an app needs.
If your app calls Firecrawl today
Rocket's connectors page lists Firecrawl among the APIs its community connected with the importer. An app that already calls Firecrawl's v2 API keeps its code: change the base address to https://api.specstream.ai/firecrawl and the key to your SpecStream key.
/v2/search is then one web search, answered in Firecrawl's shape, and /v2/scrape is one Extract API page at $0.80 per 1,000 pages. Moving from Firecrawl lists every route.
When a call fails
401: the header is missing or not in the formBearer <key>. Check the mapping of$SPECSTREAM_API_KEYin the Pre API call instructions.402: the balance is empty, or the call would pass the account's monthly limit.403: the key lacks thefinds:spendscope, or the call would pass the key's own limit.503withRetry-After: the account used its calls for the minute. Wait that many seconds. Nothing is charged.
Cost
Importing SpecStream into Rocket costs nothing. Searches and pages come out of the balance as the app runs them, with no quote. Deep Search never costs more than the confirm_max_cents you send. Balance, quotes, and billing has the details, and the API reference has every field.
Disconnect
Revoke the key under Agents & API > API keys in SpecStream, and every call from the app stops at once. Then remove the API from the Rocket project and the variable from Environment. Your saved results stay in your workspace. Questions go to [email protected].
More
SpecStream for Rocket covers what it does in Rocket on one page. Every other tool has its guide in Connect your tools. You see the most a request can cost before it starts, and the matches are paid from your balance. Billing has the details. For help, email [email protected].