Android SDK - Payment Account Management Module

DOCS

Last updated: Aug 15th, 5:56am

The payment account management module governs the functionality associated with managing the payment accounts registered in the logged-in user’s mobile wallet. This includes adding new accounts, updating or deleting existing accounts, and determining how those accounts are displayed in the app.

This chapter describes the methods available to provide complete payment account administration, including utility methods that facilitate the functionality, such as retrieving account images for a richer display, or retrieving the billing addresses of existing accounts for the purpose of pre-populating address fields for a new account.

ServiceDescription
UI Servicecom.paydiant.android.ui.service.account.PaymentAccountManagementService
Core Servicecom.paydiant.android.core.facade.PaymentAccountManagerFacade

Payment Account Metadata

The payment account management module uses a metadata approach for managing payment accounts in order to support variable property requirements for payment accounts of different tender types. For example, credit and debit card payment accounts require the card-holder’s billing address for processor authorization, but gift cards do not. This approach allows the adding and updating of different types of payment accounts to be both more flexible and more accurate, which enhances the usability of the mobile wallet app.

Each tender type element contains a set of one or more metadata elements, each of which represents a predefined property that is recognized and accepted by the Paydiant managed service. Application developers can use these metadata to design appropriate UI controls, field validation, and error handling. The following table describes the attributes that define each metadata property, the values for which can be specified individually for each metadata element when passed in a payment account creation or update method.

Meta data property attributes

Attributeescription
additionalDataValidationsList
Defines rules against which the entered value must be validated prior to submitting to the Paydiant service, for example, if the value must be an exact character length.
dataGroupString
Optional attribute specifies a category to which the property belongs for the purpose of grouping UI controls in the app layout.
dataTypeString
Specifies the format type of the property, such as DATE, STRING, BOOLEAN, or other type.
defaultValueString
Default value of the property, which will be used in the event that no other value is entered.
keyString
Unique identification of the metadata property that allows the metadata value to be recognized by the SDK. This value should not be edited by the app developer.
maskingRequiredBoolean
Specifies whether the value for the property needs to be obscured from view in the UI.
maxLengthInteger
Maximum length required by a UI widget in order to properly display or edit the property value. For example, the zip code property might be 5, while the mobile phone might be 10.
minLengthInteger
Minimum length required by a UI widget in order to properly display or edit the property value. For example, the card number of an AMEX card is 24 digits, while the card number for a Visa card is 16, but if the property is not required, the minimum value would likely be 0.
nameString
Plain language label for the attribute that the app developer can use in the UI.
orderInteger
Specifies the numerical sequence of the attribute so the UI controls can follow a logical progression.
pciEncryptionRequiredBoolean
Specifies whether the property must be encrypted in compliance with PCI sensitive data policies.
requiredBoolean
Indicates if the property is required for the payment account type.
reverificationRequiredBoolean
Indicates if the property value requires reverification upon any change to the payment account.
storageRestrictedBoolean
Specifies if the property value is prohibited from being cached or otherwise stored in the app’s private data directory.
updatesAllowedBoolean
Specifies if the user can change the value for this property during an update action. For example, when updating a payment account, the user can change the nickname property, but cannot change the card number.

Set UI Package Payment Account Service Listeners

To invoke the callback methods returned by the Paydiant service in response to the methods invoked by the Payment Account Management module of the SDK, the developer must set an implementation of the applicable listener interfaces in the UI Service class.

ItemDescription
Set Retrieval ListenerNon-metadata Listener Interface:
com.paydiant.android.ui.service.account.IPaymentAccountManagementListener
Metadata Listener Interfacescom.paydiant.android.ui.service.account.IPaymentAccountManagementMetaDataListener

or an overridden instance of
com.paydiant.android.ui.service.account.PaymentAccountManagementListenerAdapter
void setPaymentAccountRetrieveListener (IPaymentAccountRetrieveListener listener);
Set Balance Refresh ListenerListener Interfaces:
com.paydiant.android.ui.service.account.IPaymentAccountBalanceRefrshListener

or an overridden instance of
com.paydiant.android.ui.service.account.PaymentAccountBalanceRefreshListenerAdapter
void setPaymentAccountBalanceRefreshListener (IPaymentAccountBalanceRefreshListener listener);
Remove Listenervoid removeListener();

Call this method from within the corresponding service class in order to remove the associated listener and set it to null.

Retrieve All Payment Accounts

Invoke this method from the core or UI service package to request the complete set of payment accounts that are currently registered in the user’s wallet.

ItemDescription
UI Methodvoid retrieveAllPaymentAccounts (boolean includeMetaData);

includeMetaData - A boolean value indicating whether the returned payment account objects should include relevant metadata property values.
Successvoid onRetrieveAllPaymentAccountsSuccess (List < PaymentAccountsList > paymentAccountsList);

