API Reference for iOS

casan141saas
The following topics provide information about the classes, enums, and response beans of the iOS SDK:
In the context of this CA solution, the term "accounts" covers both payment card accounts and bank accounts.
Class AuthenticationHandler
This AuthenticationHandler class provides methods that can be called by the business app or authenticator app. The app can use these methods to activate CA Strong authentication for a user’s accounts and to authenticate the user.
Code Snippet
@interface AuthenticationHandler : NSObject
-(TransactionDetailsResponse *) getTransaction;
-(TransactionDetailsResponse *) getTransaction: (NSString *) transactionId AccountId: (NSString *)accountId AccountType: (NSString *)accountType;
-(AuthenticationResponse *) authenticateUsingConsent:(TransactionDetailsResponse *) transactionDetailsResponse;
-(void) verifyPINUsingTouchID:(NSString *)touchIDForAutoEnroll
withTxnalDetailsResponse:(TransactionDetailsResponse *)detailResponse
SuccessHandler :(void(^)(VerifyPINResponse *)) onSuccess
FailureHandler :(void(^)(VerifyPINResponse *)) onFailure
FallbackHandler :(void(^)(void)) onFallback
CancelHandler :(void(^)(void)) onCancel;
-(void) authenticateUsingTouchID:(TransactionDetailsResponse *) transactionDetailsResponse
SuccessHandler :(void(^)(AuthenticationResponse *)) onSuccess
FailureHandler :(void(^)(AuthenticationResponse *)) onFailure
FallbackHandler :(void(^)(void)) onFallback
CancelHandler :(void(^)(void)) onCancel;
-(AuthenticationResponse *) authenticateUsingUserPin:(TransactionDetailsResponse *) transactionDetailsResponse :(NSString *)userPin;
-(CancelTransactionResponse *) cancelTransaction:(TransactionDetailsResponse *) transactionDetailsResponse;
-(AccountActivationDetails *) verifyActivation :(NSString *)activationCode
:(NSString *)activationRefId
:(NSString *)postURL
:(NSString *)displayName
:(NSString *)pin;
-(ActivationAcknowledgementResponse *) setPin:(NSString *)accountId :(NSString *)userPin;
-(AccountDeletionResponse *)deleteAccount: (AccountDetails *)mAccountDetails;
-(NSMutableArray *) getAllEnrolledAccounts;
-(BOOL) setURL: (NSString *) orgName : (NSString *) newURL;
-(void) generateOTP : (AccountDetails *)mAccountDetails
SuccessHandler: (void(^)(OTPResponse *)) onSuccess
FailureHandler: (void(^)(OTPResponse *)) onFailure
FallbackHandler :(void(^)(void)) onFallback
CancelHandler :(void(^)(void)) onCancel;
-(void) generateOTP : (AccountDetails *)mAccountDetails
PropertyDict: (NSDictionary *)propertyDict
SuccessHandler: (void(^)(OTPResponse *)) onSuccess
FailureHandler: (void(^)(OTPResponse *)) onFailure
FallbackHandler :(void(^)(void)) onFallback
CancelHandler :(void(^)(void)) onCancel;
-(OTPResponse *) generateOTP : (AccountDetails *)mAccountDetails userPin: (NSString *)userPin;
-(OTPResponse *) generateOTP : (AccountDetails *)mAccountDetails userPin: (NSString *)userPin PropertyDict: (NSDictionary *)propertyDict;
-(NSMutableArray *) getAllAuthenticationTypes;
-(UpdateAuthenticationResponse *) updateAuthenticationType :(Authentication *)authentication PIN :(NSString *)pin;
-(BOOL) isPINSetup;
-(VerifyPINResponse *) verifyPIN :(NSString *)pin;
-(VerifyPINResponse *) verifyPIN :(NSString *)pin PropertyDict: (NSDictionary *)propertyDict;
-(ChangePINResponse *) changePIN :(NSString *)oldPin :(NSString *)newPin;
-(NSMutableArray *)getEnabledAuthenticationTypes;
-(ProfileInfo *)getProfileInfo;
-(MultipleAccountActivationDetails *) verifyActivation :(NSMutableArray <MultipleAccountActivationParams *>*) multipleAccountActivationParamsArray
:(NSString *)serverURL
:(NSString *)pin;
-(MultipleAccountActivationDetails *) verifyActivation :(NSMutableArray <MultipleAccountActivationParams *>*) multipleAccountActivationParamsArray
:(NSString *)serverURL;
-(NSMutableArray <ActivationAcknowledgementResponse *>*) setPin:(NSString*) userPin;
-(BOOL) unenrollAccounts: (BOOL) removePinSetup removeFromRemoteAll : (BOOL) removeFromServer;
-(BOOL) unenrollAccounts: (NSArray<AccountDetails *> *) accounts removeFromRemote : (BOOL) removeFromServer;
-(VerifyPINResponse *) verifyPIN:(NSString *)pin :(TransactionDetailsResponse *)transactionDetailsResponse :(NSString *)autoEnrollId;
-(AutoEnrollmentResponse *)autoEnrollAccount:displayName;
-(NSString *) getSDKVersion;
-(BOOL)isDeviceJailBroken __attribute__((deprecated));
-(SSLPinningConfigResponse *)configureSSLPinning:(SSLPinningConfigs *)sslPinningConfigs;
-(void)setBiometricDialogTitle:(NSString *)title;
-(void)setBiometricFallbackTitle:(NSString *)title;
-(void)setBiometricCancelTitle:(NSString *)title;
@end
authenticateUsingConsent
Applies device authentication.
Use this API when you do not want to apply user authentication (that is, PIN or biometric authentication) for a low-risk transaction. The use of device authentication ensures that the mobile device on which CA Strong Authentication has been activated for the user’s account is used in the authentication process. For more information about device authentication, see CA Strong Authentication SDKs.
Code Snippet
- (AuthenticationResponse *) authenticateUsingConsent: (TransactionDetailsResponse *) transactionDetailsResponse
Parameters
Parameter
Mandatory?
Description
transactionDetailsResponse
Yes
TransactionDetailsResponse object.
Return Value
This method returns an AuthenticationResponse object, which contains the status and error code.
The status can be one of the following values:
  • SUCCESS:
    Operation was successful.
  • FAILURE:
    Operation failed.
If the status is FAILURE, then one of the following error codes is returned:
  • ERROR_INVALID_ARGUMENT:
    Incorrect details were passed.
  • ERROR_SERVER_UNREACHABLE:
    Server is unreachable.
  • ERROR_ACCOUNT_NOT_FOUND:
    Invalid account.
  • ERROR_SERVER_INTERNAL:
    Server has returned an error.
  • ERROR_INVALID_AUTHENTICATION_TYPE:
    Invalid AuthenticationType object present in the request.
  • ERROR_NO_TRANSACTION_AVAILABLE
    : There are no pending transactions available for the user.
  • ERROR_PINNING_FAILURE:
    The SSL pinning has resulted in failure.
See
AuthenticationResponse for more information.
Exception
None.
authenticateUsingUserPin
Applies user authentication by using the user PIN.
This is one of the APIs for applying user authentication. For more information about user authentication, see CA Strong Authentication SDKs.
Code Snippet
- (AuthenticationResponse *) authenticateUsingUserPin: (TransactionDetailsResponse *) transactionDetailsResponse: (NSString *) userPin
Parameters
Parameter
Mandatory?
Description
transactionDetailsResponse
Yes
TransactionDetailsResponse object.
userPin
Yes
User PIN.
Return Value
This method returns an AuthenticationResponse object, which contains the status and error code.
The status can be one of the following values:
  • SUCCESS:
    Operation was successful.
  • FAILURE:
    Operation failed.
