| Modifier and Type | Class and Description |
|---|---|
static class |
D1Task.Builder
An object that constructs
D1Task from its configurations. |
static interface |
D1Task.Callback<T>
Generic callback to return result of an asynchronous call.
|
static interface |
D1Task.ConfigCallback<T>
Configuration callback to return result of an asynchronous call.
|
| Modifier and Type | Method and Description |
|---|---|
void |
activateDigitalCard(String cardID,
D1Task.Callback<Void> callback)
Google Pay only.
|
void |
activatePhysicalCard(String cardID,
EntryUI entryUI,
D1Task.Callback<Void> callback)
Activate a Physical Card.
|
void |
addDigitalCardToOEM(String cardID,
D1Task.Callback<Void> callback)
Add Digital Card for a given
cardID for OEM Type (Google Pay or Samsung Pay). |
void |
addDigitalCardToScheme(String cardID,
TokenRequestor tokenRequestor,
String appURL,
boolean tcsAccepted,
D1Task.Callback<String> callback)
Add Digital Card to scheme for a given
cardID |
void |
configure(D1Task.ConfigCallback<Void> callback,
D1Params... configParams)
D1 Task configurations.
|
void |
displayPhysicalCardPIN(String cardID,
CardPINUI cardPINUI,
D1Task.Callback<Void> callback)
Display the PIN for a Physical Card.
|
void |
getCardActivationMethod(String cardID,
D1Task.Callback<CardActivationMethod> callback)
Retrieve the activation method for a Physical Card.
|
void |
getCardDetails(String cardID,
D1Task.Callback<CardDetails> callback)
Retrieve detail information of the card, including full PAN value.
|
void |
getCardDigitizationState(String cardID,
D1Task.Callback<CardDigitizationState> callback)
Check if the card has been digitized or not.
|
void |
getCardMetadata(String cardID,
D1Task.Callback<CardMetadata> callback)
Retrieve basic card metadata.
|
D1PayWallet |
getD1PayWallet()
Retrieve D1PayWallet object for D1 Payment use cases
|
void |
getDigitalCardList(String cardID,
D1Task.Callback<List<DigitalCard>> callback)
Retrieve Digital Card list for a given
cardID. |
void |
getPhysicalCardPIN(String cardID,
D1Task.Callback<byte[]> callback)
Retrieve the PIN for a Physical Card.
|
static Map<String,String> |
getSDKVersions()
Returns SDK version(s) in the D1 SDK.
|
void |
getTokenRequestorList(String cardID,
D1Task.Callback<List<TokenRequestor>> callback)
Retrieve eligible token requestor list for a given
cardID. |
void |
handleCardResult(int requestCode,
int resultCode,
Intent data)
Handle data that Wallet has returned for card operation.
|
void |
login(byte[] issuerToken,
D1Task.Callback<Void> callback)
Login to the D1 services using a provided token.
|
void |
logout(D1Task.Callback<Void> callback)
Logout to the D1 services
|
void |
processPushMessage(Map<String,String> data,
D1Task.Callback<String> callback)
Process the pushed data received from notification server
|
void |
registerCardDataChangedListener(CardDataChangedListener listener)
Register to receive Card/Wallet update on following events:
The active wallet changes (by changing the active account)
The selected card of the active wallet changes
Tokenized cards are added or removed from the active wallet
The status of a token in the active wallet changes
|
void |
unRegisterCardDataChangedListener()
Unregister the Card/Wallet data changed listener
|
void |
updateCard(String cardID,
CardAction cardAction,
String reason,
D1Task.Callback<Void> callback)
Update the Virtual Card state.
|
void |
updateDigitalCard(String cardID,
DigitalCard digitalCard,
CardAction cardAction,
D1Task.Callback<Boolean> callback)
Update Digital Card status for a given Digital card ID.
|
void |
updatePushToken(String token,
D1Task.Callback<Void> callback)
Update new push token
|
@NonNull public static Map<String,String> getSDKVersions()
public void configure(@NonNull
D1Task.ConfigCallback<Void> callback,
@NonNull
D1Params... configParams)
App can only initialize certain feature only to reduce waiting time. It is not mandatory to initialize all features in a single call.
callback - The callback for the result.
When it succeeds, the returned argument of the D1Task.ConfigCallback.onSuccess(Object) is always null.configParams - The configurationspublic void login(@NonNull
byte[] issuerToken,
@NonNull
D1Task.Callback<Void> callback)
issuerToken - Issuer token received from the bank IDPcallback - The callback for the result.
When it succeeds, the returned argument of the D1Task.Callback.onSuccess(Object) is always null.public void logout(@NonNull
D1Task.Callback<Void> callback)
callback - The callback for result.
When it succeeds, the returned argument of the D1Task.Callback.onSuccess(Object) is always null.public void getCardMetadata(@NonNull
String cardID,
@NonNull
D1Task.Callback<CardMetadata> callback)
cardID - The card identifiercallback - The callback for the result.
When it succeeds, the returned argument of the D1Task.Callback.onSuccess(Object) is always non-null.public void getCardDetails(@NonNull
String cardID,
@NonNull
D1Task.Callback<CardDetails> callback)
cardID - The card identifiercallback - The callback for the result.
When it succeeds, the returned argument of the D1Task.Callback.onSuccess(Object) is always non-null.public void updateCard(@NonNull
String cardID,
@NonNull
CardAction cardAction,
@Nullable
String reason,
@NonNull
D1Task.Callback<Void> callback)
The following CardAction can be performed:
cardID - The card identifiercardAction - The card action to be performed, possible actions:
reason - The reason for the operationcallback - The callback for the result.
When it succeeds, the returned argument of the D1Task.Callback.onSuccess(Object) is always null.public void getPhysicalCardPIN(@NonNull
String cardID,
@NonNull
D1Task.Callback<byte[]> callback)
cardID - The card identifiercallback - The callback invoked when the operation is completed.
When it succeeds, it returns the PIN (D1Task.Callback.onSuccess(Object)).
Otherwise, it returns the error details.IllegalArgumentException - when one of the parameters is null or empty.public void displayPhysicalCardPIN(@NonNull
String cardID,
@NonNull
CardPINUI cardPINUI,
@NonNull
D1Task.Callback<Void> callback)
cardID - The card identifiercardPINUI - The ui to display card PINcallback - The callback invoked when the operation is completed.
When it succeeds, it returns no error and the D1Task.Callback.onSuccess(Object)'s argument is always null.
Otherwise, it returns the error details.IllegalArgumentException - when one of the parameters is null or empty.public void getCardActivationMethod(@NonNull
String cardID,
@NonNull
D1Task.Callback<CardActivationMethod> callback)
cardID - The card identifiercallback - The callback invoked when the operation is completed.
When it succeeds, it returns the CardActivationMethod.
Otherwise, it returns the error details.IllegalArgumentException - when one of the parameters is null or empty.public void activatePhysicalCard(@NonNull
String cardID,
@NonNull
EntryUI entryUI,
@NonNull
D1Task.Callback<Void> callback)
cardID - The card identifierentryUI - The UI to display secure text entry. If activationMethod is CardActivationMethod.NOTHING, construct EntryUI with a null `SecureEditText`callback - The callback invoked when the operation is completed.
When it succeeds, it returns no error.
Otherwise, it returns the error details.IllegalArgumentException - when one of the parameters is null or empty.public void getCardDigitizationState(@NonNull
String cardID,
@NonNull
D1Task.Callback<CardDigitizationState> callback)
cardID - The card identifiercallback - The callback for the result.
When it succeeds, the returned argument of the D1Task.Callback.onSuccess(Object) is always non-null.public void addDigitalCardToOEM(@NonNull
String cardID,
@NonNull
D1Task.Callback<Void> callback)
cardID for OEM Type (Google Pay or Samsung Pay).
OEM Type is set on ConfigParams.buildConfigCard(android.app.Activity, OEMPayType, String)
Integrator must override the Activity.onActivityResult() and pass the result back to SDK using
handleCardResult(int, int, Intent) API
cardID - The card identifiercallback - The callback for the result.
When it succeeds, the returned argument of the D1Task.Callback.onSuccess(Object) is always null.ConfigParams.buildConfigCard(android.app.Activity, OEMPayType, String),
handleCardResult(int, int, Intent)public void activateDigitalCard(@NonNull
String cardID,
@NonNull
D1Task.Callback<Void> callback)
Activate the digital card which has been digitized but not yet done ID&V (Step up authentication - Yellow Flow inApp Verification).
Integrator should call this API when the return state of getCardDigitizationState(String, Callback) is CardDigitizationState.PENDING_IDV
cardID - The card IDcallback - The callback for result.
When it succeeds, the returned argument of the D1Task.Callback.onSuccess(Object) is always null.public void getDigitalCardList(@NonNull
String cardID,
@NonNull
D1Task.Callback<List<DigitalCard>> callback)
cardID.cardID - The card identifiercallback - The callback for the result.
When it succeeds, the returned argument of the D1Task.Callback.onSuccess(Object) is always non-null.public void updateDigitalCard(@NonNull
String cardID,
@NonNull
DigitalCard digitalCard,
@NonNull
CardAction cardAction,
@NonNull
D1Task.Callback<Boolean> callback)
cardID - The card identifierdigitalCard - The digital card received from getDigitalCardList(String, Callback)cardAction - The card action to be performed: active, suspend or deletecallback - The callback for the result.
When it succeeds, the returned argument of the D1Task.Callback.onSuccess(Object) is always non-null.public void handleCardResult(int requestCode,
int resultCode,
@Nullable
Intent data)
requestCode - The requestCode available for card operation resultresultCode - The resultCode available for card operation resultdata - The data available for card operation resultpublic void registerCardDataChangedListener(@NonNull
CardDataChangedListener listener)
Note: Only foreground applications will be notified.
Therefore, application should update the token status not only when receiving this callback but also when the application launches or returns to the foreground.
For more information, refer to Android Push Provisioning API - Data Change Callbacks
listener - The callbackpublic void unRegisterCardDataChangedListener()
CardDataChangedListenerpublic void getTokenRequestorList(@NonNull
String cardID,
@NonNull
D1Task.Callback<List<TokenRequestor>> callback)
cardID.cardID - The card identifiercallback - The callback for the result.
When it succeeds, the returned argument of the D1Task.Callback.onSuccess(Object) is always non-null.IllegalArgumentException - when one of the parameter is null or emptyIllegalStateException - when core module has not been configuredpublic void addDigitalCardToScheme(@NonNull
String cardID,
@NonNull
TokenRequestor tokenRequestor,
@NonNull
String appURL,
boolean tcsAccepted,
@NonNull
D1Task.Callback<String> callback)
cardIDcardID - The card identifiertokenRequestor - The token requestor that user has selectedappURL - The issuer app's custom URL that the token requestor calls back upon completion of digitization flow to return the user to where they started their journeytcsAccepted - The terms and conditions accepted by usercallback - The callback for the result.
When it succeeds, the returned argument of the D1Task.Callback.onSuccess(Object) is always non-null.IllegalArgumentException - when one of the parameter is null or emptyIllegalStateException - when core module has not been configuredpublic void updatePushToken(@NonNull
String token,
@NonNull
D1Task.Callback<Void> callback)
token - The latest push notification tokencallback - The callback for the resultpublic void processPushMessage(@NonNull
Map<String,String> data,
@NonNull
D1Task.Callback<String> callback)
data - The pushed datacallback - The callback for the result@NonNull public D1PayWallet getD1PayWallet()