Skip to main content

Overview

The Fingerprints&I module provides contactless fingerprint capture using Identy technology. This module enables high-quality fingerprint capture directly from device cameras, supporting multiple finger detection modes for comprehensive biometric verification.

Key Features

  • Contactless Capture: Capture fingerprints using device camera (no sensor required)
  • Multiple Detection Modes: Support for various finger combinations (4 fingers, single finger)
  • Real-time Feedback: Visual guidance during capture process
  • Quality Validation: Automatic quality checks and blur detection
  • Hand Detection: Left and right hand support
  • Biometric Templates: Generates standard fingerprint templates
  • Customizable UI: Full customization of feedback messages and styling
  • Cross-Platform: Works on mobile and desktop with camera

Hardware Requirements

This module requires valid Identy credentials including model URL.
  • Modern web browser with WebRTC support
  • High-quality device camera (8MP or higher recommended)
  • Good lighting conditions (natural or bright indoor lighting)
  • Stable internet connection
  • HTTPS protocol (required)
Flash capability is recommended for optimal capture quality, especially in low-light conditions.

Installation

npm install @fad-producto/fad-sdk

Implementation

1

Import SDK and Configure Credentials

Import the FAD SDK and set up your Identy credentials:
import FadSDK from '@fad-producto/fad-sdk';

const CREDENTIALS = {
  modelUrl: 'YOUR_IDENTY_MODEL_URL',
};

const TOKEN = 'YOUR_FAD_TOKEN';
2

Define Detection Modes

Specify which fingers to capture:
// Capture left 4 fingers and right 4 fingers
const detectionModes = ['L4F', 'R4F'];

// Other options:
// 'L4F' - Left 4 fingers (index, middle, ring, pinky)
// 'R4F' - Right 4 fingers
// 'LT'  - Left thumb
// 'RT'  - Right thumb
// 'L1F' - Left single finger
// 'R1F' - Right single finger
3

Configure Module Settings

Set up capture configuration:
const CONFIGURATION = {
  livenesCheck: true,
  asThreshold: 'HIGH',
  captureTimeout: 60000,  // 60 seconds
  headerProcess: window.location.origin,
  customization: {
    moduleCustomization: {
      style: {
        identy: {
          boxes: {
            initial: null,
            updating: null,
          },
          header: {
            flashing: {
              initial: '#FFFFFF',
              middle: '#FFFFFF',
              final: '#FFFFFF',
            },
          },
          instruction: {
            color: '#FFFFFF',
          },
        },
      },
    },
  },
};
4

Customize Feedback Legends

Configure user feedback messages:
const CONFIGURATION = {
  // ... previous config
  customization: {
    moduleCustomization: {
      legends: {
        identy: {
          feedbackRetry: 'Something went wrong, please change location',
          feedbackSearching: 'Searching...',
          feedbackInsideGuide: 'Please keep your hand inside the guide',
          feedbackPleaseHold: 'Please hold',
          feedbackPleaseHoldFlash: 'Please wait for the flash',
          feedbackPleaseMove: 'Move fingers slightly to improve focus',
          feedbackNoFingers: 'Searching for {0} hand',
          feedbackStable: 'Keep your hand stable',
          feedbackHandFar: 'Move hand closer',
          feedbackHandClose: 'Move hand away',
          feedbackCapturing: 'Capturing',
          feedbackCaptured: 'Captured',
          feedbackBlurry: 'Blurry quality, please retry',
          hand: {
            left: 'left',
            right: 'right',
          },
        },
      },
    },
  },
};
5

Initialize SDK and Start Capture

Create the SDK instance and start the fingerprint capture:
async function initProcess() {
  const options = {
    environment: FadSDK.getFadEnvironments().UATHA,
  };

  const detectionModes = ['L4F', 'R4F'];

  const FAD_SDK = new FadSDK(TOKEN, options);
  
  try {
    const moduleResponse = await FAD_SDK.startIdentyFingerprints(
      detectionModes,
      CREDENTIALS,
      CONFIGURATION
    );

    console.log('Process completed', moduleResponse);

    // Access captured fingerprint data
    const fingerprintData = moduleResponse.data;
    console.log('Fingerprint templates:', fingerprintData);

    // Process or upload fingerprint data
    await uploadFingerprints(fingerprintData);

  } catch (ex) {
    console.error('Process error:', ex);
    handleError(ex);
  } finally {
    FAD_SDK.end();
  }
}

Response Structure

{
  event: string,  // 'PROCESS_COMPLETED'
  data: {
    // Structure varies based on detection modes
    leftHand?: {
      fourFingers?: {
        templates: object,  // Fingerprint templates
        quality: number,
        images: string[],   // Base64 images
      },
      thumb?: {
        templates: object,
        quality: number,
        images: string[],
      },
    },
    rightHand?: {
      fourFingers?: {
        templates: object,
        quality: number,
        images: string[],
      },
      thumb?: {
        templates: object,
        quality: number,
        images: string[],
      },
    },
  }
}
The templates object contains biometric fingerprint data that can be used for matching. Quality scores indicate capture quality.

