Create Session
Create a sandbox session and return its public session metadata, session token, and provider. Set session_kind to browser to start a browser-backed session instead of a standard command/code sandbox. Set queue_if_full to true to queue the request instead of failing when runner capacity is temporarily unavailable. It does not queue requests for session kinds the deployment does not support. Browser sessions require a Firecracker-backed deployment; standard-only deployments reject them immediately with browser_sessions_not_enabled. An optional caller network_policy restricts outbound hostnames and is intersected with the organization, team and operator policies. An empty allowlist denies outbound access.
Authorizations
Gateway auth: send Authorization: Bearer <mka1-api-key>. For multi-user server-side integrations, you can also send X-On-Behalf-Of: <external-user-id>.
Headers
Optional external end-user identifier forwarded by the API gateway.
Body
1 - 255Hard guest memory cap: 512, 1024, or 2048 MiB for standard sessions. Disables automatic memory growth and OOM retries.
512, 1024, 2048 Additional outbound hostname allowlist. Intersects tenant and operator restrictions; an empty list denies outbound hosts.
standard, browser, coding_harness Server-owned workload sizing classes.
Resource classes are deliberately independent of the language/runtime
profile. In particular, Coding Harness always uses the Medium class even when a
caller sends a smaller or absent legacy memory_mib value.
medium x >= 1python, git, claude-code standard, eval-python x >= 1