ConfigurationPayments

Payments

Sana Commerce 8.3
Your provider

Configure a Payment Module

A payment module is the code needed to implement a given payment method. This can either be an internal payment method (handled by the shop itself) or an external payment method (using a payment service provider). A payment module can be created by inheriting from the 'IPaymentModule' interface found in the 'Sana.Commerce.Payment' assembly.
 
In order to link a payment module to a payment you will need to register it in the 'web.config' file of the Sana Commerce frontend. Modules are added to the <payment-configuration> node in the <sanaCommerce> section. For example:
<payment-configuration>
    <module name="DocData" type="Sana.Commerce.CustomModule, Sana.Commerce.Payment">
        <settings>
            <clear />
            <add name="parameter" value="1" isRequestParameter="false" />
        </settings>
    </module>
</payment-configuration>
 
The example shows a single payment module with the Id 'DocData' that has a single configuration value called 'parameter'. The following two properties exist:
 
Property Description
Name The Id of the payment module. This is used to link the module to a payment method in the 'PaymentMethods' table. To link the module this name should be the same as the 'PaymentModuleId' field in the 'PaymentMethods' table (read this chapter for more information).
Type The class (and containing assembly) that implements the payment module. This class should implement either the 'IPaymentModule' interface or inherit from the 'ExternalPaymentModule' class or any other existing payment modules.
 
All other configurations can be added to the <settings> node. Possible settings and the way to add settings are explained below.
 
ConfigurationPayments