fromName(
appName: string,
sandboxName: string,
options: Pick<ModalSandboxOptions, "auth">
): Promise| Name | Type | Description |
|---|---|---|
appName* | string | |
sandboxName* | string | |
options | Pick<ModalSandboxOptions, "auth"> |
Get a running sandbox by name from a deployed app.
The name of the Modal app
The name of the sandbox
Optional auth configuration
const sandbox = await ModalSandbox.fromName("my-app", "my-sandbox");
const result = await sandbox.execute("ls -la");