Environment configurations
This document introduces the SDK environment configurations for different phases or scenarios.
Card activation phase
The following table lists the configurations used during the card activation phase.
Key | Configuration | Supported SDK version | Data type | Description |
nfc_issue_config | applyTokenTimes | 1.0.0 | Number | The number of polls for the token application. Default value: |
applyTokenInterval | 1.0.0 | Number | The polling interval for the token application. The unit is milliseconds (ms). Default value: | |
activateTimes | 1.0.0 | Number | The number of polls for the activation. Default value: | |
activateInterval | 1.0.0 | Number | The polling interval for the activation. The unit is milliseconds (ms). Default value: | |
sessionTimes | 1.0.0 | Number | The number of polls for the session. Default value: | |
sessionInterval | 1.0.0 | Number | The polling interval for the session. The unit is milliseconds (ms). Default value: |
Sample
{
"nfc_issue_config": {
"applyTokenTimes": 10,
"applyTokenInterval": 2000,
"activateTimes": 10,
"activateInterval": 2000,
"sessionTimes": 10,
"sessionInterval": 500
}
}Transaction phase
The following table lists the configurations used during the transaction phase.
Key | Configuration | Supported SDK version | Data type | Description |
nfc_transaction_config | isSupportTransit | 1.0.0 | Boolean | Whether to support transportation scenarios. Valid values are:
Default value: This remote configuration takes precedence over isSupportTransit passed via the init API. |
isSupportTransitWithoutConsent | 1.1.12 | Boolean | Whether the traffic payment is supported while the screen is locked. Valid values are:
Default value: This remote configuration takes precedence over isSupportLockScreenPay passed via the init API. | |
asyncAmountLimitSwitch | 1.2.0 | Boolean | Whether to allow querying the password-free payment amount when the isPaymentAvailable API is called. Valid values are:
Default value: This remote configuration takes precedence over asyncAmountLimitSwitch passed via the init API. | |
canQueryAmountLimit | 1.2.0 | Boolean | Whether to query and use the password-free amount from the remote configuration. Valid values are:
Default value:
| |
requireDeviceUnlock | 1.2.11 | Boolean | Whether the device must be unlocked to use NFC functionality. Valid values are:
Default value: | |
allowTapTransaction | 1.2.11 | Boolean | Whether the NFC functionality is enabled. Valid values are:
Default value: | |
isSupportCardStatusJudgement | 1.2.19 | Boolean | Whether to support card status judgment in advance. Valid values are:
Default value: | |
failedCallbackInterval | 1.2.18 | Int | The interval between the reports of the same error code. The unit is milliseconds (ms). Default value: | |
isWalletActionRequired | 1.2.18 | Boolean | Whether the refund process requires a second confirmation. Valid values are:
Default value: | |
isSupportCardProfileRepair | 1.2.19 | Boolean | Whether to support card token re-activation if a card content parsing error occurs. Valid values are:
Default value: | |
isCheckTransitAdvancePayLimit | 1.4.5 | Boolean | Whether to check the payment amount limit of the transit card. Valid values are:
Default value: | |
isSwitchDBStorage | 1.5.0 | Boolean | Whether to switch to DB storage. Valid values are:
Default value: | |
isSwitchInitCard | 1.5.0 | Boolean | Whether to switch to a new initialization card token information in the tap process. Valid values are:
Default value: | |
isEventTransactionTrackingV2 | 1.5.0 | Boolean | Whether to switch to the SDK version 1.5 parameters of the NFCMonitor API. Valid values are:
Default value: | |
sameTapJudgementLevel | 1.5.0 | Int | The time interval between two taps that will be considered as the same tap. The unit is milliseconds (ms). Default value: | |
timeOfDelayReport | 1.5.0 | Int | The time delay to report failure results after a business failure. The unit is milliseconds (ms). Default value: | |
isSupportNewTransactionResultReport | 1.5.0 | Boolean | Whether to support the new transaction result report mechanism. Valid values are:
Default value: |
Sample
{
"nfc_transaction_config":{
"isSupportTransit":true,
"isSupportTransitWithoutConsent":true,
"asyncAmountLimitSwitch":false,
"canQueryAmountLimit":false,
"requireDeviceUnlock":false,
"allowTapTransaction":true
}
}Transit
The following table lists configurations specifically for transit scenarios.
Key | Configuration | Supported SDK version | Data type | Description |
nfc_transit_config | terminalCountryCode | 1.1.16 | String | The country code of the transaction. |
merchantCategoryCode | 1.1.16 | String | The merchant category code (MCC) that represents the categorization of the merchant's business type. | |
currencyAmount | 1.1.16 | Number | The transaction amount. | |
merchantNameAndLocation | 1.1.16 | String | The merchant's name, address, and location. |
Sample
{
"nfc_transit_config": [
{
"terminalCountryCode": "0458",
"merchantCategoryCode": "4131"
},
{
"terminalCountryCode": "0458",
"merchantCategoryCode": "4111"
},
{
"terminalCountryCode": "0458",
"merchantCategoryCode": "4784"
},
{
"terminalCountryCode": "0458",
"merchantCategoryCode": "1234"
},
{
"terminalCountryCode": "0458",
"merchantCategoryCode": "0000"
}
]
}Initialization
The following table lists the configurations used during the initialization phase.
Key | Configuration | Supported SDK version | Data type | Description |
nfc_init_config | init_monitor | 1.1.25 | Boolean | Whether to activate initialization monitoring. If it is set to Default value: |
next_step_type | 1.1.25 | Number | The next step to do upon detecting a previous crash.
Default value: | |
invalidate_time_stamp | 1.1.25 | Number | The validity period for the recorded initialization flag. The unit of this value is seconds (s). Default value: |
Sample
{
"nfc_init_config": {
"init_monitor": true,
"next_step_type": 1,
"invalidate_time_stamp": 604800
}
}Transaction blacklist
The following table lists configurations for the transaction blacklist.
KEY | Configuration | Supported SDK version | Data type | Description |
nfc_transaction_black | countrycode values | 1.1.27 | List<String> | The transaction types that are blacklisted. For the valid transaction types, see Transaction types. |
Transaction types
The following table lists the transaction types and their corresponding richTransactionType.
Value | Corresponding richTransactionType | Description |
| N/A | All transaction types |
|
| Ordinary transactions |
|
| Refund |
|
| Cash withdrawal |
|
| Transit transactions |
|
| Purchases with cashback |
Sample
{
"nfc_transaction_black": {
"0344": [
"TRANSIT"
],
"0156": [
"ALL"
]
}
}Transaction whitelist
The following table lists the configurations about the transaction whitelist.
Key | Configuration | Supported SDK version | Data type | Description |
nfc_transaction_black | terminalCountryCode | 1.4.3 | String | The country code of the transaction. |
transactionType | 1.4.3 | String | Transaction types. Valid values are:
| |
needDebitBin | 1.4.3 | Boolean | Whether debit card bins are required. |
Sample
{
"nfc_transaction_black": {
"terminalCountryCode": "0344",
"transactionType": "TRANSIT",
"needDebitBin": true
}
}Manage configurations with blacklist and whitelist
The following table lists configurations for managing nfc_transaction_config items using blacklists and whitelists.
Note: Only the allowTapTransaction configuration is supported.
key | item | Supported SDK version | Data type | Description |
nfc_payment_access_control_config | key | 1.2.18 | String | The configuration that needs to be managed according to the blacklist and whitelist. Valid value is |
blackList | 1.2.18 | List<String> | A list of user IDs, who are blacklisted and the configuration for them is set to | |
whiteList | 1.2.18 | List<String> | A list of user IDs, who are whitelisted and the configuration for them is set to |
Sample
{
"nfc_payment_access_control_config": [
{
"key": "allowTapTransaction",
"blackList": ["123", "456", "789"], // Users that are not allowed to make tap payment
"whiteList": ["123", "456"] // Users that are allowed to make tap payment
},
// other configurations
...
]
}