Compute
Isolated code-execution sandboxes for AI agents — run untrusted code safely in containers, with GPU compute available. Pay per call in USDC via x402.
Isolated code-execution sandboxes for AI agents — run untrusted code safely in containers, with GPU compute available. Pay per call in USDC via x402.
Every endpoint below is callable with one API key or paid per call in USDC over x402. There is no subscription and no minimum spend; you pay for the calls you make.
Modal Sandbox
Isolated code execution in secure containers
Secure Python 3.11 runtime for AI agents. Create isolated environments (1 vCPU, 1 GiB RAM, up to 5-min burst or 24-hour sessions). Execute commands, capture stdout/stderr/exit codes, persist state between calls for multi-step workflows. Use cases: code interpretation, package verification, data processing, automation scripts. Works with Chat Completions (function calling) to let AI models run code safely. No account needed — pay per call via x402.
Pricing: From $0.0011/call
| Method | Endpoint | Price | Description |
|---|---|---|---|
POST | /sandbox/create | $0.0121 | Create isolated sandbox |
POST | /sandbox/exec | $0.0011 | Execute command in sandbox |
POST | /sandbox/status | $0.0011 | Check sandbox state |
POST | /sandbox/terminate | $0.0011 | Destroy sandbox |
How to pay
Call any endpoint. Without a key you get HTTP 402 with the exact price in USDC; sign that quote with a Base or Solana wallet and repeat the request. With an account API key the same call is billed to your balance instead.
curl -i https://api.jarvisclaw.ai/v1/chat/completions \
-H "Content-Type: application/json" \
-d '{"model":"auto/free","messages":[{"role":"user","content":"Hello"}]}'