The success callback returns the paymentAccountsList, which is a set of paymentAccount objects, each of which defines a single payment account registered to the wallet owner, with or without relevant metatdata, depending on the parameters passed in the call.

Note: The data returned may not include current balance information for the accounts. Instead use Refresh an Account Balance.
Failurevoid onPaymentAccountManagerError(PaydiantException exception);

The failure callback returns an instance of PaydiantException for the RETRIEVE_ALL_PAYMENT_ACCOUNTS_EVENT detailing the nature of the failure identified by relevant error codes.
Core Methodpublic List < PaymentAccountData > retrieveAllPaymentAccounts (boolean includeMetaData);

includeMetaData - A boolean value indicating whether the returned payment account objects should include relevant metadata property values.

Returns raw output for each payment account or relevant exception.

Errors

When retrieving payment accounts, the following errors are applicable for the RETRIEVE_ALL_PAYMENT_ACCOUNTS_EVENT:

ErrorDescription
400One or more parameters in the request is missing or invalid.
403Access to the server is prohibited because the user is not logged in.
500An unknown error occurred internally in the server.

Retrieve a Single Payment Account

Invoke this method from the core or UI service package to request the details of a specific payment account currently registered in the user’s wallet.

ItemDescription
UI Methodvoid retrievePaymentAccount (string paymentAccountUri, boolean includeMetaData);

paymentAccountUri - Paydiant’s unique identifier of the account.
includeMetaData - A boolean value indicating whether the returned payment account objects should include relevant metadata property values.
includeMetaData - A boolean value indicating whether the returned payment account objects should include relevant metadata property values.
Successvoid onRetrievePaymentAccountSuccess (PaymentAccountData paymentAccountData);

The success callback returns the paymentAccountList, which is a set of paymentAccount objects, each of which defines a single payment account registered to the wallet owner, with or without relevant metatdata, depending on the parameters passed in the call.

Note: The data returned may not include current balance information for the accounts. Instead use Refresh an Account Balance.
Failurevoid onPaymentAccountManagerError(PaydiantException exception);

The failure callback returns an instance of PaydiantException for the RETRIEVE_PAYMENT_ACCOUNT_EVENT, detailing the nature of the failure identified by relevant error codes.
Core Methodpublic PaymentAccountData retrievePaymentAccount (string paymentAccountUri, boolean includeMetaData);

paymentAccountUri - Paydiant’ s unique identifier for the account.
includeMetaData - A boolean value indicating whether the returned payment account objects should include relevant metadata property values.

Returns raw output for the payment account or relevant exception.

Errors

When retrieving a particular payment account, the following errors are applicable for the RETRIEVE_PAYMENT_ACCOUNT_EVENT:

ErrorDescription
400One or more parameters in the request is missing or invalid.
403Access to the server is prohibited because the user is not logged in.
404The specified payment account could not be located.
500An unknown error occurred internally in the server.
503The paymentAccountUri value is not valid.

Retrieve Account Without Balance Refresh

Invoke this method to retrieve the information for a specified payment account while specifically declining any balance update, which sometimes incurs a fee from payment processors. This method is useful when the payment account information is retrieved for the purpose of editing the account rather than for displaying as a payment selection.

ItemDescription
UI MethodPublic void retrievePaymentAccountWithoutBalanceRefresh (String paymentAccountUri);

paymentAccountUri - Paydiant’s unique identifier of the account.
Successvoid onRetrievePaymentAccountWithoutBalanceRefreshSuccess (PaymentAccountComplete paymentAccountComplete);

The success callback returns the paymentAccountComplete object containing the payment account properties without the balance.
Failurevoid onPaymentAccountManagerError(PaydiantException exception);

The failure callback returns an instance of PaydiantException for the RETRIEVE_PAYMENT_ACCOUNT_WITHOUT_BALANCE_REFRESH_EVENT, detailing the nature of the failure identified by relevant error codes.
Core Methodpublic PaymentAccountComplete retrievePaymentAccountWithoutBalanceRefresh (string paymentAccountUri);

paymentAccountUri - Paydiant’ s unique identifier for the account.

Returns raw output for the payment account or relevant exception.

Errors

When retrieving a payment account excluding balance refresh, the following errors are applicable for the RETRIEVE_PAYMENT_ACCOUNT_WITHOUT_BALANCE_REFRESH_EVENT:

ErrorDescription
400One or more parameters in the request is missing or invalid.
403Access to the server is prohibited because the user is not logged in.
404The specified payment account could not be located.
500An unknown error occurred internally in the server.
503The paymentAccountUri value is not valid.

Refresh an Account Balance

