CPU Sandbox gives an AI agent an isolated, programmable computer for running code, installing tools and carrying out multi-step work, without running that code directly in your application environment. It is part of the Telnyx Agent Platform and is in beta.
Models can generate code. Running it is the risky part. Your agent lives on Telnyx Edge Compute, always on and holding its memory and credentials. A Sandbox is a separate computer the agent creates on demand: install a library, open a file it did not write, run the script, return the result. Keep it available across tasks, and terminate it when it is no longer needed. If the code fails, it does so in an environment isolated from your agent's runtime.
telnyx-edge sandbox-cpu create --image docker.io/library/python:3.12-slim --name doc-quick-start --timeout 1800telnyx-edge sandbox-cpu exec doc-quick-start -- python3 /workspace/primes.pytelnyx-edge sandbox-cpu pause doc-quick-start, telnyx-edge sandbox-cpu resume doc-quick-start, telnyx-edge sandbox-cpu terminate doc-quick-startYou need a Sandbox-enabled account and the telnyx-edge CLI. Every step also has an API call in the quick start.
Read the CPU Sandbox docs.