Get payment event log
You can see history of the payment events with the
GET:/epayment/v1/payments/{reference}/events
.
This will return a list of all events for a given payment.
This is the authoritative data for all details and operations for a payment.
Example request:
curl -X GET https://apitest.vipps.no/epayment/v1/payments/UNIQUE-PAYMENT-REFERENCE/events \
-H "Content-Type: application/json" \
-H "Authorization: Bearer YOUR-ACCESS-TOKEN" \
-H "Ocp-Apim-Subscription-Key: YOUR-SUBSCRIPTION-KEY" \
-H "Merchant-Serial-Number: YOUR-MSN" \
-H "Vipps-System-Name: acme" \
-H "Vipps-System-Version: 3.1.2" \
-H "Vipps-System-Plugin-Name: acme-webshop" \
-H "Vipps-System-Plugin-Version: 4.5.6"
Response example:
An example response would look like this:
[
{ // Create Payment example event
"reference": "acme-shop-123-order123abc",
"pspReference": "83b3fdb0-9547-4ec5-bdb7-5600ce70e792",
"name": "CREATED",
"amount": {
"currency": "NOK",
"value": 49900
},
"timestamp": "2023-03-27T10:51:44.5333258Z",
"idempotencyKey": "19986263-dedf-4b8e-a424-8d042eee4013",
"success": true
},
{ // Payment authorized example event
"reference": "acme-shop-123-order123abc",
"pspReference": "1304787731",
"name": "AUTHORIZED",
"amount": {
"currency": "NOK",
"value": 49900
},
"timestamp": "2023-03-27T10:51:59.378Z",
"idempotencyKey": "19986263-dedf-4b8e-a424-8d042eee4013",
"success": true
},
{ // Captured Payment example event
"reference": "acme-shop-123-order123abc",
"pspReference": "2018200034",
"name": "CAPTURED",
"amount": {
"currency": "NOK",
"value": 10000
},
"timestamp": "2023-03-27T10:52:07.748Z",
"idempotencyKey": "19986263-dedf-4b8e-a424-8d042eee4013",
"success": true
},
{ // Cancelled Payment example event
"reference": "acme-shop-123-order123abc",
"pspReference": "2019200034",
"name": "CANCELLED",
"amount": {
"currency": "NOK",
"value": 750
},
"timestamp": "2023-03-27T10:52:15.616Z",
"success": true
}
]
Response schema:
Note that the response is not identical across all operations.
For example, the Cancel operation does not supply a value for idempotencyKey
.
Polling guidelinesโ
We have added rate limiting to our APIs to increase the stability and security of our APIs. Please see: