mk_..., from maritime keys create or the dashboard’s Settings → API keys), sent as
Authorization: Bearer. The key’s scopes (provision, deploy, secrets,
manage, sandboxes) decide which operations work.
- Two kinds of machine. Agent boxes (
agents.*) keep their disk, sleep when idle and wake on a chat message, webhook, trigger or exec. Virtual machines (sandboxes.*, idssbx-...) run one task and end with their disk;sandboxes.ephemeral.createmakes one that ends after a few idle minutes. Computers (computers.*) are desktops and phones your agent sees and clicks. - Commands and files in a virtual machine (
sandboxes.commands.*,sandboxes.files.*,sandboxes.code.run) go to the machine’s own data plane. The plugin reads the machine’sdataPlaneUrlandsecretfirst and sends the secret inX-Maritime-Token; the account key never goes there. - Money. Every machine is billed per second while awake (an agent box
per GB of memory per month). Creating, waking or resizing one, running
commands in it, starting a swarm or renting a swarm server ($1 a minute),
and plan, trial, top-up and credit purchases are
destructive, as are sends (chat, invoke, project messages, invites), key and secret changes, and every delete. - Lists page with
limitandcursor(pass the previous page’snextCursor). - Webhooks. Subscribe with
webhooks.create(agent, message, exec and end-user events, signedX-Maritime-Signature: sha256=<hex>) orsandboxWebhooks.create(virtual machine events, signedMaritime-Signature: t=...,v1=...). Store the secret returned at create time as the webhook secret: the plugin checks every delivery with it. - Rate limits. A 429 carries
Retry-After; core retries it three times, and a 5xx is retried for reads only. - Not wrapped: sign-in and OAuth flows the CLI and dashboard run, the
dashboard’s own proxies and share pages, Maritime’s internal routes, the
E2B-compatible
/e2bcopy of the sandbox API (the e2b plugin reaches it withE2B_DOMAIN=sb.mtm.sh), and the/v1/fleetspartner API, which takes a platform credential rather than anmk_key. The data plane’s terminal (WebSocket) and file watch (event stream) are left out too.
- 331 typed API operations
- 21 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 Maritime API key before the first call: More: API Key
pnpm corsair setup --plugin=maritime --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 virtual machinesWebhooks
This plugin registers 21 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
maritime.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.