Actual Capture Paper Receipts: Android Developer Guide

This guide covers everything you need to integrate paper receipt scanning into your Android app: how it works, setup, camera options, correction flows, and references.

How It Works

  1. Capture — The user photographs a receipt using the device camera.
  2. Extract — OCR processes the image on-device and returns structured data: merchant, date, total, line items, payment method, and more.
  3. Enrich (optional) — If Product Intelligence is enabled, extracted line items are matched against the product catalog for UPC, brand, category, and normalized product names.

All processing happens on-device. No receipt images are sent to the cloud.

Requirements

RequirementVersion
Android Min SDK23+ (Android 6.0+)
Android Compile SDK36+
Java17+
Architecturearmeabi-v7a, arm64-v8a
Camera720p+

Installation

  1. Add the Maven repository:

Kotlin DSL:

repositories {
    maven { url = uri("https://maven.microblink.com") }
}

Groovy:

repositories {
    maven { url "https://maven.microblink.com" }
}
  1. Add the dependencies:

Kotlin DSL:

dependencies {
    implementation(platform("com.microblink.blinkreceipt:blinkreceipt-bom:1.9.13"))
    implementation("com.microblink.blinkreceipt:blinkreceipt-recognizer")
    implementation("com.microblink.blinkreceipt:blinkreceipt-camera-ui") // for out-of-box camera
}

Groovy:

dependencies {
    implementation platform("com.microblink.blinkreceipt:blinkreceipt-bom:1.9.13")
    implementation "com.microblink.blinkreceipt:blinkreceipt-recognizer"
    implementation "com.microblink.blinkreceipt:blinkreceipt-camera-ui" // for out-of-box camera
}

The blinkreceipt-camera-ui module provides the out-of-the-box and enhanced camera experiences. If you only need the recognizer for a fully custom camera, you can omit it.

→ Android SDK Repository (GitHub)

License Configuration

Option A: Android Manifest

<meta-data
    android:name="com.microblink.LicenseKey"
    android:value="YOUR-LICENSE-KEY"
/>

Option B: Programmatically

Kotlin:

BlinkReceiptSdk.licenseKey = "YOUR-LICENSE-KEY"

Java:

BlinkReceiptSdk.licenseKey("YOUR-LICENSE-KEY");

Add camera permission to AndroidManifest.xml:

<uses-permission android:name="android.permission.CAMERA" />

Initialize the SDK

Kotlin:

BlinkReceiptSdk.initialize(this, object : InitializeCallback {
    override fun onComplete() {
        // Ready to use
    }

    override fun onException(throwable: Throwable) {
        // Log exception
    }
})

Java:

BlinkReceiptSdk.initialize(this, new InitializeCallback() {
    @Override
    public void onComplete() {
        // Ready to use
    }

    @Override
    public void onException(@NonNull Throwable throwable) {
        // Log exception
    }
});

Camera Options

Option A: Out-of-the-Box Camera (Standard)

The blinkreceipt-camera-ui module provides a complete camera interface with alignment guidance, blur detection, and real-time feedback. This is the fastest integration path.

Option B: Enhanced Camera UX

Same module with enhanced configuration. Includes improved graphics, messaging, and animations.

Data Chips: Enable on-screen indicators showing when key fields are detected:

OptionWhat it does
enableDateChipShows when the purchase date has been found
enableTotalChipShows when the total has been found
enableMerchantChipShows when the merchant has been identified

Note: Some merchant detection methods only run at the end of the scan session. The merchant chip may not appear during scanning but the merchant will still be returned in the results.

Option C: Custom Camera (RecognizerView)

For full UI control, use the RecognizerView component directly in your layout:

  1. Add RecognizerView to your XML layout.
  2. Build your own buttons, overlays, and controls around it.
  3. Forward all activity lifecycle callbacks (onCreateonResumeonPauseonDestroy) to the RecognizerView. Required for proper camera management.
  4. Use the RecognizerView methods to control scanning: capture, confirm, finish, and cancel.

Option D: Jetpack Compose

→ Camera UI + Jetpack Compose Integration Guide

Long Receipts

For receipts that don’t fit in a single frame, the SDK supports multi-frame capture:

  1. The user captures the first section of the receipt normally.
  2. After the first capture, the bottom edge of the previous frame appears at the top of the screen as an alignment guide.
  3. The user positions the next section with slight overlap and captures again.
  4. Repeat until the entire receipt is captured.
  5. The SDK stitches all frames together and returns a single set of results.

The out-of-the-box and enhanced cameras handle this flow automatically. If using RecognizerView, you are responsible for displaying alignment cues and managing the frame sequence.

Receipt Correction

The Android SDK supports the same receipt correction capabilities as iOS.

Stock Correction UI: Launch the built-in correction interface by passing a Blink Receipt ID. The user sees extracted products and prices, can edit any item, add missed items, and scan barcodes for UPC lookup. Corrected results include updated promotion qualification status.

Custom Correction UI: Build your own interface using the SDK’s data and correction methods. Load scan results, display your own editing UI, call the SDK’s correction methods, and submit modified results for validation.

Fields in corrected results:

  • userAdded — Product was added by the user during correction
  • userModified — One or more product properties were changed during correction

Localization (Override Labels)

All text elements in the camera UI can be customized by overriding string resources.

→ Override Labels — Camera UI

PDF Recognition

The Android SDK also supports extracting data from PDF receipt files (not available on iOS).

→ PDF Recognition — Getting Started → PDF Recognition — Configuration → PDF Recognition — How to Use

Receipt Quality & Feedback

FieldWhat it tells you
is_receiptWhether the image appears to be a valid receipt
is_blurryWhether the image is too blurry to extract reliably
is_screenWhether the image appears to be a photo of a screen
is_fraudulentWhether the receipt appears manipulated or counterfeit (US only, select banners)
is_duplicateWhether this receipt has been submitted before (2-week window, within your instance)
ocr_confidenceAverage OCR confidence score across all characters

Testing Recommendations

  • Test with various receipt types: thermal, inkjet, laser-printed
  • Test in different lighting conditions: bright, dim, mixed
  • Test with challenging receipts: crumpled, faded, long, torn
  • Test across device types: older phones, budget devices, different screen sizes

Implementation Timeline

ScopeEstimated Dev Time
Out-of-the-Box Camera~1 week + QA
Custom Camera~2 weeks + QA

Additional References

Related

Let’s Turn Proof Into Action 

Your next move should be backed by proof, and we’re here to help you leverage real data for real results. Start turning verified insights into measurable impact today.