fix(trigger): handle Slack reaction_added/reaction_removed event payloads#3280
Merged
waleedlatif1 merged 4 commits intostagingfrom Feb 21, 2026
Merged
fix(trigger): handle Slack reaction_added/reaction_removed event payloads#3280waleedlatif1 merged 4 commits intostagingfrom
waleedlatif1 merged 4 commits intostagingfrom
Conversation
|
The latest updates on your projects. Learn more about Vercel for GitHub. |
Contributor
Greptile SummaryThis PR adds support for handling Slack Key changes:
Confidence Score: 5/5
Important Files Changed
Sequence DiagramsequenceDiagram
participant Slack
participant Webhook
participant formatWebhookInput
participant fetchSlackMessageText
participant SlackAPI
Slack->>Webhook: reaction_added/reaction_removed event
Webhook->>formatWebhookInput: process event payload
formatWebhookInput->>formatWebhookInput: detect reaction event type
formatWebhookInput->>formatWebhookInput: extract channel from event.item.channel
formatWebhookInput->>formatWebhookInput: extract timestamp from event.item.ts
alt botToken available
formatWebhookInput->>fetchSlackMessageText: fetch original message text
fetchSlackMessageText->>SlackAPI: GET reactions.get(channel, timestamp)
alt API success
SlackAPI-->>fetchSlackMessageText: return message data
fetchSlackMessageText-->>formatWebhookInput: return message.text
else API failure
SlackAPI-->>fetchSlackMessageText: error response
fetchSlackMessageText-->>formatWebhookInput: return empty string (graceful degradation)
end
else no botToken
formatWebhookInput->>formatWebhookInput: use empty string for text
end
formatWebhookInput->>formatWebhookInput: build event object with reaction & item_user
formatWebhookInput-->>Webhook: return formatted event data
Last reviewed commit: ebbc42a |
Collaborator
Author
|
@cursor review |
Collaborator
Author
|
@greptile |
Collaborator
Author
|
@greptile |
Collaborator
Author
|
@cursor review |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
event.item.channeland timestamp fromevent.item.tsfor reaction eventsconversations.historywhen bot token is availablereaction(emoji name) anditem_user(original message author) fieldsreactionanditem_userto trigger output schemaType of Change
Testing
Tested manually
Checklist