Problem Details errors, request ids, and JSON logs #78

Open
opened 2026-11-27 16:43:20 -05:00 by bobby · 0 comments
Owner

Part of #73 (spec: #72)

What to build

Every error any endpoint returns is RFC 9457 Problem Details carrying a code and the request's request_id. Every request gets a request_id, and logs are structured JSON lines that include it.

Acceptance criteria

  • An unknown route returns application/problem+json with type, title, status, code, and request_id
  • Validation errors use the same shape with a distinct code
  • Unhandled exceptions return a generic 500 problem with no stack trace or internals
  • Each request logs one structured JSON line with request_id, method, route template, status, and duration
Part of #73 (spec: #72) ## What to build Every error any endpoint returns is RFC 9457 Problem Details carrying a `code` and the request's `request_id`. Every request gets a `request_id`, and logs are structured JSON lines that include it. ## Acceptance criteria - [ ] An unknown route returns `application/problem+json` with `type`, `title`, `status`, `code`, and `request_id` - [ ] Validation errors use the same shape with a distinct `code` - [ ] Unhandled exceptions return a generic `500` problem with no stack trace or internals - [ ] Each request logs one structured JSON line with `request_id`, method, route template, status, and duration
bobby added the ready-for-agent label 2026-11-27 16:43:20 -05:00
bobby added a new dependency 2026-11-27 16:43:21 -05:00
bobby added a new dependency 2026-11-27 16:43:21 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Reference: bobby/hapi#78