Skip to main content

Webhooks

A Lochting platform integrator can utilize webhooks to streamline processes. Webhooks are automated notifications that enable real-time data exchange between the platform and external systems, enhancing integration and enabling seamless communication.

When a webhooks gets triggered, the platform will send a POST request to the configured URL. The request will contain a JSON payload with the data that is relevant for the event that triggered the webhook.

An example of a JSON webhook call payload:

{
"id": "order-76db8ac0-2d3a-45fc-956a-da4525361492",
"webhookId": "webhook-be3768e4-8caf-43b6-bb66-32c8cb00cede",
"webhookType": "orderStatusWasUpdated",
"on": "2020-02-25 10:20:30"
}

For debugging purposes you can use the Test Webhook endpoint to trigger a webhook.

For increased security, the webhook payload can be signed with a secret. The secret is an optional string that can be unique for each webhook. When configured, the secret is send with every webhook call. The secret is added to the request headers as X-Webhook-Secret.