Add below permission in your application's AndroidManifest.xml.
Sets the SurePay mode from Warn mode(to show SurePay Dialog in case of low speed network) of Fail mode( to show SurePay Dialog in case of no network/ network error).Recommended flow is Fail Mode.
setSurePayMode(int surePay)Input params: Can be WARN_MODE/FAIL_MODEDefault: WARN_MODE
By the time CustomBrowser detects good network, if CBWebview is destroyed, we resume the transaction by passing payment post data to, this, merchant checkout activity.
customBrowserConfig.setMerchantCheckoutActivityPath(<Absolute Activity Path>);
All the notifications which will appear during a SurePay transaction can be customised as per the merchant’s needs. You can customise the icon, the header, sub-header and the message body of all the notifications which appear.
Better network Identified : This notification is fired when a better network is identified by SurePay. Use below method to customise notification when a better network is identified.Default value is Internet Restored.
No network found after timeout : This notification is fired when the threshold value until which SurePay looks for a good network is over and the user cannot resume the transaction from that point. Use below mentioned methods to customise notification when threshold value is elapsed.
customBrowserConfig.setSurePayNotificationPoorNetWorkHeader();customBrowserConfig.setSurePayNotificationPoorNetWorkTitle();//Default Value is “No Internet Found”customBrowserConfig.setSurePayNotificationPoorNetWorkBody();//Default value is “We could not detect internet on your device”
Notification for Success transaction : This notification is fired when bank confirms the status of the transaction when it is dropped in the backward leg. Use below mentioned methods to customise notification for success transaction.
customBrowserConfig.setSurePayNotificationTransactionVerifiedTitle();customBrowserConfig.setSurePayNotificationTransactionVerifiedHeader();//Default value is "Transaction Verified"customBrowserConfig.setSurePayNotificationTransactionVerifiedBody();//Default value is "The bank has verified this transaction and we are good to go.”
Notification for unknown Transaction : This notification is fired when the bank cannot confirm the status of the transaction dropped in the backward leg at that given point of time. Use below mentioned methods to customise notification for unknown transaction.
customBrowserConfig.setSurePayNotificationTransactionNotVerifiedTitle();customBrowserConfig.setSurePayNotificationTransactionNotVerifiedHeader(); //Default value is "Transaction Status Unknown"customBrowserConfig.setSurePayNotificationTransactionNotVerifiedBody();//Default value is "The bank could not verify the transaction at this time."
Set SurePay notification icon :
// input param: Drawable Resource (Default value is R.drawable.surepay_logo)customBrowserConfig.setSurePayNotificationIcon(int intRes)