feat(14-01): add site_id device filter, wireless data endpoints, and frontend API clients

- Add site_id and sector_id query parameters to devices list endpoint
- Add get_device_registrations and get_device_rf_stats to link_service
- Add RegistrationResponse, RFStatsResponse schemas to link.py
- Add /registrations and /rf-stats endpoints to links router
- Add sectorsApi frontend client (list, create, update, delete, assignDevice)
- Add wirelessApi frontend client (links, registrations, RF stats, unknown clients)

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
This commit is contained in:
Jason Staack
2026-03-19 06:42:08 -05:00
parent ea5afe3408
commit 430cab98a8
6 changed files with 360 additions and 1 deletions

View File

@@ -54,3 +54,48 @@ class UnknownClientListResponse(BaseModel):
items: list[UnknownClientResponse]
total: int
class RegistrationResponse(BaseModel):
"""A single wireless registration entry for a device."""
mac_address: str
interface: str | None = None
signal_strength: int | None = None
tx_ccq: int | None = None
tx_rate: str | None = None
rx_rate: str | None = None
distance: int | None = None
uptime: str | None = None
last_seen: datetime
hostname: str | None = None
device_id: str | None = None
model_config = ConfigDict(from_attributes=True)
class RegistrationListResponse(BaseModel):
"""List of wireless registrations with total count."""
items: list[RegistrationResponse]
total: int
class RFStatsResponse(BaseModel):
"""RF monitor stats for a single interface."""
interface: str
noise_floor: int | None = None
channel_width: int | None = None
tx_power: int | None = None
registered_clients: int | None = None
last_seen: datetime
model_config = ConfigDict(from_attributes=True)
class RFStatsListResponse(BaseModel):
"""List of RF stats with total count."""
items: list[RFStatsResponse]
total: int