mirror of
https://github.com/rzuasti/oott.git
synced 2026-07-08 19:21:54 +02:00
Records a DeviceEvent row on every scan: NewDevice when a device is first
seen, DeviceSeen on subsequent scans. Exposes GET /api/devices/{mac}/events
with pagination, ordered by date descending.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
9 lines
207 B
SQL
9 lines
207 B
SQL
CREATE TABLE device_events(
|
|
id INTEGER PRIMARY KEY,
|
|
mac_address TEXT NOT NULL,
|
|
created_on TEXT NOT NULL,
|
|
event_type TEXT NOT NULL,
|
|
ipv4_address TEXT NOT NULL,
|
|
vendor TEXT NOT NULL
|
|
);
|