@cusedev/core
Version:
Core library for implementing computer usage capabilities for AI agents
41 lines • 1.53 kB
TypeScript
import { BashInterface, SystemConfig, ExecuteCommandParams, GetProcessOutputParams, TerminateProcessParams, ProcessInfo, CommandResponse } from './types';
/**
* Bash control implementation
* Provides functionality for executing shell commands and managing processes
*/
export declare class Bash implements BashInterface {
private config;
constructor(config: SystemConfig);
/**
* Execute a shell command
* @param params Command execution parameters
* @returns Promise with command execution response
* @throws Error if command execution fails
*/
execute({ command }: ExecuteCommandParams): Promise<CommandResponse>;
/**
* Get output from a background process
* @param params Process output parameters
* @returns Promise with process output response
* @throws Error if getting process output fails
*/
getProcessOutput({ pid, }: GetProcessOutputParams): Promise<CommandResponse>;
/**
* Terminate a background process
* @param params Process termination parameters
* @throws Error if process termination fails
*/
terminateProcess({ pid }: TerminateProcessParams): Promise<void>;
/**
* List all processes managed by the API
* @returns Promise with list of managed processes
* @throws Error if listing fails
*/
listManagedProcesses(): Promise<ProcessInfo[]>;
/**
* Restart the system
* @throws Error if restart fails
*/
restart(): Promise<void>;
}
//# sourceMappingURL=bash.d.ts.map