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.
Two integration models
Each client has different needs. Unico offers two models for directing the user to the journey.
| Model | Best for |
|---|---|
| Direct access | Mobile applications that already use WebView, or web flows where the journey can happen outside the main page |
| Journeys SDK | Web applications that need an integrated, seamless experience, keeping the user within the same environment |
- Direct access
- Journeys SDK
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
callbackUridefined 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 thecallbackUriand close the tab once the process is complete. See the MDN documentation for details on the API.
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.
The journey takes place inside the application itself, without taking the user out of their context. The Journeys SDK is installed in the application and used to open the journey when needed.
This is the recommended path for a more integrated and seamless experience, keeping the user in the same environment throughout, which tends to reduce friction and drop-off across the flow.
Unico provides a JavaScript library compatible with modern browsers, allowing the journey to be integrated into virtually any application with just a few lines of code.
Compatibility
The library is designed to fit into any project without friction, regardless of the stack in use:
- Any web application. Distributed in UMD format, it works when imported through modern bundlers (such as webpack or Vite). Compatible with any framework (React, Angular, Vue) or plain JavaScript.
- Modern browsers. The library already includes the necessary polyfills for features like
Promises and
async/await, extending compatibility to older browser versions as well. - Standard web APIs. The journey runs on native browser capabilities, with no dependency on plugins or external libraries in the project.
How the SDK works internally
When a journey is opened, the SDK inserts an iFrame into the page and takes control of the entire visual experience from that point on. The screens, scripts, and assets for each step run inside this iFrame, from the moment the user begins through to the completion of the process.
This architectural decision is intentional: iFrame isolation ensures the Unico journey does not interfere with the application's styles or behavior. No script leaks into the external context, no CSS rule collides with the application's own styles. The result is a consistent experience for the end user and minimal impact on the client's product.
Since Unico is responsible for creating and managing the iFrame, journey improvements — whether in performance, experience, or validation — are delivered automatically to all users, with no changes required in the integrated application. The integration will always run with the best available optimizations, without needing to track or react to every platform update.