Skip to main content
CodeSandbox SDK (now part of Together AI) programmatically creates and runs Firecracker-based VM sandboxes billed to a CodeSandbox workspace. The following table shows what CostGraph runs on this provider.

Connect

Run the dispatcher with provider set to codesandbox and these variables:
  • CSB_API_KEY
For CI runners, CostGraph picks the smallest VM tier that fits the job.

Key and permissions

CSB_API_KEY is a CodeSandbox workspace API token, created at https://codesandbox.io/t/api with ‘Create API Token’; it is revoked from the Permissions tab of Workspace Settings. Sandboxes are created and billed in the token’s workspace. Tokens are scoped (scopes in the vendor API: sandbox_create, sandbox_read, sandbox_edit_code, vm_manage), but CodeSandbox does not document a per-operation minimum; its SDK quickstart says to “enable all scopes”. Sources: codesandbox.io: sdk, codesandbox.io: api, codesandbox.io: sandboxes, codesandbox.io: key terms, codesandbox.io: faq.

Limits

  • Hibernation timeout configurable from 1 minute to 24 hours; default 5 minutes on free and 30 minutes on paid workspaces (from the vendor sandboxes page; the page blocks automated fetching, read via search-index excerpt). (source)
  • VM tiers from Micro up to Small (8 cores / 16 GB) by default, higher tiers only via custom templates; available tiers depend on the workspace subscription (same caveat as above). (source)