Enhance API and UI for incident management and live updates
Publish telemt-api gateway Docker image / test (push) Successful in 24s
Publish telemt-api gateway Docker image / build-and-push (push) Successful in 1m58s

- Added a new endpoint `/api/agg/incidents` to provide a normalized snapshot of incidents for fleet triage, including severity and recommended actions.
- Implemented live event streaming via `/api/live/events` for real-time updates on fleet status and incidents, enhancing observability.
- Updated the Web UI to include dedicated sections for incidents and live updates, improving user navigation and access to critical information.
- Enhanced API documentation to reflect new endpoints and their functionalities, ensuring clarity for developers and users.
This commit is contained in:
Denozordec
2026-03-30 19:17:29 +07:00
parent af11a49c81
commit 8c8ccce6ee
18 changed files with 1655 additions and 28 deletions
+59
View File
@@ -106,6 +106,18 @@ paths:
application/json:
schema: { $ref: '#/components/schemas/AggEnvelopeFleetStatus' }
/api/agg/incidents:
get:
summary: Нормализованный snapshot инцидентов по флоту
parameters:
- $ref: '#/components/parameters/aliases'
responses:
'200':
description: OK
content:
application/json:
schema: { $ref: '#/components/schemas/AggEnvelopeIncidents' }
components:
parameters:
aliases:
@@ -173,6 +185,13 @@ components:
properties:
data: { $ref: '#/components/schemas/FleetStatusData' }
AggEnvelopeIncidents:
allOf:
- $ref: '#/components/schemas/AggSuccessBase'
- type: object
properties:
data: { $ref: '#/components/schemas/IncidentsData' }
TrafficRow:
type: object
properties:
@@ -297,3 +316,43 @@ components:
servers_total: { type: integer }
servers_all_ok: { type: integer }
servers_failed: { type: integer }
IncidentAction:
type: object
properties:
label: { type: string }
href: { type: string }
IncidentItem:
type: object
properties:
id: { type: string }
kind: { type: string }
severity:
type: string
enum: [info, warning, critical]
status:
type: string
enum: [firing]
title: { type: string }
summary: { type: string }
affected_aliases:
type: array
items: { type: string }
metric_name: { type: string }
metric_value: { type: number, format: float }
metric_threshold: { type: number, format: float }
actions:
type: array
items: { $ref: '#/components/schemas/IncidentAction' }
IncidentsData:
type: object
properties:
items:
type: array
items: { $ref: '#/components/schemas/IncidentItem' }
total: { type: integer }
critical_total: { type: integer }
warning_total: { type: integer }
info_total: { type: integer }