Skip to main content
Learn how to use Localpayment webhooks so you can receive real-time notifications for every payment event. This guide helps you validate signatures, process webhook data, and keep your integration in sync. We use webhooks to notify your application about events that occur in your account. They’re especially useful for asynchronous updates, such as when a payment is confirmed, a payout is processed, or a subscription status changes.

Overview

Webhooks provide real-time notifications about transaction status changes and other important events in your Localpayment account. Instead of polling our API for status updates, you can configure webhook endpoints to receive instant notifications when events occur.

Real-time Updates

Receive instant notifications when transaction status changes

Multiple Events

Support for payins, payouts, virtual accounts, subscriptions and more

Secure Delivery

HMAC signature verification ensures webhook authenticity

How Webhooks Work

  1. Event Occurs: A transaction status changes in Localpayment’s system
  2. Send Webhook: Localpayment sends a JSON payload to your webhook endpoint
  3. Signature Verification: Your endpoint verifies the request using the x-Signature header
  4. Return 200 OK: Your endpoint returns a 200 OK response
  5. Process Event: Your application handles the webhook data asynchronously
The Content-Type header on outgoing webhook requests is text/plain; charset=utf-8, not application/json. The request body is still a valid JSON payload. Parse it as JSON regardless of the Content-Type header value.

Prerequisites

Before setting up webhooks, ensure you have:

Account Setup

Proper account setup for your target country and business verification.

Secret Key

Your webhook secret key from the Localpayment Business Portal.

Configuration

Business Portal Setup

  1. Navigate to Configurations → Clients in your Localpayment Business Portal.
  2. Select the client you want to configure.
  3. Click on the Notifications tab and choose the webhook type to configure.
  4. Click the Add button and enter the following information:

Security & Authentication

Localpayment signs all webhook requests with an HMAC signature to verify their authenticity.

Signature Verification

Each webhook request includes an x-Signature header. The value is formatted as the algorithm name followed by a space and the hex-encoded HMAC-SHA256 signature:
To verify the signature, compute the HMAC-SHA256 hash of the raw request body using your webhook secret key, then compare it against the hash portion of the header — the part after HMAC-SHA256 .
Strip the HMAC-SHA256 prefix from the header value before comparing. Comparing the full header string against the computed hash will always fail.

Example Implementation


Webhook Payloads

All webhook payloads share a common structure with event-specific data in the data object. This consistent format makes it easier to parse and handle webhooks across different event types.

Common Webhook Structure

The following fields are always present in every webhook payload, regardless of the event type:
transactionType appears twice by design. The root-level field acts as a routing key for your webhook handler. The field is repeated inside the data object to make each payload self-contained — useful when storing or forwarding events individually. Both values will always be identical.
fxSource type. The fxSource field is always a float. It represents the exchange rate used for the fee or tax calculation. When no FX conversion applies (same-currency transactions), the value is 0 or 0.0.

Payin Events

Card Payments (Credit/Debit)

Approved
Chargeback
Completed
Refunded
Rejected

Bank Transfer Master Account

Subscriptions


Payout Events


Virtual Account Events

Virtual Account Creation

Upon successfully creating a Virtual Account, Localpayment will send a POST request to your configured callback URL. This notification confirms the account details are active and ready to receive payments.

Payment received (payin)

Whenever a customer completes a payment to a Virtual Account, Localpayment sends a webhook notification to your registered endpoint. All payin notifications follow the same structure and contain the same information—regardless of the timing or amount of the payment. These include key fields such as amount, currency, status, and transaction reference, allowing you to automate reconciliation and update internal systems accordingly.

Currency Exchange Events

The following fields are specific to Currency Exchange webhook events:
Completed

Settlement Events

Wire In

Completed

Wire Out

Completed

Wire Out (crypto)

When a Wire Out is paid in a supported cryptocurrency (for example USDT or USDC), the completed callback also includes a hash field with the blockchain transaction hash, so you can verify the payment independently in a block explorer. This field is not present for fiat Wire Out payloads.
Completed (crypto)

Field Reference

Understanding the detailed fields in the webhook payload is essential for correct reconciliation and settlement.
Last modified on November 22, 2026