Authenticate with PIN
The initial PIN for authentication is set when registering a device.
Authenticate
- iOS (Swift)
- Android (Java)
trustFactorClient.authenticate(pin: <string>) { result, correlationId in
switch result {
case .failure(let error):
// handle error
case .success(_):
// handle success
}
}
trustFactorClient.authenticate(pin, (result) -> result.fold(
(TFAuthenticationResponse value, String correlationId) -> {
// handle success
},
(Error error, String correlationId) -> {
// handle error
}
));
Update
- iOS (Swift)
- Android (Java)
trustFactorClient.updateAuthenticationPIN(old: <old>, new: <new>) { result, correlationId in
switch result {
case .failure(let error):
// handle error
case .success(_):
// handle success
}
}
trustFactorClient.updateAuthenticationPIN(oldPin, newPin, (result) -> result.fold(
(Boolean value, String correlationId) -> {
// handle success
},
(Error error, String correlationId) -> {
// handle error
}
));