Logging & Observability (Frontend Standard)
This document defines the minimum observability bar for Next.js frontends.
Minimum bar (required)
Server-side (Route Handlers, Server Components)
- Log request summaries for BFF endpoints (method, route, status, duration).
- Preserve correlation headers where applicable (e.g.,
X-Request-Id). - Redact secrets/PII.
Client-side
- Avoid logging PII and secrets.
- Prefer actionable, user-safe error messaging.
Error tracking tooling (project-dependent)
We do not mandate a single vendor across projects.
Standards requirement:
- The project must choose and document an approach (vendor tool or none), and meet the minimum bar above.