Skip to content

Guest runtime log tail, optionally filtered to one realm

GET
/api/v1/admin/realms/observability/logs
curl --request GET \
--url 'http://localhost:11044/api/v1/admin/realms/observability/logs?limit=200' \
--header 'X-Embabel-Api-Key: <X-Embabel-Api-Key>'

Guest log lines from the same 200-event ring buffer [LogController] serves. That buffer is shared across this whole process. A realm that last logged more than 200 events ago has aged out of it entirely. Attribution is best-effort: a line from a code path that never set the realm on the MDC comes back with realm null rather than a guess. Capture itself depends on assistant.infrastructure.features.diagnostics. When that is off nothing is recorded at all, and captureEnabled says so rather than leaving an empty list to be misread as a quiet realm.

realm
string

Restrict to one realm’s entries. Omit for every realm.

limit
integer format: int32
default: 200

How many lines, newest last. Clamped to the buffer’s own size.

The current guest log tail

Media typeapplication/json

The newest guest log lines from the process-wide log ring buffer, answered by GET /admin/realms/observability/logs

object
bufferSize
required

How many events the ring buffer holds across the whole process, so no request can return more than this

integer format: int32
captureEnabled
required

False when this deployment captures no log lines at all, because diagnostics are off; entries is then empty whatever the realms did

boolean
entries
required

The matching lines, oldest first and newest last, at most the requested limit

Array<object>

One log line a realm’s guest code wrote during a dispatch

object
dispatchId

Id of the dispatch the line was logged in, which groups the lines of one handler run. Null when not recorded

string
level
required

The log level: TRACE, DEBUG, INFO, WARN or ERROR

string
message
required

The log message as written, except that a first-run setup token in it is redacted

string
realm

The realm that logged it. Null when the code path never recorded which realm it was running for

string
timestamp
required

When the line was logged, in epoch milliseconds

integer format: int64
filteredOut
required

True when a realm was named, nothing matched it, and the buffer did hold other guest lines

boolean

Example generated

{
"bufferSize": 1,
"captureEnabled": true,
"entries": [
{
"dispatchId": "example",
"level": "example",
"message": "example",
"realm": "example",
"timestamp": 1
}
],
"filteredOut": true
}