Add payment methods

A customer can prefer to pay for an order by using different payment methods or redistribute charges across multiple payment methods. In such cases, a user must be able to add payment methods to the order.

Solution

The following section describes APIs, user exits, services, and other components.

The user can add payment methods in the Payment Confirmation screen. When the user chooses to add a payment method, the "Add Payment Method" window is displayed. The window displays any payment methods that are saved to the customer. The getCustomerPaymentMethodList API is called to retrieve the payment methods that are saved to the customer. The user can select a payment method or choose to add a payment method. The getPaymentTypeList API is called to retrieve the payment methods that are allowed by the current enterprise. From this list, the user can select a payment method to add to the order. The user can enter the required details and also save the payment method against the customer.

The user can add one or more payment methods such as customer accounts, credit cards, checks, prepaid cards, or store value cards.
  • Customer Account: If this payment method is already associated with the customer, then the account limit and currency are populated automatically. For a customer account, the account limit must be defined by an external system.
  • Credit Card: The credit card number is taken as the input and passed to the payment validation system, which stores the actual number and returns a token with the credit card type and the display value. The credit card type can be used to default the credit card type list. However, first an authentication token is created by calling the createAccessToken API. The API returns a TokenValue, which is passed in the call to the payment validation system to store the credit card number. The credit card type list is enterprise-specific and can be retrieved by using the getPaymentCardTypeList API. The month list is populated by using the common code, YCD_MONTH, which is cached. A mashup is used to populate the expiration year, which is five years starting with the current calendar year. The card type list is populated by using the YCD_CREDIT_CARD_TYPE common code. The month and year are concatenated together to form the credit card expiration date.
  • Check: The 'check' payment method belongs to the payment group 'OTHER', but it is handled specially. Only the check account number and routing number attributes are stored. This payment method can be saved for a customer.
  • Gift Cards: This payment method is not stored for the customer. It is used only when the user creates an order. A payment validation system is required to process gift cards.
  • Pre-Paid: This payment method is not used often. It is optional and is not saved for the customer.

By default, the "Add Payment Method" window displays fields for the Credit Card payment type. The "Bill to" address is also displayed. When the user chooses to edit the address, the address capture window is displayed. For more information, see Capture addresses.

When the user chooses to save the payment method against the customer either while adding or editing the payment method, the manageCustomer API is called to save the payment method for the customer. For a business customer, the payment method is saved against the appropriate contact. Consumers have only one contact so the payment method is saved against the customer. However, if there is no BIllToID on the order, the payment method is not saved against the customer.

The payment type groups that support the storage are customer account, credit card, and others.

If the application is configured to do real-time authorization of payments, the user can capture the CVV number of the credit card that is used by the customer. The CVV number is passed to the processOrderPayment API.

If the application is not configured to do real-time authorization, the payment processing occurs after the order is confirmed, through the payment agents. The CVV number is not captured, and the processOrderPayment API is not called to process payments. To determine whether the real-time authorization is enabled or not, the getRuleDetails API is called.

When the user enters details for a selected payment method and applies the changes, the capturePayment API is called to save a payment method to the order.

Note: The çç application does not store, transmit or process the PCI account data. To limit the risk of exposure, PCI account data must be re-directed, punched out using an iFrame or other technology that passes the PCI account data from the client's browser to a PCI-DSS (Payment Card Industry - Data Security Standards) compliant payment provider.

You can implement any PCI-DSS compliant system to tokenize the card numbers. This token can be used for subsequent calls in the çç application.

Implementation

The following section describes the rules that you must configure.

Configure the following rules appropriately. For more information, see the Sterling Business Center System Configuration.
  • Use A Single Field To Enter The Name On The Credit Card In The User Interface: The rule allows the use single or multiple fields for credit card name on the user interface at the time of capturing payment information. You can configure this rule at the enterprise level. When the user captures the details of a credit card, the screen behaves based on the configuration of this rule for the seller organization.
  • Authorize Credit Cards In Real Time for Draft Orders: The rule allows the user to authorize payments for an order in real time
  • Payment Types and Payment Card Types.

The "Save against customer" check box in the Add Payment Method window is permission-controlled. The check box is enabled only if the user belongs to a group that is assigned the necessary permissions. For information about assigning resource permissions to a user group, see the Administering user group permissions.

For more information about the APIs and user exits, refer to the Javadoc.

End-user impact

The user can either add saved customer payment methods or new payment methods to the order.