Skip to main content
POST
Execute a process and stream its stdout and stderr.

Authorizations

Authorization
string
header
required

Vers API key (VERS_API_KEY) sent as Authorization: Bearer <key>.

Path Parameters

computer_id
string<uuid>
required

Computer identity

Body

application/json

Request body for POST /api/v2/computers/{computer_id}/exec and its streaming variant.

command
string[]
required

Command and arguments to execute.

env
object | null

Optional environment variables to set for the process.

exec_id
string<uuid> | null

Optional exec identifier for tracking.

keep_background
boolean

Keep processes the command leaves running (for example server &) after it exits, as docker exec does. By default they are killed when the command exits. The reply arrives once the command exits; output the kept processes write afterwards is retained in the exec logs.

stdin
string | null

Optional stdin payload passed to the command.

timeout_secs
integer<int64> | null

Timeout in seconds. Omitted or zero uses 300 seconds; larger values are capped at 3600 seconds.

Required range: x >= 0
working_dir
string | null

Optional working directory for the command.

Response

NDJSON stdout/stderr chunks followed by a terminal exit event

Streaming exec events emitted over the exec stream endpoint (NDJSON lines).

cursor
integer<int64>
required
Required range: x >= 0
data_b64
string
required
stream
enum<string>
required

Streams available for exec logging.

Available options:
stdout,
stderr
type
enum<string>
required
Available options:
chunk
exec_id
string<uuid> | null