Error Handling

Handle errors using the SDK error constants:
if (ex.code === FadSDK.Errors.Identy.NO_CREDENTIALS) {
  alert('Credentials are missing. Please provide model URL.');
}

Detection Modes

Capture four fingers simultaneously (index, middle, ring, pinky):
const detectionModes = ['L4F', 'R4F'];
// L4F - Left hand 4 fingers
// R4F - Right hand 4 fingers
Use Cases:
  • Standard biometric enrollment
  • Multiple fingerprint verification
  • Government ID programs
Requirements:
  • All 4 fingers must be visible
  • Fingers should be spread slightly
  • Hand must be flat and stable

Configuration Options

Set maximum time for capture:
captureTimeout: 60000  // Milliseconds (60 seconds)
Consider:
  • Number of fingers to capture
  • Expected lighting conditions
  • User experience level
Configure quality requirements:
asThreshold: 'HIGH'  // Options: 'LOW', 'MEDIUM', 'HIGH'
LevelQualityUse Case
LOWBasicQuick verification
MEDIUMStandardGeneral purpose
HIGHPremiumCritical applications
Customize flash indicator:
header: {
  flashing: {
    initial: '#FFFFFF',  // Flash start color
    middle: '#FFFF00',   // Flash peak color
    final: '#FFFFFF',    // Flash end color
  },
}
All feedback messages are customizable:
legends: {
  identy: {
    feedbackSearching: 'Looking for your hand...',
    feedbackHandFar: 'Please move closer',
    feedbackHandClose: 'Too close, move back',
    feedbackStable: 'Hold steady',
    feedbackCapturing: 'Capturing now',
    feedbackCaptured: 'Success!',
    // ... more options
  },
}

Usage Examples

async function enrollFingerprints(userId) {
  const detectionModes = ['L4F', 'R4F'];  // Both hands, 4 fingers each
  
  const FAD_SDK = new FadSDK(TOKEN, {
    environment: FadSDK.getFadEnvironments().UATHA,
  });

  try {
    const response = await FAD_SDK.startIdentyFingerprints(
      detectionModes,
      CREDENTIALS,
      CONFIGURATION
    );

    // Save to database
    await saveFingerprints({
      userId,
      fingerprintData: response.data,
      timestamp: new Date().toISOString(),
    });

    return response.data;
  } finally {
    FAD_SDK.end();
  }
}

Best Practices

Optimal Lighting

Use bright, even lighting. Natural light or bright indoor lighting works best.

Hand Position

Ensure hand is flat, fingers slightly spread, and positioned within the guide.

Stability

Keep hand and device stable during capture. Use a stable surface if possible.

Quality Check

Validate quality scores and implement minimum thresholds for your use case.

Capture Tips for Users

1

Clean Hands

Ensure hands are clean and dry. Remove any dirt, moisture, or lotions.
2

Good Lighting

Position yourself in a well-lit area with even lighting.
3

Flat Hand

Keep hand flat and fingers slightly spread within the guide.
4

Hold Steady

Remain still during capture, especially when flash occurs.
5

Follow Guidance

Follow on-screen instructions to move closer, away, or adjust position.

Security Considerations

Fingerprint data is sensitive biometric information. Implement strict security measures.
  • Encrypt biometric templates at rest and in transit
  • Never store raw fingerprint images
  • Implement strict access controls
  • Follow ISO/IEC 19794 standards for biometric data
  • Comply with GDPR/CCPA for biometric data
  • Maintain audit logs of all captures
  • Implement secure deletion procedures
  • Use HTTPS for all communications
  • Consider data residency requirements

Troubleshooting

  • Improve lighting conditions
  • Ensure hand is within the guide frame
  • Keep hand flat and stable
  • Clean camera lens
  • Check camera quality (8MP+ recommended)
  • Increase lighting
  • Keep hand completely still
  • Ensure fingers are spread slightly
  • Clean hands (remove moisture/lotion)
  • Move to optimal distance from camera
  • Increase timeout value
  • Improve lighting conditions
  • Ensure stable hand position
  • Use device with flash capability
  • Keep device and hand perfectly still
  • Use flash if available
  • Ensure adequate lighting
  • Clean camera lens
  • Use higher quality camera device

Quality Metrics

Quality ScoreRatingAction
80-100ExcellentAccept
60-79GoodAccept for most use cases
40-59FairConsider retry for critical apps
0-39PoorReject and retry

Build docs developers (and LLMs) love