Declaw icon

Declaw

Run code securely in Firecracker microVM sandboxes — create sandboxes, execute commands, manage files

Command → Kill Process

AI-generated

Summary

Kills a background process inside a Declaw sandbox by PID. Sends a DELETE request to the sandbox's commands endpoint for that process.

Inputs

  • Sandbox ID (required) — ID of the sandbox containing the process (e.g. sbx-a1b2c3d4). It is inserted into the request path as-is.
  • PID (required) — Numeric process ID to kill. Typically taken from the output of Run Background or List Processes.

Output shape

One output item per input item, containing the JSON response returned by the Declaw API for the DELETE /sandboxes/{sandboxId}/commands/{pid} call.

The source doesn't define the response fields, so they depend on the API. If the request fails (e.g. unknown sandbox or PID), the node throws an API error. With Continue On Fail enabled, it outputs an item with an error message instead.

Examples

Example 1: Stop a long-running server started earlier in the workflow.

Sandbox ID = {{$json.sandbox_id}}, PID = {{$json.pid}} taken from a preceding Run Background step.

Example 2: Clean up a runaway process found via List Processes.

Sandbox ID = sbx-a1b2c3d4, PID = 1234 (from the List Processes output).

Links

Discussion