If the status is FAILURE, then one of the following error codes is returned:
  • ERROR_INVALID_ARGUMENT:
    Incorrect details were passed.
  • ERROR_SERVER_UNREACHABLE:
    Server is unreachable.
  • ERROR_ACCOUNT_NOT_FOUND:
    Invalid account.
  • ERROR_SERVER_INTERNAL:
    Server has returned an error.
  • ERROR_INVALID_AUTHENTICATION_TYPE:
    Invalid AuthenticationType object present in the request.
  • ERROR_SDK_INTERNAL
    :  Internal server error.
  • ERROR_ATTEMPTS_EXHAUSTED
    : The user exhausted the authentication attempts.
  • ERROR_NO_TRANSACTION_AVAILABLE
    : There are no pending transactions available for the user.
  • ERROR_PINNING_FAILURE:
    The SSL pinning has resulted in failure.
See
AuthenticationResponse for more information.
Exception
None.
authenticateUsingTouchID
Authenticates the user by using the biometric option.
This is one of the APIs for applying user authentication. For more information about user authentication, see CA Strong Authentication SDKs.
Code Snippet
- (void) authenticateUsingTouchID:(TransactionDetailsResponse *) transactionDetailsResponse
SuccessHandler :(void(^)(AuthenticationResponse *)) onSuccess
FailureHandler :(void(^)(AuthenticationResponse *)) onFailure
FallbackHandler :(void(^)(void)) onFallback
CancelHandler :(void(^)(void)) onCancel;
Parameters
Parameter
Mandatory?
Description
transactionDetailsResponse
Yes
TransactionDetailsResponse object.
onSuccess
Yes
Function to handle the Success response.
onFailure
Yes
Function to handle the Failure response.
onFallback
Yes
Function to handle the scenario in which the user selects the User PIN option for authentication.
onCancel
Yes
Function to handle the scenario in which the user cancels or closes the biometric authentication dialog.
Return Value
This method returns an AuthenticationResponse object, which contains the status and error code.The status can be one of the following values:
  • SUCCESS:
    Operation was successful.
  • FAILURE:
    Operation failed.
If the status is FAILURE, then one of the following error codes is returned:
  • ERROR_INVALID_ARGUMENT:
    Invalid value passed for the TransactionDetailsResponse parameter.
  • ERROR_INVALID_AUTHENTICATION_TYPE:
    Authentication type is not biometric authentication.
  • ERROR_NO_BIOMETRIC_AVAILABLE:
    Biometric authentication is not enabled on this device.
  • ERROR_SERVER_UNREACHABLE:
    Server is unreachable.
  • ERROR_ACCOUNT_NOT_FOUND:
    Invalid account.
  • ERROR_SERVER_INTERNAL:
    Server has returned an error
  • ERROR_SDK_INTERNAL
    : Internal server error.
  • ERROR_ATTEMPTS_EXHAUSTED
    : The user exhausted the authentication attempts.
  • ERROR_NO_TRANSACTION_AVAILABLE
    : There are no pending transactions available for the user.
  • ERROR_PINNING_FAILURE:
    The SSL pinning has resulted in failure.
See AuthenticationResponse for more information.
Exception
None.
autoEnrollAccount
Auto-enrolls a replacement card account.
Code Snippet
- (autoEnrollmentResponse *)autoEnrollAccount:displayName;
Parameters
Parameter
Mandatory?
Description
displayName
Yes
Display name for the auto-enrolled account.
This name can be derived from, for example, the card number.
Return Value
This method returns an AutoEnrollmentResponse object, which contains the auto-enrollment details for the replacement card account.
The status can be one of the following values:
  • SUCCESS:
    Operation was successful.
  • FAILURE:
    Operation failed.
If the status is FAILURE, then one of the following errorCode values is returned:
  • ERROR_SERVER_UNREACHABLE:
    Server is not reachable because, for example, the server URL is incorrect or the server is temporarily unavailable.
  • ERROR_DISPLAY_NAME_ALREADY_EXISTS:
    Display name already exists in the database.
  • ERROR_INVALID_DISPLAY_NAME:
    Display name is not valid because, for example, it is NULL or an empty string.
  • ERROR_AUTO_ENROLLMENT_FAILURE:
    Auto-enrollment operation failed on the server. Display a Transaction Rejected message.
  • ERROR_AUTHENTICATION_FAILURE:
    Authentication of the new account failed after successful auto-enrollment. Display a Transaction Rejected message.
  • INTERNAL_SERVER_ERROR:
    Internal server error occurred.
  • ERROR_PINNING_FAILURE:
    The SSL pinning has resulted in failure.
  • ERROR_NO_TRANSACTION_AVAILABLE
    : There are no pending transactions available for the user.
See
AutoEnrollmentResponse
for more information.
Exception
None.
cancelTransaction
Cancels the transaction specified by a TransactionDetailsResponse object.
Code Snippet
- (CancelTransactionResponse *) cancelTransaction: (TransactionDetailsResponse *) transactionDetailsResponse
Parameters
Parameter
Mandatory?
Description
transactionDetailsResponse
Yes
TransactionDetailsResponse object.
Return Value
This method returns a CancelTransactionResponse object, which contains the status and errorCode.
The status can be one of the following values:
  • SUCCESS:
    Operation was successful.
  • FAILURE:
    Operation failed.
If the status is FAILURE, then one of the following errorCode values is returned:
  • ERROR_INVALID_ARGUMENT:
    Incorrect details were passed.
  • ERROR_SERVER_UNREACHABLE:
    Server is unreachable.
  • ERROR_SDK_INTERNAL
    :  Internal server error.
  • ERROR_NO_TRANSACTION_AVAILABLE
    : There are no pending transactions available for the user.
  • ERROR_PINNING_FAILURE:
    The SSL pinning has resulted in failure.
See
CancelTransactionResponse for more information.
Exception
None.
changePIN
Changes the user PIN.
Code Snippet
- (ChangePINResponse *) changePIN: (NSString *) oldPin : (NSString *) newPin
Parameters
Parameter
Mandatory?
Description
oldPin
Yes
Old user PIN.
newPin
Yes
New user PIN.
Return Value
Returns a ChangePinResponse object, which contains the status and error code.
The status can be one of the following values:
  • SUCCESS:
    Operation was successful.
  • FAILURE:
    Operation failed.
If the status is FAILURE, then one of the following error codes is returned:
  • ERROR_INVALID_PIN:
    Invalid PIN passed to the method.
  • ERROR_NO_ACTIVE_ACCOUNTS
    : No active accounts are present.
  • ERROR_SERVER_INTERNAL
    : Server has returned an error.
  • ERROR_SERVER_UNREACHABLE
    : Server is unreachable.
  • ERROR_ATTEMPTS_EXHAUSTED
    : Maximum attempts utilized for authentication.
  • ERROR_INCORRECT_PIN
    : Retry providing correct pin until maximum attempts allowed.
  • ERROR_INACTIVE_ACCOUNT
    : Account is inactive, Please contact administrator.
  • pin_not_available
    : The Pin setup is not done.
  • ERROR_PINNING_FAILURE:
    The SSL pinning has resulted in failure.
See ChangePinResponse for more information.
Exception
None.
deleteAccount
Deletes the account specified by an AccountDetails object.
This method will be deprecated in a future release. The unenrollAccounts API can be used to delete a single or multiple accounts. This overloaded API is described later in this table.
Code Snippet
- (AccountDeletionResponse *) deleteAccount: (AccountDetails *) mAccountDetails
Parameters
Parameter
Mandatory?
Description
account
Yes
AccountDetails object.
Return Value
Returns an AccountDeletionResponse object, which contains the status and errorCode.
The status can be one of the following values:
  • SUCCESS:
    Operation was successful.
  • FAILURE:
    Operation failed.
If the status is FAILURE, then the one of the following errorCode values is returned:
  • ERROR_INVALID_ARGUMENT:
    Incorrect details were passed.
  • ERROR_ACCOUNT_NOT_FOUND:
    Invalid account.
  • INTERNAL_SERVER_ERROR:
    Internal server error occurred.
  • ERROR_PINNING_FAILURE:
    The SSL pinning has resulted in failure.
