Skip to navigation

Read sandbox logs and metrics

View as Markdown

Returns container logs and/or CPU and memory samples for one sandbox.

Defaults to the last hour. Narrow the window with since/until (ISO-8601 timestamps) and cap the volume with limit, which applies to logs and metrics independently.

cpu_usage is a cumulative counter in seconds — compute a rate by differencing consecutive samples.

Authentication

AuthorizationBearer

Bearer authentication of the form Bearer <token>, where token is your auth token.

Path parameters

sandbox_idstringRequiredformat: "uuid"

Headers

x-workspace-idstring or nullOptional

UUID of the workspace that scopes this request. List the workspaces you belong to with GET /workspaces.

Query parameters

sincedatetime or nullOptional

Start of the window (ISO-8601). Defaults to one hour ago.

untildatetime or nullOptional

End of the window (ISO-8601). Defaults to now.

limitintegerOptional1-5000Defaults to 500

Maximum rows returned per stream (logs and metrics each).

streamstring or nullOptional
Filter log lines by stream.
includestringOptionalDefaults to logs,metrics

Comma-separated subset of logs and metrics.

Response

Successful Response
sandbox_idstringformat: "uuid"
sandbox_namestring
logslist of objects
metricslist of objects

Errors

400
Bad Request Error
401
Unauthorized Error
403
Forbidden Error
404
Not Found Error
422
Unprocessable Entity Error