Run Command • AI Agent SDK
run_command: Run a shell command in the sandbox.
run_command
Async
Method
</div>
This is a method of the SandboxProtocol class in the protocols module.
Run a shell command in the sandbox.
Signature
async def run_command(command: Union[str, List[str]], limits: Optional[ResourceLimits], env: Optional[Dict[str, str]], working_dir: Optional[str]) -> SandboxResultParameters
ParamField
UnionCommand to run (string or list of args)
ParamField
Optional[ResourceLimits]Resource limits for execution
ParamField
OptionalEnvironment variables
ParamField
Optional[str]Working directory
Returns
ResponseField
SandboxResultExecution result
Source
View on GitHubpraisonaiagents/sandbox/protocols.py at line 276