This transaction type is available for: Cards and BLIK.
The purpose of this operation is to refund the amount of a previous payment, crediting the cardholder account and debiting the Merchant account.
A refund is performed against a previous payment, referencing its transactionID by sending a POST request over HTTPS to the /payments/{transactionID}/refund endpoint.
A refund can be performed:
- against purchase (PURS),
- against captured preauthorisation (AUTH -> Capture),
and it can be:
- a full refund when the total amount of the purchase is refunded to the cardholder,
- a partial refund when a subtotal of the total purchase is refunded to the cardholder.
Generate the transaction:
POST https://stargate-cer.qly.site1.sibs.pt/api/v1/payments/{transactionID}/refund
Header parameters
Authorization
Mandatory
Bearer Token. Based on OAuth2 authentication performed in a pre-step.
Show more
x-ibm-client-id
Mandatory
Token that identifies a client organization. It is provided during onboarding process and must be used in every call.
Show more
Request parameters
merchant
Mandatory
An optional element to query transaction status.
Show more
terminalID
numeric [<= 10 characters]
Mandatory
Merchant Terminal Identification.
Show more
channel
Mandatory
Merchant channel, Possible Value “Web”.
Show more
merchantTransactionID
Mandatory
Unique Id used by the Merchant.
Show more
transaction
Mandatory
An optional element to query transaction status.
Show more
description
Mandatory
Transaction short description.
Show more
amount
Mandatory
Parameter with the value and currency of the transaction.
Show more
value
Mandatory
Amount in the transaction.
Show more
currency
Currency Code
SO 4217 Alpha-3 Code
Mandatory
Show more
originalTransaction
Mandatory
Parameter with the original transaction.
Show more
Id
Mandatory
Unique identifier of the original transaction.
Show more
date time
Mandatory
Timestamp of the original transaction.
Show more
Here’s an example:
Request Header:
Autorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCIgOiAiSldUIiwia2lkIiA6I (...)
X-IBM-Client-Id: b4480347-9fc8-4790-b359-100a99c60ea3
Content-Type: application/json
{
"merchant": {
"terminalId": 24,
"channel": "web",
"merchantTransactionId": "BO_Order Id: c9876bcasd"
},
"transaction": {
"transactionTimestamp": "2022-05-29T18:23:41.367Z",
"description": "This is a refund request",
"amount": {
"value": 10,
"currency": "PLN"
},
"originalTransaction": {
"id": "mvuy3dh3wucpsi4389fh",
"datetime": "2022-05-29T17:23:36.105Z"
}
}
}
For BLIK refund operations only
Upon completing the refund operation, you should receive a a pending paymentStatus.
To obtain the latest update, it is necessary to subsequently perform a “Get Status” operation.
The Authorization HTTP header is set to the Bearer token as it was used in the initial Checkout.