authenticate

Authenticates an end user to the MIRACL Trust platform by generating a JWT authentication token.

Use this method to authenticate within your application.

After the token is generated, it must be sent to the application server for verification.

Return

A MIRACLResult representing the result of the authentication:

Parameters

user

The user to authenticate.

pinProvider

A callback called by the SDK when the PIN is requested.


fun authenticate(user: User, pinProvider: PinProvider, resultHandler: ResultHandler<String, AuthenticationException>)

Authenticates an end user to the MIRACL Trust platform by generating a JWT authentication token.

Use this method to authenticate within your application.

After the JWT authentication token is generated, it must be sent to the application server for verification.

Parameters

user

The user to authenticate.

pinProvider

A callback called by the SDK when the PIN is requested.

resultHandler

A callback to handle the result of the authentication.

  • If successful, the result is a MIRACLSuccess.

  • If an error occurs, the result is a MIRACLError with an exception describing issues with the operation.