Node SDK
npm install hyperclip · TypeScript-first · Node 18+ · zero runtime depsPython SDK
pip install hyperclipco · Python 3.9+ · httpx under the hoodInstall
The npm package is
hyperclip. The PyPI package is hyperclipco (the bare hyperclip name was already taken). The Python module imports as hyperclipco, but the class is still Hyperclip for consistency with the Node SDK.Configure
The only thing you need is your API key. SetHYPERCLIP_API_KEY in your environment and the SDK picks it up automatically — the base URL defaults to Hyperclip production, so you don’t have to configure it.
process.env:
Constructor options
Method reference
All methods are grouped under two namespaces:runs (the asynchronous-execution endpoints) and flows (saved-flow inspection).
runs.create(params) · POST /runs
Submit a new run. Returns immediately with a run handle — does not wait for completion.
flow_id or flow_schema required):
flow_id· saved flow UUID fromflows.list()flow_schema· inline FlowSchema JSON; see flowsinputs· per-step overrides; see inputsidempotency_key· opaque retry key; strongly recommended for every call
runs.get(id) · GET /runs/:id
Fetch the latest state of a single run. Use this to poll, or use the higher-level wait() method below.
runs.wait(id, options?) · convenience polling
Poll until the run reaches a terminal state (completed, failed, or cancelled). Replaces hand-rolled polling loops.
- Returns the final run object on
completed,failed, orcancelled. - Raises
HyperclipTimeoutErrorif the run doesn’t finish withintimeoutMs/timeout. - The
onUpdate/on_updatecallback fires on every poll — use it for progress UI or structured logging.
runs.list(params?) · GET /runs
List your recent runs. Useful for dashboards or reconciliation jobs.
runs.cancel(id) · POST /runs/:id/cancel
Cancel a queued or running run. The worker stops at the next step boundary; any in-flight provider call still completes and bills naturally.
flows.list() · GET /flows
List flows the API key can access (your own flows plus any public ones you’ve saved).
flows.get(id) · GET /flows/:id
Fetch a single flow’s full FlowSchema plus its required_inputs summary — what prompts and media slots the API caller must fill in.
Errors
Both SDKs raise a typed error class when the API returns a non-2xx response:code values you can branch on.
Runtime requirements
The Node SDK works on Vercel, Netlify, AWS Lambda, Cloudflare Workers, Bun, and Deno (with
npm: specifiers). Edge runtimes need to support fetch and crypto.randomUUID().
The Python SDK works in any 3.9+ environment that allows installing httpx. For async codebases, you can pass your own httpx.AsyncClient and call the SDK from synchronous threads, or wait for the upcoming async client.
Versioning
Both SDKs follow SemVer and ship in lockstep —[email protected] matches hyperclipco==0.1.x. Pin to a minor version in production:
When not to use the SDK
The SDKs are thin wrappers — they don’t unlock any capabilities you can’t get from raw HTTP. Reach for raw fetch / requests / curl when:- You’re calling Hyperclip from a language we don’t ship an SDK for (Go, Ruby, PHP, etc.). The REST API is plain JSON over HTTPS.
- You need an HTTP client behavior the SDK doesn’t expose — custom retries, mTLS, structured logging hooks. The SDK uses
fetch/httpx, both of which are wrappable. - You’re prototyping in a notebook or shell.
curl | jqandrequests.post()are perfectly fine.
Where to next
Quickstart
End-to-end: install the SDK, run a flow, save the MP4.
Node example
Bulk processing, Next.js routes, idempotency patterns.
Python example
CSV-driven batch jobs, FastAPI proxies, async patterns.
Error reference
Every error code with recovery guidance.
Build with AI tools
Wire Claude, Cursor, or Copilot into these docs via the hosted MCP server.