Table of Contents

Method ExecuteAsync

Namespace
Oscova.Agents.Toolsets
Assembly
Oscova.Agents.dll

ExecuteAsync(string, string?, int, CancellationToken)

Executes a shell command using the runtime selected by the host application.

Task<CommandResult> ExecuteAsync(string command, string? workingDirectory, int timeoutSeconds, CancellationToken cancellationToken = default)

Parameters

command string

The shell command text to execute.

workingDirectory string?

The working directory supplied by the tool call, if any.

timeoutSeconds int

The command timeout in seconds.

cancellationToken CancellationToken

A token that can cancel command execution.

Returns

Task<CommandResult>

The command exit code, output streams, and timeout flag.