Create Claude-Code Sandbox
Run in Apifox
Preinstalled Environment# The sandbox has pre-installed the following commonly used development and compilation environments: Node.js - JavaScript runtime
Python - Python Interpreter
Git - Version Control Tool
build-essential - C/C++ Compile Toolchain
CMake - Cross-platform Build Tool
Extended Environment# If you need to install other Development Environments or tools, you can call the commands interface to manually install them. Data Persistence# Sandbox data remains persistent under the following conditions: ✅ The sandbox has not been actively deleted
✅ The sandbox is in an active or idle state
Billing Instructions# Creation Fee : Actual time spent using the sandbox in seconds * 0.0005 PTC (Creating a sandbox, setting global system prompts, and setting MCP all incur a small amount of time overhead) Usage fee: 0.0005PTC + LLM model token fee based on the actual number of seconds spent using sandboxRequest Body Params application/json Required
{
"llm_model" : "claude-sonnet-4-5-20250929"
} Request Code Samples
curl --location --request POST 'https://api.302.ai/v1/302/claude-code/sandbox/create' \
--header 'Authorization: Bearer ' \
--header 'Content-Type: application/json' \
--data-raw '{
"llm_model": "claude-sonnet-4-5-20250929"
}' Responses application/json Generate Code
{
"success" : true ,
"data" : {
"sandbox_id" : "302-sandbox-xxxxxxx" ,
"sandbox_name" : "xxxxxxxxxxx"
}
} Modified at 2025-12-19 11:23:50