Read durable sandbox logs
GET/sandboxes/{id}/logs
Durable per-sandbox logs (service output + exec activity) that survive the sandbox. Returns 501 when the daemon has no log store configured.
path parameters
object
idstringrequiredSandbox ID, e.g. sbx_ab12cd34.
query parameters
object
sinceintegerint64Byte offset to read from; -1 (default) tails the recent log.
sourcestringFilter by source: service | exec | all (default all).
Responses
200 OKOK
LogsResponse
next_offsetintegerint64recordsarray | null
items
LogRecord
sourcestringstreamstringtextstringtime_msintegerint64400 Bad requestBad Request
ErrorResponse
errorstring404 Not foundNot Found
ErrorResponse
errorstring501 Not Implemented
ErrorResponse
errorstringAuthentication
bearerAuthHTTP bearer. Daemon API key. Omit on a keyless loopback daemon.Request
▍GET/sandboxes/{id}/logs
curl '/sandboxes/{id}/logs?since=&source='const response = await fetch("/sandboxes/{id}/logs?since=&source=", {
method: "GET",
});
const data = await response.json();import requests
response = requests.get(
"/sandboxes/{id}/logs?since=&source=",
)
data = response.json()Response
200 OK
{
"next_offset": 0,
"records": [
{
"source": "string",
"stream": "string",
"text": "string",
"time_ms": 0
}
]
}