Skip to content

feat(hub): add automatic redacted request logging - #119

Open
Copilot wants to merge 1 commit into
build/hub/newfrom
copilot/hub-request-logging
Open

Copilot wants to merge 1 commit into
build/hub/newfrom
copilot/hub-request-logging

Conversation

Copilot AI commented Oct 26, 2026

Copy link
Copy Markdown
Contributor

Why

The new Express API needs useful request diagnostics without adding logging calls to every endpoint or exposing sensitive request fields. Closes #117.

What changes

A shared Pino integration writes application events and automatic HTTP records as JSON to stdout. Each request gets a server-generated ID, and its terminal record includes the method, route template, status, duration, and sanitized parameters, query, and JSON body. Aborted requests have a distinct outcome. Pino and pino-http use the latest versions eligible under the dependency-age policy.

Structured fields receive recursive key redaction and size limits without changing the request. Endpoints can omit payloads entirely. Automatic records exclude raw URLs, headers, uploads, malformed bodies, response bodies, and error details. Mounted routers log the handler's relative route template rather than concrete mount values. The logging guide documents free-text and custom-binding limits, configuration, and backend import boundaries; collection and retention remain outside this change.

Created from a Slack conversation.

Co-authored-by: Nishiki <1121087+nshki@users.noreply.github.com>
Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Copilot AI requested review from a team and nshki as code owners October 26, 2026 20:09
Copilot AI max review requested due to automatic review settings October 26, 2026 20:09

This comment was marked as duplicate.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants