Payment or Preauthorization
Description of the Direct Sale Process (sale)
The direct sale process in a payment gateway is a flow that enables merchants to process transactions for the purchase of goods or services immediately, without the need for preauthorizations or additional confirmation steps.
Important Notes
- This process is suitable for transactions where no waiting period or additional confirmation is necessary before completing the purchase.
Description of the Preauthorization and Capture Process (preauth)
The preauthorization and capture flow in a payment gateway is a process that allows merchants to obtain approval for a transaction but postpones the actual capture of funds until a later time. This is useful in situations where it is necessary to confirm the validity of a credit card and the availability of funds before completing the transaction.
Important Notes
- The waiting period between preauthorization and capture varies by issuer and may be subject to specific time limits.
- Preauthorization allows the merchant to ensure that funds are available before fully committing to the transaction.
- This flow is commonly used in industries such as hospitality or car rentals, where ensuring fund availability before a client’s arrival is essential.
Description of the 3DS Transaction Process
A 3DS (3D Secure) transaction is an online transaction that uses the 3D Secure security protocol to authenticate the identity of a credit or debit cardholder during a purchase on a website or application. This protocol adds an extra layer of security to the online payment process and is designed to reduce the risk of card fraud. During a 3DS transaction, cardholders are prompted to authenticate themselves with an additional verification step, such as entering a one-time password, a code sent via SMS, or biometric data, depending on the specific implementation by the card issuer.
Important Notes
- A more detailed description of how to perform authentication on our platform can be found in the section "3DS Authentication."
- The terminal must have the option to send 3DS authentication parameters enabled. For more information, please contact support.
This endpoint receives the transaction data for payment/preauthorization and returns the result.
Method: post
URL:http://{environment-domain}/api/v1/make-payment
HTTP Headers:Content-Type: application/json
Add authentication headers.
Example:
{
"transactionType": "sale",
"merchantId": "3ae25846-d5fe-40cc-a311-eb2de5174c29",
"terminalId": "3ae25846-d5fe-40cc-a311-eb2de5174c29",
"order": {
"merchantOrderId": "9a6ecf36-8265-11ee-b962-0242ac120002",
"amount": "100.00",
"currency": "484"
},
"card": {
"cardNumber": "4111111111111111",
"expiryMonth": "01",
"expiryYear": "2025",
"cvv2": "123",
"holderName": "Clark Parker",
"email": "[email protected]"
},
"recurringPayment": {
"saveCardOnfile": true
},
"installments": {
"initialDiferement": 0,
"numberInstallments": 0,
"planType": "0"
},
"threeDsAutentication": {
"eci": "05",
"cavv": "AAUBAAAHCQAAAAAAAAAAAQAAAAA=",
"ucaf": null,
"xid": "AAUBAAAHCQAAAAAAAAAAAQAAAAA=",
"version": "2.2.0",
"dsTransactionId": "01e4de9c-4d4a-4f0a-bfc3-6cd3ae780446",
"protocolType": "6"
}
}
Field Description
Field | Description | Note |
---|---|---|
transactionType | Indicates the transaction type. In this case, it must be "sale" or "preauth". | |
merchantId | Unique identifier for the merchant on the payment gateway, assigned when the account is created. | |
terminalId | Unique identifier for the terminal, assigned when the account is created. | |
order | Contains details about the purchase order. | |
merchantOrderId | Unique identifier for the order assigned by the merchant. | |
amount | Total amount of the order. | |
currency | Currency code following the ISO 4217 standard. | |
card | Information related to the customer's card. | |
cardNumber | Card number. | |
expiryMonth | Card expiration month. | |
expiryYear | Card expiration year. | |
cvv2 | Card security code. | |
holderName | Name of the cardholder. | |
email | Email address associated with the card. | |
recurringPayment | Configuration for recurring payments. | Optional; if not sent, the default value is "false". |
saveCardOnfile | Indicates whether the card should be saved on file for future transactions. | |
installments | Details about installment payments. | Optional; if not sent, the transaction will be processed without installments or deferred payments. |
initialDiferement | Initial deferral. | |
numberInstallments | Number of installments. | |
planType | Payment plan type ("0" for regular plan). | |
threeDsAuthentication | Information for 3D Secure authentication. | Optional; if not sent, the transaction will be processed without 3D Secure protection. |
eci | Indicates the ECI (Electronic Commerce Indicator) value. | |
cavv | Value of the CAVV (Cardholder Authentication Verification Value). | |
ucaf | UCAF (Universal Cardholder Authentication Field). | |
xid | Value of the XID (Transaction ID). | |
version | Version of the 3D Secure protocol used. | |
dsTransactionId | Unique identifier of the transaction in the 3D Secure authentication system. | |
protocolType | Indicates the protocol type used. |
Example of successful response
Http code 200
{
"id": "5c51bebd-5b21-4ef3-b980-d41eb0b83568",
"order": {
"merchantOrderId": "9a6ecf36-8265-11ee-b962-0242ac120002",
"amount": "100.00",
"currency": "484"
},
"payload": {
"responseCode": "00",
"responseDescription": "Approved or completed successfully (if balances are available)",
"authorizationNumber": "280188",
"referenceNumber": "000027389440",
"status": "Paid"
},
"recurringPayment": {
"token": "2b43f315-b053-4cd2-bff0-14dd2e7da52a"
},
"isApproved": true,
"isFailure": false,
"errors": null
}
Field Description
Field | Description |
---|---|
id | Unique ID of the transaction assigned by the payment gateway. |
order | Contains details about the purchase order. |
merchantOrderId | Unique identifier for the order assigned by the merchant. |
amount | Total amount of the order. |
currency | Currency code following the ISO 4217 standard. |
payload | Contains detailed information about the transaction. |
responseCode | Response code indicating the result of the transaction (in this case, "00" indicates approval). |
responseDescription | Description associated with the response code. |
authorizationNumber | Authorization number of the transaction. |
referenceNumber | Reference number associated with the transaction. |
status | Transaction status; in this case, "paid" indicates that the transaction was successfully completed. |
recurringPayment | Indicates if card details have been stored. |
token | Unique identifier for the card to process future recurring payments or scheduled payments. |
isApproved | Indicates whether the transaction was approved. In this example, it is "true," meaning the transaction was approved. |
isFailure | Indicates whether the transaction failed. In this example, it is "false," meaning the transaction did not fail. |
errors | Contains details such as error number and description, if any. In this case, it is "null," meaning no errors occurred in the transaction. |
Updated 3 months ago