Failure mode: A Twilio form webhook validates in a direct test and then fails behind a reverse proxy. The app is passing its internal request URL to the validator instead of the public URL Twilio signed.
Tiny offline repro: Sign a synthetic form with Body=hello for https://example.com/webhook?source=fixture. I held the form and signature constant and changed only the validator input to http://localhost/webhook?source=fixture. The public URL matched; the internal one did not. No live account or messages needed.
Regression test: Keep both cases. In production, use Twilio’s SDK validator with the original public URL, including its query string, and the complete form parameters. Take the origin from config or trusted proxy metadata, not arbitrary forwarded headers. Twilio’s signing docs.
Optional debugging soundtrack.