Retrieving Transaction Data
The transaction data retrieval message serves as a valuable tool to retrieve transaction details associated with a specific orderId
. This functionality allows you to access essential information such as bank account details or card details used in the transaction. This feature becomes particularly beneficial when you require comprehensive insights into the payment details for a given order.
Retrieving Transaction Data Request
To retrieve transaction data, make a GET request to the v2_1/orders/{orderId}/transactions
endpoint. In this case, the orderId
should be the specific identifier you received after successfully creating the order.
When making GET requests, please remember not to include any data in the request body, as specified in the RFC 9110 standard. Requests that do not adhere to this requirement will be rejected by PayU with an HTTP 403 status.
curl -X GET https://secure.payu.com/api/v2_1/orders/{orderId}/transactions \
-H "Content-Type: application/json" \
-H "Authorization: Bearer 3e5cac39-7e38-4139-8fd6-30adc06a61bd" \
For details on the request, please refer to Retrieve a Transaction section in PayU API Reference.
Retrieving Transaction Data Response
After a transaction has been processed, card details become available immediately. However, there might be a slight delay for bank details, which can take a few minutes or sometimes until the next business day. The availability of bank details depends on the specific bank's processing time.
- Card
- PBL / Bank Transfer
{
"transactions": [
{
"payMethod": {
"value": "c"
},
"paymentFlow": "FIRST_ONE_CLICK_CARD",
"validUntil": "2024-06-20T09:05:44.238+02:00",
"card": {
"cardData": {
"cardNumberMasked": "543402******4014",
"cardScheme": "MC",
"cardProfile": "CONSUMER",
"cardClassification": "DEBIT",
"cardResponseCode": "000",
"cardResponseCodeDesc": "000 - OK",
"cardEciCode": "2",
"card3DsStatus": "Y",
"card3DsStatusDescription": "MessageVersion=2.1.0,browser flow,3DS method not available,dynamic authentication,no cancel indicator,no status reason",
"cardBinCountry": "PL",
"firstTransactionId": "MCC0111LL1121"
}
}
}
]
}
For the paymentFlow
parameter set to APPLE_PAY, GOOGLE_PAY_TOKENIZED, or CLICK_TO_PAY, the cardNumberMasked
parameter value is a token that replaces the actual card number.
{
"transactions": [
{
"payMethod": {
"value": "m"
},
"paymentFlow": "PBL",
"bankAccount": {
"number": "80607787095718703296721164",
"name": "JAN KOWALSKI",
// depending on the bank, the name and address may be all included in any of below fields
"city": "WARSZAWA",
"postalCode": "02-638",
"street": "UL.NOWOWIEJSKIEGO 8",
"address": "Warszawa Nowowiejskiego 8"
}
}
]
}
For details on some of the parameters in the cardData
section included in the response, please refer to the 3DS Details in Transaction Data section.
And for details on the parameters, please refer to Retreive a Transaction section in our API reference.
paymentFlow Parameter Values
Below is a table with the values of the paymentFlow
parameter that can occur in the response when retrieving transaction data. This parameter specifies the type of payment that was made:
Value | Description |
---|---|
FIRST_ONE_CLICK_CARD | One Click card transaction that saves the card for future use (for CIT/MIT/recurring transactions). |
ONE_CLICK_CARD | One Click card transaction (CIT/MIT/recurring). |
ONE_CLICK_CARD_RECURRING | Recurring One Click card transaction. |
ONE_CLICK_MAIL_ORDER | One Click mail order transaction. |
ONE_CLICK_PHONE_ORDER | One Click phone order transaction. |
ONE_CLICK_MAIL_RECURRING | Recurring One Click mail order transaction. |
ONE_CLICK_PHONE_RECURRING | Recurring One Click phone order transaction. |
PEX_BANK | PEX Bank (like PBL for some specific banks). |
PBL | Pay-by-link transaction. |
CARD | Standard card transaction. |
CARD_INSTALLMENTS | Installment card order. |
GOOGLE_PAY | Google Pay order. |
GOOGLE_PAY_TOKENIZED | Google Pay Tokenized order. |
APPLE_PAY | Apple Pay order. |
CLICK_TO_PAY | Click to Pay order. |
VISA_MOBILE | Visa Mobile order. |
BLIK_PBL | BLIK transaction. |
BLIK_AUTHORIZATION_CODE | BLIK transaction with authorization code. |
BBLIK_AUTHORIZATION_CODE_WITH_UID_TOKEN_REGISTERING | BLIK transaction with UID token registration. |
BLIK_UID_TOKEN | BLIK transaction with saved UID token. |
BLIK_AUTHORIZATION_CODE_WITH_PAYID_TOKEN_TYPE_O_REGISTERING | Recurring BLIK transaction with PAYID token registration. |
BLIK_PAYID_TOKEN_TYPE_O | Recurring BLIK transaction with saved PAYID token. |