Invoke this method to refresh the balance for the payment or loyalty account specified in the parameter. Developers may want to call this method prior to displaying the payment or loyalty account in the app at the time of payment selection to ensure that the balance is current, particularly since account retrieval does not automatically include a balance refresh operation.

ItemDescription
UI Methodvoid refreshPaymentAccountBalance(String paymentAccountUri);

paymentAccountUri - Paydiant’s unique identifier of the account.
Successvoid onRefreshPaymentAccountBalanceSuccess(AccountBalance accountBalance)

The success callback returns an instance of accountBalance for the payment or loyalty account specified in the request and includes data related to the relevant time and date of the balance, the relevant currency, and other details.
Failurevoid onPaymentAccountManagerError(PaydiantException exception);

The failure callback returns an instance of PaydiantException for the REFRESH_PAYMENT_ACCOUNT_BALANCE_EVENT, detailing the nature of the failure identified by relevant error codes.
Core Methodpublic AccountBalance refreshPaymentAccountBalance(String paymentAccountUri);

paymentAccountUri - Paydiant’ s unique identifier for the account.

Returns raw output for the payment account balance or relevant exception.

Errors

When refreshing a payment account balance, the following errors are applicable for the REFRESH_PAYMENT_ACCOUNT_BALANCE_EVENT:

ErrorDescription
400The balance inquiry failed.
403Access to the server is prohibited because the user is not logged in.
404The specified payment account could not be located.
405The balance is temporarily unavailable.
406Balance retrieval is not supported.
414The balance amount is not valid.
500An unknown error occurred internally in the server.
503The paymentAccountUri value is not valid.

Get Payment Account Configurations

Invoke this method to retrieve the properties that are required or relevant for each payment account type so the forms for adding or editing a payment account can be displayed accordingly in the app.

ItemDescription
UI Methodvoid retrievePaymentAccountConfigurations();
No parameters.
Successvoid onPaymentAccountConfigurationRetrievalSuccess (PaymentAccountFilters paymentAccountFilters);

The success callback returns the PaymentAccountFilters object containing the configuration details for each payment account type.
Failurevoid onPaymentAccountManagerError(PaydiantException exception);

The failure callback returns an instance of PaydiantException for the PAYMENT_ACCOUNT_CONFIGURATION_RETRIEVAL_EVENT, detailing the nature of the failure identified by relevant error codes.
Core MethodPaymentAccountFiltersretrievePaymentAccountConfigurations();

Returns raw output for the payment account configuration details.

Errors

When retrieving payment account configurations, the following errors are applicable for the PAYMENT_ACCOUNT_CONFIGURATION_RETRIEVAL_EVENT:

ErrorDescription
403Access to the server is prohibited because the user is not logged in.
500An unknown error occurred internally in the server.

Get Payment Account Billing Addresses

Invoke this method to obtain the billing addresses associated with each payment account. This information can be used to pre-populate the wallet owner’s information in the adding a payment account form, for convenience, or may also be used when the user is editing the properties for an existing payment account.

ItemDescription
UI Methodvoid retrievePaymentAccountBillingAddresses();
No parameters.
Successvoid onPaymentAccountBillingAddressesRetrievalSuccess (BillingAddressList billingAddressList);

The success callback returns the BillingAddressList object containing the billing address that is associated with each payment account registered in the wallet.
Failurevoid onPaymentAccountManagerError(PaydiantException exception);

The failure callback returns an instance of PaydiantException for the PAYMENT_ACCOUNT_BILLINGADDRESS_RETRIEVAL_EVENT, detailing the nature of the failure identified by relevant error codes.
Core MethodBillingAddressList retrievePaymentAccountBillingAddresses();
No parameters.

Returns raw output for the payment account billing addresses.

Errors

When retrieving payment account billing addresses, the following errors apply to the PAYMENT_ACCOUNT_BILLINGADDRESS_RETRIEVAL_EVENT:

ErrorDescription
403Access to the server is prohibited because the user is not logged in.
500An unknown error occurred internally in the server.

Get All Tender Types

Invoke this method to retrieve a list of all tender types that are supported by the wallet issuer for the purpose of limiting the types of payment account that the user can register. This method is useful during the adding payment account operation in the app because it returns the metadata elements that define each type so the developer can design the form for each type to display only the fields that are relevant for the selected type.

ItemDescription
UI Methodvoid retrieveAllTenderTypes();
No parameters.

or an overloaded instance of
void retrieveAllTenderTypes(Boolean provisioningSupported);

You can invoke an overloaded instance of the method to filter the returned tender types based on whether the wallet issuer allows a new card account to be generated from the app for that tender type.

provisioningSupported - Specifies how the results should be limited. Set the value to TRUE to show only tender types for which provisioning is supported or to FALSE to show only types for which provisioning is not supported.
Successvoid onRetrieveAllTenderTypesSuccess(TenderTypeList tenderTypeList);

