Get device logs
const url = 'http://localhost:3000/api/v1/devices/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/logs?severity=DEBUG&limit=100&before=2026-03-17T12%3A00%3A00Z&source=my-container&q=connection%20refused';const options = {method: 'GET', headers: {'X-API-Key': '<X-API-Key>'}};
try { const response = await fetch(url, options); const data = await response.json(); console.log(data);} catch (error) { console.error(error);}curl --request GET \ --url 'http://localhost:3000/api/v1/devices/2489E9AD-2EE2-8E00-8EC9-32D5F69181C0/logs?severity=DEBUG&limit=100&before=2026-03-17T12%3A00%3A00Z&source=my-container&q=connection%20refused' \ --header 'X-API-Key: <X-API-Key>'Retrieves log entries for a device with cursor-based pagination, newest first.
Authorizations
Section titled “Authorizations”Parameters
Section titled “Parameters”Path Parameters
Section titled “Path Parameters”Device UUID
Query Parameters
Section titled “Query Parameters”Filter by severity level
Maximum number of log entries to return. Raised to 1000 (FM-772) to guarantee at least the last 1000 lines are retrievable for an active device.
Example
2026-03-17T12:00:00ZCursor for pagination (timestamp of last entry)
Example
my-containerFilter by log source (container name, service, or “system”)
Example
connection refusedFull-text search against the log message body. Matched case-insensitively as a substring, server-side, against Loki (index-backed by the label selector; the search itself is a line filter evaluated before JSON parsing). Composes with severity and source.
Responses
Section titled “Responses”Log entries retrieved successfully
object
object
Log entry ID
Device ID
Timestamp
Severity level
Log message body
Log source (container name, service, or system)
object
Structured attributes
object
Whether there are more entries before the cursor
Example
{ "data": [ { "severity": "DEBUG" } ]}Forbidden — caller lacks required permission
Device not found