Terminate Command

  • POST
  • /workspaces
  • /:workspace
  • /sandboxes
  • /:sandbox_id
  • /commands
  • /:command_id
  • /terminate

Terminate a running command in a sandbox.

Request

REQUIRED SCOPES
SANDBOX_MANAGE
URL PARAMETERS
workspacerequiredstring
The workspace name.
sandbox_idrequiredstring
The ID of the sandbox.
command_idrequiredstring
The ID of the command.

Last modified on Jan 19, 2026

Request example

curl -X POST "https://api.buddy.works/workspaces/:workspace/sandboxes/:sandbox_id/commands/:command_id/terminate" \ -H "Authorization: Bearer <YOUR-TOKEN>" \ -H "Content-Type: application/json" \ -d '{}'

Response

EXAMPLE RESPONSE
{ "url": "https://api.buddy.works/workspaces/buddy/sandboxes/mydn9rjrqvq8d/command/68d4e0fffff30824fb1c54e9", "id": "68d4e0fffff30824fb1c54e9", "command": "npm run build", "runtime": "BASH", "status": "FAILED", "exit_code": 143 }
STATUS
200 OK