This section describes how to integrate DriveKit into an iOS mobile application.


DriveKit is developed with the Swift 5 language and is compatible with iOS 10.0 and later versions.


DriveKit SDK are available on Github repository.

To access framework in the repository, add the following lines to your Podfile

target 'my-target' do
pod 'Networking', :git => '', :tag => '1.0.1'
pod 'DriveKitCore', :git => '', :tag => '1.0.1'

Be sure to always have the same tag for all DriveKit frameworks in your project.


DriveKit initialization

To initialize DriveKit in your app, you must call the initialization method in didFinishLaunchingWithOptions method of your application class.

import DriveKitCore
func application(_ application: UIApplication, didFinishLaunchingWithOptions launchOptions: [UIApplication.LaunchOptionsKey: Any]?) -> Bool {

All DriveKit modules have a method initialize that must be called in didFinishLaunchingWithOptions method of your AppDelegate file.

Add API key

To use DriveKit framework, you have to obtain an API Key from DriveQuant. If you don't have an API key, please contact DriveQuant

Once your API key is securely stored in your application, you can configure DriveKit by calling the following method.

DriveKit.shared.setApiKey(key: "MyApiKey")

Identify user

Each driver must be identified with a unique identifier, once you have this identifier, configure DriveKit by calling the following method.

DriveKit.shared.registerUser(userId: "MyUserId")

You can call these 2 configuration methods anywhere in your app's code. DriveKit will save the value locally. If the app is killed and relaunched, DriveKit will be reconfigured automatically.

DriveKit SDK will not work until you set the API key and the userId

Check your configuration

You can check if DriveKit SDK is well configured with the following method.


This method return true if it is well configured.


If you need to reset DriveKit configuration (user logout for example), you can call the following method


All data saved locally by DriveKit will be erased.

All DriverKit frameworks have reset method that erased all data saved locally by the framework.

Be sure to call reset method of all frameworks to fully reset DriveKit configuration.


To ease integration, DriveKit provide a logging feature. To activate logging, call the following method.


Log will be written in app directory. One log file per month will be written with the name log-<MONTH>-<YEAR>.txt (example : log-8-2019.txt). All DriveKit modules log in this file.

To write log files on user smartphone, you must add the following entry in your info.plist file UIFileSharingEnabled and LSSupportsOpeningDocumentsInPlace set to true .

Disable logging by calling