Make sure the checkout page is setup to collect all the required information from customer as mentioned in eCheck Setup
-
Create / prepare your cart
a. Ensure your cart locale is set
b. Ensure the cart billing and shipping addresses are set. Phone number is a mandatory field in address for eCheck transaction
NOTE: : If the cart has multiple shipping methods, the shipping address of the first available shipping method applied to the cart will be used to process the payment
-
Enter the account number, account type and routing number
-
Create a Commercetools payment (https://docs.commercetools.com/api/projects/payments) and populate the following
Property Value Required Notes customer Reference to Commercetools customer See notes Required for non-guest checkout. If using MyPayments API this will automatically be set to the logged in customer. One of customer or anonymousId must be populated anonymousId Id for tracking guest checkout See notes Required for guest checkout. If using MyPayments API this will automatically be set. One of customer or anonymousId must be populated paymentMethodInfo.paymentInterface Cybersource Yes paymentMethodInfo.method eCheck Yes custom.type.key isv_payment_data Yes custom.fields.isv_accountNumber Customer account number Yes Encoded account number for customer's bank account (Max length is 17) custom.fields.isv_accountType Customer account type Yes Possible customer account type (Possible values are mentioned in eCheck Setup) custom.fields.isv_routingNumber Customer routing number Yes Also named as transit number(Max 9 digits) amountPlanned Amount to be processed Yes Should match cart gross total, unless split payments are being used custom.fields.isv_deviceFingerprintId Customer device fingerprint id Yes Refer Device Fingerprinting to generate this value custom.fields.isv_customerIpAddress Customer IP address Yes Populated from client-side libraries custom.fields.isv_merchantId Merchant Id used for the transaction No Required when you want to support Multi-Mid functionality. Populate this field with the value of merchant Id in which the transaction should happen. When this field is empty, default mid configuration will be considered for the transaction. The same mid will be used for the follow-on transactions. custom.fields.isv_shippingMethod Shipping method for the order No Possible values: -
lowcost: Lowest-cost service sameday: Courier or same-day serviceoneday: Next-day or overnight servicetwoday: Two-day servicethreeday: Three-day service.-
pickup: Store pick-up -
other: Other shipping method -
none: No shipping method because product is a service or subscription
custom.fields.isv_metadata Metadata for the order No This field can be used to send additional custom data as part of the authorization request. The data should be serialized into a string format (e.g., JSON string) before passing it in the request.
Example:"isv_metadata": "{"1":"value1", "2":"value2"}"custom.fields.isv_accountPurchaseCount Required to determine account creation history and purchase activity No Provide the user's purchase count for the last six months. This value will be used to determine account creation history and populate the riskInformation section of the authorization request -
-
Add the payment to the cart
-
Add a transaction to the payment
Property Value Notes type Charge state Initial amount Amount to be processed Should match amountPlanned on payment -
Verify the payment state and convey the payment result to the customer
a. If the transaction is successful, transaction state will be updated to Success, display the order confirmation page
b. If the state of transaction is updated to Pending which is due to Fraud Check, display the order confirmation page
c. If the state of transaction is updated to Failure, display the error page and See Overview#Errorhandling for handling errors or failures