@zipbox/sdk weekly downloads statistics
By zipbox · npm · MCP servers
Drive Zipbox boxes from code: create, exec, files, PTY, previews.
@zipbox/sdk has 50,423 recorded weekly downloads on npm, an increase of 17227% over the past 30 days, ranking #781 of 3,247 tracked listings.
About @zipbox/sdk
@zipbox/sdk
TypeScript client for Zipbox: create a box, run commands, move files, open a terminal, publish a port. Nothing on a box stops on a clock.
npm install @zipbox/sdk
export ZIPBOX_API_KEY=zb_… # zipbox.ai → Settings → API keys
Quickstart
import { Zipbox } from '@zipbox/sdk'
const zb = new Zipbox()
const box = await zb.sandboxes.getOrCreate('demo', { tier: 's' })
const { stdout, exitCode } = await box.exec('uname -a && node --version')
console.log(exitCode, stdout)
Node 20+ (fetch, WebSocket on Node 22+; on Node 20 pass WebSocket from the ws
package for PTYs). API keys are for servers and CLIs: the control plane refuses a key
sent from a browser page.
Client
new Zipbox({
apiKey, // default: ZIPBOX_API_KEY
baseUrl, // default: ZIPBOX_API_URL, else https://api.tribes.xyz
maxRetries, // retries of one read or create (default 3); followed streams and PTYs never give up
retryBaseDelayMs, // first retry delay (default 500); doubles up to retryMaxDelayMs (30000)
pollIntervalMs, // first readiness check in create (default 1000); grows 1.25× per check to pollMaxIntervalMs (10000), with jitter
ptyBaseDelayMs, // first PTY reconnect delay (default 500); doubles up to ptyMaxDelayMs (30000)
fetch, // custom fetch
WebSocket // WebSocket constructor for PTYs
})
Every method takes an optional { signal } (AbortSignal). No method sets a deadline
of its own.
Boxes
const box = await zb.sandboxes.create({ name: 'ci-runner', tier: 's' }) // returns once ready
// the options apply only when the box is created; an existing box comes back as it is
const same = await zb.sandboxes.getOrCreate('ci-runner', { tier: 's' })
const ready = await zb.sandboxes.waitReady(id)
const rows = await zb.sandboxes.list()
const one = await zb.sandboxes.get(id)
const paused = await zb.sandboxes.pause(id) // returns the box paused; nothing billed while paused
const resumed = await zb.sandboxes.resume(id) // returns the box ready, files and software as they were
// stop(id) and start(id) are aliases of pause(id) and resume(id): the same request, the same result
await zb.sandboxes.restart(id) // files survive
await zb.sandboxes.cancelTransition(id) // 'cleared' | 'cancelling' | 'none'; conflict past the point of no return
await zb.sandboxes.setTier(id, 'm')
await zb.sandboxes.delete(id) // keeps a recoverable copy for 30 days by default
await zb.sandboxes.delete(id, { archive: false }) // no recoverable copy
const handle = zb.sandbox(id) // no network call
create, get, getOrCreate, waitReady, pause and resume return a Sandbox: the
row (box.info, box.status, box.name, box.baseUrl, …) plus everything below. On a
Sandbox, box.pause() and box.resume() (aliases box.stop(), box.start()) return
the updated row. A status is provisioning, running, stopping (a Pause landing),
paused, deleting or destroyed.
pause, resume and create return as soon as the server answers with the final state,
which it does when the host acts within its response budget (a warm create, a pause, a
resume of a box still on its host). Otherwise the call waits on GET /sandbox/:id/wait,
which the server answers when the box gets there, with no deadline of its own; an older
API without /wait is polled with backoff instead. A pause that is cancelled before it
lands raises conflict.
Fork a box
// a new box with the source's files, software and settings, its own name and identity
const child = await zb.sandboxes.fork(id, {
name: 'ci-runner-2',
sourcePolicy: 'pause_and_resume', // a running source pauses for the capture, then resumes
private: true, // optional: a fork starts public unless you ask for a private one
tailscaleAuthKey // optional: sealed here to the new box once it runs, never in the fork request
})
const accepted = await box.fork({
name: 'ci-runner-3',
sourcePolicy: 'require_paused',
wait: false
})
accepted.info?.fork // { operationId, phase: 'queued', … }: the new box is still provisioning
await zb.sandboxes.getFork(accepted.id) // or accepted.forkStatus(): phase, sourceRecovery, error
await zb.sandboxes.cancelTransition(accepted.id) // cancel the fork; the name stays yours
fork returns the new box's Sandbox once it is ready (wait: false: at once, still
provisioning). require_paused refuses a running source with pause_required. A
source holding machine-scoped keys raises requires_interactive for an API key: fork it
from the dashboard. The new box starts public, whatever the source's privacy, unless
private: true. A new box its fork removed (a cancel or a failure) raises its fork's
error code (copy_failed, start_failed, …), or conflict when the fork was cancelled. A signal
stops only the local wait; the fork keeps running. RAM and running processes are not
copied. See zipbox.ai/docs/fork.
An account holds 250 machine names, and a deleted box keeps its name: reuse a fixed pool of
names with getOrCreate instead of a fresh name per job. A new name past the limit raises
machine_limit_reached (zipbox.ai/docs/machine-limit).
Commands
const r = await box.exec('npm test', { cwd: 'app', env: { CI: '1' } })
r.exitCode // a non-zero exit is a result, never an exception
for await (const event of box.execStream(['make', 'build'])) {
if (event.type === 'stdout') process.stdout.write(event.data)
}
const server = await box.execBackground('npm run dev', { cwd: 'app' })
for await (const event of server.events()) {
/* follows output, resumes after a drop */
}
await server.signal('TERM')
await box.runCode('python', 'print(2 + 2)', { cwd: 'app' })
```…
Description from the npm listing.
- zipbox
- sandbox
- agents
- mcp
- exec
README badge
Show your rank in a README or on your website. The badge updates automatically.
Charts
Images: 30d · 1y · all time · 1600×900 dark
Adoption over time
7/30/90-day growth
Ranking history
Listing placement
Listing placement
Filled points are observed values; hollow points come from Internet Archive snapshots of the listing page. Dashed segments span periods with no observations — values between points are not interpolated.
Each band is one page of 20. Weekly downloads on a linear scale. Placement is projected from weekly downloads, so it can differ from the marketplace's own sort order. Hover a dot to see the listing.
Recent observations
Full history (121)Similar npm MCP servers plugins
All 20 @zipbox/sdk alternativesData source
Weekly downloads (trailing 7 complete days) come from the official npm downloads API. Downloads include CI and mirrors and are not equivalent to installs or users. npm publishes no ratings.
Listing: https://www.npmjs.com/package/@zipbox/sdk. First seen Dec 3, 2026; last successful collection Dec 6, 2026. See the methodology.