Captured ID

Defined in framework ScanditIdCapture

CapturedId
open class CapturedId : NSObject

Added in version 6.6.0

This class represents the result of a document scan. It provides commonly present information, such as the holder’s name and date of birth, directly accessible at the top level. Additional document-specific details can be accessed through properties representing different zones of the document, such as the barcode, machine-readable zone (MRZ), and visual inspection zone (VIZ).

Note that not all properties are relevant to every document type. If a property is not applicable or the corresponding data could not be read, it will be set to null.

init
convenience init(jsonString JSONString: String)

Added in version 6.12.0

Creates a captured id from the passed JSON string.

firstName
open var firstName: String? { get }

Added in version 6.6.0

The first name of the document holder. Separated by spaces if more than one name is present. Characters can be all uppercase for document types which don’t capitalize names (for example names encoded in ICAO Machine Readable Zones).

lastName
open var lastName: String? { get }

Added in version 6.6.0

The last name of the document holder. Separated by spaces if more than one name is present. Characters can be all uppercase for document types which don’t capitalize names (for example names encoded in ICAO Machine Readable Zones).

secondaryLastName
open var secondaryLastName: String? { get }

Added in version 6.24.0

Optional secondary last name for document holders of French passports. This field holds the common name, known as “nom d’usage” when it is specified on the passport.

fullName
open var fullName: String { get }

Added in version 6.6.0

The full name of the document holder. Characters can be all uppercase for document types which don’t capitalize names (for example names encoded in ICAO Machine Readable Zones).

sexType
open var sexType: Sex { get }

Added in version 7.1.0

Deprecated since version 8.0: This property will be replaced in SDK version 8.0 with a single sex property that returns an optional Sex.

The sex of the document holder.

sex
open var sex: String? { get }

Added in version 6.6.0

Deprecated since version 8.0: This property will be replaced in SDK version 8.0 with a single sex property that returns an optional Sex.

The description of the document holder’s sex.

dateOfBirth
open var dateOfBirth: DateResult? { get }

Added in version 6.6.0

The date of birth of the document holder. If the document doesn’t provide two first digits of the year then the date of birth is always set to be earlier than or equal to the scan date. For example if the year of scanning is 2021 and the document returns that the year of birth is 14 then the returned year is set to 2014. However if the document returns that the year of birth is 24 then the returned year is set to 1924.

age
open var age: NSNumber? { get }

Added in version 6.16.0

The age of the document holder. Calculated as the difference in full years between the birth date and the current local date. If null is returned it means that the full birth date is not available. The returned value depends on the device date. The same document may result in different values for devices with different dates (e.g. in different time zones, or with a date set manually by the user).

nationality
open var nationality: String? { get }

Added in version 6.6.0

The nationality of the document holder represented by a three-letter code (Alpha-3 codes specified in ISO 3166-1).

address
open var address: String? { get }

Added in version 6.6.0

The address of the document holder.

usRealIdStatus
open var usRealIdStatus: UsRealIdStatus { get }

Added in version 6.28.0

Indicates whether the document is REAL ID compliant.

document
open var document: IdCaptureDocument? { get }

Added in version 7.0.0

The document type.

issuingCountryISO
open var issuingCountryISO: String? { get }

Added in version 6.6.0

The ISO (Alpha-3 code) abbreviation of the issuing country of the document.

issuingCountry
open var issuingCountry: IdCaptureRegion { get }

Added in version 7.0.0

Issuing country of the document.

documentNumber
open var documentNumber: String? { get }

Added in version 6.6.0

The document number.

If IdCaptureSettings.anonymizationMode is enabled for the field results, the returned value might be null for certain documents.

documentAdditionalNumber
open var documentAdditionalNumber: String? { get }

Added in version 6.19.0

If IdCaptureSettings.anonymizationMode is enabled for the field results, the returned value might be null for certain documents.

If IdCaptureSettings.anonymizationMode is enabled for the field results, the returned value might be null for certain documents.

dateOfExpiry
open var dateOfExpiry: DateResult? { get }

Added in version 6.6.0

The date of expiry of the document. Returning null with isExpired = false indicates that the document never expires.

isExpired
open var isExpired: NSNumber? { get }

Added in version 6.16.0

Whether this document is expired. Calculated by comparing the document’s expiration date with the current local date. When converted to boolean returns true if the document is expired and false when either not expired, or never expires. null is returned if the value of this property could not be determined - for example if the date of expiry is not present, or if the date of expiry couldn’t be captured. Please note that the system time is used for computation of this field so users of the device are capable of changing the result of the field by changing the system time.

dateOfIssue
open var dateOfIssue: DateResult? { get }

Added in version 6.6.0

The date of issue of the document. Please note that some documents may specify the exact date of issue, while other the month and the year only.

barcode
open var barcode: BarcodeResult? { get }

Added in version 7.0.0

The additional information extracted from a barcode on a document.

mobileDocumentResult
open var mobileDocumentResult: MobileDocumentResult? { get }

Added in version 7.5.0

The additional information extracted from a mobile identity document.

mrzResult
open var mrzResult: MrzResult? { get }

Added in version 6.6.0

The additional information extracted from the Machine Readable Zone (MRZ) of a Machine Readable Travel Document (MRTD).

vizResult
open var vizResult: VizResult? { get }

Added in version 6.6.0

The additional information extracted from a documents or its part intended to be read by humans (for example Visual Inspection Zone (VIZ) of a Machine-Readable Travel Document (MRTD)).

images
open var images: IdImages { get }

Added in version 7.0.0

The images extracted from a document.

isIdCard
open func isIdCard() -> Bool

Added in version 7.0.0

Indicates whether the document is of type IdCard.

isDriverLicense
open func isDriverLicense() -> Bool

Added in version 7.0.0

Indicates whether the document is of type DriverLicense.

isPassport
open func isPassport() -> Bool

Added in version 7.0.0

Indicates whether the document is of type Passport.

isVisaIcao
open func isVisaIcao() -> Bool

Added in version 7.0.0

Indicates whether the document is of type VisaIcao.

isResidencePermit
open func isResidencePermit() -> Bool

Added in version 7.0.0

Indicates whether the document is of type ResidencePermit.

isHealthInsuranceCard
open func isHealthInsuranceCard() -> Bool

Added in version 7.0.0

Indicates whether the document is of type HealthInsuranceCard.

isRegionSpecific
open func isRegionSpecific(_ subtype: RegionSpecificSubtype) -> Bool

Added in version 7.0.0

Indicates whether the document is of type RegionSpecificSubtype.

verificationResult
open var verificationResult: VerificationResult { get }

Added in version 7.1.0

Results of verifications automatically performed when IdCaptureSettings.rejectInconsistentData or IdCaptureSettings.rejectForgedAamvaBarcodes are enabled.

jsonString
open var jsonString: String { get }

Added in version 6.6.0

Returns the JSON representation of the captured id.

jsonStringWithoutImages
open var jsonStringWithoutImages: String { get }

Added in version 7.5.1

Returns the JSON representation of the captured ID without embedding image data. This variant avoids image compression and serialization, making it significantly more performant when image data is not required.