Skip to content

Documentation / @agentick/sandbox / SandboxProps

Interface: SandboxProps

Defined in: component.tsx:20

Properties

allow?

optional allow: Permissions

Defined in: component.tsx:31

Advisory permissions.


children

children: ReactNode

Defined in: component.tsx:48


env?

optional env: Record<string, string | () => string>

Defined in: component.tsx:34

Environment variables. Functions are resolved at creation time.


limits?

optional limits: ResourceLimits

Defined in: component.tsx:43

Resource constraints.


mounts?

optional mounts: Mount[]

Defined in: component.tsx:28

Host↔sandbox path mappings.


persist?

optional persist: boolean

Defined in: component.tsx:46

Whether to persist sandbox state in snapshots. Default: false.


provider

provider: SandboxProvider

Defined in: component.tsx:22

The sandbox provider to use (e.g. localProvider()).


setup()?

optional setup: (sandbox) => Promise<void>

Defined in: component.tsx:37

Post-creation setup callback. Runs after sandbox creation, before tools are available.

Parameters

sandbox

SandboxHandle

Returns

Promise<void>


teardown()?

optional teardown: (sandbox) => Promise<void>

Defined in: component.tsx:40

Pre-destroy teardown callback. Runs while sandbox is still alive — readFile, readDir, exec all work.

Parameters

sandbox

SandboxHandle

Returns

Promise<void>


workspace?

optional workspace: string | true

Defined in: component.tsx:25

Workspace path, or true for auto temp directory. Default: true.

Released under the ISC License.