Initialize

You can pass in different handler functions like the onLoad, onStart, onRestart, onPassStep, onComplete or onError method to handle different events of the verification flow to the init function.

Allpass.init({
  onLoad: () => {},
  onRestart: ({appKey, transactionId, clientSession}) => {},
  onStart: ({appKey, transactionId, clientSession}) => {},
  onPassStep: ({appKey, transactionId, stepType, clientSession}) => {},
  onComplete: ({appKey, transactionId, clientSession}) => {},
  onError: ({appKey, transactionId, error, stepType, clientSession}) => {},
});

If user doesn't finish verification process and current session is still active - we can automatically start this verification. In order to make it you should call restart after init method.

Allpass.restart();

Also it could be chaining with an init method:

Allpass
  .init({onComplete: ({appKey, transactionId, clientSession}) => {}})
  .restart();

Last updated

elKYC - Allpass.ai 2023