See
AccountDeletionResponse for more information.
Exception
None.
generateOTP (for Biometric authentication and when transaction data signing is not enabled)
Generates an OTP in the Offline mode for the specified account. This method is to be used when the user selects the Biometric authentication type and transaction data signing is not enabled.
Code Snippet
- (void) generateOTP: (AccountDetails *) mAccountDetails
SuccessHandler: (void(^)(OTPResponse *)) onSuccess
FailureHandler: (void(^)(OTPResponse *)) onFailure
FallbackHandler: (void(^)(void)) onFallback
CancelHandler: (void(^)(void)) onCancel;
Parameters
Parameter
Mandatory?
Description
mAccountDetails
Yes
AccountDetails object.
onSuccess
Yes
Function to handle the Success response.
onFailure
Yes
Function to handle the Failure response.
onFallBack
Yes
Function to handle the scenario in which the user selects the PIN option. In other words, the user opts to use PIN authentication instead of continuing with Biometric authentication.
onCancel
Yes
Function to handle the scenario in which the user cancels or closes the Biometric authentication dialog.
Return Value
If the Generate OTP operation is successful, then the method returns an OTPResponse object, which contains the status and errorCode.The status can be one of the following values:
  • SUCCESS:
    Operation was successful.
  • FAILURE:
    Operation failed.
If the status is FAILURE, then one of the following errorCode values is returned:
  • ERROR_INVALID_ARGUMENT
    : Incorrect details were passed.
  • ERROR_INVALID_AUTHENTICATION_TYPE
    : Invalid AuthenticationType object present in the request.
  • ERROR_NO_BIOMETRIC_AVAILABLE
    : Biometric authentication is not enabled on this device.
  • ERROR_INVALID_PIN
    : Invalid PIN.
  • ERROR_INVALID_SIGNING_KEY
    : Signing data not found.
  • ERROR_ACCOUNT_NOT_FOUND
    : Account not present in the database.
See OTPResponse for more information.
Exception
None.
generateOTP (for PIN authentication and when transaction data signing is not enabled)
Generates an OTP in the Offline mode for the specified account. This method is to be used when the user selects the PIN authentication type and transaction data signing is not enabled.
Code Snippet
- (OTPResponse *) generateOTP: (AccountDetails *) mAccountDetails
userPin: (NSString *) userPin
Parameters
Parameter
Mandatory?
Description
mAccountDetails
Yes
AccountDetails object.
userPin
Yes
User PIN.
Return Value
If the Generate OTP operation is successful, then the method returns an OTPResponse object, which contains the status and errorCode.
The status can be one of the following values:
  • SUCCESS:
    Operation was successful.
  • FAILURE:
    Operation failed.
If the status is FAILURE, then one of the following errorCode values is returned:
  • ERROR_INVALID_ARGUMENT:
    Incorrect account details were passed.
  • ERROR_INVALID_PIN:
    Incorrect PIN was passed.
  • ERROR_INVALID_AUTHENTICATION_TYPE
    : Invalid AuthenticationType object present in the request.
  • ERROR_ACCOUNT_NOT_FOUND
    : Account not present in the database.
See OTPResponse for more information.
Exception
None.
generateOTP (for Biometric authentication and when transaction data signing is enabled)
Generates an OTP in the Offline mode for the specified account. This method is to be used when the user selects the Biometric authentication type and transaction data signing is enabled.
Code Snippet
-(void) generateOTP : (AccountDetails *)mAccountDetails
PropertyDict: (NSDictionary *)propertyDict
SuccessHandler: (void(^)(OTPResponse *)) onSuccess
FailureHandler: (void(^)(OTPResponse *)) onFailure
FallbackHandler :(void(^)(void)) onFallback
CancelHandler :(void(^)(void)) onCancel;
Parameters
Parameter
Mandatory?
Description
mAccountDetails
Yes
AccountDetails object.
propertyDict
Yes
Dictionary that has the SIGNING_DATA key. The value of this key must be the transaction data. The SIGNING_DATA is defined in the "Header.h" header file, which should be included so that this key can be used.
onSuccess
Yes
Function to handle the Success response.
onFailure
Yes
Function to handle the Failure response.
onFallBack
Yes
Function to handle the scenario in which the user selects the PIN option. In other words, the user opts to use PIN authentication instead of continuing with Biometric authentication.
onCancel
Yes
Function to handle the scenario in which the user cancels or closes the Biometric authentication dialog.
Return Value
If the Generate OTP operation is successful, then the method returns an OTPResponse object, which contains the status and errorCode.The status can be one of the following values:
  • SUCCESS:
    Operation was successful.
  • FAILURE:
    Operation failed.
If the status is FAILURE, then one of the following errorCode values is returned:
  • ERROR_INVALID_ARGUMENT:
    Incorrect account details were passed.
  • ERROR_INVALID_PIN:
    Incorrect PIN was passed.
  • ERROR_INVALID_AUTHENTICATION_TYPE
    : Invalid AuthenticationType object present in the request.
  • ERROR_ACCOUNT_NOT_FOUND
    : Account not present in the database.
  • ERROR_NO_BIOMETRIC_AVAILABLE
    : Biometric authentication is not enabled on this device.
  • INVALID_SIGNING_KEY
    : Signing data not found.
See OTPResponse for more information.
Exception
None.
generateOTP (for PIN authentication and when transaction data signing is enabled)
Generates an OTP in the Offline mode for the specified account. This method is to be used when the user selects the PIN authentication type and transaction data signing is enabled.
Code Snippet
-(OTPResponse *) generateOTP : (AccountDetails *)mAccountDetails userPin: (NSString *)userPin PropertyDict: (NSDictionary *)propertyDict;
Parameters
Parameter
Mandatory?
Description
mAccountDetails
Yes
AccountDetails object.
userPin
Yes
User PIN.
propertyDict
Yes
Dictionary that has the SIGNING_DATA key. The value of this key must be the transaction data. The SIGNING_DATA is defined in the "Header.h" header file, which should be included so that this key can be used.
Return Value
If the Generate OTP operation is successful, then the method returns an OTPResponse object, which contains the status and errorCode.
The status can be one of the following values:
  • SUCCESS:
    Operation was successful.
  • FAILURE:
    Operation failed.
If the status is FAILURE, then one of the following errorCode values is returned:
  • ERROR_INVALID_ARGUMENT:
    Incorrect account details were passed.
  • ERROR_INVALID_PIN:
    Incorrect PIN was passed.
  • INVALID_SIGNING_KEY:
    Invalid transaction data was passed.
  • ERROR_INVALID_AUTHENTICATION_TYPE
    : Invalid AuthenticationType object present in the request.
  • ERROR_ACCOUNT_NOT_FOUND
    : Account not present in the database.
See OTPResponse for more information.
Exception
None.
getAllAuthenticationTypes
Gets all available (SDK supported) authentication types for the user’s mobile.
Code Snippet
- (NSMutableArray *) getAllAuthenticationTypes
Parameters
None.
Return Value
Array of authentication types.
getAllEnrolledAccounts
Gets all accounts and cards for which CA Strong Authentication has been activated.
Code Snippet
- (NSMutableArray *) getAllEnrolledAccounts
Parameters
None.
Return Value
Array of AccountDetails objects.
See AccountDetails for more information.
Exception
None.
getProfileInfo
Returns the user profile details, such as device nickname and device ID, configured in the device.
Code Snippet
- (ProfileInfo *) getProfileInfo
Parameters
None.
Return Value
Returns a ProfileInfo object, which contains the status and errorCode values.
The status can be one of the following values:
  • SUCCESS: Operation was successful.
  • FAILURE: Operation failed.
If status is FAILURE, then the following errorCode value is returned:
  • PROFILE_INFO_NOT_AVAILABLE: No profile available in the device.
See ProfileInfo for more information.
Exception
None.
isDeviceJailBroken
Checks if the device is jail-broken or not.
Code snippet
-(BOOL)isDeviceJailBroken;
Parameters
None.
Return Value
Return a boolean object.The status can be one of the following values:
  • TRUE: Indicates device is jail-broken.
  • FALSE: Indicates that the device is not jail-broken.
