Skip to main content

TerminalProcesses API

Terminal Processes API

import { CodeBoltClient } from '@codebolt/clientsdk';

const client = new CodeBoltClient();

Quick Reference

MethodDescription
getActiveProcessesRetrieves all currently active terminal processes.
stopAllProcessesStops all running terminal processes.
stopProcessStops a specific terminal process by its ID.

Methods


getActiveProcesses

client.terminalProcesses.getActiveProcesses(): Promise<TerminalProcess[]>

Retrieves all currently active terminal processes.

Returns terminal processes that are currently running, including their process IDs, commands, and status information. Use this to monitor what shell operations are in progress.

No parameters.

Returns: Promise<TerminalProcess[]> — A promise that resolves to an array of active TerminalProcess objects

Full reference →


stopAllProcesses

client.terminalProcesses.stopAllProcesses(): Promise<unknown>

Stops all running terminal processes.

Terminates every currently active terminal process in the system. Use this for cleanup operations or when shutting down the platform to ensure no orphaned processes remain.

No parameters.

Returns: Promise<unknown> — A promise that resolves when all processes have been stopped

Full reference →


stopProcess

client.terminalProcesses.stopProcess(processId: string): Promise<unknown>

Stops a specific terminal process by its ID.

Sends a termination signal to the specified terminal process, ending its execution gracefully if possible. The process will be removed from the active process list.

ParameterTypeRequiredDescription
processIdstringYesThe unique identifier of the terminal process to stop

Returns: Promise<unknown> — A promise that resolves when the process has been stopped

Full reference →