Skip to catalogue

48

webhook

Their server hits yours when something happens. Verify the signature. Do not trust the browser return.

What is webhook?

A webhook is an HTTP callback from another system: payment succeeded, repo pushed, email opened. You expose an endpoint; they POST. Retries are normal.

Why does webhook matter when vibe coding?

Models mark an order paid when Stripe redirects the browser. The user closed the tab. The webhook is the source of truth. Also: unsigned webhooks are a write API for strangers.

How do you do webhook?

Verify signatures. Make handlers idempotent. Process out of band if work is slow. Never take payment state from a query string.

How do you ask a model for webhook?

Mark (object) paid from the webhook, not from the browser return. Verify the signature. The handler must be idempotent; providers retry.

What goes wrong with webhook?

Returning 200 before you persisted. Their retry storms, or they never retry and you lost the event.

adjacent