Exception
None.
setBiometricDialogTitle
This sets the title for the biometric authentication dialog.
Code snippet
-(
void
)setBiometricDialogTitle:(NSString *)title;
Parameters
The title to be displayed.
Return Value
None.
Exception
None.
setBiometricFallbackTitle
This sets the title for the fallback authentication that is triggered in case biometric authentication cannot be performed.
Code snippet
-(
void
)setBiometricFallbackTitle:(NSString *)title;
Parameters
The title to be displayed. 
Return Value
None.
Exception
None.
setBiometricCancelTitle
This set the title to cancel the biometric authentication.
Code snippet
-(
void
)setBiometricCancelTitle:(NSString *)title;
Parameters
The title to be displayed. 
Return Value
None.
Exception
None.
getTransaction (get the latest pending transaction)
Gets the latest pending transaction for the accounts.
Code Snippet
- (TransactionDetailsResponse *) getTransaction
Parameters
None.
Return Value
Returns a TransactionDetailsResponse object, which contains the status and errorCode.
The status can be one of the following values:
  • SUCCESS:
    Operation was successful. This means one of the accounts has the pending transactions.
  • FAILURE:
    Operation failed.
If the status is FAILURE, then the response object will have one of the following errorCode values:
  • ERROR_NO_ACTIVE_ACCOUNTS:
    No active accounts are present. For example, when the existing accounts are locked.
  • ERROR_SERVER_UNREACHABLE:
    Server is not reachable.
  • ERROR_ACCOUNT_NOT_FOUND:
    Invalid account.
  • ERROR_SERVER_INTERNAL:
    Server has returned an error.
  • ERROR_NO_TRANSACTION_AVAILABLE:
    There are no pending transactions.
  • ERROR_PINNING_FAILURE:
    The SSL pinning has resulted in failure.
See TransactionDetailsResponse for more information.
Exceptions
None.
getTransaction (get a specified transaction)
Gets the pending transaction for a given AccountId of a given AccountType.
Code Snippet
- (TransactionDetailsResponse *) getTransaction: (NSString *) transactionId
AccountId: (NSString *) accountId
AccountType: (NSString *) accountType
Parameters
Parameter
Mandatory?
Description
transactionId
Yes
Transaction ID.
accountId
Yes
Account ID.
accountType
Yes
Account type sent by the server.
The value can be one of the following:
TM
FM
Return Value
Returns a TransactionDetailsResponse object, which contains the status and errorCode.
The status can be one of the following values:
  • SUCCESS:
    Operation was successful. This means the account has pending transactions.
  • FAILURE:
    Operation failed.
If the status is FAILURE, then the response object will have one of the following errorCode values:
  • ERROR_INVALID_ARGUMENT
    : The input parameter is invalid. 
  • ERROR_SERVER_UNREACHABLE:
    Server is not reachable.
  • ERROR_ACCOUNT_NOT_FOUND:
    Invalid account.
  • ERROR_SERVER_INTERNAL:
    Server has returned an error.
  • ERROR_NO_TRANSACTION_AVAILABLE:
    There are no pending transactions.
  • ERROR_PINNING_FAILURE:
    The SSL pinning has resulted in failure.
See TransactionDetailsResponse for more information.
Exceptions
None.
isPINSetup
Returns true if the user has set up a PIN. Most of the SDK flows, including the Authentication flows, begin with a call to this API. These flows can proceed only if the user has a PIN.
Code Snippet
- (BOOL) isPINSetup
Parameters
None.
Return Value
BOOL
Exception
None.
setPin (for a single account)
Sets the user PIN when the verifyActivation method (for a single account) is called in a scenario when the user has not set a PIN.
Code Snippet
- (ActivationAcknowledgementResponse *) setPin: (NSString *) accountId
: (NSString *) userPin
Parameters
Parameter
Mandatory?
Description
accountId
Yes
Account ID.
userPin
Yes
User PIN.
Return Value
Returns an ActivationAcknowledgementResponse object, which contains the status and errorCode.
The status can be one of the following values:
  • SUCCESS:
    Operation was successful.
  • FAILURE:
    Operation failed.
If the status is FAILURE, then one of the following errorCode values is returned:
  • ERROR_SDK_INTERNAL:
    An SDK error was encountered.
  • ERROR_INVALID_PIN:
    Invalid user PIN.
  • ERROR_INVALID_ARGUMENT
    : Incorrect details were passed.
  • ERROR_SERVER_INTERNAL:
    Internal server error occurred.
  • ERROR_PINNING_FAILURE:
    The SSL pinning has resulted in failure.
See ActivationAcknowledgementResponse for more information.
Exception
None.
setPin (for multiple accounts)
Sets the user PIN when the verifyActivation method (for multiple accounts) is called in a scenario when the user has not set a PIN.
Call this API in a background thread.
Code snippet
-(NSMutableArray <ActivationAcknowledgementResponse *>*) setPin:(NSString*) userPin;
Parameters
Parameter
Mandatory?
Description
userPin
Yes
User PIN.
Return Value
Return a List of ActivationAcknowledgementResponse objects. Each object contains the status and error code.
The status can be one of the following values:
  • SUCCESS:
    Operation was successful.
  • FAILURE:
    Operation failed.
If the status is FAILURE, the one of the following error codes value is returned:
  • ERROR_INVALID_PIN
    : Invalid user PIN.
  • ERROR_INTERNAL_READWRITE
    : An SDK error was encountered.
  • ERROR_SDK_INTERNAL
    : An SDK error was encountered.
  • ERROR_PINNING_FAILURE:
    The SSL pinning has resulted in failure.
See ActivationAcknowledgementResponse for more information.
Exception
None.
setURL
Updates the Service URL for the specified organization.
Code Snippet
- (BOOL) setURL: (NSString *) orgName: (NSString *) newURL
Parameters
Parameter
Mandatory?
Description
orgName
Yes
Organization name.
newURL
Yes
Service URL.
Return Value
Returns TRUE or FALSE.
Exception
None.
updateAuthenticationType
Enables or disables the specified Authentication type on a user’s mobile.
Important!
Before calling the updateAuthenticationType API, call the verifyPin API to ensure that the user has submitted the correct PIN.
Code Snippet
- (UpdateAuthenticationResponse *) updateAuthenticationType: (Authentication *) authentication: (NSString *) pin
Parameters
Parameter
Mandatory?
Description
authentication
Yes
Authentication object.
pin
Yes
User PIN.
Return Value
Returns an UpdateAuthenticationResponse object, which contains the status and error code.The status can be one of the following values:
  • SUCCESS:
    Operation was successful.
  • FAILURE:
    Operation failed.
If the status is FAILURE, then one of the following error codes is returned:
  • ERROR_OPERATION_NOT_ALLOWED:
    User is trying to disable an authentication type (biometric) that is already disabled.
  • ERROR_INVALID_PIN:
    User submitted an invalid PIN.
  • ERROR_NO_BIOMETRIC_AVAILABLE:
    Biometric authentication is not available or configured on this device.
  • ERROR_INTERNAL_READWRITE:
    SDK error was encountered.
See UpdateAuthenticationResponse for more information.
Exception
None.
verifyActivation
Activates CA Strong Authentication for the second or subsequent account.
Code Snippet
- (AccountActivationDetails *) verifyActivation: (NSString *) activationCode
: (NSString *) activationRefId
: (NSString *) postURL
: (NSString *) displayName
: (NSString *) pin
Parameters
Parameter
Mandatory?
Description
activationCode
Yes
Activation code.
activationRefId
Yes
Activation reference ID.
postURL
Yes
CA Strong Authentication server URL.
displayName
Yes
Display name of the account or card.
pin
Yes
User PIN.
Return Value
Returns an AccountActivationDetails object, which contains the status and error code.
The status can be one of the following values:
  • SUCCESS:
    Operation was successful.
  • FAILURE:
    Operation failed.
If the status is FAILURE, then one of the following error codes is returned:
  • ERROR_INVALID_ARGUMENT:
    Incorrect details were passed.
  • ERROR_SERVER_UNREACHABLE:
    Server is not reachable.
  • ERROR_DISPLAY_NAME_ALREADY_EXISTS:
    Display name already exists in the database.
  • invalid_activation_code:
    User submitted an invalid activation code.
  • invalid_activation_ref_id:
    User submitted an invalid reference ID.
  • ERROR_SERVER_INTERNAL
    : Internal server error.
  • ERROR_PINNING_FAILURE:
    The SSL pinning has resulted in failure.
