Przejdź do głównej treści

Alerts API

Monitor and manage security alerts from scans, IDS, honeypots, and anomaly detection.

List Alerts

GET /api/v1/alerts?page=1&per_page=25

Query Parameters

ParameterTypeDescription
severitystringFilter: critical, high, medium, low, info
statusstringFilter: open, acknowledged, resolved
site_idstringFilter by site
sourcestringFilter: scan, ids, honeypot, rogue, anomaly
sincedatetimeAlerts after this timestamp

Response:

{
"data": [
{
"id": "alert-uuid",
"title": "New open port detected on 192.168.1.10",
"description": "Port 3389 (RDP) was found open on workstation-01",
"severity": "high",
"status": "open",
"source": "scan",
"device_ip": "192.168.1.10",
"site_id": "site-uuid",
"created_at": "2026-03-15T10:30:00Z",
"metadata": {
"port": 3389,
"service": "RDP",
"previous_state": "closed"
}
}
],
"meta": {"page": 1, "per_page": 25, "total": 18}
}

Get Alert Details

GET /api/v1/alerts/{alert_id}

Acknowledge Alert

POST /api/v1/alerts/{alert_id}/acknowledge

Response:

{
"id": "alert-uuid",
"status": "acknowledged",
"acknowledged_at": "2026-03-15T10:35:00Z",
"acknowledged_by": "user@company.com"
}

Resolve Alert

POST /api/v1/alerts/{alert_id}/resolve
Content-Type: application/json

{
"resolution_note": "Port closed after firewall rule update"
}

Alert Severity Levels

SeverityDescriptionExample
criticalImmediate action requiredActive exploit detected
highSignificant riskRDP exposed to network
mediumModerate riskOutdated service version
lowMinor concernNew device on network
infoInformationalScan completed

Alert Sources

SourceDescription
scanPort scan / device discovery
idsSuricata IDS alerts
honeypotHoneypot interaction
rogueRogue DHCP/ARP detection
anomalyML anomaly detection
baselineBaseline drift alert
dnsDNS sinkhole threat

WebSocket: Real-time Alerts

Connect to wss://api.netreconapp.com/ws/alerts for live alert notifications:

{"event": "ids_alert", "data": {"rule": "ET SCAN Nmap", "src": "10.0.0.5", "severity": "high"}}
{"event": "honeypot_hit", "data": {"port": 22, "src": "10.0.0.99", "action": "login_attempt"}}
{"event": "rogue_detected", "data": {"type": "dhcp", "mac": "AA:BB:CC:DD:EE:FF"}}