Skip to main content

Web App Integration

This page describes how the Unico journeys work and the available integration models for embedding them into an application.

A journey is the set of steps the user goes through to complete an identity verification. For example: capturing a document photo and performing a facial capture (liveness).

Unico manages the entire experience. The integration effort is minimal: the journey is created via CreateProcess, the user is directed to it, and the result is received at the end. Everything in between — screens, instructions, validations — is already built and maintained by Unico.

Choosing your integration approach
  • Web SDK (unico-webframe package) — use when your back-end already controls the identity verification flow and only needs the client-side capture component. Returns base64 + encrypted JWT directly to your callback; you manage the API calls.
  • Web App Integration (idpay-b2b-sdk package) — use when you want Unico to orchestrate the full journey (multi-step flows, document capture + liveness). The idpay-b2b-sdk package powers the embedded Journeys SDK (iFrame) model; the Direct access (redirect) model needs no library.

Two integration models

Each client has different needs. Unico offers two models for directing the user to the journey.

ModelBest for
Direct accessMobile applications that already use WebView, or web flows where the journey can happen outside the main page
Journeys SDKWeb applications that need an integrated, seamless experience, keeping the user within the same environment

The user is redirected to a Unico-hosted link, where the journey takes place. Upon completion, they are returned to the URL defined during process creation (the callbackUri parameter).

This is the simplest approach to adopt: it requires no library installation and works well when the journey does not need to happen inside the application's own page. On the other hand, taking the user outside the client's environment tends to introduce more friction and, consequently, a higher drop-off rate.

After creating a process, the API response includes the URL of the Unico-hosted journey. There are two common ways to direct the user to it:

  • Standard redirect. The user is redirected directly to the journey URL. Upon completion, Unico redirects them back to the callbackUri defined during process creation.
  • New tab with window.open(). The journey is opened in a new browser tab, keeping the user in a separate context. In this case, it is recommended to monitor for a URL change to the callbackUri and close the tab once the process is complete. See the MDN documentation for details on the API.

Redirect integration flow

In mobile applications, it is common to use a WebView to open the journey directly, with no additional redirect needed. In this case, the callbackUri also accepts a deeplink, allowing the journey's completion to trigger the opening of a specific screen in the native application. Simply configure the deeplink as the return destination and the operating system handles routing the user to the right place.

Webview integration flow

Do not keep DevTools open during capture tests

The Unico application uses the Capture SDK (unico-webframe) for facial capture, which detects open DevTools as a potential fraud signal and blocks the submission. Close DevTools before running end-to-end capture tests.

Unsupported integrations

The models described in this documentation — direct access and Journeys SDK — are the only integration approaches officially supported by Unico. Integrations that deviate from these standards may cause unexpected behavior, security flow failures, and journey interruptions, and will not be covered by Unico support.

Examples of unsupported approaches:

  • Embedding the SDK inside a WebView in mobile applications. In these cases, the correct approach is to use the direct access model, opening the journey link directly in the WebView without involving the Journeys SDK.
  • Loading the iFrame directly via an <iframe> HTML tag, without going through the Journeys SDK. The iFrame is an internal implementation detail of the SDK and must not be instantiated manually. The correct approach is to use the Journeys SDK, which manages the iFrame lifecycle securely and within the expected standards.

If there is any doubt about whether an approach is within the supported standard, consult the documentation or contact support before proceeding with the implementation.