See AccountActivationDetails for more information.
Exception
None.
verifyActivation (used for multiple accounts)
Activates CA Strong Authentication for the second or subsequent account.
Code Snippet
- (MultipleAccountActivationDetails *) verifyActivation :(NSMutableArray <MultipleAccountActivationParams *>*) multipleAccountActivationParamsArray :(NSString *)serverURL
Parameters
Parameter
Mandatory?
Description
multipleAccountActivationParamsArray
Yes
Array of accounts.
serverURL
Yes
Strong Authentication server URL.
pin
Yes
Authentication PIN.
Return Value
Returns an MultipleAccountActivationDetails object, which contains the status and error code. The status can be one of the following values:
  • SUCCESS:
    Operation was successful.
  • FAILURE:
    Operation failed.
If the status is FAILURE, then one of the following error codes is returned:
  • ERROR_INVALID_ACTIVATION_PARAMS
    : The MultipleAccountActivationParams parameter is nil.
  • ERROR_INVALID_SERVER_URL
    : The serverURL is empty.
  • ERROR_INVALID_PIN
    : Invalid PIN.
  • ERROR_DISPLAY_NAME_ALREADY_EXISTS
    : Display name already exists in the database.
  • ERROR_SERVER_UNREACHABLE
    : The verifyActivationResponse is nil.
  • ERROR_SERVER_INTERNAL
    : Internal server error was encountered.
  • ERROR_PINNING_FAILURE:
    The SSL pinning has resulted in failure.
See
AccountActivationDetails for more information.
Exception
None.
verifyActivation (used for multiple accounts)
Activates CA Strong Authentication for the second or subsequent account.
Code Snippet
- (MultipleAccountActivationDetails *) verifyActivation :(NSMutableArray <MultipleAccountActivationParams *>*) multipleAccountActivationParamsArray :(NSString *)serverURL :(NSString *)pin
Parameters
Parameter
Mandatory?
Description
multipleAccountActivationParamsArray
Yes
Array of accounts.
serverURL
Yes
Strong Authentication server URL.
pin
Yes
Authentication PIN.
Return Value
Returns an MultipleAccountActivationDetails object, which contains the status and error code. The status can be one of the following values:
  • SUCCESS:
    Operation was successful.
  • FAILURE:
    Operation failed.
If the status is FAILURE, then one of the following error codes is returned:
  • ERROR_INVALID_ACTIVATION_PARAMS
    : The MultipleAccountActivationParams parameter is nil.
  • ERROR_INVALID_SERVER_URL
    : The serverURL is empty.
  • ERROR_INVALID_PIN
    : Invalid PIN.
  • ERROR_DISPLAY_NAME_ALREADY_EXISTS
    : Display name already exists in the database.
  • ERROR_SERVER_UNREACHABLE
    : The verifyActivationResponse is nil.
  • ERROR_SERVER_INTERNAL
    : Internal server error was encountered.
  • ERROR_PINNING_FAILURE:
    The SSL pinning has resulted in failure.
See
AccountActivationDetails for more information.
Exception
None.
verifyPin (when transaction data signing is not enabled)
Verifies the user PIN, without using transaction data.
Use this API for operations such as activating new accounts on the device, changing the PIN, disabling or enabling the authentication types, or deleting an account.
If you are implementing the Dynamic Linking article of PSD2, then see verifyPin (verifies PIN using transaction data).
Code Snippet
- (VerifyPINResponse *) verifyPIN: (NSString *) pin
Parameters
Parameter
Mandatory?
Description
pin
Yes
User PIN.
Return Value
Returns a VerifyPINResponse object, which contains the status and error message.
The status can be one of the following values:
  • SUCCESS:
    Operation was successful.
  • FAILURE:
    Operation failed.
If the status is FAILURE, then one of the following error codes is returned:
  • ERROR_INVALID_PIN:
    Invalid user PIN.
  • ERROR_NO_ACTIVE_ACCOUNTS:
    No active accounts are present are present. For example, when the existing accounts are locked.
  • ERROR_SERVER_INTERNAL:
    Server has returned an error.
  • ERROR_SERVER_UNREACHABLE
    : Server is unreachable.
  • ERROR_ATTEMPTS_EXHAUSTED
    : The user exhausted the authentication attempts.
  • ERROR_INCORRECT_PIN
    : User submitted an incorrect PIN.
  • ERROR_INACTIVE_ACCOUNT
    : The account is inactive.
  • INVALID_SIGNING_KEY
    : Transaction data is invalid.
  • pin_not_available
    : The pin setup is not done.
  • ERROR_PINNING_FAILURE:
    The SSL pinning has resulted in failure.
Exception
None.
verifyPin (when transaction data signing is enabled)
Verifies the user PIN by using transaction data.
Use this API if you are implementing the Dynamic Linking article of PSD2.
Use this API for operations such as activating new accounts on the device, changing the PIN, disabling or enabling the authentication types, or deleting an account.
Code Snippet
- (VerifyPINResponse *) verifyPIN :(NSString *)pin PropertyDict: (NSDictionary *)propertyDict;
Parameters
Parameter
Mandatory?
Description
pin
Yes
User PIN.
propertyDict
Yes
Dictionary containing the SIGNING_DATA key, whose value is the transaction data. The SIGNING_DATA is defined in the "Header.h" header file, which should be included so that this key can be used.
Return Value
Returns a VerifyPINResponse object, which contains the status and error message.
The status can be one of the following values:
  • SUCCESS:
    Operation was successful.
  • FAILURE:
    Operation failed.
If the status is FAILURE, then one of the following error codes is returned:
  • ERROR_INVALID_PIN:
    Invalid user PIN.
  • ERROR_NO_ACTIVE_ACCOUNTS:
    No active accounts are present are present. For example, when the existing accounts are locked.
  • ERROR_SERVER_INTERNAL:
    Server has returned an error.
  • INVALID_SIGNING_KEY:
    Transaction data is invalid.
  • ERROR_SERVER_UNREACHABLE
    : Server is unreachable.
  • ERROR_ATTEMPTS_EXHAUSTED
    : The user exhausted the authentication attempts.
  • ERROR_INCORRECT_PIN
    : User submitted an incorrect PIN.
  • ERROR_INACTIVE_ACCOUNT
    : The account is inactive.
  • pin_not_available
    : The pin setup is not done.
  • ERROR_PINNING_FAILURE:
    The SSL pinning has resulted in failure.
Exception
None.
verifyPin (used in auto enroll flow)
Verifies the user PIN by using transaction data. Use this API if you are implementing the Dynamic Linking article of PSD2. Use this API for operations such as activating new accounts on the device, changing the PIN, disabling or enabling the authentication types, or deleting an account.
Code Snippet
- (VerifyPINResponse *) verifyPIN:(NSString *)pin :(TransactionDetailsResponse *)transactionDetailsResponse:(NSString *)autoEnrollId
Parameters
Parameter
Mandatory?
Description
pin
Yes
User PIN.
transactionDetailsResponse
Yes
Response from the gettransaction method.
autoEnrollId
Yes
Auto enrollment Identifier.
Return Value
Returns a VerifyPINResponse object, which contains the status and error message.The status can be one of the following values:
  • SUCCESS:
    Operation was successful.
  • FAILURE:
    Operation failed.
If the status is FAILURE, then one of the following error codes is returned:
  • ERROR_INVALID_ARGUMENT
    : Incorrect details were passed.
  • ERROR_INVALID_PIN
    : User PIN is nill. User submitted an invalid PIN.
  • ERROR_INVALID_SIGNING_DATA
    : The signing key is not valid.
  • ERROR_SERVER_UNREACHABLE
    : The response is nil.
  • ERROR_ATTEMPTS_EXHAUSTED
    : The user exhausted the authentication attempts.
  • ERROR_INCORRECT_PIN
    : User submitted an incorrect PIN.
  • ERROR_INACTIVE_ACCOUNT
    : The account is inactive.
  • ERROR_SERVER_INTERNAL
    : Internal server error was encountered.
  • pin_not_available
    : The PIN setup is not done.
  • ERROR_PINNING_FAILURE:
    The SSL pinning has resulted in failure.
