## Summary - **ADS-B & AIS:** OpenSky and AISStream OSINT feeds upsert into the CoT store; tactical tracks still arrive via adsbcot/aiscot on `:8089`. Map clients subscribe via `GET /api/cot/stream` (SSE) with viewport bbox filtering and Air / Surface / Team layer toggles. - **ALPR (Flock/OSM):** Toggleable license-plate reader layer sourced from OpenStreetMap, with SQLite cache, Overpass fallback, tiled viewport fetching, and clustered markers with direction cones. - **Map performance:** Ring-based tile selection (fixes zoom-out crash), immutable tile cache, incremental marker sync, split cluster load/query, and padded SSE bbox to reduce reconnect churn. ## Docs - `docs/tracking.md` — ADS-B/AIS accuracy tiers, freshness, self-hosted receivers, optional OSINT API keys - `docs/map-and-cameras.md` — ALPR layer and map behavior updates --------- Co-authored-by: Madison Grubb <madison@elastiflow.com> Reviewed-on: #36
2.2 KiB
Map and Cameras
KestrelOS shows a map with devices, POIs, live sessions (Share live), and ATAK/iTAK positions. Click markers or use Cameras page to view streams.
Map Layers
- Devices - Fixed feeds (IPTV, ALPR, CCTV, NVR, etc.) added via API
- ALPR (OSM / DeFlock) - Crowdsourced license-plate cameras from OpenStreetMap; toggle on the map (camera icon control). Reference only, no stream.
- POIs - Points of interest (admin/leader can edit)
- Live sessions - Mobile devices streaming via Share live
- CoT (ATAK/iTAK) - Amber markers for connected TAK devices (position only)
Cameras
A camera is either:
- A device - Fixed feed with stream URL
- A live session - Mobile device streaming via Share live
View via map markers or Cameras page (sidebar).
Device Types
| device_type | Use case |
|---|---|
alpr, nvr, doorbell, feed, traffic, ip, drone |
Labeling/filtering |
source_type: mjpeg (MJPEG over HTTP) or hls (HLS .m3u8 playlist)
Stream URLs must be http:// or https://.
API: Devices
Create: POST /api/devices (admin/leader)
{
"name": "Main gate ALPR",
"device_type": "alpr",
"lat": 37.7749,
"lng": -122.4194,
"stream_url": "https://alpr.example.com/stream.m3u8",
"source_type": "hls"
}
List: GET /api/devices
Update: PATCH /api/devices/:id
Delete: DELETE /api/devices/:id
Cameras endpoint: GET /api/cameras returns devices + live sessions + CoT entities.
ALPR layer (DeFlock / OpenStreetMap)
deflock.me has no bulk download API. KestrelOS queries OpenStreetMap via Overpass (surveillance:type=ALPR) and returns GeoJSON FeatureCollection from GET /api/alpr.
- Map: ALPR layer is on by default (toggle top-left to hide). Marker popups show OSM identifying tags (manufacturer, model, operator, ref, Wikidata, etc.) when contributors tagged them.
- Offline: Run
npm run import:alprto preload SQLite; cache serves automatically when Overpass is unreachable.
Attribution: © OpenStreetMap contributors.
POIs
Admins/leaders add/edit from POI page (sidebar). POIs appear as map pins (reference only, no stream).