The lifecycle log and history

GET /api/bng/events/log?limit=<n>                      read_only
GET /api/bng/events/history                            read_only

/events/log reads the tail of the append-only lifecycle log — the record of
every transition, not the current state. Entries are returned newest first;
limit defaults to 200 and is clamped between 1 and 2000. A non-integer limit
falls back to the default rather than erroring.

Recorded actions include fired, severity_changed (carrying the old and new
severity), re_fired, condition_resolved (carrying the incident window),
operator_acknowledged, operator_cleared, and auto_cleared. The distinction
between the last two is the operationally interesting one: auto_cleared means
the condition resolved without an acknowledgement — the power supply was
re-seated before anyone clicked.

The same log is the system's general audit sink; configuration writes and
snapshot operations land here too, which is how they reach the merged audit
timeline.

/events/history returns every event since the history was last cleared,
including resolved ones, sorted by first-seen descending, with a computed
duration_s. For an active event that duration is measured to now and
therefore grows between polls; for a resolved one it is the incident length.