Skip to main content

Get started

This page demonstrates how to configure your account to use the SDK, as well as how to install and configure it in your project.

Before you begin

Before you start, make sure that your development environment meets the following requirements:

Installation

Using Flutter CLI

Use the following command in flutter cli to add the SDK to your project:

$ flutter pub add unico_check

The command above adds the following line in your pubspec.yaml file.

dependencies:
unico_check: ^2.0.2
Manually get the packages

The command flutter pub add unico_check implicitly triggers command flutter pub get. If package is not correctly installed, make sure that you have unico_check in you pubspec.yamlfile, and manually run flutter pub get.

Declare app permissions

In order to use user's camera, include the following user permissions in your app:

<key>NSCameraUsageDescription</key>
<string>Camera usage description</string>

Including dependencies

Now you just need to correctly import the SDK into your project. You just need to import it in your Dart file.

main.dart

import 'package:unico_check/unico_check.dart';

Get your credentials

  1. Log in to the Unico Customer Area;
  2. Go to Configurações (Configurations), then Integração (Integrations) and finally to API Key;
  3. Generate or edit an existing API Key;
  4. If you want to use the Smartlive with interaction functionality in your app, check if the field "Utiliza liveness com interação" is enabled (this field must be showing you the word "SIM"). Otherwise, contact the support team to request the activation.
Smartlive with interaction

Learn more about Smartlive with interaction in the key concepts section.

  1. Select SIM (Yes) in the field "Utiliza autenticação segura na SDK" (Asking if use secure authentication in SDK);
  2. Expand the Android iOS section and add your Android application name and Bundle ID;
  3. Save your changes.
  4. Repeat the procedures 1 to 7 to create another key to your Android App.

GETTING CREDENTIALS

To use the Android SDK you need to obtain the SDK Key credential, a unique customer identification key generated by the Unico team.

  1. contact the CSs and/or Onboarding team.
  2. Request the SDK Key by entering the identifiers of your applications. Bundle Identifier for iOS, PackageID for Android and Host for WEB.
  3. The identifiers of your applications will be linked to the SDK Key by the Unico team.
  4. You receive your SDK Key to implement the AccessBioConfigDataSource.
Credentials (Client API Key) - Deprecated Method

To import the credentials (Client API Key) into your project, use the following guide:

  1. Access your instance with login and password;
  2. Scroll down the menu bar and click on the Settings menu, then click on the Integration menu and finally click on the API Key menu;
  3. To create an API Key click on + New API Key or to edit click under the desired API Key;
  4. If you want to use the FaceTec Proof of Life Selfie Camera mode, check that the Use liveness with interaction field is filled in with the YES option. If it is filled in with NO, or is not appearing, please contact the support through Help Center and request activation;
  5. In the Use secure authentication in SDK field, select the Yes option;
  6. Expand the Android SDK section, add the project ID and Package Name;
  7. Finally, click on Save;
  8. Go back to the APIKey section;
  9. Choose the API Key configured, in the Bundle column, click on the Download button;
  10. A new section will open, select the Android option;
  11. Click on Generate and automatically a new tab will open in your browser containing project information in JSON format;
  12. Save this JSON.
SMARTLIVE WITH INTERACTION (LIVENESS WITH INTERACTION)

Learn more about Smartlive with Interaction here.

ATTENTION TO POP-UP BLOCKERS

If in step 10 the tab does not open, please check if your browser is blocking pop-ups.

EMBARKING CREDENTIALS INTO YOUR PROJECT

To add the SDK Key to the project, implement the AccessBioConfigDataSource protocol in your class.

  final _configIos = UnicoConfig(
getBundleIdentifier: "Your BundleIdentifier Ios",
getHostKey: "Your HostKey Ios");

final _configAndroid = UnicoConfig(
getBundleIdentifier: "Your BundleIdentifier Android",
getHostKey: "Your HostKey Android");

void initUnicoCamera() {
_unicoCheck = new UnicoCheck(
listener: this,
unicoConfigIos: _configIos,
unicoConfigAndroid: _configAndroid);
}
Credentials (Client API Key) - Deprecated Method
  final _configIos = UnicoConfig(
getProjectNumber: "Your ProjectNumber Ios",
getProjectId: "Your ProjectId Ios",
getMobileSdkAppId: "Your MobileSdkAppId Ios",
getBundleIdentifier: "Your BundleIdentifier Ios",
getHostInfo: "Your HostInfo Ios",
getHostKey: "Your HostKey Ios");

final _configAndroid = UnicoConfig(
getProjectNumber: "Your ProjectNumber Android",
getProjectId: "Your ProjectId Android",
getMobileSdkAppId: "Your MobileSdkAppId Android",
getBundleIdentifier: "Your BundleIdentifier Android",
getHostInfo: "Your HostInfo Android",
getHostKey: "Your HostKey Android");

void initUnicoCamera() {
_unicoCheck = new UnicoCheck(
listener: this,
unicoConfigIos: _configIos,
unicoConfigAndroid: _configAndroid);
}

Getting help

Are you missing something or still need help? Please, please get in touch with the support team at help center.

Next steps