Skip to Content

Logs

The host's journal.

OperationKindHTTP
logs.readcallGET /v1/logs
logs.followstreamGET /v1/logs

logs.read

Journal entries.

Host level only. Through rookery serve it needs the role view.

Arguments

NameWhereRequiredDescription
unitquerynoOnly this unit.
sincequerynoA cursor from an earlier entry, or a time.
limitquerynoMost entries; default 100.

Result

LogEntry[]

Request
{
  "id": 1,
  "op": "logs.read",
  "args": {
    "since": "VALUE"
  }
}
Reply
{
  "id": 1,
  "result": [
    {
      "cursor": "s=4f2a…",
      "message": "text",
      "priority": 0,
      "time": "2026-11-12T09:30:00Z",
      "unit": "rookeryd.service"
    }
  ]
}

logs.follow

Journal entries, then what is logged.

Host level only. A stream, as a subscription on the portal or a WebSocket of its own. It resumes from since. Through rookery serve it needs the role view.

Arguments

NameWhereRequiredDescription
unitquerynoOnly this unit.
sincequerynoA cursor from an earlier entry, or a time journalctl understands.

Frames from the server

FrameKindDescription
entryJSONOne journal entry. Example: {"cursor":"s=…","message":"Server listening on 0.0.0.0 port 22.","priority":6,"time":"2026-11-12T10:00:00Z","unit":"ssh.service"}
Request
{
  "id": 1,
  "op": "logs.follow",
  "args": {
    "since": "VALUE"
  }
}
Reply
{
  "id": 1,
  "result": {
    "open": true
  }
}

{
  "sub": 1,
  "data": {
    "cursor": "s=…",
    "message": "Server listening on 0.0.0.0 port 22.",
    "priority": 6,
    "time": "2026-11-12T10:00:00Z",
    "unit": "ssh.service"
  }
}

End the subscription with {"sub": 1, "end": true}.

Types

The named types used on this page.

LogEntry

FieldTypeDescription
cursorstringGive it back as since to go on from here.
messagestring
priorityinteger
timestring
unitstring

On this page