Cereal docs
TypeScript SDKTypeScript signatures

SandboxHandle

Public TypeScript declaration from @trycereal/sdk.

Import from @trycereal/sdk. Generated from the repository SDK declarations (package version 0.0.0); not from HTTP request schemas.

export interface SandboxHandle {
    readonly id: string;
    readonly state: string;
    readonly exec: (command: string, options?: {
        readonly stdin?: string;
        readonly encoding?: "utf8" | "base64";
        readonly cwd?: string;
        readonly env?: Readonly<Record<string, string>>;
        readonly timeoutSeconds?: number;
        readonly background?: boolean;
        readonly name?: string;
    }) => Promise<SandboxCallResult>;
    readonly env: (patch: {
        readonly set?: Readonly<Record<string, string>>;
        readonly unset?: ReadonlyArray<string>;
        readonly replace?: boolean;
    }) => Promise<SandboxEnvNames>;
    readonly client: () => CerealClient;
}

See SDK setup, authoring, client behavior, and the API/SDK map for usage. Domain types are described in schema reference.