A typed client for the whole network.
Install @internetivo/sdk and skip the boilerplate. Auth, the {ok,data,meta} envelope and cursor pagination are handled for you - you get autocomplete, types and real errors instead of raw JSON.
Up and running in two lines.
Install
Run npm i @internetivo/sdk. ESM and CommonJS both supported, types bundled - no extra @types package.
Construct a client
Pass your API key once. The client attaches auth to every request and validates responses for you.
Call a resource
await client.projects.list() returns typed objects - the envelope is unwrapped, errors are thrown as typed exceptions.
What the SDK does for you.
The repetitive, error-prone parts of any integration - solved once, maintained for you.
Auth, automatic
Set your key on the client. Every call carries the bearer token - no manual headers.
Envelope unwrapped
You get data directly. On ok:false the SDK throws a typed error so you never parse failures by hand.
Pagination handled
Iterate list endpoints with async iterators - the SDK reads cursors from meta and fetches pages for you.
Full type safety
Every resource, request and response is typed. Your editor autocompletes fields and catches mistakes at compile time.
Safe retries
Built-in idempotency and backoff on transient failures keep escrow and payout calls correct under retry.
Webhook helpers
Verify signed webhook payloads with one helper - no hand-rolled signature checks.
Why teams reach for the SDK.
Same network, far less code.
Ship features, not plumbing
Create projects, fund escrow and read reputation with typed calls. The SDK handles transport, retries and parsing so your code stays about your product.
Install itPredictable in production
Typed errors, idempotent writes and automatic pagination mean fewer edge cases at 3am. The envelope contract is guarded by tests against drift.
Built to depend on.
Versioned, tested and tracking the API.
Semver releases
Published to npm with semantic versioning - breaking changes are major bumps, never surprises.
Contract-tested
A contract test guards the {ok,data,meta} envelope so the SDK and API never drift apart.
Lightweight
Small dependency footprint and tree-shakeable, so it stays out of your bundle's way.
Typed docs
Types are the docs - hover any method for its signature, fields and return shape.
SDK questions.
Which runtimes are supported?
Node and modern bundlers, ESM and CommonJS. It is published as @internetivo/sdk on npm with types included, so TypeScript and JavaScript both work out of the box.
Do I still need to know the API?
Not to get started. The SDK mirrors the REST resources one to one, so the API reference doubles as your method map when you want the detail.
How does it handle pagination?
Automatically. List methods return async iterators that read the cursor from meta and fetch subsequent pages, so you just loop over results.
What about errors?
A failed call throws a typed error carrying the stable code and message from the envelope. Catch it, switch on the code, show the message.
npm i @internetivo/sdk
Install the typed client and make your first escrow-backed call in a single line.