fix(projects): name the portal user in project audit events #47

Merged
sharang merged 1 commits from fix/project-audit-actor into main 2026-09-29 14:50:38 +00:00
Owner

Found in the staging test of Projekte. project.created|updated|deleted by a workspace user (the portal sends X-Portal-User-Email) used to show up in the audit log as the service ("BreakPilot"). They now carry actor_name = the user's email and actor_type = user. Staff were already attributed by emitAudit.

New test TestProjects_auditNamesThePortalUser (memory and Postgres).

Goes together with portal#62 (texts for the new audit actions) and the Prüfwerk audit event target.projects_changed.

🤖 Generated with Claude Code

https://claude.ai/code/session_01DmXxNULoSNPvjF7buKipsB

Found in the staging test of Projekte. `project.created|updated|deleted` by a workspace user (the portal sends `X-Portal-User-Email`) used to show up in the audit log as the service ("BreakPilot"). They now carry `actor_name` = the user's email and `actor_type` = `user`. Staff were already attributed by `emitAudit`. New test `TestProjects_auditNamesThePortalUser` (memory and Postgres). Goes together with portal#62 (texts for the new audit actions) and the Prüfwerk audit event `target.projects_changed`. 🤖 Generated with [Claude Code](https://claude.com/claude-code) https://claude.ai/code/session_01DmXxNULoSNPvjF7buKipsB
sharang added 1 commit 2026-09-29 14:26:02 +00:00
fix(projects): name the portal user in project audit events
ci / shared (pull_request) Successful in 14s
ci / test (pull_request) Successful in 24m0s
ci / image (pull_request) Skipped
ca78aeacf7
Project changes made by a workspace user through the portal were logged
as the service; they now carry the user's email (X-Portal-User-Email)
and actor type user. Staff were already attributed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01DmXxNULoSNPvjF7buKipsB
sharang merged commit f96525dd4d into main 2026-09-29 14:50:38 +00:00
Sign in to join this conversation.