Exception
None.
verifyPINUsingTouchID
Verifies the user PIN through Touch ID authentication.
Code snippet
- (void) verifyPINUsingTouchID:(NSString *)touchIDForAutoEnroll
withTxnalDetailsResponse:(TransactionDetailsResponse *)detailResponse
SuccessHandler :(void(^)(VerifyPINResponse *)) onSuccess
FailureHandler :(void(^)(VerifyPINResponse *)) onFailure
FallbackHandler :(void(^)(void)) onFallback
CancelHandler :(void(^)(void)) onCancel;
Parameters
None.
Return Value
Returns a VerifyPINResponse object, which contains the status and error message.
The status can be one of the following values:
  • SUCCESS:
    Operation was successful.
  • FAILURE:
    Operation failed.
If the status is FAILURE, then one of the following error codes is returned:
  • ERROR_INVALID_ARGUMENT:
    Check the values of the arguments passed in the API.
  • ERROR_SERVER_UNREACHABLE:
    Server is unreachable.
  • ERROR_ACCOUNT_NOT_FOUND:
    Invalid account.
  • ERROR_SERVER_INTERNAL:
    Server has returned an error.
  • ERROR_NO_BIOMETRIC_AVAILABLE
    : Biometric authentication is not enabled on this device.
  • INVALID_SIGNING_KEY
    : The signing data is not found.
  • ERROR_INCORRECT_PIN
    : User submitted an incorrect PIN.
  • ERROR_INACTIVE_ACCOUNT
    : The account is inactive.
  • ERROR_PINNING_FAILURE
    : The SSL pinning has resulted in failure.
Exception
None.
unenrollAccounts (for a single or multiple accounts)
Deletes a single or multiple accounts selected by the user.
Code snippet
- (BOOL) unenrollAccounts: (NSArray<AccountDetails *> *) accounts removeFromRemote : (BOOL) removeFromServer;
Parameters
Parameter
Mandatory?
Description
accounts
Yes
Array of AccountDetails objects.
removeFromServer
Yes
Boolean flag that specifies whether the accounts must also be deleted from the CA Strong Authentication server.
When this flag is set to true, accounts are removed from the device and server. However, the PIN is not removed, so new accounts can continue to be provisioned on this device.
Return Value
Return a boolean value, which specifies whether the accounts have been deleted.
Exception
None.
unenrollAccounts (for all accounts)
Deletes all accounts and can also delete the PIN setup.
Code snippet
- (BOOL) unenrollAccounts: (BOOL) removePinSetup removeFromRemoteAll : (BOOL) removeFromServer;
Parameters
Parameter
Mandatory?
Description
removePinSetup
Yes
Boolean flag that specifies whether the user's current PIN must be retained or removed. In addition, the PIN is removed. To activate new accounts on this device or a different device, the user will be prompted to set up a PIN.
removeFromServer
Yes
Boolean flag that specifies whether the accounts must also be deleted from the CA Strong Authentication server.
When this flag is set to true, accounts are removed from the device and server. However, the PIN is not removed, so new accounts can continue to be provisioned on this device.
Return Value
Return a boolean value, which specifies whether the accounts have been deleted.
Exception
None.
configureSSLPinning
This method checks if the SSL pinning configurtion is successful.
Code snippet
-(SSLPinningConfigResponse *)configureSSLPinning:(SSLPinningConfigs *)sslPinningConfigs;
Parameters
Parameter
Mandatory?
Description
sslPinningConfigs
Yes
Contains the pinning configuration details, such as certificates, type of pinning (public key or certiticate), indication if the pinning is required or not.
Return Value
Returns a SSLPinningResponse object, which contains status, error code, and error message. The status can be one of the following values:
  • SUCCESS:
    Operation was successful.
  • FAILURE:
    Operation failed.
If the status is FAILURE, then one of the following error codes is returned:
  • ERROR_PINNING_CONFIG
    The SSL pinning configuration has resulted in failure. This error can be returned in case of following scenario. Based on the error description, provide the correct input to the SDK.
    • SSL configuration (sslPinningConfigs) is null
    • Certificate is null
    • Certificate size is zero
Exception
None.
Class Authentication
This Authentication class contains the AuthenticationType and AuthenticationTypeStatus properties. This class manages the various authentications types, such as USER_PIN and BIOMETRIC.
Code Snippet
@interface Authentication : NSObject
@property AuthenticationType authenticationType;
@property AuthenticationTypeStatus authenticationTypeStatus;
-(id) initWithData :(AuthenticationType) mAuthenticationType : (AuthenticationTypeStatus) mAuthenticationTypeStatus;
@end
initWithData
Initializes the Authentication object with the authenticationType and authenticationTypeStatus parameters.
Code Snippet
- (id) initWithData: (AuthenticationType) mAuthenticationType
: (AuthenticationTypeStatus) mAuthenticationTypeStatus
Parameters
Parameter
Mandatory?
Description
mAuthenticationType
Yes
Type of Authentication that is supported and configured on a user's mobile device at any point of time. Valid values are the following integers:
0:
Indicates device authentication.
1:
Indicates user PIN authentication.
2:
Indicates biometric authentication.
AuthenticationTypeStatus
Yes
Status of the AuthenticationType supported and configured on a user's device at any point of time. Valid values are the following:
0:
Indicates that the authentication type is enabled.
1 :
Indicates that the authentication type is disabled.
2:
Indicates that biometric authentication is not supported on the device.
Return Value
Returns an Authentication object.
See Authentication for more information.
Exceptions
None.
Properties of Class Authentication
Name
Type
Description
authenticationType
AuthenticationType
Type of Authentication that is supported and configured on a user's mobile at any point of time.
The value can be one of the following:
  • User PIN
  • Biometric Auth
  • Device PIN Auth
authenticationTypeStatus
AuthenticationTypeStatus
Status of the AuthenticationType that is supported and configured on the user's mobile at any point of time.
The value can be one of the following:
  • Enabled
  • Disabled
  • Not Applicable
Response Classes
This section describes the classes whose objects are returned by the responses of the SDK operations.
Class TransactionDetailsResponse
The TransactionDetailsResponse class contains information about pending transactions. An object of this class is sent in the response of the following methods:
Code Snippet
@interface TransactionDetailsResponse : NSObject
@property(retain, nonatomic) NSString * status;
@property(retain, nonatomic) NSString * transactionId;
@property(retain, nonatomic) NSString * transactionMessage;
@property(retain, nonatomic) NSString * displayName;
@property(retain, nonatomic) NSMutableArray * authenticationTypes;
@property(retain, nonatomic) NSString * errorCode;
@property(retain, nonatomic) NSString * autoEnrollId;
- (id)initWithData :(NSString *)aStatus TransactionId: (NSString *) aTransactionId TransactionMessage: (NSString *) aTransactionMessage DisplayName:(NSString *)aDisplayName AuthenticationTypes: (NSMutableArray *) aAuthenticationTypes;
-(id)initWithStatus:(NSString *)aStatus;
-(id)initWithErrorCode :(NSString *)errorCode;
@end
Properties
Name
Type
Description
authenticationTypes
NSMutableArray
Authentication types that are configured on the user's mobile. For example:
User PIN and BIOMETRIC
displayName
NSString
Display name that the user has set for the account or card.
errorCode
NSString
errorCode is returned depending on the scenario in which the TransactionDetailsResponse object is created.
status
NSString
Status of the operation. The value can be one of the following:
  • SUCCESS: Operation was successful.
  • FAILURE: Operation failed.
