SDK

Build with Computer Agents from JavaScript.

The JavaScript SDK is the main ACP product SDK for Node backends, platform integrations, internal tools, and agent-native products. It gives you both the high-level run() flow and first-class managers for the platform surfaces that teams actually operate.

Run agents

Start threads, stream work, resume sessions, approve permissions, and collect feedback from Node.js.

Ship resources

Deploy web apps, functions, databases, auth, runtimes, and secrets from the same client.

Use runtime helpers

Read bound secrets, write database records, and start agent runs inside deployed Node resources.

Build products

Embed Computer Agents inside your own app with typed managers for the full platform surface.

Install and initialize

The JavaScript SDK is designed to get you from API key to working ACP integration quickly. Start with one client instance and then decide whether you want the high-level run() path or the lower-level resource managers.

Install and initialize
InstallInstall the typed Node.js package with npm. Node.js 18 or newer is required.
AuthenticateCreate an API key in Computer Agents and pass it through COMPUTER_AGENTS_API_KEY or apiKey.
Start fastUse client.run() when your app only needs to hand a task to an agent and stream the result.
Go deeperUse the resource managers when you need exact lifecycle control over threads, computers, projects, and deployments.
Install the JavaScript SDK
Loading...
Initialize the client
Loading...

Core execution managers

The SDK exposes the operational ACP model directly. Threads run work, tasks organize planned execution, computers hold state, agents define reusable behavior, and files let you manage the workspace behind a run.

Core execution managers
ThreadsMulti-turn agent sessions with messages, logs, reasoning, diffs, permission requests, feedback, and resumable state.
ComputersPersistent cloud workspaces where agents browse, code, run CLIs, install packages, edit files, and keep state.
ProjectsShared workspaces for strategy, releases, tickets, comments, resources, review state, and task-linked threads.
AgentsReusable execution profiles with model, instructions, skills, reasoning effort, and analytics.
Files and GitManage workspace files, download folders, inspect git state, create commits, and automate repo-aware workflows.
Threads, computers, agents, and files
Loading...

Tasks, review feedback, and permission decisions

Project work now has a dedicated SDK surface. Tasks can start multiple linked threads, thread turns can collect thumbs up/down or issue reports, and paused runtime permission requests can be decided without leaving your app.

Tasks, review feedback, and permission decisions
Create tasksCreate planned work with project, release, priority, assignee, reviewer, comments, and status metadata.
Start task threadsUse startThread() for UI-controlled streaming or runThread() for backend jobs that execute immediately.
Capture feedbackUse setFeedback() and reportIssue() to collect structured quality signals on thread outputs.
Approve safelyList, approve, or deny runtime permission requests when an agent pauses before a sensitive action.
Run planned task work in JavaScript
Loading...

Product-shaped SDK managers

ACP now exposes first-class product managers on top of the generic resources layer. That means you can work with web apps, functions, auth, runtimes, secrets, databases, and notifications directly instead of always setting kind manually.

Product-shaped SDK managers
Web appsDeploy dashboards, internal tools, portals, prototypes, and AI apps from a source computer.
FunctionsDeploy APIs, webhooks, jobs, data transforms, and backend actions, then invoke them from the SDK.
DatabasesCreate structured app state with databases, collections, and JSON documents.
AuthCreate authentication modules for sign-up, sign-in, sessions, and user administration.
SecretsStore API keys, tokens, credentials, and private runtime configuration in vaults instead of source code.
ResourcesUse generic resource operations for cross-kind automation when one workflow handles multiple deployed surfaces.
Create resources through first-class managers
Loading...

Runtime helpers for deployed resources

Inside deployed Node Functions and server-rendered Web Apps, import native runtime helpers from the SDK. This is the supported replacement for local runtime shims and gives deployed code access to bound databases, secrets, auth modules, and agent runs.

Runtime helpers for deployed resources
Runtime metadatagetComputerAgentsRuntime(), getConnectedDatabase(), getConnectedAuth(), getConnectedAgentRuntime(), and getConnectedSecrets().
SecretslistSecrets(), getSecret(), and getSecretValue() for vault-backed runtime configuration.
DatabasesCreate collections, list documents, read documents, write documents, and delete records from bound databases.
AuthUse signUpWithAuthModule(), signInWithAuthModule(), and getAuthModuleUser() from deployed code.
Agent runsCreate, start, stream, wait for, inspect, and cancel agent runs from web apps and functions.
Use native runtime helpers
Loading...

Automation, scheduling, and orchestration

The SDK also covers ACP’s automation layer. You can create skills, schedules, triggers, and multi-agent orchestrations from the same client surface.

Automation, scheduling, and orchestration
SkillsPublish and update reusable capabilities agents can invoke during project work.
SchedulesRun recurring tasks such as daily research briefs, monitoring jobs, and periodic reports.
TriggersStart work from webhooks, GitHub, Slack, email, and other event sources.
OrchestrationsCoordinate multi-agent workflows around one objective, including research, build, review, and deployment phases.
Schedule and trigger work
Loading...

Models, budget, and SDK surface

Use the SDK to discover model availability, create reusable agents, check budget state, read usage, and choose the right manager for each ACP surface.

Models, budget, and SDK surface
ModelsCreate agents with Anthropic, OpenAI, Gemini, DeepSeek, Kimi, or connected external models available to the workspace.
BudgetCheck whether a task can execute before starting work and display account status inside your product.
BillingRead usage stats, transactions, checkout state, and plan information for account-aware applications.
NotificationsList in-app notifications and manage push tokens for product surfaces that embed Computer Agents.
ErrorsCatch ApiClientError to inspect status, code, and user-safe message when API calls fail.
Model discovery and budget checks
Loading...