Integration guide
1. Install library
Add to dependencies:
2. Init SDK
merchantCode
This is the code of the partner when integrating the SDK
secretKey
Key connect to API 9Pay
uId
User identifier using merchant's account, optional, can be null
flavorEnv
Using environment, there are 2 environments, sandbox (test code environment) and production (actual running environment), see the table below for configuration.
colorCode
The color code that the merchant wants to use on the buttons in the SDK, hex color code and not the # character, for example 15AE62
3. List of constants config SDK
EnvironmentKey.SANDBOX
flavorEnv environment Sandbox
EnvironmentKey.PRODUCTION
flavorEnv environment Production
PaymentMethod.DEFAULT
Payment using all methods (used in the openPaymentOnSDK function).
PaymentMethod.WALLET
Payment using method 9Pay Ewallet (used in the openPaymentOnSDK function).
PaymentMethod.ATM_CARD
Payment using method inland card (used in the openPaymentOnSDK function).
PaymentMethod.CREDIT_CARD
Payment using method credit card (used in the openPaymentOnSDK function).
4. Technical Diagram
4.1 Example init SDK
4.2 Open fucntion SDK 9Pay
LOGIN
Login
HISTORY
Transaction history
TRANSFER
Money transfer and withdrawal functions
DEPOSIT
Deposit to 9Pay Ewallet
QR
Function scan QR code
BILLING
Billing (electric, water...)
TOPUP
Topup phone
PHONE_CARD
Buy phone card
DATA_CARD
Buy data card 4G
SERVICE_CARD
Buy service card
4.3 Function Payment order merchant
4.4 Get user info
4.5 Logout
4.6 Close screen SDK
5. Data test sandbox
Account Ewallet 9Pay SDK
0912365431
Password (Account Ewallet 9Pay SDK)
123123
OTP (Account Ewallet 9Pay SDK)
123456
Bank information used to link and deposit
Bank: Agribank
Number card: 9704 0000 0000 0018
Account holder: Nguyen Van A
Issuance date: 03/07
OTP: otp
International card
Account holder: NGUYEN VAN A
Number card:
4005555555000009 (Visa)
5200000000001005 (MasterCard)
Expiration: 05/25
CVV: 123
6. List error code SDK
Error will return callback from onError
when init SDK.
403
Not login
2001
Error validate information order
2002
Error payment order merchant
2003
Error getting bank information and payment card SDK support
2004
Error decoding returned data
2005
Unknown error
Last updated