Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

In this section, you will find everything you need to manage the various entry points that your application will receive during and after an dit gedeelte vind je alles wat je nodig hebt om de verschillende instappunten te beheren die je applicatie ontvangt tijdens en na een Axepta BNP Paribas Online payment-betaling.

You will learn:

  • Which URLs to transmit when creating a payment,
  • The order in which they are called,
  • How to interpret the returned information,
  • How to verify the actual status of a transaction,
  • How to manage the webhook.

Je leert:
- Welke URL's je moet doorgeven bij het aanmaken van een betaling,
- De volgorde waarin ze worden aangeroepen,
- Hoe je de geretourneerde informatie moet interpreteren,
- Hoe je de daadwerkelijke status van een transactie kunt verifiëren,
- Hoe je de webhook beheert.


InhoudstafelTable of Contents

Table of Contents


1.

Provide

URLs doorgeven: return, cancel, webhook

When initializing the payment, you must provide a URLs object:Bij het initialiseren van de betaling moet u een URLs-object opgeven.

Code Block
titleExample of a return URL
linenumberstrue
	urls{
		"return":"https://myProcessingServer.net/myApi/success.php?transId=95330876-67ae-4949-a11c-b9a29257831b",
		"cancel":"https://myProcessingServer.net/myApi/cancel.php?transId=95330876-67ae-4949-a11c-b9a29257831b",
 		"webhook":"https://myBackOfficeServer.net/webhook.php"
	}


Info
  • Return = redirection when the customer clicks the confirmation button at the end of the payment process.

  • Cancel = redirection if the customer cancels the payment.

  • doorverwijzing wanneer de klant op de bevestigingsknop klikt aan het einde van het betaalproces

  • Cancel = doorverwijzing als de klant de betaling annuleert.

  • Webhook = asynchrone en gegarandeerde melding, onafhankelijk van de actie van de klantWebhook = asynchronous and guaranteed notification, independent of the customer’s action.


2. Return URL & Cancel URL

One of these two URLs

Een van deze twee URL's (return

or cancel) will be called at the end of the transaction processing in order to:
  • Redirect the customer back to the merchant website at the end of the transaction
  • Inform the merchant of the transaction status: (successful or not)
  • Return to the merchant’s back-office the unique transaction identifier payId generated by Axepta Online

When one of these URLs is called, Axepta BNP Paribas Online automatically appends the following parameter : PayId=<paymentId generated by Axepta> - see Integration recommendation

of cancel) wordt aangeroepen aan het einde van de transactieverwerking om:

  • De klant terug te sturen naar de website van de handelaar,
  • De handelaar te informeren over de transactiestatus (geslaagd of niet),
  • Het unieke transactie-ID (payId) door te geven aan het back-officesysteem van de handelaar.

Axepta BNP Paribas Online voegt automatisch de volgende parameter toe: zie Integratieaanbevelingen


Tip

Belangrijk: Voeg uw eigen identifier (bijv. transId) toe aan de URL's om de retouroproep te koppelen aan uw interne bestelling.

Voorbeeld van een URL die wordt geactiveerd na betalingsbevestiging door de klant:

  • In groen, door u opgegeven URL met transId.
  • In rood, door Axepta BNP Paribas Online toegevoegde PayId
Tip

You should include your own identifier in the URLs to link the return call to your internal order.

Example of a URL triggered after customer payment validation:

  • In green, the URL provided during payment initialization, including a transId to link the return to a merchant ID.
  • In red, the PayId parameter added by the server.


https://myProcessingServer.net/myApi/success.php?transId=95330876-67ae-4949-a11c-b9a29257831b&PayId=b6eae9b16e3343fa90da39d4ee7bf4ad 

What to Do When You Receiving This Call?


Wat te doen bij ontvangst van deze oproep?

  1. Haal de PayId-parameter op.
  2. Roep de API aan om de daadwerkelijke transactiestatus op te halen

When one of these URLs is triggered:

  1. Retrieve the PayId parameter.

  2. Call the API to get the actual transaction status
  3. : GET /payments/getByPayId/{payId}
  4. - 
  5. –  Retrieve payment details by Payment ID
  6. Update your order based on the status and
  7. Werk de bestelling bij op basis van de status en responseCode.


