{"_id":"@specstream/sdk","_rev":"5-a86b2ced7cb117a6099469168ea11210","name":"@specstream/sdk","dist-tags":{"latest":"1.2.0"},"versions":{"0.0.0-stage":{"name":"@specstream/sdk","version":"0.0.0-stage","_id":"@specstream/sdk@0.0.0-stage","stub":true,"maintainers":[{"name":"specstream","email":"support@specstream.ai"}],"dist":{"shasum":"f7277cc932a35bcb13df65ccebdfaf863139215c","tarball":"https://registry.npmjs.org/@specstream/sdk/-/sdk-0.0.0-stage.tgz","fileCount":2,"integrity":"sha512-ahGA9+g7lhqmAXqY/bblUUQoFPBs1wOmhxPh3w33hubm55j6dNZJ/dMXRyCT7wQns432eqFHPlJw35feR+8XXA==","signatures":[{"sig":"MEUCIQDoye//eMi957NgRDVWZ01eTxfaF03gn6Y5HB88i+NzkgIgH6CBCSysEOZ+ZI0GVEX2KD77kKHhCSd/MXqTBye6ECA=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":337},"_npmUser":{"name":"specstream","email":"support@specstream.ai"},"description":"Temporary package placeholder for staged publishing","directories":{}},"1.0.0":{"name":"@specstream/sdk","version":"1.0.0","keywords":["specstream","web-data","live-web","lead-lists","enrichment","monitoring","mcp","ai-agents","sdk"],"author":{"url":"https://specstream.ai","name":"SpecStream","email":"support@specstream.ai"},"license":"MIT","_id":"@specstream/sdk@1.0.0","maintainers":[{"name":"specstream","email":"support@specstream.ai"}],"homepage":"https://specstream.ai/docs/sdk","bugs":{"url":"https://github.com/Specstreamai/specstream-tools/issues"},"dist":{"shasum":"9746987f315203594ab5c8affdb373d6579c9975","tarball":"https://registry.npmjs.org/@specstream/sdk/-/sdk-1.0.0.tgz","fileCount":9,"integrity":"sha512-iaURHZkOiNA/KqF4bbDntGxorGH2CSFzCss0etshsFyj1bd6J3YfH1UMX117NanLhv8gv6uL+5yOQeeHQahUKA==","signatures":[{"sig":"MEUCIQCO9CZGgs/KtIGC6JZnydsxxrlsQ5sO2W2URlmOuh0NEQIgTCynpTrLx/0RV7PnYBUV2hyMcbK77lpLt1Gd3E06ls4=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"},{"sig":"MEYCIQDJVm5JnCxDxPVc2aXdNr1V27f2gZJ/lWyaRJMCjmMttQIhAOrV+r2PZY0kZoWAiwmNII+attv/blycLCrzXPakFHMT","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@specstream%2fsdk@1.0.0","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":131074},"main":"./dist/index.js","type":"module","types":"./dist/index.d.ts","engines":{"node":">=22"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","default":"./dist/index.js"}},"gitHead":"a0db3a4c43b39ac91101336b51373a22d609f84f","scripts":{"test":"npm run build && node --experimental-strip-types --test test/*.test.ts","build":"tsc -p tsconfig.json","prepack":"npm run build"},"_npmUser":{"name":"specstream","email":"support@specstream.ai"},"repository":{"url":"git+https://github.com/Specstreamai/specstream-tools.git","type":"git","directory":"packages/sdk-ts"},"_npmVersion":"10.9.9","description":"TypeScript client for SpecStream: finished lists from the live web, every row with its source, priced before anything runs.","directories":{},"sideEffects":false,"_nodeVersion":"22.23.3","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"typescript":"5.9.3"},"_npmOperationalInternal":{"tmp":"tmp/sdk_1.0.0_1791776370262_0.6654948338616624","host":"s3://npm-registry-packages-npm-production"}},"1.1.0":{"name":"@specstream/sdk","version":"1.1.0","keywords":["specstream","web-data","live-web","lead-lists","enrichment","monitoring","mcp","ai-agents","sdk"],"author":{"url":"https://specstream.ai","name":"SpecStream","email":"support@specstream.ai"},"license":"MIT","_id":"@specstream/sdk@1.1.0","maintainers":[{"name":"specstream","email":"support@specstream.ai"}],"homepage":"https://specstream.ai/docs/sdk","bugs":{"url":"https://github.com/Specstreamai/specstream-tools/issues"},"dist":{"shasum":"ecfdcf037e1b09de4def294e7694e7e014830ce3","tarball":"https://registry.npmjs.org/@specstream/sdk/-/sdk-1.1.0.tgz","fileCount":9,"integrity":"sha512-rOfYJpz91hDUQkoFwA0EOPE6/zKTWMi9KA0V2oR9EgpSsiEFnTcmZmoY65tSSV/qKEB1gmd9T8MMHGfNI6wgfw==","signatures":[{"sig":"MEUCIQDy51ZuoHw0j/uY+o+qixTJfShXRNsHCE8kEoKinVwOwwIgJk5ByH8Qf5X0VrhvmaAsiTOi1n7GS8y3SXQsX+42Nmc=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"},{"sig":"MEUCIQD23Ec62p8lw3PsODnchKE4biGe/VRYuncvP5EbhBvX+gIgHYmrtX1OLlSqch3ior24r958En/M7CFPiyrHbnG0ym0=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@specstream%2fsdk@1.1.0","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":149705},"main":"./dist/index.js","type":"module","types":"./dist/index.d.ts","engines":{"node":">=22"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","default":"./dist/index.js"}},"gitHead":"d2faa4d68a4ef4387a6f06facda6c96e9f416f0a","scripts":{"test":"npm run build && node --experimental-strip-types --test test/*.test.ts","build":"tsc -p tsconfig.json","prepack":"npm run build"},"_npmUser":{"name":"specstream","email":"support@specstream.ai"},"repository":{"url":"git+https://github.com/Specstreamai/specstream-tools.git","type":"git","directory":"packages/sdk-ts"},"_npmVersion":"10.9.9","description":"TypeScript client for SpecStream: finished lists from the live web, every row with its source, priced before anything runs.","directories":{},"sideEffects":false,"_nodeVersion":"22.23.3","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"typescript":"5.9.3"},"_npmOperationalInternal":{"tmp":"tmp/sdk_1.1.0_1792023203972_0.5085435954718633","host":"s3://npm-registry-packages-npm-production"}},"1.1.1":{"name":"@specstream/sdk","version":"1.1.1","keywords":["specstream","web-data","live-web","lead-lists","enrichment","monitoring","mcp","ai-agents","sdk"],"author":{"url":"https://specstream.ai","name":"SpecStream","email":"support@specstream.ai"},"license":"MIT","_id":"@specstream/sdk@1.1.1","maintainers":[{"name":"specstream","email":"support@specstream.ai"}],"homepage":"https://specstream.ai/docs/sdk","bugs":{"url":"https://github.com/Specstreamai/specstream-tools/issues"},"dist":{"shasum":"4ae203366b156b45daf055152c653fb5451796dd","tarball":"https://registry.npmjs.org/@specstream/sdk/-/sdk-1.1.1.tgz","fileCount":9,"integrity":"sha512-200q8LWYdeMhAU8TYKlYPV8/J7xWlO5kKTxfK1SlE8MkqB1/SR4PJG2ProVqmDZhq52Fg9y25Iezb42QHEcpMA==","signatures":[{"sig":"MEQCIEFXvImdmzDcKMIm1pyIBtcUQ8sG8lT0A5azayJOH3+qAiB2/Hjtx6h18XALWF1fA8beqGiQ80cuhZebRuAo1VAqQw==","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"},{"sig":"MEUCIBRBxshz1edcFtukGFh9+IA0q5zgaWsTaOZqr7s3bCAMAiEAhCBSkH/QRCUWmPsFEo5IqfotGXBSJ+IZlCCBkVTTSjg=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@specstream%2fsdk@1.1.1","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":149753},"main":"./dist/index.js","type":"module","types":"./dist/index.d.ts","engines":{"node":">=22"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","default":"./dist/index.js"}},"gitHead":"19762596c1a3adcca70fd50f9869745266812b0c","scripts":{"test":"npm run build && node --experimental-strip-types --test test/*.test.ts","build":"tsc -p tsconfig.json","prepack":"npm run build"},"_npmUser":{"name":"specstream","email":"support@specstream.ai"},"repository":{"url":"git+https://github.com/Specstreamai/specstream-tools.git","type":"git","directory":"packages/sdk-ts"},"_npmVersion":"10.9.9","description":"TypeScript client for building lead lists and company lists from the live web. Every match comes with its source, priced before it runs.","directories":{},"sideEffects":false,"_nodeVersion":"22.23.3","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"typescript":"5.9.3"},"_npmOperationalInternal":{"tmp":"tmp/sdk_1.1.1_1792033508618_0.03006212592279378","host":"s3://npm-registry-packages-npm-production"}},"1.2.0":{"_id":"@specstream/sdk@1.2.0","bugs":{"url":"https://github.com/specstream/specstream-tools/issues"},"dist":{"shasum":"2c2bfaaff6c526f558abfe659d76a79a02b8be2b","tarball":"https://registry.npmjs.org/@specstream/sdk/-/sdk-1.2.0.tgz","fileCount":9,"integrity":"sha512-qP9WGw61iU5trF+lQrkbIyqK84bvUQJSRB8Yyo7RgM/FoKEtA8pGz50CUdZy/rSVqzq2RFtI4Dk4PUeZrCY7LA==","signatures":[{"sig":"MEUCIAQ6bpLfG0FPq9nlv3H+Ls+x4VE6C2LBQiWE2BAlTE2gAiEAtrKkyzRp9VyE3l2CPTa98rBkwyKznuVq6ac73XffIc4=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"},{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEYCIQCZ1xqL7SAlqMxPvED/LRLf3AgLHtKeH79IbGr3w9pZ5gIhAO9DisnDvZZwOQt2KuCCJqfZeiUmhlXBP4bnltAZtKKn"}],"attestations":{"url":"https://registry.npmjs.org/-/npm/v1/attestations/@specstream%2fsdk@1.2.0","provenance":{"predicateType":"https://slsa.dev/provenance/v1"}},"unpackedSize":152256},"main":"./dist/index.js","name":"@specstream/sdk","type":"module","types":"./dist/index.d.ts","author":{"url":"https://specstream.ai","name":"SpecStream","email":"support@specstream.ai"},"engines":{"node":">=22"},"exports":{".":{"types":"./dist/index.d.ts","import":"./dist/index.js","default":"./dist/index.js"}},"gitHead":"986f44534932287afb185347e022e2d3c53aa8cd","license":"MIT","scripts":{"test":"npm run build && node --experimental-strip-types --test test/*.test.ts","build":"tsc -p tsconfig.json","prepack":"npm run build"},"version":"1.2.0","_npmUser":{"name":"GitHub Actions","email":"npm-oidc-no-reply@github.com","trustedPublisher":{"id":"github","oidcConfigId":"6fa53f1d-14b2-4c99-b66a-2e65ae5fed76"}},"homepage":"https://specstream.ai/docs/sdk","keywords":["specstream","web-data","live-web","lead-lists","enrichment","monitoring","mcp","ai-agents","sdk"],"repository":{"url":"git+https://github.com/specstream/specstream-tools.git","type":"git","directory":"packages/sdk-ts"},"_npmVersion":"12.2.1","description":"TypeScript client for building lead lists and company lists from the live web. Every match comes with its source, priced before it runs.","directories":{},"maintainers":[{"name":"specstream","email":"support@specstream.ai"}],"sideEffects":false,"_nodeVersion":"22.23.4","publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"typescript":"5.9.3"},"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/sdk_1.2.0_1793410225652_0.08691397999973538"}}},"time":{"created":"2026-10-12T03:38:34.257Z","modified":"2026-10-31T01:30:26.083Z","0.0.0-stage":"2026-10-12T03:38:34.257Z","1.0.0":"2026-10-12T03:39:30.342Z","1.1.0":"2026-10-15T00:13:24.061Z","1.1.1":"2026-10-15T03:05:08.718Z","1.2.0":"2026-10-31T01:30:25.745Z"},"bugs":{"url":"https://github.com/specstream/specstream-tools/issues"},"author":{"url":"https://specstream.ai","name":"SpecStream","email":"support@specstream.ai"},"license":"MIT","homepage":"https://specstream.ai/docs/sdk","keywords":["specstream","web-data","live-web","lead-lists","enrichment","monitoring","mcp","ai-agents","sdk"],"repository":{"url":"git+https://github.com/specstream/specstream-tools.git","type":"git","directory":"packages/sdk-ts"},"description":"TypeScript client for building lead lists and company lists from the live web. Every match comes with its source, priced before it runs.","maintainers":[{"name":"specstream","email":"support@specstream.ai"}],"readme":"# @specstream/sdk\n\nTypeScript client for [SpecStream](https://specstream.ai), the live web data engine for teams and agents. Describe the list you need in plain words; SpecStream reads the web where those things live, hands back only the matches, each with the page it came from, and you pay for each result delivered.\n\nThe client has no runtime dependencies and needs Node 22 or newer. It uses the same account, permissions, projects and balance as the workspace.\n\n```sh\nnpm install @specstream/sdk\n```\n\nCreate an API key under **Agents & API** in your SpecStream workspace and keep it in the environment: `SPECSTREAM_API_KEY`.\n\n## Read a request, get the price\n\n```ts\nimport { Client } from \"@specstream/sdk\";\n\nconst client = new Client({ apiKey: process.env.SPECSTREAM_API_KEY! });\n\nconst read = await client.compile(\n  \"Open-source document-signing tools I can self-host. Include the license and latest release.\",\n);\nconst offer = await client.quoteCapacityWork({\n  ast_hash: String(read.ast_hash),\n  operation: \"find\",\n  requested_units: 25,\n});\nconsole.log(offer.maximum_cents, offer.expires_at);\n```\n\nNothing has run yet. Show a person the quote: what will be found, the facts that come back, the most the work can cost, and when the price expires. A price lasts 30 minutes.\n\n## Approve it, then read the results\n\nAfter a person approves, send the approved maximum in cents and a request key you saved first:\n\n```ts\nconst run = await client.authorizeCapacityWork({\n  quote_id: offer.quote_id,\n  quote_hash: offer.quote_hash,\n  confirm_max_cents: approvedMaximumCents,\n  idempotency_key: savedRequestKey,\n});\n\nif (!run.find_id) throw new Error(\"The work was not started; retry with the same key\");\nconst page = await client.rows(run.find_id);\nfor (const row of page.rows) console.log(row);\n```\n\nIf the response is lost, `getCapacityRequest(savedRequestKey)` returns the same work. Keep the original key when you retry, and you will not pay twice. `authorizeCapacityWork` throws before any network call unless the quote, its signature, a whole-number maximum and the key are all present. `getFind` reports progress, and `rows` pages with `next_cursor`. Reading, exporting and sharing results you own cost nothing.\n\n## More\n\n- `quoteCapacityWork` also prices `extend`, `add_facts` and `refresh` (a recheck, at half price) on a finished run.\n- `specOptions(kind)` lists the facts you can ask for per kind of thing. `editSpec` changes a request without rereading it.\n- `createCapacitySchedule` keeps a request current inside per-run and per-period limits.\n- `export` and `downloadExport` give CSV, XLSX, JSON or HTML.\n- Errors are `SpecstreamError` with `status`, `code` and `details`.\n\n## Pricing\n\nNew accounts start with $10 of work for 30 days, no card. A delivered result costs 10 cents, 30 cents or $1 depending on how many facts it carries. No result, no charge. See [pricing](https://specstream.ai/pricing).\n\n## Links\n\n- [SDK docs](https://specstream.ai/docs/sdk) and [API docs](https://specstream.ai/docs/api)\n- [Source and issues](https://github.com/specstream/specstream-tools)\n- [Python client](https://pypi.org/project/specstream-client/)\n- Support: support@specstream.ai\n\nMIT license.\n","readmeFilename":"README.md"}