The success callback returns the TenderTypeList object detailing all tender types that are supported for the wallet.
Failurevoid onPaymentAccountManagerError(PaydiantException exception);

The failure callback returns an instance of PaydiantException for the RETRIEVE_ALL_TENDER_TYPES_EVENT, detailing the nature of the failure identified by relevant error codes.
Core MethodTenderTypeList retrieveAllTenderTypes();
No parameters.
Filter Resultspublic tenderTypeList retrieveAllTenderTypes (boolean provisioningSupported);

Invoke this overloaded instance of the method to filter the returned tender types based on whether the wallet issuer allows a new card account to be generated from the app for that tender type.

provisioningSupported - Specifies how the results should be limited. Set the value to TRUE to show only tender types for which provisioning is supported or to FALSE to show only types for which provisioning is not supported.

Returns raw output for the TenderTypesList object.

Errors

When retrieving supported tender types, the following errors apply to the RETRIEVE_ALL_TENDER_TYPES_EVENT:

ErrorDescription
403Access to the server is prohibited because the user is not logged in.
500An unknown error occurred internally in the server.

Get One Tender Type

Invoke this method to obtain the collection of properties that are relevant for a tender type of the specified account and network type values. Call this method when a tender type is selected for payment account addition or update so the requirements specific to that type are upheld.

ItemDescription
UI Methodvoid retrieveSpecificTenderType(String paymentAccountTypeUri, String paymentAccountNetworkTypeUri);

paymentAccountTypeUri - Paydiant’s unique code that identifies an account type such as gift, credit, debit, etc.
paymentAccountNetworkTypeUri - Paydiant’s unique code that identifies a payment network such as Visa, Nyce, Amex, etc.
Successvoid onRetrieveSpecificTenderTypeSuccess(TenderType tenderType);

The success callback returns the TenderType definition that matches the values specified in the request.
Failurevoid onPaymentAccountManagerError(PaydiantException exception);

The failure callback returns an instance of PaydiantException for the RETRIEVE_SPECIFIC_TENDER_TYPE_EVENT, detailing the nature of the failure identified by relevant error codes.
Core Methodpublic TenderType retrieveSpecificTenderType(String paymentAccountTypeUri, String paymentAccountNetworkTypeUri);

paymentAccountTypeUri - Paydiant’s unique code that identifies an account type such as gift, credit, debit, etc.
paymentAccountNetworkTypeUri - Paydiant’s unique code that identifies a payment network such as Visa, Nyce, Amex, etc.

Raw output of the TenderType definition or relevant exception.

Errors

When retrieving the details for a particular tender type, the following errors apply to the RETRIEVE_SPECIFIC_TENDER_TYPE_EVENT:

ErrorDescription
400One or more parameters in the request is missing or invalid.
403Access to the server is prohibited because the user is not logged in.
417The specified tender type has not been configured.
500An unknown error occurred internally in the server.

Add Payment Account (Single Step)

Invoke this method to submit payment account information input by the wallet user for the purpose of linking an existing payment instrument, such as a credit card, debit card, gift card, etc., to the wallet as a mobile payments tender.

Do not use emoji characters in the nickname attribute because on some networks it can cause the payment to fail.

ItemDescription
UI Methodvoid addPaymentAccount(PaymentAccountData paymentAccountData);

paymentAccountData - The complete set of metadata that defines the payment account to be added to the wallet. The property values required for this object may vary depending on the type of payment account being submitted. For example, a credit card or debit account requires the user billing address, but a gift card does not.
Successvoid onAddPaymentAccountSuccess(DetailedPaymentAccount detailedPaymentAccount);

The success callback returns an instance of the DetailedPaymentAccount object defining the account as it was linked to the wallet, including Paydiant-generated identifiers.
Failurevoid onPaymentAccountManagerError(PaydiantException exception);

The failure callback returns an instance of PaydiantException for the ADD_PAYMENT_ACCOUNT_METADATA_EVENT, detailing the nature of the failure identified by relevant error codes.
Core MethodDetailedPaymentAccount addPaymentAccount(paymentAccountData PaymentAccountData);

paymentAccountData - The complete set of metadata that defines the payment account to be added to the wallet. The property values required for this object may vary depending on the type of payment account being submitted. For example, a credit card or debit account requires the user billing address, but a gift card does not.

Returns raw output for the newly linked payment account or relevant exception.

Errors

When adding a payment account, the following errors are applicable for the ADD_PAYMENT_ACCOUNT_MAETADATA_EVENT:

