Skip to content

Conversation

@icecrasher321
Copy link
Collaborator

@icecrasher321 icecrasher321 commented Jul 19, 2025

Description

  • Webhook Trigger Block --> Can configure triggers to workflows. Don't take input -- similar to start blocks, but just for webhooks. Support the same providers and other functionality as start block webhook functionality.

  • Makes webhook have block level identification since it's not a global property of the workflow anymore.

  • Added docs for the block

Type of change

  • New feature (non-breaking change which adds functionality)

How Has This Been Tested?

Screen.Recording.2025-07-19.at.11.38.09.AM.mov

Checklist:

  • My code follows the style guidelines of this project
  • I have performed a self-review of my own code
  • I have commented my code, particularly in hard-to-understand areas
  • I have added tests that prove my fix is effective or that my feature works
  • All tests pass locally and in CI (bun run test)
  • My changes generate no new warnings
  • Any dependent changes have been merged and published in downstream modules
  • I have updated version numbers as needed (if needed)
  • I confirm that I have read and agree to the terms outlined in the Contributor License Agreement (CLA)

Security Considerations:

  • My changes do not introduce any new security vulnerabilities
  • I have considered the security implications of my changes

@vercel
Copy link

vercel bot commented Jul 19, 2025

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
sim ✅ Ready (Inspect) Visit Preview 💬 Add feedback Jul 20, 2025 4:22am
1 Skipped Deployment
Name Status Preview Comments Updated (UTC)
docs ⬜️ Skipped (Inspect) Jul 20, 2025 4:22am

@delve-auditor
Copy link

delve-auditor bot commented Jul 19, 2025

No security or compliance issues detected. Reviewed everything up to 3533255.

Security Overview
  • 🔎 Scanned files: 45 changed file(s)
Detected Code Changes

The diff is too large to display a summary of code changes.

Reply to this PR with @delve-auditor followed by a description of what change you want and we'll auto-submit a change to this PR to implement it.

@vercel vercel bot temporarily deployed to Preview – docs July 19, 2025 18:49 Inactive
@icecrasher321 icecrasher321 marked this pull request as ready for review July 19, 2025 18:49
Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

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

Greptile Summary

This PR introduces a significant architectural change in how webhook triggers are handled within workflows. The key changes include:

  1. Moving webhook configuration from workflow-level to block-level through a new WebhookTriggerBlock
  2. Adding a block_id column to the webhook table to support multiple webhook triggers per workflow
  3. Updating the executor to support starting workflows from webhook trigger blocks
  4. Modifying the API and UI components to handle block-level webhook configuration

The change enables multiple webhook triggers within a single workflow, similar to starter blocks but specifically for webhooks. This improves modularity and provides more flexibility in workflow design.

PR Description Notes:

  • The test section only includes a video link without written test scenarios
  • The tests checkbox is unchecked in the checklist

Confidence score: 3/5

  1. This PR is moderately safe to merge but requires careful testing of webhook execution paths
  2. The score reflects concerns about missing test coverage and potential edge cases in webhook execution
  3. Files needing attention:
    • apps/sim/lib/webhooks/utils.ts: Webhook execution logic needs thorough testing
    • apps/sim/blocks/blocks/webhook-trigger.ts: Implementation seems basic and may need additional validation
    • apps/sim/app/api/webhooks/route.ts: Edge cases in backwards compatibility need verification

14 files reviewed, 8 comments
Edit PR Review Bot Settings | Greptile

@icecrasher321 icecrasher321 changed the title feat(webhook-triggers): multiple webhook triggers feat(webhook-triggers): multiple webhook triggers through new block Jul 19, 2025
@icecrasher321 icecrasher321 changed the title feat(webhook-triggers): multiple webhook triggers through new block feat(webhook-triggers): multiple webhook trigger blocks Jul 19, 2025
{
"title": "Blocks",
"pages": [
"agent",
Copy link
Collaborator Author

Choose a reason for hiding this comment

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

just making this alphabetical order

…l, added chat fields into tag dropdown for start block
…block, removed unique constraint on scheule workflows and added combo constraint on workflowid/blockid and schedule
@vercel vercel bot temporarily deployed to Preview – docs July 20, 2025 04:19 Inactive
@icecrasher321 icecrasher321 merged commit 5ee6625 into staging Jul 20, 2025
6 checks passed
@waleedlatif1 waleedlatif1 deleted the feat/trigger-blocks branch July 22, 2025 19:57
arenadeveloper02 pushed a commit to arenadeveloper02/p2-sim that referenced this pull request Sep 19, 2025
)

* checkpoint

* correctly clear status

* works

* improvements

* fix build issue

* add docs

* remove comments, logs

* fix migration to have foreign ref key

* change filename to snake case

* modified dropdown to match combobox styling

* added block type for triggers, split out schedule block into a separate trigger

* added chat trigger to start block, removed startAt from schedule modal, added chat fields into tag dropdown for start block

* removed startedAt for schedules, separated schedules into a separate block, removed unique constraint on scheule workflows and added combo constraint on workflowid/blockid and schedule

* icons fix

---------

Co-authored-by: Waleed Latif <walif6@gmail.com>
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.

3 participants