GERAS
Dual-channel emergency alerting for road safety agencies. One tap on the roadside becomes a live incident on the dispatcher's map — over data, or over SMS when there is no signal.
- Automatic SMS failover: connectivity probe distinguishes real throughput from a dead connection
- Atomic server-side dedup — SMS and data reports merge on a shared reference code into one incident
- SMS payload fits one GSM-7 segment, with bounds validated at parse time and 20 tests on the parser/builder
- PostGIS nearest-unit dispatch with GIST-indexed geodesic lookups and ETA estimates
- TOTP MFA on all dispatcher access, RLS on every table, constant-time webhook auth, append-only audit log
GERAS is built around one hard problem: the moment a road user needs help is exactly when the network is least likely to work. It treats connectivity as three states rather than two — online, offline, and online with zero throughput — probing a health endpoint before choosing a channel and falling back to a prefilled SMS when the probe fails. The reporter is a PWA, so there is no install and no account; alerts that cannot send at all queue in IndexedDB and reconcile when signal returns.
Both channels land in the same pipeline. A data report and an SMS for the same event merge server-side on a shared six-character reference code through one upsert function, so a user who sends both produces exactly one incident row rather than two. Dispatchers work from a realtime console with a PostGIS-backed nearest-unit lookup over spheroid-accurate distances, and every status transition appends to an audit log that authenticated users cannot rewrite — the service-role key is confined to server-only paths so the trail cannot be bypassed by an RLS-restricted user.