transactionId
NSString
Transaction ID.
transactionMessage
NSString
Transaction message that has the details of the transaction conducted by the user. These details are displayed by the app to the user.
For a push-notification-based transaction, the transaction message contains the HTML snippets that were specified as the value of the Push Body Heading Message and Push Body Passage Message elements in the Push Notification message template.
autoEnrollId
NSString
Auto Enrollment ID that is used to auto-enroll a replacement card.
Class AuthenticationResponse
The AuthenticationResponse class contains information about user authentication results. An object of this class is sent in the response of the authenticateUsingConsent and authenticateUsingUserPin methods.
Code Snippet
@interface AuthenticationResponse : NSObject
@property(retain, nonatomic) NSString * transactionId;
@property(retain, nonatomic) NSString * status;
@property(nonatomic) BOOL attemptAgain;
@property(retain, nonatomic) NSString * errorCode;
- (id)initWithData: (NSString *)aTransactionId Status:(NSString *)aStatus AttemptAgain:(BOOL)aAttemptAgain;
-(id)initWithStatus:(NSString *)aStatus;
-(id) initWithErrorCode :(NSString *)errorCode;
@end
Properties
Name
Type
Description
attemptAgain
BOOL
Specifies whether the user is allowed to attempt authentication again for a given transaction. This property is set by the CA Strong Authentication Server and sent to the SDK.
errorCode
NSString
errorCode that is returned depending on the scenario in which the AuthenticationResponse object is created.
status
NSString
Success or failure status that is returned in the AuthenticationResponse object.
transactionId
NSString
Transaction ID.
Class AutoEnrollmentResponse
The AutoEnrollmentResponse class contains information about the enrollment details for a replacement card. An object of this class is sent in the response of the autoEnrollAccount method.
@interface AutoEnrollmentResponse : NSObject
@property(retain, nonatomic) NSString * transactionId;
@property(retain, nonatomic) NSString * status;
@property(retain, nonatomic) NSString * errorCode;
-(id)initWithData :(NSString *)aTransactionId
:(NSString *)aStatus
:(NSString *)aErrorCode;
-(id)initWithStatus :(NSString *)aStatus;
-(id)initWithErrorCode :(NSString *)_errorCode;
Properties
Name
Type
Description
errorCode
NSString
errorCode that is returned depending on the scenario in which the AutoEnrollmentResponse object is created.
status
NSString
Success or failure status that is returned in the AutoEnrollmentResponse object.
transactionId
NSString
Transaction ID.
Class CancelTransactionResponse
The CancelTransactionResponse class contains information about the results of a Cancel Transaction operation. An object of this class is sent in the response of the cancelTransaction method.
Code Snippet
@interface CancelTransactionResponse : NSObject
@property(retain, nonatomic) NSString * transactionId;
@property(retain, nonatomic) NSString * status;
@property(retain, nonatomic) NSString * errorCode;
- (id)initWithData: (NSString *)aTransactionId Status:(NSString *)aStatus;
-(id)initWithStatus:(NSString *)aStatus;
-(id)initWithErrorCode :(NSString *)_errorCode;
@end
Properties
Name
Type
Description
errorCode
NSString
errorCode that is returned depending on the scenario in which the CancelTransactionResponse object is created.
status
NSString
Success or failure status that is returned in the CancelTransactionResponse object.
transactionId
NSString
Transaction ID.
Class AccountActivationDetails
The AccountActivationDetails class contains account activation details. An object of this class is sent in the response of the verifyActivation method.
Code Snippet
@interface AccountActivationDetails : NSObject
@property(retain, nonatomic) NSString * accountId;
@property(retain, nonatomic) NSString * displayName;
@property(retain, nonatomic) NSString * status;
@property(retain, nonatomic) NSString * errorCode;
@property Boolean isPINRequired;
- (id)initWithData :(NSString *)mAccountId Status: (NSString *)aStatus DisplayName:(NSString *)aDisplayName;
-(id)initWithStatus:(NSString *)aStatus;
-(id)initWithStatusAndDisplayName: (NSString *)aStatus DisplayName: (NSString *)aDisplayName;
-(id)initWithErrorCode :(NSString *)errorCode;
@end
Properties
Name
Type
Description
accountId
NSString
Account or card provisioned on the user's mobile.
displayName
NSString
Display name set by the user for the account or card.
errorCode
NSString
errorCode that is returned depending on the scenario in the AccountActivationDetails object is created.
isPINRequired
Boolean
Specifies whether the user PIN is required during activation of the account or card.
If this method returns true, then the app must display a prompt for the user to submit the PIN or biometric.
status
NSString
Specifies whether the status is SUCCESS or FAILURE.
Class MultipleAccountActivationDetails
The MultiipleAccountActivationDetails class contains account activation details. An object of this class is sent in the response of the verifyActivation method.
Code Snippet
@interface MultipleAccountActivationDetails : NSObject
@property(retain, nonatomic) NSString * status;
@property(retain, nonatomic) NSString * errorCode;
@property Boolean isPINRequired;
@property NSMutableArray *multipleAccountActivationStatusArray;
- (id)initWithData:(NSMutableArray*)multipleAccountActivationStatusArray;
-(id)initWithStatus:(NSString *)aStatus;
-(id)initWithErrorCode :(NSString *)errorCode;
-(MultipleAccountActivationDetails *) mergeMultipleActivationAcknowledgementResponses:(MultipleAccountActivationDetails *)multipleAccountActivationDetails
:(NSMutableArray<ActivationAcknowledgementResponse*>*)acknowledgementResponses;
@end
Properties
Name
Type
Description
multipleAccountActivationStatusArray
NSMutableArray
This parameter provides the following details:
  • Account or card provisioned on the user's mobile
  • Display name set by the user for the account or card
  • Status of activation for each account (SUCCESS or FAILURE)
  • Reference ID for each account
  • Error code (if any) for each account
