v1

latestSwagger 2.02026-07-17107130444.8 KB
Task

Get task logs

Get stdout and stderr logs from a task. See also /containers/{id}/logs.

Note: This endpoint works only for services with the local, json-file or journald logging drivers.

get/tasks/{id}/logs

Path parameters

idstring required

ID of the task

Query parameters

detailsboolean

Show task context and extra details provided to logs.

followboolean

Keep connection after returning logs.

stdoutboolean

Return logs from stdout

stderrboolean

Return logs from stderr

sinceinteger

Only return logs since this time, as a UNIX timestamp

timestampsboolean

Add timestamps to every log line

tailstring

Only return this number of log lines from the end of the logs. Specify as an integer or all to output all log lines.

Response

logs returned as a stream in response body