Skip to content
masterclass Buddy

Deep Agents · Class

DockerSandbox

SandboxClient runs commands in isolated environments through the LangSmith Sandbox API. Create a snapshot from a Docker image, open a sandbox, and execute a command.

Last updated

Since
v0.6

Syntax

client = SandboxClient()
snapshot = client.create_snapshot(docker_image="...", name="...")
with client.sandbox(snapshot_id=snapshot.id) as sb:
    result = sb.run("...")

In-depth API docs are only for subscribers: parameters, examples, common mistakes and interview practice.

Subscribe
  • SandboxClient
  • create_snapshot
  • sandbox
  • run
  • snapshot.id
  • stdout

Source: sandbox | langsmith | LangChain Reference. Checked 2026-11-03.