A standalone TypeScript SDK for any developer: durable agents, tools, streaming, and an experimental MCP server for Claude Code, Cursor, and other MCP clients. The same contract is the integration layer under Zhivex Harness.
TypeScript 1.36.0 shipped on 2026-10-26 with Core 1.37.0, OpenAI 0.18.0, Gateway 1.8.2, Kimi 0.8.1, and Qwen 0.18.1. npm latest was checked the same day. The other adapter patches only raise the Core floor or update dependencies.
What's new in 1.36
GPT-6.1 Terra, Kimi K3.1 Pro, PixVerse V6, and OpenAI Decisions GA
OpenAI gpt-6.1-terra joins the catalog with a 1,050,000-token combined context window and 128,000 max output tokens. Standard rates are $1 input, $0.05 cached input, and $5 output per million tokens. Prompts above 272K input tokens use 2x input and cache rates and 1.5x output. @zhivex-ai/openai@0.18.0 recognizes it for text and image input. Tool calling requires the Responses API.
kimi-k3.1-pro and kimi-k3.1-pro-highspeed have a 1,048,576-token combined context window, and kimi-k3 stays the Kimi default. Qwen adds PixVerse V6 text-to-video, image-to-video, keyframe, and reference-to-video models. The default Qwen host is unchanged. The default catalog snapshot 2026-10-26 lists 284 models.
decisionModel targets the GA OpenAI Decisions API with JSON, image URLs, message history, prompt-cache options, safety identifiers, and score descriptions. experimentalDecisionModel remains a deprecated alias, and the default decision model stays gpt-6-luna. Core 1.37.0 exports the new Decision* types, and the SDK re-exports them. Optional GA fields are sent only when you set them.
bun add @zhivex-ai/sdk@1.36.0 @zhivex-ai/openai@0.18.0
useObject streams structured output. useApproval sends client decisions to a server gate. The AG-UI adapter stays in @zhivex-ai/ag-ui and is not part of @zhivex-ai/sdk.
Adopt one layer at a time. The shared contract stays small while operational capabilities remain available when your system needs them.
01
Portable contracts
Keep messages, tools, streaming events, usage, and structured output consistent as models change.
02
Agent-ready runtimes
Build tool-using agents with sessions, handoffs, approvals, durable state, replay, and governed control-plane primitives.
03
Production controls
Add safety policies, evaluation gates, bounded artifacts, OpenTelemetry, model catalogs, and provider-aware routing.
04
Native escape hatches
Start portable, then reach provider-specific capabilities without leaking them through your whole app.
05
Multimodal foundations
Use text, tools, structured output, embeddings, audio, files, and realtime features where supported.
06
Server-first by design
Keep credentials, tools, databases, and policy on trusted server runtimes—not inside browser clients.
Quickstart
From install to first response in minutes
Pick your language, copy the command, and follow the focused quickstart for your runtime.
Start with the local verification in the guide to avoid model charges. The code below makes a billable call. Set OPENAI_API_KEY and ZHIVEX_MODEL: API keys and credentials.
quickstart.mts
Install: bun add @zhivex-ai/sdk@1.36.0 @zhivex-ai/openai@0.18.0 (or npm install). Run: bun run quickstart.mts or npx tsx quickstart.mts. See the guide for project setup.
import { generateText } from"@zhivex-ai/sdk";
import { createOpenAI } from"@zhivex-ai/openai";
const openai = createOpenAI();
const result = await generateText({
model: openai(process.env.ZHIVEX_MODEL!),
prompt: "What should we build next?"
});
console.log(result.text);
quickstart.py
Install: python3 -m pip install zhivex-ai-sdk==0.29.0. Run: python3 quickstart.py. Use Python 3.11+; the guide includes virtual environment setup.
import asyncio, os
from zhivex_ai import Agent, create_openai, run_agent
async def main():
provider = create_openai()
agent = Agent(
name="builder",
instructions="Help ship useful AI products.",
model=provider(os.environ["ZHIVEX_MODEL"]),
)
result = await run_agent(agent=agent, prompt="What should we build next?")
print(result.text)
asyncio.run(main())
A production path
Adopt only what you need Add rigor when it matters
01
Start small
Choose the stable surface
Begin with generation or the agent runtime and install only the provider adapters your app needs.
02
Scale safely
Move state to durable stores
Add shared SQL state, approval queues, artifacts, privacy-aware telemetry, and regression gates before real users arrive.
03
Stay flexible
Route without rewriting
Use the shared contract for portable behavior and native namespaces only for deliberate provider features.