ErrorDescription
400One or more parameters in the request is invalid or missing.
402The specified payment card value is invalid.
403Access to the server is prohibited because the user is not logged-in.
404The specified payment account could not be located.
406The expiration date specified for the account is not valid.
410The specified payment account already exists in the wallet.
414The specified account contains insufficient funds for validation.
419The tender type specified for the payment account does not match the type for the card number provided.
420The network provider specified for the payment account does not match that of the card number provided.
421The payment account could not be added due to an error.
426The Issuer Identification Number (IIN) associated with the payment account specified is not supported for the wallet.
500An unknown error occurred internally in the server.
508Network verification of the payment account failed.

Non-Metadata Implementations

To Be Deprecated

Both UI and Core implementations pass values for only the default properties used to define a payment account in the wallet. The properties passed in this method are static and do not vary by tender type and cannot define custom fields of data.

ItemDescription
UI Methodvoid addPaymentAccount(PaymentAccountInfo paymentAccountInfo);

paymentAccountinfo - The set of properties, without metadata, that defines a payment account to be added to the wallet.
Successvoid onAddPaymentAccountSuccess(PaymentAccounAdded paymentAccountAdded);

The success callback returns an instance of the PaymentAccountAdded object defining the account as it was linked to the wallet.
Failurevoid onPaymentAccountManagerError(PaydiantException exception);

The failure callback returns an instance of PaydiantException for the ADD_PAYMENT_ACCOUNT_EVENT, detailing the nature of the failure identified by relevant error codes.

|Core Method|PaymentAccountAdded addPaymentAccount(paymentAccountInfo PaymentAccountInfo);

Raw output for the added payment account or relevant exception.|

Provision a Payment Account (Single Step)

Invoke this method to submit the relevant data supplied in the app by the wallet owner for the purpose of generating a new payment account in the wallet user’s name that is automatically registered in the wallet.

ItemDescription
UI Methodvoid provisionAccount(ProvisionCard provisionCard);

provisionCard - The set of metadata that defines the new payment account application. The property values required for this object may vary depending on the type of payment account being provisioned. For example, a credit card or debit account requires the user billing address, but a gift card does not.
Successvoid onProvisionAccountSuccess(ProvisionCardResponse provisionCardResponse);

The success callback returns an instance of the ProvisionCardResponse object defining the results of the account application and provisioning, as well as the new account details, if applicable.
Failurevoid onPaymentAccountManagerError(PaydiantException exception);

The failure callback returns an instance of PaydiantException for the PROVISION_ACCOUNT_EVENT, detailing the nature of the failure identified by relevant error codes.
Core Methodpublic ProvisionCardResponse provisionAccount(ProvisionCard provisionCard);

provisionCard - The set of metadata that defines the new payment account application. The property values required for this object may vary depending on the type of payment account being provisioned. For example, a credit card or debit account requires the user billing address, but a gift card does not.

Returns raw output for the result of the application and newly created account or relevant exception.

Errors

When provisioning a new payment account, the following errors are applicable for the PROVISION_ACCOUNT_EVENT:

ErrorDescription
400One or more parameters in the request is invalid or missing.
403Access to the server is prohibited because the user is not logged-in.
404The specified payment account could not be located.
411Card provisioning was declined by the processor.
414The card provisioning limit has been exceeded.
421The payment account could not be added due to an error.
426Card provisioning is not supported in this use case.
500An unknown error occurred internally in the server.
502An error occurred while trying to reach the processor.

Start Payment Account Enrollment (Variable Steps)

Invoke this method to initialize the process for designating a payment account as a mobile payments tender in the wallet. This process is applicable to both existing payment accounts (credit cards, debit cards, gift cards, etc.) and newly-issued accounts (a new gift card, loyalty card, private label credit card, etc.). Depending on the type of payment account being enrolled in the wallet and the specifications from the processing service, the response may indicate that the enrollment is complete or that additional information is required in order to further process the enrollment. In the latter case, collect the additional information to pass in the Continue Payment Account Enrollment (Variable Steps) call.

ItemDescription
UI Methodvoid startPaymentAccountEnrollment (StartPaymentAccountEnrollment startPaymentAccountEnrollment);

startPaymentAccountEnrollment - An instance of the object defining the basic information about the payment account to be enrolled, such as whether it is an existing account LINK or a new account PROVISION, payment account type, network type, and any additional data that may be relevant for the specific payment account.
Successvoid onStartPaymentAccountEnrollmentSuccess (PaymentAccountEnrollment paymentAccountEnrollment);

paymentAccountEnrollment - An object that specifies a unique identifier for the generated enrollment event, as well as the state of that event. If enrollmentState=END, enrollment is complete. If enrollmentState=MORE_INFO, this object will specify the additional data required before enrollment can resume. Collect that input and pass it in the Continue Payment Account Enrollment (Variable Steps) call.
Failurevoid onPaymentAccountManagerError (PaydiantException exception);

