Same-terminal application integration
1. Introduction
The merchant's POS application runs at the same POS terminal. It can pull up checkout component to complete payment through the payment integration APIs of CodePay Register.
1.1 Typical process workflow
- POS application send order info (include order number, amount) to CodePay Register app to pull payment checkout component.
- The checkout component of CodePay Register collects the bank card information/mobile wallet user payment voucher and processes it securely, then merges it and order information in the transaction data, and sends the payment request to CodePay Gateway .
- CodePay Gateway processes the transaction packet and sends to payment gateway or acquire system.
- Payment gateway or acquire system responses result to CodePay Gateway .
- CodePay Gateway responses transaction result to CodePay Register application.
- CodePay Register application returns transaction result to POS application.
1.2 Integration method
POS application uses Android Intent to interact with CodePay Register application. The following diagram shows the interactions between this 2 applications.
- POS application call "startActivityForResult" function to invoke the CodePay Register application .
- CodePay Register application parse the bundle data from POS application and then process transaction.
- Then CodePay Register application call "setResult" function after the transaction and "finish" own Activity.
- POS application received the transaction result by "onActivityResult" event.