ibk_..., from
the dashboard’s API keys page or instabox keys create), sent as
Authorization: Bearer. Its scopes decide which operations work. A key
belongs to one workspace and sees only that workspace’s machines and
snapshots. Member, invite and workspace-secret changes need a workspace
key with workspace:admin; a personal org’s key gets 403 missing_scope
there.
- Lifecycle calls (create, start, stop, suspend, resume, fork,
snapshot, delete) take an
Idempotency-Key; the plugin sends a fresh one unless you passidempotency_key. They answer with an operation; read its progress withoperations.get. - Deletes of a machine or snapshot need
X-Confirm-Deletewith its ID or exact name. The plugin sends the id from the call unless you passconfirm_delete. - Exec (
machines.exec) runscmdthroughbash -lc, orargvwith no shell, and waits for the exit (default 60 s, at most 600). Output is cut at 1 MiB per stream; download files withmachines.files.downloadrather thancat. - Money. Machines are billed per second while they run (vCPU, memory,
storage, egress, GPUs). Creating, starting, resuming, waking, forking or
restoring one, running a command in it, invites, SSH certificate and
token issuing and every delete are
destructive. - Webhooks. Register an endpoint with
orgs.webhooks.createand store thewhsec_secret it returns as the webhook secret. Deliveries follow Standard Webhooks (webhook-id,webhook-timestamp,webhook-signature), and the plugin checks each one. - Rate limits. A 429
rate_limitedcarriesRetry-Afterand core retries it; a 429quota_exceededis a plan limit and is not retried. - Not wrapped: routes that answer
403 permission_deniedto every API key and take only a dashboard or CLI sign-in (billing, API key management, Vault, sessions, support tickets, Discord, creating, deleting and moving workspaces, GitHub App installations), sign-in and OAuth flows, the WebSocket terminal, VNC and Orca tunnels, the desktop watch stream, the GitHub and Stripe webhook receivers, and deprecated/v1/imagesroutes (usesnapshots.*).
- 93 typed API operations
- 12 incoming webhook event types
Setup
1
Install
2
Add the plugin
corsair.ts
multiTenancy: true, scope calls with corsair.withTenant(id). See Quick start for KEK + Hub keys, and Multi-tenancy for account isolation.3
Choose authentication
- API Key (Recommended)
Store the InstaBox API key before the first call: More: API Key
pnpm corsair setup --plugin=instabox --tenant=acme api_key=<your-key> (leave out --tenant without multiTenancy), or pass it as key in the plugin options. With Hub, each tenant enters their own key on the connect page. See API key auth.4
Connect a tenant
Mint a connect link and send the tenant to it. Hub hosts the page and delivers the result to your app — see Connect / OAuth.
Example API calls
List machinesWebhooks
This plugin registers 12 webhook event types. Configure the provider to POST to your Corsair HTTP handler, then usewebhookHooks on the plugin factory.
See Webhooks for every event path and payload shape, and Webhooks concept for routing.
What’s next
API reference
Every
instabox.api.* operation with input and output types.Webhooks
Event paths, payloads, and
webhookHooks examples.Connect / OAuth
createLink, Hub delivery, and tenant connect flows.
Use with agents
Expose this plugin’s operations as MCP tools.