Logo : Id Capture Web

Id Capture Web

Organisation
Scandit
id-capture-web

Scandit ID Capture in web/browser projects (`@scandit/web-datacapture-id`) — scanning passports, driver's licenses, ID cards, residence permits, visas via MRZ, VIZ, PDF417 barcode, or mobile documents. Use for integration, accepted-document and scanner configuration, CapturedId result handling, rejection rules, AAMVA verification, overlay UI, and SDK version migration in TypeScript/JavaScript web apps.

Présentation

ÉditeurScandit
Dépôtskills
Nom de la compétenceid-capture-web
Étoiles
21
Forks
2
Fichiers inclus
2
LicenceApache-2.0
Liens
  • Instructions en Markdown

    Un fichier SKILL.md que le modèle charge à la demande : il ne consomme donc des tokens que lorsqu’une demande correspond réellement à la compétence.

  • Compatible avec tous les LLM

    Les compétences IA sont rédigées en Markdown et non sous forme de code propre à un fournisseur. Elles fonctionnent donc avec GPT, Claude, Gemini, Grok ou un modèle local.

  • Fichiers inclus : 2

    Des scripts, des gabarits et des références que le modèle peut consulter pendant son travail. Les fichiers sont en lecture seule et ne sont jamais exécutés.

  • Open source

    Publiée par Scandit sur GitHub. Consultez les sources avant de l’installer.

Installation

Installez la compétence IA Id Capture Web dans TypingMind pour l’utiliser avec n’importe quel LLM, ou ajoutez-la à un autre agent capable de lire SKILL.md.

1

Installer dans TypingMind

TypingMind installe une compétence directement depuis son dossier GitHub : l’application lit SKILL.md, regroupe les fichiers de ressources et enregistre le tout localement.

  1. Ouvrez l’application et accédez à Plugins → Compétences.
  2. Choisissez « Installer depuis GitHub ».
  3. Copiez l’URL ci-dessous, qui pointe vers le dossier de la compétence, puis collez-la et confirmez.
    https://github.com/Scandit/skills/tree/dist/skills/id-capture-web
  4. Activez la compétence dans chaque discussion où vous souhaitez pouvoir l’utiliser.
Plugins → Compétences → Ajouter une compétence → Via une URL GitHub, puis collez l’URL du dossier et appuyez sur Continuer.
2

Installer dans un autre agent

Tout agent capable de lire le format Agent Skills peut utiliser cette compétence : copiez le dossier dans le répertoire des compétences de cet agent.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/Scandit/skills.git /tmp/skills
mkdir -p .claude/skills
cp -r /tmp/skills/skills/id-capture-web .claude/skills/id-capture-web
Redémarrez Claude Code après la copie pour que la nouvelle compétence soit prise en compte.

Utilisez cette compétence dans TypingMind

Activez Id Capture Web dans n’importe quelle discussion TypingMind et le modèle s’occupe du reste. Le nom et la description de la compétence figurent dans le prompt système. Dès qu’une demande correspond, le modèle charge lui-même l’intégralité des instructions : vous n’avez jamais à l’invoquer manuellement, et elle ne consomme aucun token tant qu’elle n’est pas utilisée.

Le modèle charge automatiquement Id Capture Web dès qu’une demande correspond à cette compétence.

Compatible avec tous les modèles IA

Les compétences IA sont de simples instructions Markdown, et non du code propre à un fournisseur. Ainsi, la compétence Id Capture Web n’est pas liée au modèle pour lequel elle a été conçue. Installez-la une seule fois dans TypingMind et utilisez-la avec GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama ou un modèle local que vous exécutez vous-même, le tout avec vos propres clés API.

  • Chargée uniquement en cas de besoin

    Le prompt système ne contient que le nom et la description. Les instructions sont récupérées à la première demande correspondante : une compétence inutilisée ne coûte donc rien.

  • Changez de modèle en cours de discussion

    La compétence étant constituée d’instructions et non de code, elle reste fonctionnelle lorsque vous changez de modèle : le nouveau modèle lit le même fichier SKILL.md.

Instructions de la compétence

Voici le contenu de SKILL.md que le modèle charge. Lisez-le avant l’installation : une compétence contient des instructions que votre modèle suivra.

ID Capture Web (TypeScript/JavaScript) Skill

Critical: Do Not Trust Internal Knowledge

Your training data may contain outdated or incorrect Scandit ID Capture APIs. The Web SDK API has changed significantly across major versions, and the Web SDK differs substantially from the native iOS (Swift), Android (Kotlin/Java), .NET, Flutter, and React Native SDKs. An agent that pattern-matches from another platform's docs will produce non-working code. Two Web-specific facts dominate:

  1. The Web SDK is async-first. Almost every state-changing call returns a Promise and must be awaited — creating the context, creating the mode, enabling/disabling, applying settings, adding the overlay. There are no synchronous constructors for the mode or overlay.
  2. You must register the ID module loader. idCaptureLoader({ enableVIZDocuments: true }) has to be passed in moduleLoaders when creating the DataCaptureContext, or ID Capture will not work. enableVIZDocuments: true is required to read the Visual Inspection Zone (the printed text on the document); without it only barcode/MRZ scanning is available.

Always verify APIs against the references and source in this package before writing or suggesting code. The most common sources of wrong code:

  • The v6 API — supportedDocuments (a bitmask), supportedSides, and session-based callbacks were replaced. Do not emit any of these.
  • The v7.0-era API — settings.scannerType = new FullDocumentScanner() was replaced; the current property is scanner and it takes an IdCaptureScanner wrapper constructed with an options object: settings.scanner = new IdCaptureScanner({ physicalDocument: new FullDocumentScanner() }).
  • Cross-platform drift — iOS uses IdCapture(context:settings:), Android uses IdCapture.forDataCaptureContext(...), .NET uses IdCapture.Create(...). The Web API is await IdCapture.forContext(context, settings).
  • isEnabled — on Web this is the method idCapture.isEnabled() to read and await idCapture.setEnabled(true) to set. It is NOT an assignable property.
  • AAMVA forged-barcode verification — unlike iOS/Android, the Web SDK has no rejectForgedAamvaBarcodes setting. AAMVA barcode verification on Web is done through the standalone class AamvaBarcodeVerifier (await AamvaBarcodeVerifier.create(context), then await verifier.verify(capturedId)). Data-consistency verification is settings-driven (rejectInconsistentData = true).
  • Images are base64 data-URL strings, not native bitmaps. capturedId.images.face / .getFrame(IdSide.Front) / .getCroppedDocument(IdSide.Back) return string | null (a data:image/... URL), suitable for an <img> src. They are only populated when enabled via settings.setShouldPassImageTypeToResult(IdImageType.Face, true).

Forbidden APIs (commonly hallucinated — do NOT emit these)

Do NOT writeUse instead
new IdCapture(context, settings)await IdCapture.forContext(context, settings)
IdCapture.forDataCaptureContext(...) / IdCapture.Create(...)await IdCapture.forContext(context, settings)
idCapture.isEnabled = true / idCapture.enabled = trueawait idCapture.setEnabled(true) (read with idCapture.isEnabled())
settings.supportedDocuments = [...] / settings.supportedSides = ... (v6)settings.acceptedDocuments = [...] + settings.scanner = new IdCaptureScanner({...})
settings.scannerType = new FullDocumentScanner() (v7)settings.scanner = new IdCaptureScanner({ physicalDocument: new FullDocumentScanner() })
new IdCaptureScanner(new FullDocumentScanner()) (positional)new IdCaptureScanner({ physicalDocument: new FullDocumentScanner() }) (options object)
new IdCaptureOverlay(idCapture, view)await IdCaptureOverlay.withIdCaptureForView(idCapture, view)
settings.rejectForgedAamvaBarcodes = trueconst v = await AamvaBarcodeVerifier.create(context); await v.verify(capturedId)
capturedId.barcodeResultcapturedId.barcode
capturedId.images.croppedDocument(side) / capturedId.images.face() as a methodcapturedId.images.getCroppedDocument(IdSide.Front) / capturedId.images.face (a getter)
DataCaptureContext.initialize(licenseKey) (iOS) / forLicenseKey(...) syncawait DataCaptureContext.forLicenseKey(key, { moduleLoaders: [idCaptureLoader({...})] })
Creating the context without idCaptureLoader(...) in moduleLoadersalways include idCaptureLoader({ enableVIZDocuments: true })
SDCIdCapture / SDCCapturedId / any SDC-prefixed typeIdCapture / CapturedId (no prefix; import from @scandit/web-datacapture-id)
Camera.default / camera.switch(toDesiredState:)Camera.pickBestGuess() / await camera.switchToDesiredState(FrameSourceState.On)

Intent Routing

Based on the user's request, pick the right path before responding:

  • Hosted, drop-in ID scanning with no custom camera UI (e.g. "add ID/passport scanning to my website with as little code as possible", "use the hosted / pop-up ID scanner", "scan an ID without building the camera UI", or the project uses @scandit/web-id-bolt) → that is ID Bolt, a hosted wrapper around ID Capture, not the in-page ID Capture SDK. Hand off to the id-bolt skill.
  • Questions about other Scandit products or scanning modes (e.g. Barcode Capture, SparkScan, MatrixScan, Label Capture, or product selection) → hand off to the data-capture-sdk skill. Do not attempt to answer questions about other capture modes from memory.
  • Integrating ID Capture from scratch, configuring documents/scanner/rejection rules, reading results, customizing the overlay, or verification (e.g. "scan a passport in the browser", "reject expired IDs", "show the face image") → use the Product Guidance and Minimal integration shape below, verifying every API against the References.
  • A plain HTML page, no bundler, or loading the SDK from a CDN (e.g. "scan IDs on a static page", "use an import map") → read references/cdn.md for the import map, libraryLocation and the headers, then use the Minimal integration shape.
  • Migrating or upgrading an existing ID Capture integration (e.g. "upgrade from v6 to v7", "migrate my ID Capture to v8", "bump the Scandit Web SDK", "what changed between SDK versions") → read references/migration.md and follow the instructions there.

Product Guidance

  • Accept only the documents you actually need. Ask the user which document types and regions they expect. Documents not in acceptedDocuments are rejected with RejectionReason.NotAcceptedDocumentType.
  • Pick the scanner that matches the data you need. Ask whether they need both sides and all zones, a single zone only (barcode / MRZ / VIZ), or a mobile-presented ID — then choose FullDocumentScanner, SingleSideScanner(barcode, machineReadableZone, visualInspectionZone), or MobileDocumentScanner. SingleSideScanner takes positional booleans selecting which zone to read.
  • enableVIZDocuments. Reading the printed VIZ (and most full-document scanning) requires idCaptureLoader({ enableVIZDocuments: true }) and a license entitled for VIZ. If the license lacks VIZ entitlement, loading throws IdCaptureErrorCode.InvalidLicenseKeyForVIZProcessing. Barcode-only / MRZ-only flows can run without it.
  • Handle didRejectId, not just didCaptureId. Rejections (Timeout, NotAcceptedDocumentType, DocumentExpired, DocumentVoided, HolderUnderage, InconsistentData, SingleImageNotRecognized, …) are how the user learns why a scan didn't succeed. SingleImageNotRecognized is Web-specific (single-image-upload flows) and usually warrants an idCapture.reset().
  • Disable the mode while handling a result. The samples consistently await idCapture.setEnabled(false) at the top of didCaptureId/didRejectId, then re-enable when the user dismisses the result. Do the same.
  • Handle didFailWithError for recoverable failures. On IdCaptureErrorCode.RecoveredAfterFailure, inform the user and call idCapture.reset() so they start over from the front side.
  • Use the Localization API for overlay text. IdCaptureOverlay.setFrontSideTextHint(...) and friends are deprecated. Customize hints via Localization.getInstance().update({ "id.idCaptureOverlay.scanFrontSideHint": "..." }).
  • Defer non-ID-Capture questions. For Barcode Capture, SparkScan, MatrixScan, Label Capture, or product selection, hand off to the data-capture-sdk skill — this skill covers ID Capture only.

Minimal integration shape

Prerequisites: install @scandit/web-datacapture-core and @scandit/web-datacapture-id (same version) with the project's package manager, and serve the SDK engine files so libraryLocation resolves them (the samples copy them to library/engine/; self-hosted projects typically use sdc-lib). License keys — see Licence key below.

A page without a bundler follows references/cdn.md for loading the SDK.

When the SDK is loaded from a CDN, pin one exact version (for example @8.6.1) in every URL: the import map and libraryLocation. A floating @8 lets the JavaScript and the engine resolve to different releases, which breaks start-up.

This is the canonical structure shared by every sample under web/samples/02_ID_Scanning_Samples/. Use it as the skeleton; adjust documents/scanner/listeners to the task.

ts
import {
  Camera,
  CameraSwitchControl,
  DataCaptureContext,
  DataCaptureView,
  FrameSourceState,
} from "@scandit/web-datacapture-core";
import {
  IdCapture,
  IdCaptureSettings,
  IdCaptureScanner,
  IdCaptureOverlay,
  FullDocumentScanner,
  IdCard,
  Passport,
  DriverLicense,
  Region,
  IdImageType,
  RejectionReason,
  idCaptureLoader,
  type CapturedId,
} from "@scandit/web-datacapture-id";

const view = new DataCaptureView();
view.connectToElement(document.getElementById("data-capture-view")!);
view.showProgressBar();

const context = await DataCaptureContext.forLicenseKey(LICENSE_KEY, {
  libraryLocation: new URL("library/engine/", document.baseURI).toString(),
  moduleLoaders: [idCaptureLoader({ enableVIZDocuments: true })],
});
view.hideProgressBar();

const camera = Camera.pickBestGuess();
await camera.applySettings(IdCapture.recommendedCameraSettings);
await context.setFrameSource(camera);
await view.setContext(context);
view.addControl(new CameraSwitchControl());

const settings = new IdCaptureSettings();
settings.scanner = new IdCaptureScanner({ physicalDocument: new FullDocumentScanner() });
settings.acceptedDocuments = [new IdCard(Region.Any), new Passport(Region.Any), new DriverLicense(Region.Any)];
settings.setShouldPassImageTypeToResult(IdImageType.Face, true);

const idCapture = await IdCapture.forContext(context, settings);
idCapture.addListener({
  didCaptureId: async (capturedId: CapturedId) => {
    await idCapture.setEnabled(false);
    // read capturedId.fullName, capturedId.dateOfBirth, capturedId.images.face, ...
  },
  didRejectId: async (_capturedId: CapturedId, reason: RejectionReason) => {
    await idCapture.setEnabled(false);
    // surface a message based on `reason`
  },
});
await IdCaptureOverlay.withIdCaptureForView(idCapture, view);

await idCapture.setEnabled(false); // keep disabled until the camera is on
await camera.switchToDesiredState(FrameSourceState.On);
await idCapture.setEnabled(true);

API Usage Policy

Only use APIs that exist in this package (@scandit/web-datacapture-id) and the referenced documentation. Do not invent or guess method signatures, parameters, or property names. When unsure whether an API exists or how to call it, fetch the documentation before responding. Do not tell the user to check the docs themselves. After answering, include the relevant link so they can explore further. Never construct or guess documentation URLs — fetch the index page and follow links from there.

Licence key

Scanning needs a Scandit licence key. For this skill the licence product is sdk and the licence platform is webassembly.

Work through these in order — never block the user on MCP:

  1. The Scandit MCP server is connected — call ensure_scanner_setup with product sdk and platforms webassembly, 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.

  2. 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.

  3. 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.

References

TopicResource
Get Started (Web)Get Started (Web)
Advanced configurationAdvanced (Web)
Migration between major SDK versions6 → 7 · 7 → 8
Full API referenceID Capture API (Web)
Source of truth@scandit/web-datacapture-id package
SamplesTo be found on github

Sample → use-case map

  • IdCaptureSimpleSample — minimal full-document scan, accept IdCard/Passport/DriverLicense, show face image.
  • IdCaptureExtendedSample — switch between barcode / MRZ / VIZ via SingleSideScanner(barcode, mrz, viz); applySettings to change mode at runtime; localized loading text.
  • IdCaptureSettingsSample — exhaustive settings playground; the QA reference for every setting.
  • IdCaptureUSDLVerificationSample — rejectExpiredIds + rejectInconsistentData, plus standalone AamvaBarcodeVerifier.create(context) / verify(capturedId); DataConsistencyResult.frontReviewImage().
  • IdCaptureDriverOnboardingSample — two-sided flow with notifyOnSideCapture = true, capturedId.isCapturingComplete, SingleImageUploader fallback, IdSide image access.
  • IdCaptureShutterModeSample — IdCaptureTrigger.ButtonTap (tap-to-scan shutter), single-image upload, image review.