Key fields Belangrijke velden in the API Responsede API-respons:

VeldBeschrijving
Amount
:
value, capturedValue, refundedValue
Identifiers
:
payId, transId, xId, refNr
Status
: status =
AUTHORIZED, CAPTURE_REQUEST, OK, FAILED, etc.
Result:
ResultaatresponseCode = "00000000"
OR
 of "0"
indicates success
 duidt op succes.

responseDescription =
textual message
tekstuele beschrijving.


Info

A successful transaction may return either Let op: Een geslaagde transactie kan zowel "00000000" or als "0" depending on the payment stage or method.

You must check both values to determine success, "00000000" OR "0"

retourneren, afhankelijk van de betaalfase of -methode.

Controleer altijd beide waarden om succes te bevestigen.



Voorbeelden van samengevatte responsen:Examples of summarized responses

Code Block
languagejson
titlegetByPayId response for a card transaction in AUTHORIZED status
linenumberstrue
 {
	"amount":{
		"value":126,
		"currency":"EUR",
		"capturedValue":0,
		"refundedValue":0
	},
	"payId":"91a6299a704147bf934aabd79fd1dc5d",
	"merchantId":"MY_MERCHANT_ID",
	"transId":"Trans361039",
	"xId":"b55e68b7e4644a90836ae31effe1fc60",
	"refNr":"refNb77254",
	"status":"AUTHORIZED",
	"responseCode":"00000000",
	"responseDescription":"Transaction successful",
	"paymentMethods":{
		"type":"CARD"
	}
}


Code Block
languagejson
titlegetByPayId response for a card transaction in a CAPTURE_REQUEST status
linenumberstrue
 {
	"amount":{
		"value":1200,
		"currency":"EUR",
		"capturedValue":0,
		"refundedValue":0
	},
	"payId":"09526745fa704e9c8584dbe893c31f99",
	"merchantId":"MY_MERCHANT_ID",
	"transId":"1230861007",
	"xId":"2781d7d379e5449e9717c901ba6f9ff7",
	"refNr":"Q1ovVxioaZ6n",
	"status":"CAPTURE_REQUEST",
	"responseCode":"0",
	"responseDescription":"REQUEST",
	"paymentMethods":{
		"type":"CARD"
	}
}


3. Webhook


At the end of transaction processing, Aan het einde van de transactieverwerking meldt Axepta BNP Paribas Online notifies the merchant website of the final transaction result.

The webhook notification is the only reliable way to be informed of transaction completion.

It is mandatory for the merchant system to process webhook calls.

It is sent via an HTTP REST call to the webhook URL provided during payment initialization.

It is sent even if the customer:

  • Closes their browser,
  • Loses connection,
  • Does not return to your website.

When is it sent?

 het definitieve transactieresultaat aan de website van de handelaar. De webhook-melding is de enige betrouwbare manier om op de hoogte te worden gebracht van de voltooiing van een transactie. Verplicht voor handelaren: verwerk webhook-oproepen in uw systeem.

  • Verzonden via een HTTP REST-oproep naar de webhook-URL die u bij de betalingsinitialisatie hebt opgegeven.
  • Wordt verzonden, zelfs als de klant:
    • De browser sluit,
    • De verbinding verliest,
    • Niet terugkeert naar uw website.


Wanneer wordt de webhook verzonden?

Na elke asynchrone verwerking van een betaling. Als het eindpunt niet beschikbaar is, wordt de melding tot 8 keer opnieuw verzonden:


PogingVertraging (uur:min)Totaal (uur:min)

After each asynchronous payment processing completion

If the endpoint is unavailable, the notification is retried up to 8 times

Time after 1st notification

Attempt

Delay

0

Instantaneous

0

1

00:01 h

00:01 h

2

00:08 h

00:09 h

3

00:27 h

00:36 h

4

01:04 h

01:40 h

5

02:05 h

03:45 h

6

03:36 h

07:21 h

7

05:43 h

13:04 h

8

08:32 h

21:36 h

