init
Call the init API to initialize the client SDK.
Note: The SDK is initialized after the first API call.
Method signature
ACTapManager.getInstance(context).init(config)Request parameters
Item | Type | Description | Required |
config | Configuration settings for the SDK. | Required |
APNFCConfig
Item | Type | Description | Required | Default value |
authType | String | The authentication type. Valid values are:
| Optional | FLEXIBLE |
isSupportTransit | Boolean | Whether to support transportation scenarios. Valid values are:
| Optional | false |
isSupportLockScreenPay | Boolean | Whether to support transportation payments when the screen is off. Valid values are:
| Optional | false |
isNeedConfirmActivate | Boolean | Whether secondary confirmation is required for card activation. Valid values are:
| Optional | false |
minNumberAllowedReplenish | Integer | The minimum Credential threshold for replenishment requests through the replenish API. When local Credentials exceed this value, replenish calls return the | Optional | 10 |
autoReplenishThreshold | Integer | The threshold for automatic replenishment. When Credentials fall below this threshold due to transactions, the SDK automatically triggers replenishment.
| Optional | 10 |
amountLevel | String | The exempted password amount level. Pass in a positive integer as the initial value of this parameter. | Required | N/A |
asyncAmountLimitSwitch | Boolean | Whether the amount limit switching is asynchronous. Valid values are:
| Optional | false |
canQueryAmountLimit | Boolean | Whether setting a limit is allowed for the query amount. Valid values are:
| Optional | false |
initMonitorDefault | Boolean | Whether to set NFCMonitor init status to false by default. Valid values are:
| Optional | false |
isUseDefaultDeviceFingerPrint | Boolean | Whether the default device fingerprint is used. Valid values are:
| Optional | false |
Response parameters
N/A
Sample
private static APNFCConfig getDefaultSDKConfig() {
APNFCConfig.Builder builder = new APNFCConfig.Builder()
.setNeedConfirmActivate(true)
.setAuthType(NFCAuthMode.FLEXIBLE_WITHOUT_UPPER_AMOUNT)
.setSupportLockScreenPay(false);
return builder.build();
}