Skip to content

feat(slack): add author, space, and environment context to notifications [AIS-323] - #11167

Merged
Harika Kondur (harikakondur) merged 2 commits into
masterfrom
feat/slack-enrich-notification-context
Aug 3, 2026
Merged

feat(slack): add author, space, and environment context to notifications [AIS-323]#11167
Harika Kondur (harikakondur) merged 2 commits into
masterfrom
feat/slack-enrich-notification-context

Conversation

@mgoudy91

Copy link
Copy Markdown
Contributor

What

Enriches the Contentful → Slack notification payload with the entry author, space name, and environment ID, so notifications carry the context requested in #10075.

  • Header now reads e.g. An entry was published by Jane Doe in space "Marketing" (master environment)!
  • Context line lists content type, date, author, space, and environment.

Why

Customer feature request (#10075, ZoomInfo). The current notification only shows the entry name, content type, and date, which isn't enough context to act on in a shared channel.

How

Based on the prototype service.ts / types.ts attached to the issue by Russell Schwager (@rschwager). Two new CMA lookups are added inside getResolvedEntity:

  • user.getManyForSpace → resolves the actor's display name (falls back to email, then user ID)
  • space.get → resolves the space name (falls back to space ID)

Both are wrapped in try/catch with ID fallbacks, so a failed lookup degrades gracefully rather than dropping the notification. Environment ID comes straight off the event body (no extra call).

Tests

  • Extended the getResolvedEntity unit tests to assert the new actorName, spaceName, and environmentId fields across all four event types, and stubbed the new user / space CMA calls in the mock client.
  • Full suite green (56 passing), tsc --noEmit clean, ESLint + Prettier clean on the changed files.

Notes for reviewers

  • Opened as draft: this came in off-roadmap from a customer prototype. Flagging for the team to decide whether to prioritize/merge rather than committing to ship.
  • Two additional CMA calls per notification (user list + space get). Worth a look if we're concerned about added latency or rate-limit pressure on high-volume spaces — could be cached or made opt-in if needed.

Closes #10075

🤖 Generated with Claude Code

@mgoudy91 Mitch Goudy (mgoudy91) changed the title feat(slack): add author, space, and environment context to notifications feat(slack): add author, space, and environment context to notifications [] Jul 27, 2026
Enriches the Slack notification payload with the entry author, space name,
and environment ID, addressing the customer feature request in #10075.

Based on the prototype attached to the issue by @rschwager. Adds two CMA
lookups (user.getManyForSpace, space.get), each wrapped in try/catch with
ID fallbacks so a failed lookup degrades gracefully rather than dropping
the notification. Updates the message header and context block, and extends
the getResolvedEntity unit tests to cover the new fields.

Closes #10075

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@mgoudy91
Mitch Goudy (mgoudy91) force-pushed the feat/slack-enrich-notification-context branch from abda728 to 352a690 Compare July 27, 2026 19:58
@mgoudy91
Mitch Goudy (mgoudy91) marked this pull request as ready for review July 27, 2026 19:58
@mgoudy91
Mitch Goudy (mgoudy91) requested review from a team as code owners July 27, 2026 19:58
@harikakondur
Harika Kondur (harikakondur) merged commit 0849cf5 into master Aug 3, 2026
15 checks passed
@harikakondur
Harika Kondur (harikakondur) deleted the feat/slack-enrich-notification-context branch August 3, 2026 15:31
@harikakondur Harika Kondur (harikakondur) changed the title feat(slack): add author, space, and environment context to notifications [] feat(slack): add author, space, and environment context to notifications [AIS-323] Aug 3, 2026
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.

Feature Request: Slack App - Additional Information on the update

2 participants