Skip to main content

Overview

The Vouch Android SDK provides email validation and device fingerprinting for native Android applications. Built with Kotlin, it integrates seamlessly with both Jetpack Compose and traditional Views.
Package: com.github.Vouch-IN:vouch-sdk-android Platform: Android 8.0+ (API 26+) Language: Kotlin 1.9+ Distribution: JitPack (Gradle/Maven)

Installation

Add JitPack repository to your project’s settings.gradle.kts:
settings.gradle.kts
Add the dependency to your app’s build.gradle.kts:
build.gradle.kts

Permissions

Add internet permission to your AndroidManifest.xml:
AndroidManifest.xml
No other permissions required. The SDK only needs internet access to communicate with the Vouch API.

Quick Start

Jetpack Compose Integration

Basic Form Validation

Real-Time Validation

Traditional View/Activity Integration

Basic Usage

With ViewModel (MVVM Pattern)

Configuration

Custom Options

API Version

Control which API version to use:

Core Methods

validate()

Validate an email address with automatic device fingerprinting. Never throws — all errors are returned in the result.
For more detail, access the full response:
Returns: ValidationResult
email
String?
The normalized email address
error
String?
Error message if request failed
data
ValidationData?
Response data from server (sealed class with Validation or Error)
statusCode
Int?
HTTP status code
Convenience properties:
isAllowed
Boolean
Whether the validation passed (recommendation is “allow”)
recommendation
String?
The recommendation string (“allow”, “block”, or “flag”)
signals
List<String>?
The validation signals list
errorMessage
String?
A descriptive error message for any failure scenario, null if allowed

generateFingerprint()

Get the device fingerprint directly without validating an email:
Returns: Fingerprint with the following signals:
hardware
HardwareSignals
Device hardware information (screen, CPU, memory, model, manufacturer)
fonts
FontSignals
System fonts and SHA-256 hash
system
SystemSignals
Android version, SDK level, language, locale, timezone
storage
StorageSignals
SharedPreferences, KeyStore, FileSystem availability
timestamp
Long
Unix timestamp in milliseconds
version
String
SDK version (e.g., “2.0.0”)

Error Handling

The SDK never throws from validate(). All errors (network failures, invalid format, API errors) are captured in the ValidationResult:

Accessing Detailed Error Info

For cases where you need more control:

Privacy & Permissions

Minimal Permissions

The Vouch Android SDK only requires the INTERNET permission:
No dangerous permissions required. The SDK does not access location, camera, contacts, or any other sensitive data.
No permissions needed for:
  • Location
  • Camera/Photos
  • Contacts
  • Microphone
  • Bluetooth

Data Collection

The SDK collects device fingerprint data for fraud prevention. You must disclose this in:
  1. Your app’s privacy policy
  2. Google Play Data Safety form
  3. GDPR/CCPA notices (if applicable)
What data is collected:
  • Hardware signals: Screen dimensions, CPU cores, memory, device model, manufacturer
  • Font signals: System fonts and SHA-256 hash
  • System signals: Android version, SDK level, language, locale, timezone
  • Storage signals: SharedPreferences, KeyStore, FileSystem availability
No personally identifiable information (PII) is collected. All data is technical device and system information.

ProGuard/R8

The SDK is fully compatible with ProGuard and R8. Obfuscation rules are included automatically in the library. No additional configuration is required.

Performance

  • Fingerprint Generation: ~100-500ms (first time)
  • Email Validation: Instant local validation + network request time
  • Font Collection: ~200-1000ms (can be disabled)
The SDK starts fingerprint generation immediately when initialized, so the first validate() call can reuse the cached fingerprint.

Best Practices

1. Initialize with Application Context

Always use applicationContext to avoid memory leaks:

2. Use Dependency Injection

Inject the Vouch instance using Hilt or Koin:

3. Handle Errors Gracefully

Always handle validation errors without blocking the user:

4. Use StateFlow for UI Updates

Combine with StateFlow for reactive UI updates:

API Reference

Vouch

Main SDK class for email validation and fingerprinting.

VouchOptions

SDK configuration options.

ApiVersion

API version specification.

ValidationAction

Validation action enum used in toggle configuration.

ValidationResult

Email validation response structure with convenience properties.

ValidationData

Validation response data — sealed class with two cases.

CheckResult

Individual check result.

ValidationMetadata

Validation metadata.

DeviceData

Device fingerprint data returned in validation results.

IPData

IP address analysis data.

ValidationToggles

Toggle configuration for which validations to run.

ErrorResponseData

Error response from the API.

Support

For issues and questions: