Webhook

The Digitalpaye Webhook (or callback) allows you to receive real-time notifications about transactions made through your platform. When a transaction is completed successfully or encounters an error, Digitalpaye sends a notification to the URL you have configured as the webhook.

Webhook URL

You must provide a receiving URL for the webhook so that Digitalpaye can send transaction notifications. Make sure this URL is publicly accessible from the Internet.

Webhook URL example:

https://your-domain.com/webhook

Notification Format (Payload)

The webhook sends data in JSON format containing the transaction details. Here is an example of the data format you will receive:

{
        "ref": "6AY5E5GS2F",
        "transactionId": "b553d176-9152-4537-a536-4ad320ec773c",
        "currency": "XOF",
        "amount": "25000",
        "fees": "250",
        "amountReceive": "25000",
        "amountTotal": "25250",
        "phone": "0777101308",
        "status": "SUCCESSFUL",
        "typeTransaction": "transfer",
        "operator": "ORANGE_MONEY_CI",
        "createdAt": "2025-04-03T22:03:50.000Z",
        "customer": {
            "id": "26b35534-3165-4143-8fff-ec2f70bb430c",
            "lastName": "GUEI",
            "firstName": "HELIE",
            "email": "[email protected]",
            "phoneNumber": "0777101308",
            "address": {
                "countryCode": "CI",
                "city": "Abidjan",
                "streetAddress": "Plateau Cocody"
            },
            "createdAt": "2024-10-11T07:07:59.000Z"
        }
}

Using the Webhook

To use the Digitalpaye webhook, configure the receiving URL in your Digitalpaye account. Once configured, Digitalpaye will automatically send transaction notifications to that URL in real time.

To process these notifications, you can create a script or an endpoint on your web server to receive the JSON data and perform the necessary actions based on the status and details of the received transaction.

Last updated