Skip to content

feat(webhooks): honour per-webhook event subscriptions so Daily Pulse payloads stop reaching content workflows #911

Closed

Description

@gkhngyk

Description

Each brand has one webhook, and every event goes to it. A brand that wired its webhook to a content workflow (n8n, Zapier, Make — "create a brief from this opportunity") also receives a daily_pulse.created payload every day. That payload has no opportunity field, so the workflow fails or creates junk tasks.

The data model already anticipates subscriptions — webhook_configs.events exists with a default of {opportunity.sent} (supabase/migrations/00001_initial_schema.sql line 370) — but nothing reads it:

Proposed behavior

  • The webhook settings show one checkbox per event: Opportunity sent and Daily Pulse.
  • A webhook only receives the events it is subscribed to. webhook.test is always delivered.
  • Existing webhooks keep today's behavior (they receive both events) until the user changes the selection.

Suggested approach

  • A migration that adds daily_pulse.created to events on existing rows and to the column default, so nothing changes for current users.
  • Filter in dispatch and in the content send route with .contains('events', [event]).
  • Read and write events in the settings form and saveWebhookConfig.
  • Document the subscription in docs/api-reference/webhooks.mdx.

Apply the migration as described in CONTRIBUTING.md; run yarn test from server/ and yarn lint / yarn build from web/.

Activity

  1. added
    enhancement
    help wanted
    integrations
    needs-migration
    on Oct 4, 2026
  2. knockknock10 commented on Oct 20, 2026

    @knockknock10
    Contributor

    Hey @gkhngyk
    I had created pr addressing #1239
    once please check it out if it works!!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementhelp wantedintegrationsneeds-migration

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions