/scandit-sdk:matrixscan-ar-net-mauifrom scandit-sdk
Integrates MatrixScan AR (barcode AR) in .NET MAUI projects using the Scandit SDK. Covers XAML BarcodeArView, NuGet setup, lifecycle, highlights, annotations, and troubleshooting.
Ships in scandit-sdk. Installing the plugin adds it to Claude Code.
What the skill costs in Claude's context, stage by stage
Name and description: Claude knows it exists.
SKILL.md joins the conversation and stays.
Read when SKILL.md points to them.
Your training data may contain outdated or incorrect Scandit SDK APIs. The BarcodeAr API is relatively new (first shipped on dotnet.android / dotnet.ios in 7.2), and the MAUI binding is a thin layer on top that turns the per-TFM BarcodeArView into a XAML control — it changes the class identity, the namespace, the assembly name, the constructor surface, the lifecycle hooks, and the way controls are wired. Patterns from the standalone matrixscan-ar-net-android / matrixscan-ar-net-ios skills do not always apply unchanged here.
Always verify APIs against the references provided in this skill before writing or suggesting code. Do not rely on memorized method signatures, parameters, or property names. If you cannot find an API in the provided references, fetch the relevant documentation page before responding.
MAUI-specific gotchas worth flagging:
<UseMaui>true</UseMaui>. For non-MAUI .NET projects, use matrixscan-ar-net-android (for net*-android) or matrixscan-ar-net-ios (for net*-ios) instead. The MAUI BarcodeArView is a completely different class (Scandit.DataCapture.Barcode.Ar.UI.Maui.BarcodeArView deriving from Microsoft.Maui.Controls.View) with bindable properties and no Create(parentView, ...) factory — patterns from the per-TFM skills will not compile here..csproj. WebFetch https://www.nuget.org/packages/Scandit.DataCapture.Barcode.Maui/ and read the latest stable version off the page (skip -beta.* / -preview.* / -rc.* suffixes). Do not guess — versions from training data are stale and dotnet restore will fail with NU1103 if the pinned version isn't published. Use the same version for all four packages.SupportedOSPlatformVersion must be ≥ 24. The MAUI template defaults to 21, which is below Scandit's Android AAR minimum and fails the build with uses-sdk:minSdkVersion 21 cannot be smaller than version 24 declared in library. Bump the .csproj value to 24.0 as part of the integration. iOS minimum is 15.0 (matches the MAUI template default).Scandit.DataCapture.Core, Scandit.DataCapture.Core.Maui, Scandit.DataCapture.Barcode, Scandit.DataCapture.Barcode.Maui. All four are needed — Core/Barcode provide the platform bindings, Core.Maui/Barcode.Maui provide the MAUI builder extensions and handlers.MauiProgram.cs builder chain for BarcodeAr is .UseScanditCore().UseScanditBarcode(configure => configure.AddBarcodeArView()). UseScanditCore() takes no configure lambda — BarcodeAr has its own dedicated MAUI control (<scandit:BarcodeArView>), it does not use the generic <scandit:DataCaptureView>. UseScanditBarcode(c => c.AddBarcodeArView()) must include the inner configure with AddBarcodeArView() to register the MAUI handler. This is the SparkScan shape, not the BarcodeBatch shape (the BarcodeBatch MAUI integration uses .UseScanditCore(c => c.AddDataCaptureView()).UseScanditBarcode() because BarcodeBatch has no dedicated MAUI view). Do not cross-pollinate the two patterns.<scandit:BarcodeArView> is a MAUI View (XAML control), not IDisposable. There is no BarcodeArView.Create(parentView, barcodeAr, dataCaptureContext, settings, cameraSettings) factory in MAUI — that signature lives in the per-TFM Scandit.DataCapture.Barcode.Ar.UI namespace. The MAUI control lives in Scandit.DataCapture.Barcode.Ar.UI.Maui and is declared in XAML; wire it via bindable properties (DataCaptureContext, BarcodeAr, BarcodeArViewSettings, optional CameraSettings, HighlightProvider, AnnotationProvider). Writing BarcodeArView.Create(...) in MAUI code-behind is a compile error.BarcodeArView is clr-namespace:Scandit.DataCapture.Barcode.Ar.UI.Maui;assembly=ScanditBarcodeCaptureMaui. Note assembly=ScanditBarcodeCaptureMaui — no dots in the assembly name, even though the NuGet package id (Scandit.DataCapture.Barcode.Maui) has dots. Easy to typo by copy-pasting the package id.DataCaptureContext, BarcodeAr, and BarcodeArViewSettings are all mandatory bindable properties on <scandit:BarcodeArView>. Without all three bound, the preview renders as a black/blank screen at runtime even though the code-behind compiles and dotnet build is clean. Setting x:Name="barcodeArView" is not enough; the bindable properties are what wire the mode and context to the control. The page's BindingContext (view model or this) must expose DataCaptureContext, BarcodeAr, and BarcodeArViewSettings properties of the matching types.BarcodeArView bindable properties for context / mode / settings / camera are BindingMode.OneTime. Set them once via XAML or via the constructor overloads (new BarcodeArView(context, barcodeAr, settings) / new BarcodeArView(context, barcodeAr, settings, cameraSettings)). Attempting to change them after initial binding has no effect — the underlying platform view is constructed from the initial values and not reconstructed.ScanditCaptureCore.Initialize() / ScanditBarcodeCapture.Initialize() in MainApplication.OnCreate or AppDelegate.FinishedLaunching. The MAUI builder extensions (UseScanditCore / UseScanditBarcode) call those initializers themselves. This is different from the non-MAUI matrixscan-ar-net-android / matrixscan-ar-net-ios skills, which require manual initialization for SDK 8.0+. In a MAUI app, the MainApplication / AppDelegate only need to forward to MauiProgram.CreateMauiApp() — leave them as the MAUI template generates them.OnAppearing / OnDisappearing — and you must forward both OnResume/OnPause and Start/Stop into the BarcodeArView. The canonical pattern is OnAppearing → barcodeArView.OnResume(); barcodeArView.Start(); and OnDisappearing → barcodeArView.Stop(); barcodeArView.OnPause();. The OnResume() / OnPause() methods are gated by #if __ANDROID__ inside the MAUI handler's command-mapper — they are no-ops on iOS by design, so the same code is safe on both platforms. Conversely, Start() / Stop() are mandatory on iOS for the camera lifecycle. Calling only one pair would silently break one of the two platforms.BarcodeArView queues commands until the handler attaches. The MAUI control has an internal ConcurrentQueue<PendingCommand> and a volatile bool isHandlerReady flag — calling Start(), Stop(), Pause(), Reset(), OnResume(), or OnPause() before the handler has connected is safe: the command is queued and replayed on HandlerReady. This is the opposite of the per-TFM skills, where calling Start() before the view is in the resumed state is a no-op. There is a public HandlerReady event you can subscribe to if you need to wait for handler readiness explicitly, but for normal OnAppearing-driven flows you do not.ShouldShowMacroModeControl and MacroModeControlPosition are NOT exposed on the cross-platform MAUI BarcodeArView. They exist on the iOS native BarcodeArViewMauiWrapper (passthrough to the underlying UI.BarcodeArView), but the MAUI control class does not surface them as bindable properties. Do not suggest them in MAUI XAML or MAUI code — there is no <scandit:BarcodeArView ShouldShowMacroModeControl="True" /> and no barcodeArView.ShouldShowMacroModeControl = true getter/setter visible from cross-platform code. If a user needs the macro-mode toggle on iOS, they need a per-platform helper (use a partial class or a custom handler mapping) — and even then, the matrixscan-ar-net-ios skill is the better fit if macro is a hard requirement.IBarcodeArListener has only one method: OnSessionUpdated(BarcodeAr, BarcodeArSession, IFrameData). There are no OnObservationStarted / OnObservationStopped callbacks like the Kotlin/Swift BarcodeArListener interface has. Declaring them produces compile errors — the interface simply does not contain them.barcodeAr.SessionUpdated += handler) over the listener interface in idiomatic C#. The handler receives BarcodeArEventArgs with BarcodeAr, Session, and FrameData. AddListener(IBarcodeArListener) still works for parity with other platforms.OnSessionUpdated / SessionUpdated runs on a background recognition thread on both platforms. Dispatch any UI update via MainThread.BeginInvokeOnMainThread(() => …) or MainThread.InvokeOnMainThreadAsync(...) — not RunOnUiThread (Android-specific) and not DispatchQueue.MainQueue.DispatchAsync (iOS-specific).IBarcodeArHighlightProvider.HighlightForBarcodeAsync(Barcode) returns Task<IBarcodeArHighlight?> and IBarcodeArAnnotationProvider.AnnotationForBarcodeAsync(Barcode) returns Task<IBarcodeArAnnotation?>. Do not look for a Callback parameter or a callback.OnData(...) method — they don't exist in the .NET binding. Return Task.FromResult<IBarcodeArHighlight?>(null) (or null from an async method) to suppress the highlight/annotation for a given barcode.BindingMode.TwoWay and can be assigned at any time (unlike context/mode/settings which are OneTime). You can assign them in XAML via {Binding HighlightProvider} on the view model, or imperatively in code-behind via this.BarcodeArView.HighlightProvider = …. Both patterns are supported.Barcode — no Context / UIView argument. Use new BarcodeArRectangleHighlight(barcode), new BarcodeArCircleHighlight(barcode, BarcodeArCircleHighlightPreset.Dot), new BarcodeArInfoAnnotation(barcode), new BarcodeArStatusIconAnnotation(barcode), new BarcodeArPopoverAnnotation(barcode, buttons). Passing a Context / UIViewController is a compile error.Symbology.Ean13Upca, Symbology.Ean8, Symbology.Code128, Symbology.Code39, Symbology.Qr, Symbology.DataMatrix, Symbology.InterleavedTwoOfFive. They are not the Kotlin underscore style (EAN13_UPCA) and not Swift's camelCase (.ean13UPCA).BarcodeArSettings does not expose an Enabled toggle — BarcodeAr itself has no Enabled property either. To pause/resume tracking, use barcodeArView.Pause() / barcodeArView.Start().BarcodeArViewSettings is minimal in .NET. Only three properties: SoundEnabled (default true), HapticEnabled (default true), DefaultCameraPosition (default WorldFacing). Do not invent properties like TriggerButtonCollapseTimeout, InactiveStateTimeout, ToastSettings, or DefaultMiniPreviewSize — those are SparkScan, not BarcodeAr.BarcodeArFeedback lives in Scandit.DataCapture.Barcode.Ar.Feedback and has two Core.Common.Feedback.Feedback properties: Scanned and Tapped. The empty constructor new BarcodeArFeedback() produces a feedback object with both events silent — assigning it to barcodeAr.Feedback disables the default beep/vibration. To restore defaults, use the static BarcodeArFeedback.DefaultFeedback. (Note: it's a static property in .NET, not the Kotlin BarcodeArFeedback.defaultFeedback() method or the Swift BarcodeArFeedback.default() method.)HighlightForBarcodeTapped event on the MAUI BarcodeArView (EventHandler<HighlightForBarcodeTappedEventArgs>). There is no UiListener / UIDelegate property on the .NET BarcodeArView — the native BarcodeArViewUiListener / BarcodeArViewUIDelegate are surfaced as a C# event instead. Event args expose BarcodeAr, Barcode, and Highlight. The event subscription is gated by #if __ANDROID__ || __IOS__ inside the MAUI control — on unsupported TFMs the add/remove accessors are silent no-ops, so subscribing from cross-platform code is always safe to compile.barcodeAr.Feedback is a property (get/set); ApplySettingsAsync(BarcodeArSettings) returns a Task. BarcodeAr.RecommendedCameraSettings is a static property, not a method (the Kotlin SDK exposes BarcodeAr.createRecommendedCameraSettings() — in .NET it's a getter).BarcodeArFilter / SetBarcodeFilter in the .NET API tree. The Kotlin/iOS setBarcodeFilter(...) method (added in 8.1) is not surfaced on dotnet.android / dotnet.ios (and therefore not on MAUI either) at present. Do not attempt to use it.await Permissions.CheckStatusAsync<Permissions.Camera>() and await Permissions.RequestAsync<Permissions.Camera>(). MAUI's permission system takes care of Permissions.Camera on both platforms — but on iOS the project still needs the NSCameraUsageDescription string set in Platforms/iOS/Info.plist. On Android, MAUI adds android.permission.CAMERA automatically when Permissions.Camera is requested at build time (it can also be added to Platforms/Android/AndroidManifest.xml explicitly). There is no CameraPermissionActivity helper to copy in MAUI — that's a non-MAUI .NET Android pattern.Based on the user's request, load the appropriate reference file before responding:
Feedback objects (vibration + sound) on BarcodeArFeedback, and per-tap-on-annotation routing (e.g. "show a popover with three action buttons when the user taps a barcode in MAUI", "handle a tap on the right icon of my info annotation in MAUI", "play a custom sound when a barcode is tapped in MAUI", "I need the popover annotation listener in MAUI") → read references/advanced.md after integration.md.Only use APIs that are explicitly documented in the Scandit references below. Do not invent or guess method signatures, parameters, or property names. If unsure whether an API exists or how it is called — or if a compile error occurs — fetch the relevant reference page before responding. Do not tell the user to check the docs themselves. After answering, always include the relevant link so the user can explore further.
Never construct or guess documentation URLs. When you need a specific class or property's API page:
URL structures can vary (e.g. api/ui/ subdirectory) and guessing will lead to 404s.
Scanning needs a Scandit licence key. For this skill the licence product is native and the licence platforms are ios and android.
Work through these in order — never block the user on MCP:
The Scandit MCP server is connected — call ensure_scanner_setup with product native and platforms ios and android, app_identifier (the app's bundle or application id; for web, its production domain, never localhost) and env_var SCANDIT_LICENSE_KEY. Do not run the command it returns. Then call get_license_key with the key's id, from that result or from list_license_keys; if list_license_keys shows the key is not a trial, ask the user before fetching it. Show at most a masked preview in chat; never print a full key.
It is not connected — tell the user once that they can connect the remote Scandit MCP server, https://ssl.scandit.com/mcp, in their MCP client, then continue from step 1. Do not edit MCP client configuration yourself.
Authentication is browser-based, so it is not supported headless or in CI. The server provisions trial keys only; it never creates, revokes, or modifies production licences.
The user declines, or has no MCP client — they generate a key themselves at https://ssl.scandit.com (no account yet: https://ssl.scandit.com/dashboard/sign-up?p=test) and paste it in.
Then put the key into the code: write it into the licence-key call in place of the placeholder — the key get_license_key returned, or the one the user pastes or gives you — still showing only a masked preview in chat. Do not search the project, its files or the environment for a key.
Direct users to the right resource based on their question:
| Topic | Resource |
|---|---|
| Get Started (Android target) | Get Started (.NET for Android) |
| Get Started (iOS target) | Get Started (.NET for iOS) |
| Advanced topics (custom highlights, custom annotations, tap interactions, popovers, filter) | Android Advanced Configurations · iOS Advanced Configurations |
| Migration between major SDK versions | Android: 7 → 8 · iOS: 7 → 8 |
| Full API reference | BarcodeAr API (.NET Android) · BarcodeAr API (.NET iOS) |
Scandit publishes the .NET API reference per underlying TFM (
dotnet.androidanddotnet.ios). For MAUI projects, both pages apply — the cross-platformBarcodeAr/BarcodeArSettings/ provider / highlight / annotation surface is identical between them, but platform-specific notes are documented on the per-TFM page. The MAUI-specific surface (theScandit.DataCapture.Barcode.Ar.UI.Maui.BarcodeArViewXAML control, theUseScanditBarcode(c => c.AddBarcodeArView())builder extension, and theOnAppearing/OnDisappearinglifecycle hooks) is not in the per-TFM API reference — it is covered exclusively in this skill's references/integration.md.
Read the "API surface this skill covers" section at the end of references/integration.md before writing or reviewing code. It lists every class and member this skill covers, the APIs documented for other platforms that do not exist here, and the binding differences between platforms. Do not emit an API that is not in that section or in the official API reference.
What SKILL.md sets; muted values are Claude Code's defaults
Three short reads, in order
barcode-scanning, augmented-reality, scandit-sdk, xaml, dotnet-maui
npx claudepluginhub scandit/skills --plugin scandit-sdk87 skills in this plugin
/barcode-capture-androidScandit Barcode Capture (`BarcodeCapture`) in native Android (Kotlin/Java) projects — the low-level, full-control single-barcode scanning mode (BarcodeCapture + DataCaptureView + overlay), without the pre-built SparkScan UI. Use for integration, symbology and scan settings, result handling, overlay customization, SDK version migration (v6→v7→v8), replacing third-party scanners (ZXing, ML Kit), or troubleshooting./barcode-capture-capacitorCapacitor — Scandit Barcode Capture (`BarcodeCapture`) in Capacitor (Ionic) hybrid apps via the Scandit Capacitor plugins (`ScanditCaptureCorePlugin`), the low-level, full-control single-barcode scanning mode (BarcodeCapture + DataCaptureView + BarcodeCaptureOverlay) without the pre-built SparkScan UI, not the browser-only web SDK. Use for integration, symbology settings, result handling, viewfinder and feedback customization, SDK version migration, replacing a third-party scanner (@capacitor-mlkit/barcode-scanning), or troubleshooting./barcode-capture-cordovaCordova — Scandit Barcode Capture (`BarcodeCapture`) in Apache Cordova hybrid apps via the `scandit-cordova-datacapture-*` plugins (global `window.Scandit`), the low-level, full-control single-barcode scanning mode (BarcodeCapture + DataCaptureView + BarcodeCaptureOverlay) without the pre-built SparkScan UI, not the browser-only web SDK. Use for integration, scan settings, result handling, overlay wiring, SDK version migration, replacing a third-party scanner (phonegap-plugin-barcodescanner), or troubleshooting.Other plugins' skills for the same job