You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Forms plugin: let webhook receivers verify the sender, and retry failed deliveries
#4546
@emdash-cms/plugin-forms (0.2.12) sends each submission to the form's webhook URL as one POST with only a Content-Type header. The code is in handlers/submit.ts, inside after(). A failed delivery is logged and never retried.
This causes two problems:
The receiver can't tell the request came from the site. There's no signature and no token. The URL itself is the only secret, which the plugin's own code acknowledges ("The webhook URL is a credential").
A short outage at the receiver loses the handoff. One 5xx or timeout, and the CRM or automation never sees that submission. The submission is still stored in emDash, so it isn't lost. But nothing tells the site owner that the integration missed it, apart from a log line.
The official @emdash-cms/plugin-webhook-notifier (0.2.3), which sends content events, already does both:
it sends an optional Authorization: Bearer <secret token> header and an X-EmDash-Event header
it retries with exponential backoff
Forms submissions are arguably the more sensitive data of the two, and they get neither.
Use case
We reviewed the Forms plugin for emdashnow.com with client sites in mind, where a contact or enquiry form feeds a CRM or an automation tool (Zapier, Make, n8n). Those receivers are usually public URLs, so anyone who learns the URL can post fake submissions into the pipeline. A missed delivery is a lost lead that nobody notices.
We also know the receiving side of this well. Our own newsletter plugin verifies the email provider's signed webhooks, an HMAC over a timestamp and the body, using the raw-body route support from #1043. The pattern is well established. Forms just doesn't send anything to verify.
Current workarounds
Put a secret in the webhook URL's query string and check it at the receiver. This works, but the secret ends up in logs and in the admin.
Have the receiver deduplicate on submissionId, and export submissions as CSV now and then to find missed deliveries.
Write a custom plugin that duplicates the Forms webhook with signing and retries.
Possible directions, as examples rather than a design:
An optional per-form secret. When set, add a signature header, such as HMAC-SHA256 over a timestamp and the raw body, plus a timestamp header. Or at least match plugin-webhook-notifier with a bearer token.
A few retries with backoff, kept within the time after() allows on Workers. Plus a visible "last delivery failed" status on the form in the admin.
Open question: durable retries (minutes or hours later) would need plugin storage and the scheduler rather than after(). Is that worth it here, or is a short in-request retry enough?
Related: #2619 (outbound webhooks for content events, which also asks for signing and retries).
I drafted this with Claude Code (Claude Opus 5.5), then reviewed and edited it myself.
Your involvement
I am requesting this capability.
I am offering to champion the design in a feature plan or RFC.
I am offering to implement it after the design is accepted.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
Uh oh!
There was an error while loading. Please reload this page.
Problem
@emdash-cms/plugin-forms(0.2.12) sends each submission to the form's webhook URL as onePOSTwith only aContent-Typeheader. The code is inhandlers/submit.ts, insideafter(). A failed delivery is logged and never retried.This causes two problems:
The official
@emdash-cms/plugin-webhook-notifier(0.2.3), which sends content events, already does both:Authorization: Bearer <secret token>header and anX-EmDash-EventheaderForms submissions are arguably the more sensitive data of the two, and they get neither.
Use case
We reviewed the Forms plugin for emdashnow.com with client sites in mind, where a contact or enquiry form feeds a CRM or an automation tool (Zapier, Make, n8n). Those receivers are usually public URLs, so anyone who learns the URL can post fake submissions into the pipeline. A missed delivery is a lost lead that nobody notices.
We also know the receiving side of this well. Our own newsletter plugin verifies the email provider's signed webhooks, an HMAC over a timestamp and the body, using the raw-body route support from #1043. The pattern is well established. Forms just doesn't send anything to verify.
Current workarounds
submissionId, and export submissions as CSV now and then to find missed deliveries.Possible directions, as examples rather than a design:
plugin-webhook-notifierwith a bearer token.after()allows on Workers. Plus a visible "last delivery failed" status on the form in the admin.Open question: durable retries (minutes or hours later) would need plugin storage and the scheduler rather than
after(). Is that worth it here, or is a short in-request retry enough?Related: #2619 (outbound webhooks for content events, which also asks for signing and retries).
I drafted this with Claude Code (Claude Opus 5.5), then reviewed and edited it myself.
Your involvement
All reactions