Interface PaymentGatewayTransactionService
- All Superinterfaces:
PaymentGatewayTypeAware
- All Known Subinterfaces:
PassthroughTransactionService
- All Known Implementing Classes:
DefaultPassthroughTestingTransactionService
,DefaultPassthroughTransactionService
This is an interface that provides the basic functions to create billable credit card transactions
The intention of these methods are to make a server to server API call. Depending on the gateway implementation, the overall goal and meaning of the method may vary. For example, a module can implement the AUTHORIZE method:
- Either to send credit card information directly (server to server) to the gateway to perform the transaction
- Or to confirm an AUTHORIZATION process (some gateways don't handle a token based process through a Transparent Redirect)
- OR handle both (the implementation will do one or the other based on the passed in parameters)
Please check the documentation of the implementing module to determine intended goal.
- Author:
- Elbert Bautista (elbertbautista)
-
Method Summary
Modifier and TypeMethodDescriptiondefault PaymentResponse
authorize
(PaymentRequest paymentRequest) Responsible for executing aDefaultTransactionTypes.AUTHORIZE
transaction against the payment gateway, based on the providedPaymentRequest
, & returning the transaction's results in the form of aPaymentResponse
.default PaymentResponse
authorizeAndCapture
(PaymentRequest paymentRequest) Responsible for executing aDefaultTransactionTypes.AUTHORIZE_AND_CAPTURE
transaction against the payment gateway, based on the providedPaymentRequest
, & returning the transaction's results in the form of aPaymentResponse
.default PaymentResponse
capture
(PaymentRequest paymentRequest) Responsible for executing aDefaultTransactionTypes.CAPTURE
transaction against the payment gateway, based on the providedPaymentRequest
, & returning the transaction's results in the form of aPaymentResponse
.default PaymentResponse
detachedCredit
(PaymentRequest paymentRequest) Responsible for executing aDefaultTransactionTypes.DETACHED_CREDIT
transaction against the payment gateway, based on the providedPaymentRequest
, & returning the transaction's results in the form of aPaymentResponse
.default String
identifyParentTransactionReferenceIfExists
(Map<String, Object> transactionProperties, Map<String, Object> paymentProperties) default TransactionType
identifyTransactionTypeFromTransactionResults
(Map<String, Object> transactionProperties, Map<String, Object> paymentProperties) default PaymentResponse
refund
(PaymentRequest paymentRequest) Responsible for executing aDefaultTransactionTypes.REFUND
transaction against the payment gateway, based on the providedPaymentRequest
, & returning the transaction's results in the form of aPaymentResponse
.default PaymentResponse
reverseAuthorize
(PaymentRequest paymentRequest) Responsible for executing aDefaultTransactionTypes.REVERSE_AUTH
transaction against the payment gateway, based on the providedPaymentRequest
, & returning the transaction's results in the form of aPaymentResponse
.Methods inherited from interface com.broadleafcommerce.paymentgateway.service.PaymentGatewayTypeAware
getGatewayType
-
Method Details
-
authorize
Responsible for executing aDefaultTransactionTypes.AUTHORIZE
transaction against the payment gateway, based on the providedPaymentRequest
, & returning the transaction's results in the form of aPaymentResponse
.- Parameters:
paymentRequest
- The request payload that must be converted into the gateway's expected payload- Returns:
- The results of the authorization transaction
-
capture
Responsible for executing aDefaultTransactionTypes.CAPTURE
transaction against the payment gateway, based on the providedPaymentRequest
, & returning the transaction's results in the form of aPaymentResponse
.- Parameters:
paymentRequest
- The request payload that must be converted into the gateway's expected payload- Returns:
- The results of the capture transaction
-
authorizeAndCapture
Responsible for executing aDefaultTransactionTypes.AUTHORIZE_AND_CAPTURE
transaction against the payment gateway, based on the providedPaymentRequest
, & returning the transaction's results in the form of aPaymentResponse
.- Parameters:
paymentRequest
- The request payload that must be converted into the gateway's expected payload- Returns:
- The results of the authorization & capture transaction
-
reverseAuthorize
Responsible for executing aDefaultTransactionTypes.REVERSE_AUTH
transaction against the payment gateway, based on the providedPaymentRequest
, & returning the transaction's results in the form of aPaymentResponse
.- Parameters:
paymentRequest
- The request payload that must be converted into the gateway's expected payload- Returns:
- The results of the reverse authorization transaction
-
refund
Responsible for executing aDefaultTransactionTypes.REFUND
transaction against the payment gateway, based on the providedPaymentRequest
, & returning the transaction's results in the form of aPaymentResponse
.- Parameters:
paymentRequest
- The request payload that must be converted into the gateway's expected payload- Returns:
- The results of the refund transaction
-
detachedCredit
Responsible for executing aDefaultTransactionTypes.DETACHED_CREDIT
transaction against the payment gateway, based on the providedPaymentRequest
, & returning the transaction's results in the form of aPaymentResponse
.- Parameters:
paymentRequest
- The request payload that must be converted into the gateway's expected payload- Returns:
- The results of the void transaction
-
identifyParentTransactionReferenceIfExists
-
identifyTransactionTypeFromTransactionResults
-