Skip to content

Include update authors in Slack space update notifications - #1196

Merged
gregberge merged 1 commit into
mainfrom
greg/rnd-11105-include-actor-identity-in-slack-docs-updated-webhook-alerts
Jun 10, 2026
Merged

Include update authors in Slack space update notifications#1196
gregberge merged 1 commit into
mainfrom
greg/rnd-11105-include-actor-identity-in-slack-docs-updated-webhook-alerts

Conversation

@gregberge

Copy link
Copy Markdown
Contributor

Summary

When a space_content_updated event is received, the Slack notification now shows who made the changes, using the updatedBy field (a list of users) from the event payload.

The notification footer goes from:

📊 3 total changes • Updated just now

to:

📊 3 total changes • Updated just now by Jane Doe, John Smith

Implementation notes

  • The author list comes directly from the event payload (event.updatedBy), so no extra API call is needed.
  • event.updatedBy ?? [] guards against older events emitted before the field existed, and users without a display name are filtered out. When no author is available, the footer falls back to the previous text.
  • Requires @gitbook/api types that include updatedBy on SpaceContentUpdatedEvent (already present in the workspace-generated client).

Changeset

Minor bump of @gitbook/integration-slack.

🤖 Generated with Claude Code

Use the new `updatedBy` field from the `space_content_updated` event
payload to display who made the changes in the notification footer.

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Copilot AI review requested due to automatic review settings June 10, 2026 08:02
@changeset-bot

changeset-bot Bot commented Jun 10, 2026

Copy link
Copy Markdown

🦋 Changeset detected

Latest commit: 8fb125b

The changes in this PR will be included in the next version bump.

This PR includes changesets to release 1 package
Name Type
@gitbook/integration-slack Minor

Not sure what this means? Click here to learn what changesets are.

Click here if you're a maintainer who wants to add another changeset to this PR

@pkg-pr-new

pkg-pr-new Bot commented Jun 10, 2026

Copy link
Copy Markdown

Open in StackBlitz

bun add https://pkg.pr.new/GitbookIO/integrations/@gitbook/api@1196

commit: 8fb125b

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates the Slack integration’s space_content_updated notification to attribute content changes to the users who made them, using the updatedBy list from the event payload (no additional API calls).

Changes:

  • Extract event.updatedBy display names and append them to the notification footer.
  • Add a changeset bumping @gitbook/integration-slack (minor) for the user-visible notification enhancement.

Reviewed changes

Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.

File Description
integrations/slack/src/index.ts Appends update authors to the Slack notification footer for space content updates.
.changeset/silver-pugs-report.md Declares a minor version bump for the Slack integration change.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread integrations/slack/src/index.ts
@gregberge
gregberge merged commit 1d1284f into main Jun 10, 2026
14 checks passed
@gregberge
gregberge deleted the greg/rnd-11105-include-actor-identity-in-slack-docs-updated-webhook-alerts branch June 10, 2026 08:11
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.

4 participants