TypeScript SDK
@iris/sdk is a thin, fully-typed wrapper around the REST API. It works in any Node 20+ environment.
Install
npm install @iris/sdkConfigure
import { IrisClient } from "@iris/sdk";
const iris = new IrisClient({
apiKey: process.env.IRIS_API_KEY!,
baseUrl: process.env.IRIS_API_URL, // optional; defaults to hosted URL
});Common calls
// Get the most recent recording's full structured context
const latest = await iris.getLatestRecording();
console.log(latest.context.summary);
// List with pagination
const { items, pagination } = await iris.listRecordings({ limit: 20, offset: 0 });
// Fetch a specific recording's context
const ctx = await iris.getRecordingContext("rec_…id…");
// Search summaries/transcripts/OCR
const hits = await iris.search("deploy bug", 5);Error handling
The client throws an Error on non-2xx responses with the status and body included. Wrap calls in try/catch if you need to distinguish 401 (bad key) from 429 (rate limit) from 5xx (transient).
Types
Shared types (Recording, RecordingContext, TimelineEvent, UserAction) re-export from @iris/shared. The SDK consumes them, so anything you build on top has consistent typing.
Found a gap or a typo? Open an issue or PR on GitHub.