# What is a webhook? A simple explanation and an example

> A webhook is an automatic message one system sends to another when something happens, such as a feed error. How it works, what it is for and what to protect.

Source: <https://sortyra.com/glossary/what-is-a-webhook>

---

[Sortyra](https://sortyra.com/) [Glossary](https://sortyra.com/glossary) [U – X](https://sortyra.com/glossary/u-x)

# Webhook

Sortyra team · September 1, 2026 · 3 min read

[Glossary](https://sortyra.com/glossary)

[A – D](https://sortyra.com/glossary/a-d) [E – H](https://sortyra.com/glossary/e-h) [I – L](https://sortyra.com/glossary/i-l) [M – P](https://sortyra.com/glossary/m-p) [Q – T](https://sortyra.com/glossary/q-t) [U – X](https://sortyra.com/glossary/u-x)

- [Unmatched offer](https://sortyra.com/glossary/unmatched-offer-comparison-site)
- [URL](https://sortyra.com/glossary/what-is-a-url)
- [UTF-8 encoding](https://sortyra.com/glossary/utf-8-encoding-in-feed)
- [UTM parameters](https://sortyra.com/glossary/utm-parameters-in-links)
- [Value mapping table](https://sortyra.com/glossary/value-mapping-table-feed)
- [VAT in the feed](https://sortyra.com/glossary/vat-in-feed-price-and-rate)
- [Webhook signature (HMAC)](https://sortyra.com/glossary/webhook-signature-hmac)
- [Wholesale](https://sortyra.com/glossary/wholesale-b2b-feed)
- [XLSX](https://sortyra.com/glossary/what-is-an-xlsx-file)
- [XML](https://sortyra.com/glossary/what-is-an-xml-file)
- [XML attribute](https://sortyra.com/glossary/xml-attribute-in-feed)
- [XML element](https://sortyra.com/glossary/xml-element)

A webhook is an automatic message that one system sends to the address of another system the moment something happens – for example when a feed fails to download or a new order arrives. The second system does not have to keep asking whether there is anything new; the information arrives on its own.

**In this article**

1. What is a webhook
2. What it is used for
3. What to watch out for
4. How Sortyra helps
5. Related terms
6. Frequently asked questions

## What is a webhook

Imagine you are waiting for a parcel. You can phone the courier every hour to ask if it is on the way – or the courier can text you when they are outside your house. **A webhook is that text message**, only between two computer systems.

How it works:

1. In the source system you enter the **webhook address** – the URL of your system that receives messages.
2. When an **event** occurs (an error, a price change, a new order), the source system sends a **POST** request with data to that address, usually in [JSON](https://sortyra.com/glossary/what-is-json-format) format.
3. Your system receives the message and does something – creates a task, sends an email, starts a recalculation.

The difference from an [API](https://sortyra.com/glossary/what-is-an-api): with an API **you ask** another system ("what are the prices?"), while a webhook **lets you know by itself** when something changes. They are often used together – a webhook announces the change and you fetch the details through the API.

A shortened example of a message about a source error:

`{ "event": "alert", "alert": { "kind": "source_error", "severity": "error", "message": "The source could not be downloaded or read: Server returned HTTP 404" } }`

## What it is used for

- **Alerts** – a source error, an unpublished output or a price change straight into your own monitoring.
- **Chat and team tools** – Slack, for example, receives messages through a so-called Incoming Webhook.
- **Orders and payments** – a payment gateway or marketplace tells the shop about a new payment or order.
- **Connecting to an ERP** – an internal system learns about a change and downloads the new data itself.

## What to watch out for

- **Verify the sender.** Anyone can call a webhook address; that is why messages are signed with a secret key and the signature must be verified.
- **https only.** Data should travel encrypted.
- **A quick response.** The receiving system should acknowledge the message immediately and do heavier work later, otherwise the sender reports an error.
- **Duplicate messages.** After an outage the same message may arrive again; process it so that this does no harm.
- **A secret key does not belong in code in a public place** or in an email.

## How Sortyra helps

In **Settings** on the **Alerts** tab you add a channel of the **Webhook** type with a **URL (https)**. When an event occurs, Sortyra sends a POST with JSON and a signature in the `X-Sortyra-Signature` header; the signing key is shown only once, when you create it. With the **Send test** button you check that the message arrived.

## Related terms

- [API](https://sortyra.com/glossary/what-is-an-api)
- [JSON](https://sortyra.com/glossary/what-is-json-format)
- [URL](https://sortyra.com/glossary/what-is-a-url)
- [MCP – Model Context Protocol](https://sortyra.com/glossary/what-is-mcp-model-context-protocol)
- [Data export](https://sortyra.com/glossary/what-is-data-export)
- More detail: [Alerts by email, Slack, Telegram, webhook](https://sortyra.com/knowledge-base/feed-alerts-email-slack-telegram-webhook), [REST API](https://sortyra.com/knowledge-base/rest-api-product-feeds)

## Frequently asked questions

### What is the difference between a webhook and an API?

With an API you request data when you need it. A webhook sends it to you by itself when an event occurs.

### Do I need a programmer for a webhook?

To receive and process a message, yes – somebody has to prepare an address that accepts the messages. Ready-made tools such as Slack, however, accept a webhook without programming.

### How do I verify that Sortyra really sent the webhook?

From the timestamp and the body of the message, calculate an HMAC-SHA256 with the signing key and compare it with the `X-Sortyra-Signature` header.

[← Previous article **VAT in the feed**](https://sortyra.com/glossary/vat-in-feed-price-and-rate) [Next article → **Webhook signature (HMAC)**](https://sortyra.com/glossary/webhook-signature-hmac)

## Try it on your own feed

[Try it free](https://app.sortyra.com/registracia?lang=en) [Book a 15-min call](https://sortyra.com/contact)
