Repository navigation
Release v1.14.0 — alert webhooks (#225) - #512
Merged
Merged
Conversation
…-develop chore: sync main v1.13.2 into develop
Add project webhook CRUD, signed alert.fired dispatch with retry/dead-letter, and an operator-facing delivery history on Alerts → Delivery so MVP #225 is closable after merge. Co-authored-by: Cursor <[email protected]>
…as FAILED DNS-rebinding helper hostnames passed create-time string checks; re-check resolved IPs on each delivery. Single-shot test deliveries never retry, so record FAILED instead of DEAD. Co-authored-by: Cursor <[email protected]>
Add ## [1.8.11] and ## [1.5.0] so historical release notes and changelog anchors resolve correctly. Co-authored-by: Cursor <[email protected]>
Use the resolved, validated address for direct alert deliveries and record retry outcomes without relying on unsupported queue states. Co-authored-by: Cursor <[email protected]>
Enqueue PENDING AlertWebhookDelivery rows before fireProjectAlert returns, process them via a claim/lease worker (brief-worker pattern), and pin HTTPS connects to validated resolved IPs to close DNS-rebinding TOCTOU. Co-authored-by: Cursor <[email protected]>
…version-headings fix(docs): restore missing CHANGELOG version headings
Keep AlertEvent insert and PENDING enqueue in one transaction so a failed createMany cannot orphan a dedupe key, and reuse the test delivery UUID in the log row. Co-authored-by: Cursor <[email protected]>
Normalize IPv6 hextets so IPv4-mapped and IPv4-compatible forms (compressed, expanded, or hex-mapped) cannot bypass the delivery blocklist. Co-authored-by: Cursor <[email protected]>
Check completeAlertWebhookDelivery after successful POST so a lost lease is not reported as success, renew the lease before POST, and create webhooks under a serializable count+insert to honor MAX_PROJECT_WEBHOOKS. Co-authored-by: Cursor <[email protected]>
When HTTP delivery succeeds but the lease-scoped complete misses, still mark the row SUCCESS so it cannot stay PROCESSING and be POSTed again. Co-authored-by: Cursor <[email protected]>
Prevent short lease overrides from expiring mid-HTTPS POST, and persist test delivery rows before sending so Recent deliveries cannot miss a hit. Co-authored-by: Cursor <[email protected]>
Exclude webhook:test: rows from worker claim and fail null alert_event_id deliveries instead of inventing a generic payload that could double-POST. Co-authored-by: Cursor <[email protected]>
Retry the final SUCCESS/FAILED update and fall back to FAILED so claim-excluded webhook:test rows cannot stay PROCESSING forever. Co-authored-by: Cursor <[email protected]>
Clear PROCESSING immediately without burning the attempt toward DEAD, so a still-owned row is not stuck until lease expiry. Co-authored-by: Cursor <[email protected]>
Reclaiming an expired lease no longer increments attempt, so a crash before POST still gets the full WEBHOOK_MAX_ATTEMPTS of real deliveries. Co-authored-by: Cursor <[email protected]>
…ooks feat(alerts): outbound HTTPS webhooks + delivery log (#225)
Promote alert webhooks (#225) from develop: finalize CHANGELOG and stamp API_VERSION 1.14.0. Co-authored-by: Cursor <[email protected]>
Abandon expired webhook:test PROCESSING rows as FAILED without re-POST, and keep worker leases at least POST timeout plus margin. Co-authored-by: Cursor <[email protected]>
Delivery-time DNS had no timeout while the claim lease only covered POST+margin, so a slow resolver could expire the lease mid-flight and allow duplicate POSTs. Cap DNS at WEBHOOK_DNS_TIMEOUT_MS and clamp lease to DNS+POST+margin. Co-authored-by: Cursor <[email protected]>
Contributor
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes using default effort and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit 8163eda. Configure here.
A successful outbound POST must never leave a reclaimable PROCESSING row; retry scoped finalize and last-resort update SUCCESS by id. Co-authored-by: Cursor <[email protected]>
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
develop→main(first ship of milestone v1.14.x — Notifications).alert.firedPOSTs, DNS-pinned SSRF checks, delivery log.[1.14.0] - 2026-07-17, committedAPI_VERSION1.14.0.Deploy / post-merge (before tag)
DATABASE_URL=… pnpm --filter api exec prisma migrate deploy(ProjectWebhook/AlertWebhookDelivery).pnpm --filter api alert-webhook-worker(or Railway service equivalent); optional envALERT_WEBHOOK_WORKER_POLL_MS/ALERT_WEBHOOK_WORKER_LEASE_MS.GET /healthshows"version":"1.14.0"; configure a webhook on Alerts → Delivery and run Test.Test plan
build, etc.) on this PR/healthreports1.14.0After merge (RELEASE.md)
v1.14.0onmain(after migrate + verify) — triggers product update email (MINOR).docs/RELEASE_NOTES_TEMPLATE.md.main→developand push.Made with Cursor