Available in this package but NOT covered by this skill

  • Cloud / free-form-text scanning (VisaLetter, SingleSideScanner freeFormText, allowCloudScanning) — partly internal; verify against source and docs before using. Currently not used except by some customers doing a pilot project.
  • Internal frame-signal callbacks on Listener (didEncounterCaptureIssue, didChangeViewfinderHint, didUpdateIdOutline) — marked @internal; do not use in customer code.

Fichiers inclus

Le modèle lit ces fichiers à la demande lorsque la compétence est chargée. Ils sont accessibles en lecture et ne sont jamais exécutés.

Foire aux questions

À quoi sert la compétence IA Id Capture Web ?

Scandit ID Capture in web/browser projects (`@scandit/web-datacapture-id`) — scanning passports, driver's licenses, ID cards, residence permits, visas via MRZ, VIZ, PDF417 barcode, or mobile documents. Use for integration, accepted-document and scanner configuration, CapturedId result handling, rejection rules, AAMVA verification, overlay UI, and SDK version migration in TypeScript/JavaScript web apps.

Pourquoi utiliser Id Capture Web sur TypingMind ?

Parce que vous l’installez une seule fois pour l’utiliser avec n’importe quel modèle. Id Capture Web se compose de simples instructions en Markdown plutôt que de code propre à un fournisseur. La même compétence fonctionne donc avec GPT-5, Claude, Gemini, Grok ou un modèle local, et vous pouvez changer de modèle en cours de discussion sans perturber son fonctionnement. TypingMind utilise vos propres clés API : vous payez donc directement les fournisseurs plutôt qu’un abonnement par siège, et vos compétences et discussions restent dans votre propre espace de stockage.

Comment installer Id Capture Web dans TypingMind ?

Dans TypingMind, ouvrez Plugins → Compétences → Installer depuis GitHub et collez https://github.com/Scandit/skills/tree/dist/skills/id-capture-web. TypingMind lit le fichier SKILL.md, regroupe les fichiers associés et installe le tout sous forme de compétence que vous pouvez activer pour chaque discussion.

Quels modèles d’IA peuvent utiliser Id Capture Web ?

N’importe quel modèle que vous connectez dans TypingMind. Les compétences IA sont de simples instructions en Markdown, et non du code propre à un fournisseur. GPT, Claude, Gemini, Grok et les modèles locaux peuvent donc tous charger cette compétence lorsqu’une demande lui correspond.

Combien de modèles d’IA puis-je utiliser avec Id Capture Web ?

Autant que vous le souhaitez. Vous pouvez utiliser Id Capture Web avec tout modèle qui prend en charge les compétences : GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama et bien d’autres, le tout dans TypingMind avec vos propres clés API.

La compétence IA Id Capture Web est-elle gratuite ?

Oui. Cette compétence est publiée sur GitHub par Scandit sous licence Apache-2.0. Vous ne payez que votre propre fournisseur d’IA pour les tokens utilisés.

Que sont les compétences IA ?

Une compétence IA est un ensemble d’instructions réutilisables qui apprend à un modèle d’IA à accomplir une tâche précise. Elle suit le format ouvert Agent Skills : un fichier SKILL.md contenant un nom et une description, ainsi que les éventuels scripts, gabarits ou fichiers de référence dont le modèle peut avoir besoin. Le modèle ne lit les instructions que lorsque votre demande correspond à la compétence. Une compétence installée ne coûte donc rien tant qu’elle n’est pas utilisée.

En quoi les compétences IA diffèrent-elles des plugins ou des serveurs MCP ?

Un plugin ou un serveur MCP fournit au modèle de nouveaux outils à appeler : du code qui s’exécute quelque part et renvoie un résultat. Une compétence IA lui apporte plutôt des connaissances et une méthode : comment aborder une tâche, quelles étapes suivre et à quoi ressemble un bon résultat. Les compétences sont de simples instructions en Markdown. Elles ne nécessitent donc ni serveur, ni clé API, ni environnement d’exécution, et fonctionnent avec n’importe quel modèle.

Tout voir

Créez votre propre espace de travail IA dès maintenant

Abonnez-vous à notre newsletter pour être informé des nouvelles fonctionnalités et des prochains cadeaux à gagner 👇