Reverification

🚧

Reverification is only supported in the JS Plugin and avant theme currently.

The reverification job compares a new selfie to a source job's selfie or ID photo. This allows you to verify that the current user is the same person that was verified previously. To initiate a reverification job:

  1. Perform the initial verification job and capture the job id
  2. Submit a new job using the JS Plugin
  3. Set type to reverify
  4. Specify jobId from the source job in reverificationParameters
  5. Set theme to avant
  6. Define onReverify to redirect to the next page once user is reverified

Reverification quick start code

<head>
  <!-- utf-8 is required for JS Plugin default fonts -->
  <meta charset="utf-8" />
  <script src="https://static.vouched.id/widget/vouched-2.0.0.js"></script>
  <script type='text/javascript'>


    (function() {
      var vouched = Vouched({
        // specify reverification job
        type: 'reverify',
        reverificationParameters: {
          // reference the source job by its id
          jobId: 'gmYDEJWB2'
        },

        // theme must be 'avant' for reverification
        theme: {
          name: 'avant',
        },
        
        appId: "<PUBLIC_KEY>",
        // your webhook for POST verification processing
        callbackURL: 'https://website.com/webhook',

        // mobile handoff
        crossDevice: true,
        crossDeviceQRCode: true,
        crossDeviceSMS: true,
        onInit: ({token, job}) => {
          console.log('initialization');
        },
        
        // called when the reverification is completed.
        onReverify: (job) => {
          // token used to query jobs
          console.log("Reverification complete", { token: job.token });

          // Redirect to the next page based on the job success
          if( job.result.success){
            window.location.replace("https://website.com/success/");
          }else{
            window.location.replace("https://website.com/failed/");
          }
        },       
      });
      vouched.mount("#vouched-element");
    })();

  </script>
</head>
<body>
  <div id='vouched-element' style="height: 100%"/>
</body>