Skip to content

About

PawaPay Webhook Proxy is a lightweight, standalone PHP application designed to centralize PawaPay webhooks and route them dynamically to multiple WordPress / WooCommerce websites.

Topics

Resources

Stars

3 stars

Watchers

0 watching

Forks

Latest commit

 

History

6 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 

Repository files navigation

PawaPay Webhook Proxy

Centralized Webhook Router for Multi-Site WooCommerce Integrations

Overview

PawaPay Webhook Proxy is a lightweight, standalone PHP application designed to centralize PawaPay webhooks and route them dynamically to multiple WordPress / WooCommerce websites.

Since PawaPay allows configuring only one webhook URL for deposits and refunds, this proxy acts as an intelligent router, forwarding each webhook to the correct site based on a unique platform signature (platform_signature) sent in the payment metadata.

This solution is ideal for agencies, SaaS platforms, plugin vendors, and developers managing multiple WooCommerce stores.


How It Works

  1. PawaPay sends all webhooks to a single endpoint
  2. The proxy:
    • reads the raw JSON payload
    • extracts platform_signature
    • identifies the target website
  3. The webhook is forwarded unchanged to the correct WordPress REST endpoint
  4. The proxy responds with 200 OK to PawaPay

No additional configuration is required on the PawaPay side once set.


Compatibility


Project Structure

pawapay-webhook-proxy/ ├── pawapay.php # Main webhook endpoint ├── config.php # platform_signature → site URL mapping ├── logs/ │ └── webhook.log # Event logs └── README.md


⚙️ Installation

Hosting

Upload the files to a publicly accessible server, for example: https://webhooks.example.com/pawapay.php


Configure Sites

Edit config.php:

<?php

return [
    'store-signature-1' => 'https://site1.com',
    'store-signature-2' => 'https://site2.com',
];

Each key must match the Unique Signature configured in the WooCommerce PawaPay plugin.

WooCommerce Plugin Configuration

In WooCommerce → Payments → PawaPay:

Set Unique Webhook Identifier

Use a unique value per site

Example: store-signature-1

This value is automatically sent to PawaPay in the payment metadata.

PawaPay Dashboard Setup

In the PawaPay dashboard, configure:

  • Deposit Webhook URL: https://webhooks.example.com/pawapay.php
  • Refund Webhook URL: https://webhooks.example.com/pawapay.php

One endpoint handles all sites.

Supported Webhooks

  • ✅ Deposit (payments)

  • ✅ Refunds

Security (Recommended)

All webhook events are logged in: /logs/webhook.log

About

PawaPay Webhook Proxy is a lightweight, standalone PHP application designed to centralize PawaPay webhooks and route them dynamically to multiple WordPress / WooCommerce websites.

Topics

Resources

Stars

3 stars

Watchers

0 watching

Forks

Releases

Contributors

Languages