ServiceM8 add-on PWA + admin portal for HVAC hygiene field reporting. Single Next.js codebase (route segments separate the field-tech PWA and admin portal); Supabase Postgres + Storage + Realtime; Railway worker for PDF render.
Per design review §24.A4 — what to walk Mitch / Luke through.
Two-button SM8 manifest
Both 'Photo Audit' and 'Generate Photo Report' configured in the SM8 dev portal.
Vault-backed OAuth tokens
platform_integrations row references vault.secrets — raw tokens unreadable from app SQL.
Platform-agnostic schema
tenants, platform_users, platform_integrations — no sm8_* anywhere.
Sentry + Axiom + Google Chat plumbing
Use the trigger below — error in Sentry, log in Axiom, alert in GChat.
Fires a structured Axiom log + a Google Chat alert + a Sentry capture in one shot. Use this during the demo to prove the plumbing is live.
Direct URLs, exercised by the SM8 add-on Job Card buttons in the live flow.
Field-tech PWA
/field/job
SM8 “Photo Audit” button lands here. Without a launch token, displays the “launch from SM8” prompt.
Admin modal
/admin/job
SM8 “Generate Photo Report” button lands here. Admin session minting wires up alongside the M3 onboarding flow.
Apr 27
Project scaffold + observability env wiring
Apr 28
Supabase scaffolding + Vault extension
Apr 29
Full DB schema (34 tables, 6 domains)
Apr 30
RLS policies + pgTAP suite + CI gates
May 1
Storage buckets + signed-URL strategy
May 5
OAuth code flow + Vault helper RPCs + refresh
May 6
SM8 launch handler + add-on manifest
May 7
Launch session redeem + field-scoped middleware
May 8
🎯 Foundation demo — this page
May 11
PWA shell + install-to-home-screen
May 12
Platform mirror initial sync
May 13
Foundation polish + docs pass
May 14
🎯 M1 demo + signoff
Spec hierarchy: design review > delivery plan > schema > sources. See docs/EHS_DESIGN_REVIEW.md for the ratified amendments.