Claude Wire — Development skill for Claude Code
TypeScript SDK for Claude Code - spawn, stream, and control the CLI programmatically.
How to install Claude Wire
This entry records only its repository, not the path inside it, so there is no
exact command to give. Open pivanov/claude-wire and copy the folder into
~/.claude/skills/, or the file into ~/.claude/agents/.
What Claude Wire does
TypeScript SDK for Claude Code - spawn, stream, and control the CLI programmatically.
Alternatives in Development
- Happy Coder — by GrocerPublishAgent - Spawn and control multiple Claude Codes in parallel from your phone or desktop 15.7k ★
- Connect — Fancy stream processing made operationally mundane 8608 114 1 8.6k ★
- Mcporter — Call MCPs via TypeScript, masquerading as simple TypeScript API 4.1k ★
README
@pivanov/claude-wire
Run [Claude Code](https://claude.ai/download) programmatically from TypeScript.
[](https://www.npmjs.com/package/@pivanov/claude-wire) [](./LICENSE)
import { claude } from "@pivanov/claude-wire";
const result = await claude.ask("Fix the bug in main.ts", {
model: "haiku",
maxCostUsd: 0.50,
});
console.log(result.text); // "Fixed the undefined variable..."
console.log(result.costUsd); // 0.0084
Features
- Simple API -
claude.ask()returns a typed result,claude.stream()yields events - Structured JSON -
claude.askJson(prompt, schema)with Standard Schema (Zod/Valibot/ArkType) validation - Tool control - allow, block, or intercept any tool at runtime
- Multi-turn sessions - persistent process across multiple prompts
- Cost tracking - per-request budgets with auto-abort and projection primitives
- Typed errors - rate-limit, overload, context-length, retry-exhausted as
KnownErrorcodes - Fully typed - discriminated union events, full IntelliSense
- Resilient - auto-respawn with backoff, transient error detection, AbortSignal
- Zero dependencies
- Subpath exports -
/errors,/parser,/testingfor narrower imports and bundle-isolated test helpers
Install
bun add @pivanov/claude-wire
# or
npm install @pivanov/claude-wire
Requires [Claude Code CLI](https://claude.ai/download) installed and authenticated. Runs on [Bun](https://bun.sh) >= 1.0 or Node.js >= 22.
**Platform:** POSIX only (macOS, Linux, WSL). Native Windows isn't supported yet -- binary resolution relies on `which` and POSIX path conventions.
This SDK wraps Claude Code's `--output-format stream-json` protocol, which is not officially documented by Anthropic and may change between releases.
CLI
`claude-wire` ships a minimal CLI for shell-driven JSON extraction. Same e
Related Skills
Codex Headless
Programmatically drive the real OpenAI Codex CLI in a PTY — structured events, live rollout-stream token strea
Claude Code Headless
Programmatically drive the real Claude Code CLI in a PTY — structured semantic/screen/committed events, live t
Claudebot Claude Runner
Claude CLI 整合細節:spawn 參數、stream-json 解析、session 管理、prompt 建構。
Open Agent SDK TypeScript
Agent-SDK without CLI dependencies, as an alternative to claude-agent-sdk, completely open source
TS Anaf
TypeScript SDK, CLI, and MCP server for Romania's ANAF e-Factura system.
Agent Mux
unified TypeScript SDK and CLI (amux) for driving heterogeneous coding-agent harnesses — Claude Code, Codex, G
Related Agents
SDK Adapter Reviewer
Reviews SDK integration layer code - validates stream event conversion, hook handling, client lifecycle, and e
Vercel AI SDK Expert
Use for Vercel AI SDK v5 implementation work: chat interfaces, tool calling, streaming, agentic loop control,
Sf Lwc Engineer
Implements Lightning Web Components, Aura bundles, static resources, and their Jest specs. Use for wave-1 UI w