worldline Direct
Sign up

Our platform links every webhook to a specific transaction with property payment.id. The full structure of payment.id is

paymentid_operationid

Both elements of this structure have a different purpose to indicate a transaction’s status:

Element Description
paymentid

A unique number referring to your order

This is a fixed identifier that will never change over the course of a transaction life cycle. The latest final maintenance operation (i.e. authorisation/capture/refund) you have performed defines the transaction's current global status of your order.

operationid

A maintenance operation (i.e. authorisation/capture/refund) performed on this paymentid.

Every maintenance operation has an individual operationid. Once you request a new transaction, it will receive a first operationid"0" (i.e. an authorisation or direct sales request).

During a transaction's life cycle, every subsequent maintenance operation receives an incremental operationid. It indicates its order in the transaction life cycle (i.e. "1" for a capture after authorisation and "2" for a refund after that capture).

Every operationidhas its own StatusOutput.statusCode reflecting the outcome of the respective maintenance operation (i.e. an auhorisation request results either in StatusOutput.statusCode=5 or 2.

Mind that an update for waiting/uncertain operationidstatuses (i.e. from 91/92 to 9 or 93) will not result in an additional operationid.
Instead, the existing status related to the operationidis updated to this final status (9 or 93) on the same operationid.

Our webhooks refer only to an online/offline event of a specific maintenance operation - and not on the transaction's global status. Have a look at the following example for transaction with paymentid 3136405348 to understand how webhooks work:

Property payment.id

Maintenance operation/
webhook event

operationid Operationid
statusOutput.statusCode
3136405348_0 You send an authorisiation request via CreatePayment/CreateHostedCheckout

Our platform sends a webhook for online event payment.created
0 5
3136405348_1 You capture this transaction via CapturePayment

Our platform sends a webhook for online event payment.capture_requested
1 91
3136405348_1

Our platform receives the confirmation that the capture has been successful

Our platform updates the original capture request 3136405348_1 to statusOutput.status=9 and sends a webhook for offline event payment.captured

1 9
3136405348_2

You refund this transation via RefundPayment

Our platform sends a webhook for online event refund.refund_requested

2 81
3136405348_2

Our platform receives the confirmation that the refund has been successful

Our platform updates the original capture request 3136405348_2 to statusOutput.status=8 and sends a webhook for offline event payment.refunded

2 8
Use GetPaymentDetails to get a global transaction status

Was this page helpful?

Do you have any comments?

Thank you for your response.