The failure callback returns an instance of PaydiantException for the START_PAYMENT_ACCOUNT_ENROLLMENT_EVENT, detailing the nature of the failure identified by relevant error codes.
Core MethodPaymentAccountEnrollment startPaymentAccountEnrollment (StartPaymentAccountEnrollment startPaymentAccountEnrollment);

startPaymentAccountEnrollment - An instance of the object defining the basic information about the payment account to be enrolled, such as whether it is an existing account (LINK) or a new account (PROVISION), payment account type, network type, and any additional data that may be relevant for the specific payment account.

Returns raw output for the new enrollment event and its state or relevant exception.

Errors

The following error states are applicable in the PaydiantException instance returned for the START_PAYMENT_ACCOUNT_ENROLLMENT_EVENT.

See Variable-Step Payment Account Enrollment Statuses 790 - 809 for relevant ErrorInformation.errorCode status and values.

ErrorDescription
400 (BAD_REQUEST)Required additional data values are missing.
The enrollmentType is not specified.
Supported tender types could not be located.
Payment account already exists in wallet.
Duplicates are not allowed.
500(INTERNAL_SERVER_ERROR)An internal server error has occurred.
A processing error has occurred.

Continue Payment Account Enrollment (Variable Steps)

Invoke this method to submit additional information required in the enrollment process for an enrollment event with a state of MORE_INFO. The enrollment process can have a variable number of steps depending on the information required and submitted throughout the process. Therefore, the properties required in this call will have been specified in the response to either the Start Payment Account Enrollment (Variable Steps) call or the immediately previous instance of this call.

This call should continue to be invoked until the enrollmentState in the response is END.

