Skip to main content

StateSet Sandbox Quickstart

This quickstart shows the minimal flow to create a sandbox and execute a command.

1) Register and get an API key

curl -X POST https://api.sandbox.stateset.app/api/v1/register \
  -H "Content-Type: application/json" \
  -d '{"first_name": "Your", "last_name": "Name", "organization_name": "Company", "email": "[email protected]"}'

2) Create a sandbox

curl -X POST https://api.sandbox.stateset.app/api/v1/sandbox/create \
  -H "Authorization: ApiKey YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"timeout_seconds": 300}'

3) Execute a command

curl -X POST https://api.sandbox.stateset.app/api/v1/sandbox/SANDBOX_ID/execute \
  -H "Authorization: ApiKey YOUR_API_KEY" \
  -H "Content-Type: application/json" \
  -d '{"command": "python3 -c \"print(Hello World!)\""}'

Next Steps