Skip to content

[MS-1383] Non-credential fields (name, dob, etc.) can now be returned in the MFID#1656

Merged
alexandr-simprints merged 10 commits into
mainfrom
MS-1383-mfid-expand-result-set-returned-by-ocr
May 7, 2026
Merged

[MS-1383] Non-credential fields (name, dob, etc.) can now be returned in the MFID#1656
alexandr-simprints merged 10 commits into
mainfrom
MS-1383-mfid-expand-result-set-returned-by-ocr

Conversation

@alexandr-simprints
Copy link
Copy Markdown
Contributor

@alexandr-simprints alexandr-simprints commented May 6, 2026

JIRA ticket
Will be released in: 2026.2.0

Notable changes

The majority of the changes is related to refactoring of ScannedCredential usage in favor of ExternalCredentialSearchResult. See the details below

1. Non-credential fields can now be scanned

This requires isCapturingAllFields flag to be set to true in MultiFactorIdConfiguration for the specific document type. We haven't agreed on the specific card fields yet, so currently there are only two options: capture everything or nothing. The credential capture is not affected by that flag.

  • If enabled, the OCR reader will try to find the values for the labels printed on cards. See GhanaNhisCardOcrReaderUseCase and GhanaIdCardOcrReaderUseCase for examples.
  • The return type is updated in LibSimprintsResponseMapper. If enabled, the response can look like this:
"scannedCredential" : {
  "NHISCard": "12345678",
  "documentFields": {
    "name": "Name",
    "dateOfBirth": "01/01/2000",
    "dateOfIssue": "12/06/2028"
  }
}

2. OCR result set expanded into a model.

The OCR scan results are now structured as an MfidDocument sealed class (GhanaNhisCard, GhanaIdCard, GhanaQrCode), with each carrying a credential + document-specific non-credential fields (name, date of birth, nationality, etc.).

3. ScannedCredential is renamed to ScannedCredentialResult

This helps to better represent ScannedCredentialResult as a part of the step result.

4. ExternalCredentialSearchResult replaces ScannedCredential across the flow.

This allows downstream steps to receive a complete data of the credential scan, search and its matches. ExternalCredentialSearchResult carries:

  • ScannedCredentialResult, that contains the entire MfidDocument with all OCR-extracted fields
  • confirmedCredential: what the user actually confirmed as correct after scanning
  • matchResults: biometric matches against credentials linked to credential (if any)

This way the entire outcome of the MFID flow is accessible from a single object through the orchestrator steps cache.

Additional work checklist

  • Effect on other features and security has been considered
  • Design document marked as "In development" (if applicable)
  • External (Gitbook) and internal (Confluence) Documentation is up to date (or ticket created)
  • Test cases in Testiny are up to date (or ticket created)
  • Other teams notified about the changes (if applicable)

@alexandr-simprints alexandr-simprints marked this pull request as ready for review May 7, 2026 07:12
@alexandr-simprints alexandr-simprints requested review from BurningAXE, alex-vt, Copilot and luhmirin-s and removed request for Copilot May 7, 2026 07:24
Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 100 out of 100 changed files in this pull request and generated 7 comments.

…detected values of given length. This should not happen normally, and was caused by a racing condition
…el, where a new frame from a camera might start processing before the finish is processed by fragment
@sonarqubecloud
Copy link
Copy Markdown

sonarqubecloud Bot commented May 7, 2026

@alexandr-simprints alexandr-simprints merged commit 5f774a3 into main May 7, 2026
14 checks passed
@alexandr-simprints alexandr-simprints deleted the MS-1383-mfid-expand-result-set-returned-by-ocr branch May 7, 2026 15:37
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants