Skip to main content
POST
Execute a command in a Box

Authorizations

Authorization
string
header
required

Box bearer token in the form box_.... Service API keys authenticate Box operations.

Path Parameters

boxId
string
required

Public Box id returned by create/list/get box calls.

Pattern: ^bx_[23456789abcdefghjkmnpqrstuvwxyz]{8}$

Body

application/json
command
string
required
cwd
string

Relative working directory inside the Box work directory.

timeoutSeconds
integer
default:30
Required range: 1 <= x <= 60

Response

200 - application/json

Command result.

ok
boolean
required
Example:

true

type
string
required

Stable success envelope discriminator added by v1.

Allowed value: "command.finished"
success
boolean
required
exitCode
integer | null
required
stdout
string
required
stderr
string
required
timedOut
boolean
required
signal
string | null
stdoutTruncated
boolean
stderrTruncated
boolean
cwd
string
startedAt
string<date-time>
finishedAt
string<date-time>