What you must do

  1. Read the JSON payload
  2. Identify the transaction using payId or transId
  3. Update your system accordingly
  4. Respond with HTTP 200 OK
Tip

Important: Never finalize an order based solely on the Return URL.

Always rely on the webhook as the source of truth.

Wat moet u doen?

  1. Lees de JSON-payload.
  2. Identificeer de transactie met payId of transId.
  3. Werk uw systeem bij.
  4. Reageer met HTTP 200 OK.
Tip

Finaliseer een bestelling nooit alleen op basis van de Return-URL.
Vertrouw altijd op de webhook als bron van waarheid.



Webhook Structuur

Meegestuurde velden:

Webhook Structure

Provided Fields

  • merchantId
  • payId
  • transId
  • xId
  • refNr
  • status (AUTHORIZED, FAILED, etc.)
  • responseCode / responseDescription
  • amount
  • paymentMethods
  • creationDate (UTC)
  • channel (ECOM, MOTO, Pay By Link…)


ExampleVoorbeeld

Code Block
languagejson
titlewebhook payload
linenumberstrue
{
    "merchantId": "YOUR_MERCHANT_ID",
    "payId": "91a6299a704147bf934aabd79fd1dc5d",
    "transId": "Trans361039",
    "xid": "b55e68b7e4644a90836ae31effe1fc60",
    "refNr": "refNb77254",
    "status": "AUTHORIZED",
    "responseCode": "00000000",
    "responseDescription": "Transaction successful",
    "amount": {
        "value": 126,
        "currency": "EUR"
    },
    "paymentMethods": {
        "type": "CARD"
    },
    "creationDate": "2025-10-30T11:27:57Z",
    "channel": "ECOM"
}

Security and Verification



Beveiliging en verificatie

Om de authenticiteit van webhookgegevens te garanderen, worden payloads ondertekend met To ensure the authenticity of webhook data, payloads are signed using HMAC-SHA256. 

De handtekening wordt meegestuurd in drie HTTP-headers:The signature is included in three HTTP headers within the webhook message.

Signature headers