errorCode
NSString
errorCode that is returned depending on the scenario in the AccountActivationDetails object is created.
isPINRequired
Boolean
Specifies whether the user PIN is required during activation of the account or card.
If this method returns true, then the app must display a prompt for the user to submit the PIN or biometric.
status
NSString
Specifies whether the status is SUCCESS or FAILURE.
Class MultipleAccountActivationParams
The MultipleAccountActivationParams class contains account activation parameters. An object of this class is passed to the verifyActivation method.
Code Snippet
@interface MultipleAccountActivationParams : NSObject
@property(nonatomic, strong) NSString * activationCode;
@property(nonatomic, strong) NSString * activationRefId;
@property(nonatomic, strong) NSString * displayName;
@property(nonatomic, strong) NSString * pin;
- (id)initWithData :(NSString *)activationCode :(NSString *)activationRefId :(NSString *)displayName :(NSString *)pin;
-(NSMutableDictionary *)createMultipleAccountActivationParamsDict:(NSMutableArray <MultipleAccountActivationParams *>*) multipleAccountActivationParamsArray:(BOOL)isMasterAccountPresent:(NSDictionary *)deviceParamDict;
-(BOOL)areValidActivationParams:(NSMutableArray <MultipleAccountActivationParams *>*) activationParamsArray;
@end
Properties
Name
Type
Description
activationCode
NSString
Activation code that is provided by the user and then validated by the CA Strong Authentication Service before the user account is provisioned on the user's device.
activationRefId
NSString
Reference ID that is mapped to the activation code.
displayName
NSString
Display name that is provided in the request.
pin
NSString
PIN set by the user.
Class MultipleAccountActivationStatus
The MultipleAccountActivationStatus class contains account activation details. An object of this class is sent in the response of the verifyActivation method.
Code Snippet
@interface MultipleAccountActivationStatus: NSObject
@property(nonatomic, strong) NSString * status;
@property(nonatomic, strong) NSString * displayName;
@property(nonatomic, strong) NSString * accountId;
@property(nonatomic, strong) NSString * errorCode;
@property(nonatomic, strong) NSString * referenceId;
- (id)initWithData :(NSString *)status :(NSString *)accountId :(NSString *)referenceId :(NSString *)displayName :(NSString *)errorCode;
@end
Properties
Name
Type
Description
status
NSString
Specifies whether the status is SUCCESS or FAILURE.
displayName
NSString
Display name that is provided in the request.
accountId
NSString
Account ID received by the CA Strong Authentication service.
errorCode
NSString
Error code.
referenceId
NSString
Reference ID.
Class AccountDeletionResponse
The AccountDeletionResponse class contains information about the results of an Account Deletion operation. An object of this class is sent in the response of the deleteAccount method.
Code Snippet
@interface AccountDeletionResponse : NSObject
@property (nonatomic, strong) NSString * status;
@property (nonatomic, strong) NSString * displayName;
@property (nonatomic, strong) NSString * errorCode;
-(id)initWithData: (NSString *)mStatus DisplayName: (NSString *)mDisplayName;
-(id)initWithStatus:(NSString *)aStatus;
-(id)initWithErrorCode :(NSString *)errorCode;
@end
Properties
Name
Type
Description
displayName
NSString
Display name set by the user to the account or card on the user's mobile.
errorCode
NSString
errorCode that is returned depending on the scenario in which the AccountDeletionResponse object is created.
status
NSString
Specifies whether the deletion operation was successful or a failure.
Class ActivationAcknowledgementResponse
The ActivationAcknowledgementResponse class contains activation acknowledgement details. An object of this class is sent in the response of the setPin method.
Code Snippet
@interface ActivationAcknowledgementResponse : NSObject
@property(retain, nonatomic) NSString * status;
@property(retain, nonatomic) NSString * displayName;
@property(retain, nonatomic) NSString * errorCode;
- (id)initWithData:(NSString *)aStatus DisplayName:(NSString *)aDisplayName;
- (id)initWithStatus:(NSString *)aStatus;
- (id)initWithErrorCode :(NSString *)errorCode;
@end
Properties
Name
Type
Description
errorCode
NSString
error Code that is returned depending on the scenario in which the ActivationAcknowledgementResponse object is created.
status
NSString
Specifies whether activation was successful or failed.
Class AccountDetails
The AccountDetails contains information about an account. An object of this class is sent in the response of the getAllEnrolledAccounts method.
Code Snippet
@interface AccountDetails : NSObject
@property (nonatomic, strong) NSString * accountId;
@property (nonatomic, strong) NSString * accountType;
@property (nonatomic, strong) NSString * displayName;
- (id) initWithData: (NSString *)mAccountId AccountType: (NSString *) mAccountType DisplayName:(NSString *)mDisplayName;
@end
Properties
Name
Type
Description
accountId
NSString
Account ID of the account or card provisioned on the user's mobile.
accountType
NSString
accountType (for example, Net-Banking or Credit/Debit Card) specified by the CA Strong Authentication Server and saved in the SDK when account provisioned on the user's mobile.
displayName
NSString
Display name set by the user to the account or card provisioned on the user's mobile.
Class OTPResponse
The OTPResponse class contains information about an OTP. An object of this class is sent in the response of the generateOTP method.
Code Snippet
@interface OTPResponse : NSObject
@property(retain, nonatomic) NSString *otp;
@property(retain, nonatomic) NSString *status;
@property(retain, nonatomic) NSString *errorCode;
- (id) initWithData : (NSString *)mOtp status:(NSString *)mStatus;
- (id) initWithStatus : (NSString *)mStatus;
- (id) initWithErrorCode : (NSString *)_errorCode;
@end
Properties
Name
Type
Description
errorCode
NSString
errorCode that is returned depending on the scenario in which the OTPResponse object is created.
otp
NSString
OTP that is generated and returned to the CA Strong Authentication server for validation, for the account or card specified by the user, when the user enters the User PIN.
status
NSString
Success or failure status that is returned in the OTPResponse object.
Class VerifyPinResponse
The VerifyPinResponse class contains information about the results of the Verify PIN operation. An object of this class is sent in the response of the verifyPin method.
Code Snippet
@interface VerifyPINResponse : NSObject
@property(retain, nonatomic) NSString * status;
@property(retain, nonatomic) NSString * errorCode;
@property(retain, nonatomic) NSString * transactionId;
-(id)initWithData :(NSString *)status
:(NSString *)errorCode;
-(id)initWithStatus:(NSString *)status;
-(id)initWithErrorCode: (NSString *)errorCode;
@end
Properties
Name
Type
Description
errorCode
NSString
errorCode that gets returned depending on the scenario wherein the VerifyPINResponse object gets populated.
status
NSString
Specifies whether the Verify PIN operation is a success or failure.
transactionId
NSString
Transaction ID.
Class ChangePinResponse
The ChangePinResponse class contains information about the results of the Change PIN operation. An object of this class is sent in the response of the changePIN method.
Code Snippet
@interface ChangePINResponse : NSObject
@property(retain, nonatomic) NSString * status;
@property(retain, nonatomic) NSString * errorCode;
-(id)initWithData :(NSString *)status
:(NSString *)errorCode;
-(id)initWithStatus:(NSString *)status;
-(id)initWithErrorCode: (NSString *)errorCode;
@end
Properties
Name
Type
Description
errorCode
NSString
errorCode that is returned depending on the scenario in which the ChangePINResponse object is created.
status
NSString
Specifies whether the Change PIN operation has succeeded or failed.
Class ProfileInfo
The ProfileInfo class contains information about the device. An object of this class is sent in the response of the getProfileInfo method.
Code Snippet
@interface ProfileInfo : NSObject
@property(retain, nonatomic) NSString * deviceNickName;
@property(retain, nonatomic) NSString * deviceId;
@property(retain, nonatomic) NSString * status;
@property(retain, nonatomic) NSString * errorCode;
-(id)initProfileInfo :(NSString *)deviceNickName
:(NSString *)deviceId;
-(id)initWithErrorCode :(NSString *)_errorCode;
@end
Properties
Name
Type
Description
deviceId
NSString
Unique ID generated and assigned to the user's mobile by the CA Strong Authentication server. The deviceId in conjunction with the deviceNickName is used to uniquely identify the user’s mobile.
deviceNickName
NSString
Device nickname that is set by the user while initializing the app. The deviceNickName in conjunction with the deviceId is used to uniquely identify the user’s mobile.
errorCode
NSString
errorCode that is returned depending on the scenario in which the ProfileInfo object is created.
status
NSString
Specifies whether retrieving ProfileInfo has succeeded or failed.
Class UpdateAuthenticationResponse
The UpdateAuthenticationResponse class contains information about the results of the Update Authentication Type operation. An object of this class is sent in the response of the updateAuthenticationType method.
Code Snippet
@interface UpdateAuthenticationResponse : NSObject
@property(retain, nonatomic) NSString * status;
@property(retain, nonatomic) NSString * error_code;
-(id)initWithData :(NSString *)status
:(NSString *)error_code;
-(id)initWithStatus:(NSString *)status;
@end
Properties
Name
Type
Description
error_code
NSString
errorCode that is returned depending on the scenario in which the UpdateAuthenticationResponse object is populated.
status
NSString
Specifies whether the Update Authentication Type operation has success or failed.
Localizing the Biometric Authentication Dialog Text
To localize the text that is displayed on the app for biometric authentication:
  1. Select your project file in Project Navigator, and then select your project in the
    Project and Targets
    list.
  2. Open
    Info
    tab, expand the
    Localizations
    section. Then choose a language you want to support from the dropdown list shown.
  3. To add
    Localizable.strings
    file, navigate to File->New->File, choose
    Strings File
    under
    Resource
    tab of iOS, name it
    Localizable.strings
    and create the file.
For example, to add Localizable.strings for Japanese, click Japanese in the File Inspector. This will create a new Localizable.strings file under the
ja.lproj
folder.
Add the below content in the Localizable.string file:
"FALLBACK_TITLE" = "
<string in Japanese>
";
"BIOMETRIC_DIALOG_TITLE" = "
<string in Japanese>
";
"CANCEL_TITLE" =  "
<
string in Japanese>
";
The following code snippet provides the key and the respective title configured in the Localizable.string file:
AuthenticationHandler *authHandlerobject=[[AuthenticationHandler alloc] init];
[authHandlerobject setBiometricDialogTitle:NSLocalizedString(@"BIOMETRIC_DIALOG_TITLE", @"Biometric dialog title text")];
[authHandlerobject setBiometricFallbackTitle:NSLocalizedString(@"FALLBACK_TITLE", @"Fall back text")];
[authHandlerobject setBiometricCancelTitle:NSLocalizedString(@"CANCEL_TITLE", @"Cancel text")];
The following images show the text that can be localized and the corresponding methods that must be used for the text.
Screenshot_20180628-125457_CA MPN Demo.jpg Screenshot_20180628-125457_CA MPN Demo.jpg