Docutain.SDK.MAUI 2.1.0

dotnet add package Docutain.SDK.MAUI --version 2.1.0
                    
NuGet\Install-Package Docutain.SDK.MAUI -Version 2.1.0
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Docutain.SDK.MAUI" Version="2.1.0" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Docutain.SDK.MAUI" Version="2.1.0" />
                    
Directory.Packages.props
<PackageReference Include="Docutain.SDK.MAUI" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Docutain.SDK.MAUI --version 2.1.0
                    
#r "nuget: Docutain.SDK.MAUI, 2.1.0"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Docutain.SDK.MAUI@2.1.0
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Docutain.SDK.MAUI&version=2.1.0
                    
Install as a Cake Addin
#tool nuget:?package=Docutain.SDK.MAUI&version=2.1.0
                    
Install as a Cake Tool

Docutain SDK for .NET MAUI

What is it?

The Docutain SDK brings functionalities for automatic document scanning, data capture, image processing, OCR text recognition, intelligent data extraction, PDF creation and photo payment to your apps.

It works 100% offline, which ensures maximum data safety.

It contains individually licensable modules:

For more details visit our website https://sdk.Docutain.com

If you like to test the functionality without writing any lines of code, check out our Showcase Apps.

Usage

The following shows a minimum example to use the document scanner. For all available features and theming possibilities, please check out our documentation.

Initialize

In order to use any functionality of the SDK, you must initialize it first.

public partial class App : Application
{
    public App()
    {
        InitializeComponent();
        if (!DocutainSDK.InitSDK("<YOUR-LICENSE-KEY>"))
        {
            // init of Docutain SDK failed, get the last error message
            var error = DocutainSDK.LastError;
            // implement handling to avoid accessing Docutain SDK when it is not initialized
        }
    }
}

For testing purposes, you can leave the license key empty. However, the SDK will stop working after 1 minute. You can get a free extended trial license on our website.

Start the scanner to scan documents

On iOS, make sure to add a camera usage description in the Info.plist. If you don't, the app will crash.

NSCameraUsageDescription - "In order to scan documents, you need to grant permission to access the camera."

To start the document scanner, provide a DocumentScannerConfiguration and alter it according to your needs. Then just call UI.ScanDocument and wait for the result. Check out the documentation for possible scan configurations.

// customize the scan config according to your needs
var scanConfig = new DocumentScannerConfiguration();
var result = await UI.ScanDocument(scanConfig);

Generate a PDF document

Once the user finished the scan, you can generate a PDF document out of the scanned pages. The PDF document will include the recognized text, making it searchable and selectable. Check out the documentation for more details.

var destinationPath = FileSystem.CacheDirectory + "/TestPDF.pdf";
var pdfFile = Document.WritePDF(destinationPath);

Image Export

It is also possible to get the scanned pages as single image files. Check out the documentation for more details.

int pages = Document.PageCount;
for (int p = 1; p <= pages; p++)
{
    string targetFilePath = string.Format("{0}/Image_{1}.jpg", path, p);
    string imageFile = Document.WriteImage(p, targetFilePath);
}

Text Recognition

With a single line of code, you can get the recognized text of the scanned document or single pages. Check out the documentation for more details.

var text = DocumentDataReader.GetText();

Data Extraction

It is also possible to run data extraction on the scans to extract certain values, like Address, Amount, IBAN, Date and more. Check out the documentation for more details.

var jsonData = DocumentDataReader.Analyze();

Photo Payment

Integrate Photo Payment into your banking app within minutes with just a few lines of code. It works 100% offline on device. No data at all is transfered to any external server or cloud service, ensuring 100% data protection.

Check out the documentation for more details.

// customize the photo payment process according to your needs
var photoPaymenConfig = new PhotoPaymentConfiguration();
var result = await UI.StartPhotoPayment(photoPaymenConfig);
if (result != null)
{
    if(result != string.Empty)
    {
        // payment information has been extracted
        // result is a JSON string containing the information
        // extract the fields you need and pass it on to your payment sheet
    }
    else
    {
        // no data was extracted at all
        // Note: this case is only reachable, if you disabled the Empty Result Screen
    }
}
else
{
    // user canceled scan process
}

Documentation of the Docutain SDK

The documentation includes everything you need to know to integrate the Docutain SDK into your .NET MAUI application. If you prefer sample projects over documentation, check out our Docutain SDK .NET MAUI sample app on Github to get a quick start on how to scan documents.

Changelog

All changes included in each version can be found here: Changelog

License and Support

The Docutain SDK is a commercial product and requires a paid license for production use. In order to get a trial license, please visit our website via https://sdk.docutain.com/TrialLicense to generate a trial license key..

If you need technical support of any kind, please contact us via support.sdk@Docutain.com.

Product Compatible and additional computed target framework versions.
.NET net9.0-android35.0 is compatible.  net9.0-ios16.1 is compatible.  net10.0-android was computed.  net10.0-ios was computed. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
2.1.0 112 10/8/2025
2.0.0 320 5/12/2025
1.3.3 367 2/22/2025
1.3.2 202 1/30/2025
1.3.1 229 1/11/2025
1.3.0 281 12/9/2024
1.2.2 1,904 4/18/2024
1.2.0 257 3/14/2024
1.1.0 224 2/13/2024
1.0.2 527 8/14/2023
1.0.0 371 7/5/2023