@otto-code/client
v0.9.0
Published
Otto client SDK package
Readme
@otto-code/client
TypeScript SDK for building integrations on top of a Otto daemon.
npm install @otto-code/clientimport { createOttoClient } from "@otto-code/client";
const client = createOttoClient({ url: "ws://127.0.0.1:6868/ws" });
await client.connect();
const agent = await client.agents.create({
config: { provider: "codex/gpt-5.5" },
cwd: "/Users/me/dev/storefront",
prompt: "Review the current diff and name the riskiest change.",
});
const result = await agent.waitForFinish();
console.log(result.lastMessage);
await client.close();The public API is the package root. Imports under @otto-code/client/internal/* are unsupported implementation details used by Otto's own packages.
Read the SDK documentation for agents, workspaces, provider discovery, events, recipes, and the API reference. Runnable TypeScript patterns also live in examples/.
Runtime
The client needs a WebSocket implementation. Modern browsers and Node.js 22 provide one globally.
Use a WebSocket URL ending in /ws, such as ws://127.0.0.1:6868/ws. Pass password when the daemon requires authentication.
Stability
The high-level API exported from @otto-code/client is the supported SDK surface. The SDK and daemon remain protocol-compatible across versions, but newly added capabilities can require a newer daemon.