ItemDescription
UI Methodvoid continuePaymentAccountEnrollment (ContinuePaymentAccountEnrollment continuePaymenParameters

continuePaymentAccountEnrollment - An instance of the object that identifies the associated enrollment event and passes the additional data that was specified in the previous enrollment step.
Successvoid onContinuePaymentAccountEnrollmentSuccess (PaymentAccountEnrollment paymentAccountEnrollment);

paymentAccountEnrollment - An object that informs the state of the enrollment and, if applicable, specifies the additional properties required to be passed in the next step.
Failurevoid onPaymentAccountManagerError (PaydiantException exception);

The failure callback returns an instance of PaydiantException for the CONTINUE_PAYMENT_ACCOUNT_ENROLLMENT_EVENT, detailing the nature of the failure identified by relevant error codes.
Core MethodPaymentAccountEnrollment continuePaymentAccountEnrollment (ContinuePaymentAccountEnrollment continuePaymentAccountEnrollment);

continuePaymentAccountEnrollment - An instance of the object identifying the associated enrollment event and passing the additional data that was specified in the previous enrollment step.

Returns raw output for the PaymentAccountEnrollment class or relevant exception.

Errors

The following error states are applicable in the PaydiantException instance returned for the CONTINUE_PAYMENT_ACCOUNT_ENROLLMENT_EVENT. See Variable-Step Payment Account Enrollment Statuses 790 - 809 for relevant ErrorInformation.errorCode status and values.

ErrorDescription
400 (BAD_REQUEST)PaydiantCorrelationId not found.
Payment account already exists in wallet.
Duplicates are not allowed.
500 (INTERNAL_SERVER_ERROR)An internal server error has occurred.
A processing error has occurred.

Retrieve Payment Account Enrollments

Invoke this method to retrieve a list of enrollments that are still pending completion so the user can select one to resume or cancel the enrollment, if desired.

ItemDescription
UI Methodvoid retrieveAllPaymentAccountEnrollments();
Successvoid onRetrieveAllPaymentAccountEnrollmentSuccess (List < PaymentAccountEnrollment > paymentAccountEnrollments);

paymentAccountEnrollments - An array of paymentAccountEnrollment instances that still have an enrollmentState of MORE_INFO, indicating that they can still be resumed and completed.
Failurevoid onPaymentAccountManagerError (PaydiantException exception);

The failure callback returns an instance of PaydiantException for the PAYMENT_ACCOUNT_ENROLLMENT_RETRIEVAL_EVENT, detailing the nature of the failure identified by relevant error codes.
Core MethodList < PaymentAccountEnrollment > retrieveAllPaymentAccountEnrollments();

Returns raw output for the list of incomplete PaymentAccountEnrollment instances or relevant exception.

Errors

The following error states are applicable in the PaydiantException instance returned for the PAYMENT_ACCOUNT_ENROLLMENT_RETRIEVAL_EVENT.

ErrorDescription
500 (INTERNAL_SERVER_ERROR)An internal server error has occurred.

Cancel Payment Account Enrollments

Invoke this method to delete an incomplete payment account enrollment that is still active.

ItemDescription
UI Methodvoid cancelPaymentAccountEnrollment(String padiantCorrelationId);

paydiantCorrelationId - The unique identifier of the enrollment.
Successvoid onCancelPaymentAccountEnrollmentSuccess (Boolean result);

result - A Boolean response indicating whether the enrollment was deleted.
Failurevoid onPaymentAccountManagerError (PaydiantException exception);

The failure callback returns an instance of PaydiantException for the CANCEL_PAYMENT_ACCOUNT_ENROLLMENT_EVENT, detailing the nature of the failure identified by relevant error codes.
Core MethodcancelPaymentAccountEnrollment(String paydaintCorrelationId);

raw output for the result or relevant exception.

Errors

The following error states are applicable in the PaydiantException instance returned for the CANCEL_PAYMENT_ACCOUNT_ENROLLMENT_EVENT.

ErrorDescription
500 (INTERNAL_SERVER_ERROR)An internal server error has occurred.

Delete Payment Account

Invoke this method to remove a payment account from the wallet application so a user can suspend wallet use of that account. Note that this operation does not cancel the card associated with the payment account.

ItemDescription
UI Methodvoid deletePaymentAccount(String paymentAccountUri);

paymentAccountUri - Paydiant’s unique identifier of the account.
Successvoid onDeletePaymentAccountSuccess();

The success callback does not return any additional data other than confirmation that the operation succeeded.
Failurevoid onPaymentAccountManagerError(PaydiantException exception);

The failure callback returns an instance of PaydiantException for the DELETE_PAYMENT_ACCOUNT_EVENT, detailing the nature of the failure identified by relevant error codes.
Core MethodBoolean deletePaymentAccount(String paymentAccountUri);

paymentAccountUri - Paydiant’ s unique identifier for the account.

Returns raw output for the successful completion or relevant exception.

Errors

When deleting a payment account, the following errors are applicable for the DELETE_PAYMENT_ACCOUNT_EVENT:

ErrorDescription
400One or more parameters in the request is missing or invalid.
403Access to the server is prohibited because the user is not logged in.
404The specified payment account could not be located.
500An unknown error occurred internally in the server.
503The paymentAccountUri value is not valid.

Verify Payment Account

Invoke this method when a payment account has been added to the wallet that requires double deposit verification in order to submit the deposit values, as provided by the wallet owner, for verification. This verification step is often required for debit accounts and must be completed before the payment account can be activated for use in the wallet.

ItemDescription
UI Methodvoid verifyPaymentAccount (PaymentAccountVerification paymentAccountVerification);

paymentAccountVerification - The object that contains the payment account identification and the values of the two verification deposits made by the server.
Successvoid onVerifyPaymentAccountSuccess();

The success callback does not return any additional data other than confirmation that the operation completed.
Failurevoid onPaymentAccountManagerError(PaydiantException exception);

The failure callback returns an instance of PaydiantException for the VERIFY_PAYMENT_ACCOUNT_EVENT, detailing the nature of the failure identified by relevant error codes.
Core MethodPaymentAccountSuccess verifyPaymentAccount (PaymentAccountVerification paymentAccountVerification);

paymentAccountVerification - The object that contains the payment account identification and the values of the two verification deposits made by the server.

Returns raw output for the successful completion or relevant exception.

Errors

When verifying a payment account, the following errors are applicable for the VERIFY_PAYMENT_ACCOUNT_EVENT:

ErrorDescription
400One or more parameters in the request is missing or invalid.
403Access to the server is prohibited because the user is not logged in.
404The specified payment account could not be located.
500An unknown error occurred internally in the server.
503The paymentAccountUri value is not valid.

Update Payment Account

Implements the function to invoke this method to apply property edits (for example, account nickname) made to a payment account by the wallet owner from within the app.

ItemDescription
UI Methodvoid updatePaymentAccount(PaymentAccountData paymentAccountData);

paymentAccountData - set of metadata property values to edit in the specified payment account.
Successvoid onUpdatePaymentAccountSuccess(DetailedPaymentAccount detailedPaymentAccount);

The success callback returns an instance of the DetailedPaymentAccount instance showing the updated values.
Failurevoid onPaymentAccountManagerError(PaydiantException exception);

The failure callback returns an instance of PaydiantException for the UPDATE_PAYMENT_ACCOUNT_METADATA_EVENT, detailing the nature of the failure identified by relevant error codes.
Core MethodDetailedPaymentAccount updatePaymentAccount (paymentAccountData PaymentAccountData);

paymentAccountData - The set of set of metadata property values to edit in the specified payment account.

Returns raw output for the updated payment account properties or relevant exception.

Errors

When adding a payment account, the following errors are applicable for the UPDATE_PAYMENT_ACCOUNT_MAETADATA_EVENT:

ErrorDescription
400One or more parameters in the request is invalid or missing.
403Access to the server is prohibited because the user is not logged in.
404The specified payment account could not be located.
406The expiration date specified for the account is not valid.
410The specified payment account already exists in the wallet.
414The specified account contains insufficient funds for validation.
417One or more arguments included in the request is not valid.
500An unknown error occurred internally in the server.
503The paymentAccountUri provided is not valid.

Gift Account Management Services

The following methods deal specifically with GIFT-type payment accounts and are exposed through separate services to manage the unique nature of gift accounts.

ServiceDescription
Gift UI Servicecom.paydiant.android.ui.service.giftaccount.GiftAccountManagerService
Gift Core Servicecom.paydiant.android.core.facade.GiftAccountManagerFacade

Set UI package gift account service listeners

In order to invoke the callback methods returned by the Paydiant service in response to the methods invoked by the Gift Account services, the developer must set an implementation of the applicable listener interfaces in the UI Service class.

ItemDescription
Set Gift Listenervoid setGiftAccountManagementListener (IGiftAccountManagementListener listener);

Listener Interfaces:com.paydiant.android.ui.service.giftaccount.IGiftAccountManagementListener

or an overridden instance of com.paydiant.android.ui.service.giftaccount.GiftAccountManagementListenerAdapter
Remove Listenervoid removeListener();

Call this method from within the corresponding service class in order to remove the associated listener and set it to null.

Get account load configuration

Invoke this method to obtain the specifications relevant to loading or reloading the balance of a gift account of the account and networks types specified. This method should be called prior to the Load a New Payment Account method so the configuration values returned can be applied to the load options presented in the app.

ItemDescription
UI Methodvoid retrieveLoadConfiguration(String paymentAccountTypeUri, String paymentAccountNetworkTypeUri);

paymentAccountTypeUri - Paydiant’s unique code that identifies an account type such as gift, credit, debit, etc.
paymentAccountNetworkTypeUri - Paydiant’s unique code that identifies a payment network such as Visa, Nyce, Amex, etc.
Successvoid onRetrieveLoadConfigurationSuccess (List < LoadConfiguration > loadConfiguration);

The success callback returns the LoadConfiguration definition for the specified tender type or, if not specified, the list of definitions for each supported tender type in the wallet.
Failurevoid onGiftAccountManagementError (PaydiantException exception);

The failure callback returns an instance of PaydiantException for the RETRIEVE_LOAD_CONFIGURATION_EVENT, detailing the nature of the failure identified by relevant error codes.
Core MethodPaymentAccountFilters retrievePaymentAccountConfigurations();
No paramters.

Returns raw output for the load configuration details.

Errors

When retrieving load configurations, the following errors are applicable for the RETRIEVE_LOAD_CONFIGURATION_EVENT:

ErrorDescription
400One or more of the input parameters is invalid.
403Access to the server is prohibited because the user is not logged in.
500An unknown error occurred internally in the server.

Load a new payment account

Invoke this method to specify a starting balance for a newly provisioned payment account (a GIFT account), the tender for which is procured from another existing payment account.

ItemDescription
UI Methodvoid loadPaymentInstrument(LoadPaymentAccountParameters loadPaymentAccountParameters);

loadPaymentAccountParameters - The object instance that specifies the details for the loading event, such as the payment account from which the load funds will be transfered and the amount and currency type.

|Success|void onLoadPaymentInstrumentSuccess (loadPaymentAccountResponse LoadPaymentAccountResponse);

The success callback returns the response object that details the results of the load operation.| |Failure|void onGiftAccountManagementError (PaydiantException exception);

The failure callback returns an instance of PaydiantException for the LOAD_PAYMENT_INSTRUMENT_EVENT, detailing the nature of the failure identified by relevant error codes.| |Core Method|loadPaymentAccountResponse loadPaymentInstrument (LoadPaymentAccountParameters loadPaymentAccountParameters);

loadPaymentAccountParameters - The object instance that specifies the details for the loading event, such as the payment account from which the load funds will be transfered and the amount and currency type.

Returns raw output for the account load results or relevant exception.|

Errors

When retrieving load configurations, the following errors are applicable for the LOAD_PAYMENT_INSTRUMENT_EVENT:

ErrorDescription
400One or more of the input parameters is invalid.
403Access to the server is prohibited because the user is not logged in.
409The card provisioning load limit has been exceeded.
410The load amount specified is not valid.
414The request URI is too long - operation failed.
420The maximum balance for the card has been exceeded.
421The maximum load amount has been exceeded.
426The operation is not supported.
500An unknown error occurred internally in the server.
501An error has occurred during processing.