Skip to content

Variable: addSshProjectOperationSchema

const addSshProjectOperationSchema: ZodObject<{ config: ZodOptional<ZodRecord<ZodString, ZodJSONSchema>>; machineId: ZodString; name: ZodOptional<ZodString>; openPath: ZodOptional<ZodString>; path: ZodOptional<ZodString>; port: ZodOptional<ZodNumber>; projectId: ZodOptional<ZodString>; route: ZodOptional<ZodBoolean>; serviceDependencies: ZodOptional<ZodArray<ZodEnum<{ desktop: "desktop"; stats: "stats"; terminal: "terminal"; }>>>; stripPrefix: ZodOptional<ZodBoolean>; }, $strict>

Create or update a persisted Sandbox project, its isolated directory, mise configuration, reserved loopback port, and authenticated AppKit route. Every call runs mise install and its installation-only hooks.postinstall. Runtime lifecycle belongs in documented start and stop tasks.

  • machineId: Assigned Sandbox id from list_ssh_machines. Do not invent an id or pick an unlisted sandbox.
  • projectId (optional): Stable project identifier to update. Omit when creating a project.
  • name (optional): Lowercase project name. A unique name is generated when omitted.
  • port (optional): Loopback HTTP port. An unused machine-local port is generated when omitted.
  • path (optional): Project path suffix beneath the user’s prefix. Defaults to the project name and must be unique on the Sandbox.
  • openPath (optional): Optional project-relative entry URL, such as open.html or vnc.html?autoconnect=1. An empty string or slash opens the route root. External URLs and parent-directory traversal are rejected.
  • config (optional): Mise configuration represented as JSON. The server serializes it to mise.toml and injects reserved PROJECT_NAME, PROJECT_PATH, and PROJECT_PORT environment values.
  • route (optional): Whether AppKit exposes the project server through an authenticated route. Defaults true when creating and retains the stored value when updating.
  • serviceDependencies (optional): Built-in machine services that must be available before the project starts. Defaults empty when creating and retains the stored value when updating.
  • stripPrefix (optional): Remove the registered HTTP and WebSocket path before forwarding; defaults true off root. Set false only when the service is configured for the full public base path.