Using the SDK – GBG IDscan Documentation

Using the SDK

Import MJCS SDK into the project

  • Inside the provided package, there’s a folder called SDK. You would then see 3 folders that include MJCS.framework
    • Release-iphoneos: includes only iphone architectures
    • Release-iphonesimulator: includes only simulator architectures
    • Release-iphoneuniversal: includes all of the above. Please be aware that Apple does not allow submitting simulator architectures to the AppStore, hence they should be stripped before the submission.
  • Depending on your needs, select the right SDK and copy it into your project directory.
  • Import MJCS.framework into your Xcode project.
  • Make sure that it’s being Embedded & Signed under your target settings:

Import additional GBG IDscan dependencies

  • Some additional dependencies are required to be added to your project for MJCS to be able to work, for example ReadID.framework, which is responsible for accessing the Biometric Chip.
  • Inside the provided package, there’s a folder called Dependencies. Copy all of these dependencies into your project folder.
  • Import them into your Xcode project
  • Make sure that they are all Embedded & Signed under your target settings

Import open-source 3rd party dependencies

  • MJCS requires some 3rd party dependencies in order to perform certain operations.
  • Inside the provided package, there’s a file called Cartfile. It contains the dependencies we may require and minimum versions.
  • Cartfile adheres to Carthage dependency manager, hence you could import these into your own Cartfile. Alternatively, you could either download binaries from github repositories manually and import them into the project or use your own dependency managers, such as Cocoapods.

Complete dependency list

Please find a table below of the dependencies, that MJCS is using:

NameRequired?Used by componentLocation
AFNetworkingYESMJCShttps://github.com/AFNetworking/AFNetworking
FLAnimatedImageNOIDSLivenesshttps://github.com/Flipboard/FLAnimatedImage
IDSLivenessNOMJCSInside SDK folder, comes as a separate package
LottieYESMJCShttps://github.com/airbnb/lottie-ios
MJCSYES Inside SDK folder
ReadID, ReadID_UINOMJCSInside Dependencies folder
ZipZapYESMJCShttps://github.com/pixelglow/ZipZap

You may notice, that some dependencies are not required. That means, that if you don’t use certain functionalities, you can save size and do not embed them into your app. For example, if you don’t need Liveness step during your on-boarding journey, you can exclude IDSLiveness and FLAnimatedImage from your app build. To do so:

  • Go to your target settings
  • Select the dependency you don’t want to include
  • Select Do not Embed option from the dropdown list

Info: If you try access certain functionalities during the runtime and dependency was not included – it will likely result in a crash

Choosing the right Document Profile

As MJCS is using Machine Learning to classify documents on the device itself, we require those models to be present on the device during the runtime and it comes with a price of size. In order to save the size, we are able to split those resources by country or create a customised resources package for you. 

In order to start using the SDK, you need to choose 1 default profile from the provided list to you by the GBG Account Manager. Afterwards:

  1. Take provided zip file
  2. Rename its name to IDES-default-profile.zip
  3. Add it to your Xcode project
  4. Once you load MJCS, unless specified otherwise, MJCS will look for this package.

For more information please refer to Hot-Swapping functionality.

Required permissions and entitlements

MJCS requires certain permissions to be enabled either in your project settings, please find a table below describing it:

PermissionLocationNote
<key>NSCameraUsageDescription</key>
<string>Uses camera to capture documents</string>
Info.plistRequired for document capture/Liveness components
<key>NFCReaderUsageDescription</key>
<string>Uses NFC reader to scan document chip</string>
<key>com.apple.developer.nfc.readersession.iso7816.select-identifiers</key>
<array>
<string>A0000002471001</string>
<string>A00000045645444C2D3031</string>
</array>
Info.plistOnly required when NFC module is used
Near Field Communication Tag ReadingProvisioning Profile CapabilitiesTo add such capability, the easiest way is to go to your Target Settings/Signing & Capabilities/ Choose to add Near Field Communication Tag Reading 
Was this page helpful?