Uh oh!
There was an error while loading. Please reload this page.
feat(confluence): add webhook triggers for Confluence events - #3318
Conversation
The latest updates on your projects. Learn more about Vercel for GitHub. |
Greptile SummaryAdded comprehensive Confluence webhook trigger support with 16 specific event triggers plus a generic catch-all webhook. Implementation follows established patterns from Jira/GitHub/Linear integrations with proper HMAC signature verification, payload-based event filtering, and entity-specific data extraction. Key Changes:
Architecture:
Confidence Score: 5/5
Important Files Changed
Flowchart%%{init: {'theme': 'neutral'}}%%
flowchart TD
A[Confluence Webhook Event] --> B{Signature Verification}
B -->|Valid/No Secret| C{Provider Check}
B -->|Invalid| D[Return 401]
C -->|confluence| E{Payload Filtering}
E -->|Match triggerId| F[formatWebhookInput]
E -->|No Match| G[Skip Execution]
F -->|page_*| H[extractPageData]
F -->|comment_*| I[extractCommentData]
F -->|blog_*| J[extractBlogData]
F -->|attachment_*| K[extractAttachmentData]
F -->|space_*| L[extractSpaceData]
F -->|label_*| M[extractLabelData]
F -->|generic webhook| N[Extract All Entities]
H --> O[Queue Workflow Execution]
I --> O
J --> O
K --> O
L --> O
M --> O
N --> O
Last reviewed commit: f9d5f2c |
Adds 16 Confluence triggers: page CRUD, comments, blogs, attachments, spaces, and labels — plus a generic webhook trigger. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Add trigger subBlocks and triggers config to ConfluenceV2Block so triggers appear in the UI. Add Confluence signature verification and event filtering to the webhook processor. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Rewrite output builders to match real Confluence webhook payload structure (flat spaceKey, numeric version, actual API fields) - Remove fabricated fields (nested space/version objects, comment.body) - Add missing fields (creatorAccountId, lastModifierAccountId, self, creationDate, modificationDate, accountType) - Add extractor functions (extractPageData, extractCommentData, etc.) following the same pattern as Jira - Add formatWebhookInput handler for Confluence in utils.server.ts so payloads are properly destructured before reaching workflows - Make event field matching resilient (check both event and webhookEvent) Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
The generic webhook (confluence_webhook) was falling through to extractPageData, which only returns the page field. For a catch-all trigger that accepts all event types, preserve all entity fields (page, comment, blog, attachment, space, label, content). Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
def5224 to
59ea2feCompare…vent field Confluence Cloud webhooks don't include an event/webhookEvent field in the body (unlike Jira). Replaced broken event string matching with structural payload filtering that checks which entity key is present.
waleedlatif1
commented
Feb 24, 2026
@cursor review |
Uh oh!
There was an error while loading. Please reload this page.
…ure verification These providers define their secret subBlock with id: 'webhookSecret' but the processor was reading providerConfig.secret which is always undefined, silently skipping signature verification even when a secret is configured.
waleedlatif1
commented
Feb 24, 2026
waleedlatif1
commented
Feb 24, 2026
@cursor review |
Uh oh!
There was an error while loading. Please reload this page.
…ory fallback Admin REST API webhooks (Settings > Webhooks) include an event field for action-level filtering (page_created vs page_updated). Connect app webhooks omit it, so we fall back to entity-category matching.
waleedlatif1
commented
Feb 24, 2026
@cursor review |
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
Bugbot Autofix is OFF. To automatically fix reported issues with Cloud Agents, enable Autofix in the Cursor dashboard.
Uh oh!
There was an error while loading. Please reload this page.
…ioai#3318) * feat(confluence): add webhook triggers for Confluence events Adds 16 Confluence triggers: page CRUD, comments, blogs, attachments, spaces, and labels — plus a generic webhook trigger. * feat(confluence): wire triggers into block and webhook processor Add trigger subBlocks and triggers config to ConfluenceV2Block so triggers appear in the UI. Add Confluence signature verification and event filtering to the webhook processor. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> * fix(confluence): align trigger outputs with actual webhook payloads - Rewrite output builders to match real Confluence webhook payload structure (flat spaceKey, numeric version, actual API fields) - Remove fabricated fields (nested space/version objects, comment.body) - Add missing fields (creatorAccountId, lastModifierAccountId, self, creationDate, modificationDate, accountType) - Add extractor functions (extractPageData, extractCommentData, etc.) following the same pattern as Jira - Add formatWebhookInput handler for Confluence in utils.server.ts so payloads are properly destructured before reaching workflows - Make event field matching resilient (check both event and webhookEvent) Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> * fix(confluence): handle generic webhook in formatWebhookInput The generic webhook (confluence_webhook) was falling through to extractPageData, which only returns the page field. For a catch-all trigger that accepts all event types, preserve all entity fields (page, comment, blog, attachment, space, label, content). Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com> * fix(confluence): use payload-based filtering instead of nonexistent event field Confluence Cloud webhooks don't include an event/webhookEvent field in the body (unlike Jira). Replaced broken event string matching with structural payload filtering that checks which entity key is present. * lint * fix(confluence): read webhookSecret instead of secret in signature verification * fix(webhooks): read webhookSecret for jira, linear, and github signature verification These providers define their secret subBlock with id: 'webhookSecret' but the processor was reading providerConfig.secret which is always undefined, silently skipping signature verification even when a secret is configured. * fix(confluence): use event field for exact matching with entity-category fallback Admin REST API webhooks (Settings > Webhooks) include an event field for action-level filtering (page_created vs page_updated). Connect app webhooks omit it, so we fall back to entity-category matching. --------- Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
Summary
Type of Change
Testing
Tested manually
Checklist