Jahanzaib
Production

Webhook

HTTP callback that lets one service push real-time data to another by sending a POST request to a registered URL when an event happens.

Last updated: April 26, 2026

Definition

A webhook is the inverse of polling. Instead of service A periodically asking service B "anything new?", service B calls service A directly via HTTP POST when something happens. Webhooks are the standard way modern SaaS APIs notify consumers of events: Stripe payment succeeded, GitHub PR opened, Slack message received, Sanity content published. For AI agents, webhooks are the most common trigger: an event happens, the webhook hits your agent endpoint, the agent runs. Production webhook handling needs three things: signature verification (so the request actually came from the claimed sender), idempotency keys (events get redelivered), and fast response (most providers expect 2xx in under 5 seconds; do the real work async).

When To Use

Default mechanism for any third-party service notifying your agent. Always verify webhook signatures and handle redelivery idempotently.

Sources

Related Terms

Building with Webhook?

I've shipped this pattern in real production systems. If you want a second pair of eyes on your architecture, that's what I do.