Version of the signature format (currently, epoch timestamp (seconds since Signature in the format &lt;hex-hmac&gt;
Multiple signatures can be supported to manage key renewal (e.g. v1=&lt;hmac1&gt;,v2=&lt;hmac2&gt;)
X-Paygate-Signature-VersionVersie van het handtekeningformaat (momentaneel v1).
X-Paygate-TimestampUnix-tijdstempel (seconden sinds 1970-01-01T00:00:00Z, UTC).
X-Paygate-SignatureHandtekening in het formaat v1=<hex-hmac>.


Signature Generation (Axepta BNP-Paribas Online)

signed_payload = timestamp + "." + raw_json_body
signature = HMAC_SHA256(secret, signed_payload)
  • secret – HMAC key
  • The generated Signature is encoded 'hex' and the header is set as followsDe gegenereerde handtekening wordt hex-gencodeerd en als header meegegeven:
X-Paygate-Signature: v1=<hex-hmac>


Signature Verification (Merchant)

To verify the authenticity of the webhook message data:

    Extract the data carried by the HTTP
  1. Extraheer de headers:
    • X-Paygate-Timestamp
    • X-Paygate-Signature
  2. Retrieve the
  3. Haalt de raw JSON-payload op (
  4. exact binary
  5. exacte binaire body).
  6. Compute the HMAC using the extracted data
  7. Bereken de HMAC:
    • signed_payload = timestamp + "." + raw_
  8. body                                                                                                           
    • body
    • expected_signature = HMAC_SHA256(secret, signed_payload)
  9. Compare the calculated signature with the received signature using a
  10. Vergelijk de handtekeningen met een "constant-time"
  11. method
  12. -methode.
  13. Validate the
  14. Valideer de webhook
  15. if
  16. als:
    • The signatures are identical
    • The Timestamp is within ±5 minutes of your local clock.
      • De handtekeningen identiek zijn,
      • Het tijdstempel binnen ±5 minuten van uw lokale klok valt.


Voorbeeld van authenticiteitsverificatie:

Webhook authenticity verification example:

Merchant Id used :
  • Handelaars-ID: 
  • BNP_DEMO_MID
Merchant Id
  • HMAC
Key : see Sandbox & Test page Transaction done the 19th of May, 2026, at 09h23m20sec Paris time (
  • -sleutel: zie Sandbox & Testpagina.
  • Transactiedatum: 19 mei 2026, 09:23:20 (Parijse tijd, GMT+2).


Code Block
titleWebhook received
collapsetrue
Headers
{
	"Accept-Encoding": "gzip",
	"Content-Length": 381,
	"Content-Type": "application/json",
	"Expect": "100-continue",
	"X-Forwarded-Host": "bin.webhookrelay.com",
	"X-Forwarded-Proto": "https",
	"X-Paygate-Signature": "v1=DF1F4AA6022460A9821832F9B89DF82D92D01B35C80DDDF596E97FF26E0ABB14",
	"X-Paygate-Signature-Version": "v1",
	"X-Paygate-Timestamp": "1779175402",
	"X-Real-Ip": "213.155.65.68"
}

Body
{
	"merchantId": "BNP_DEMO_MID",
	"payId": "413cef3ff4fd4b08af2245d5a889dbaa",
	"transId": "Trans293156",
	"xid": "7919a1e81571466ca8f5737d5414f7a4",
	"refNr": "refNb81210",
	"status": "FAILED",
	"responseCode": "22940040",
	"responseDescription": "NO RESPONSE",
	"amount": {
		"value": 460,
		"currency": "EUR"},
	"paymentMethods": {
		"type": "CARD"},
	"creationDate": "2026-05-19T07:23:20Z",
	"channel": "ECOM"
}



Webhook ValidationVerificatie:

Is the signature version equal to v1v1

Is the Timestamp is within

±5 minutes of your local clock Are the signatures identical Unix epoch time: 1779175402
Converted to GMT = 07h23m22sec
It's between 5 min of transaction date&time
(2 sec exactly)DF1F4AA6022460A9821832F9B89DF82D92D01B35C80DDDF596E97FF26E0ABB14 
(see below)
ControlepuntHeader/waardeResultaat
Is de handtekeningsversie v1?
CheckParameter usedValueResult
X-Paygate-Signature-Version
CORRECT
Valideert het tijdstempel (±5 min)?X-Paygate-Timestamp
: 1779175402CORRECT
Komen de handtekeningen overeen?X-Paygate-Signature
CORRECT

BerekeningSignature verification:

1779175402.{"merchantId": "BNP_DEMO_MID","payId": "413cef3ff4fd4b08af2245d5a889dbaa","transId": "Trans293156","xid": "7919a1e81571466ca8f5737d5414f7a4","refNr": "refNb81210","status": "FAILED","responseCode": "22940040","responseDescription": "NO RESPONSE","amount": {"value": 460,"currency": "EUR"},"paymentMethods": {"type": "CARD"},"creationDate": "2026-05-19T07:23:20Z","channel": "ECOM"}

Computed HMAC-SHA256 with previous value as input, using
  • Data
used for signature: <epoch timestamp value>.<full webhook json body>
Value:
  • voor handtekening: 1779175402.<volle JSON-body>
  • Verwachte HMAC-SHA256 (met sleutel 
  • 6Gp_A!8f)3zZ9K]gb7S?2*tN(yH54[wB
key
  • ): 
  • df1f4aa6022460a9821832f9b89df82d92d01b35c80dddf596e97ff26e0abb14

Nota: signature verification should be done without case sensitivity


Integration

Best Pratices voor Integratie

Tip
  • Verifieer de transactie altijd via het getByPayId-eindpunt, zelfs als de front-end "succes" meldt.
  • Verwerk altijd webhook-meldingen.
  • Valideer de authenticiteit van webhookgegevens door de handtekening te controleren.
  • Log alle
  • Always verify the transaction via the getByPayId endpoint, even if the front-end return indicates success,
  • Always process the webhook notifications.
  • Always verify webhook data authenticity by validating the signature.
  • Log all
  • return/cancel/webhook
  • calls
  • -oproepen voor auditing.