Provides access to various logs. Since logs may contain sensitive
information, this service is available only to users with the
save
privilege (see
/auth/rights).
Get the alert log. It has a fixed maximum length and consists of a sequence of prioritized and time-stamped entries. When the log fills up, older entries are replaced. Currently up to 50 alert log entries are supported.
Alert log response.
Unauthorized response.
{- "drops": 0,
- "log": [
- {
- "id": 1804289524,
- "acked": false,
- "prio": 6,
- "count": 1,
- "first": "1684952450.123",
- "last": "1684952450.123",
- "name": "Device up and running",
- "detail": "software reset"
}, - {
- "id": 1804289527,
- "acked": true,
- "prio": 3,
- "count": 15,
- "first": "1684952489.205",
- "last": "1685739471.800",
- "name": "Proxy-connection established",
- "detail": "",
- "reported": "1685739472.250"
}
], - "error": "Error message (present if an error occurred)."
}
Acknowledge all or some alerts.
Status response.
Unauthorized response.
"ack"
{- "status": "OK",
- "error": "Error message (present if an error occurred)."
}
Delete all or some alerts.
Status response.
Unauthorized response.
{- "status": "OK",
- "error": "Error message (present if an error occurred)."
}
Get the kernel log. It has a fixed size and consists of a sequence of prioritized and time-stamped entries. When the log fills up, older entries are replaced.
after | number Limits the output to messages with a timestamp that is newer than the value specified by this parameter. The value must be a decimal number and may include a fractional part. The number is interpreted as seconds since the epoch. For most logs, the epoch is the Unix epoch (i.e., seconds since the start of Jan 1, 1970 UTC). However, for the kernel log, the epoch is the time the meter was powered up (booted). Example: after=6.9801816 |
Kernel log response.
Unauthorized response.
{- "log": [
- {
- "prio": 6,
- "ts": "6.9801816",
- "msg": " 6.980181] ehci-atmel: EHCI Atmel driver"
}, - {
- "prio": 3,
- "ts": "6.9886136",
- "msg": " 6.988613] atmel-ehci 500000.ehci: EHCI Host Controller"
}
], - "error": "Error message (present if an error occurred)."
}
Get a Lua log. Each log has a fixed size and consists of a sequence of time-stamped entries. When the log fills up, older entries are replaced.
after | number Limits the output to messages with a timestamp that is newer than the value specified by this parameter. The value must be a decimal number and may include a fractional part. The number is interpreted as seconds since the epoch. For most logs, the epoch is the Unix epoch (i.e., seconds since the start of Jan 1, 1970 UTC). However, for the kernel log, the epoch is the time the meter was powered up (booted). Example: after=6.9801816 |
Lua log response.
Unauthorized response.
{- "log": [
- {
- "ts": "1677872469.109779248",
- "msg": "Register cost script failed: Lua error: unknown register Grid."
}, - {
- "ts": "1677872470.100956573",
- "msg": "Tariff season: Winter"
}
]
}
Get the system log. It has a fixed size and consists of a sequence of messages. When the log fills up, older messages are replaced. The size of this log can be configured with /config/log/system/size.
System log response.
Unauthorized response.
{- "log": [
- {
- "msg": "Aug 31 22:11:08 devname syslog.info syslogd started: BusyBox v1.26.2"
}, - {
- "msg": "Aug 31 22:11:08 devname daemon.err statusd[427]: failed"
}
]
}