Skip to main content
Webhooks are how Taliup notifies your server when a payment outcome is available. After a payment is captured — whether approved or declined — Taliup sends an HTTP POST request to the webhook_url you provided when creating the checkout session. The request body contains a JSON payload describing the event, and the X-Taliup-Signature header lets you verify that the request genuinely came from Taliup.

Webhook payload

Every webhook Taliup sends has the following JSON structure:

Signature verification

Every request from Taliup includes an X-Taliup-Signature header with the value:
You must verify this signature using the raw request body — before it is parsed or decoded. Verifying the signature confirms that the webhook came from Taliup and that the payload has not been tampered with in transit.
Always verify the X-Taliup-Signature before processing a webhook event or fulfilling an order. Processing unverified webhooks can expose your application to spoofed payment notifications.

Verification methods

The SDK provides two ways to verify a webhook:

Complete webhook receiver example

Respond with HTTP 200 as quickly as possible. If your webhook endpoint takes too long to respond, Taliup may retry the delivery. Perform any heavy processing (e.g. sending a confirmation email) asynchronously after acknowledging the webhook.

Status values

The status field in the webhook payload indicates the payment outcome:

Idempotency

Taliup may deliver the same webhook more than once in rare retry scenarios. Use the transaction_id field as an idempotency key — check whether you have already processed a transaction with that ID before taking action, and skip duplicate deliveries.
Store the transaction_id in your database when you fulfil an order. Before processing any webhook, query for an existing record with that transaction_id and skip the event if one is found.