LogoLogo
ProductsUse casesDocsSupport
  • Introducing DriveKit
  • DriveKit Guides
  • Get started with drivekit
    • Trip recording lifecycle
    • iOS
      • 🚀Quick start
      • Advanced configurations
      • References
      • iOS DriveKit Demo App
    • Android
      • 🚀Quick start
      • Advanced configurations
      • References
      • Android DriveKit Demo App
      • Android 15 Migration guide
      • Android 14 Migration guide
      • Troubleshooting
  • Trip analysis
    • Introduction
    • iOS
      • Permissions
      • Trip management
      • TripListener
      • Crash Detection
      • Beacon usage
      • Bluetooth usage
      • Custom metadata
      • References (iOS)
    • Android
      • Runtime permissions
      • Trip management
      • TripListener
      • Crash Detection
      • Beacon usage
      • Bluetooth usage
      • Custom metadata
      • References (Android)
    • User interface
      • iOS
        • Get started
        • Working hours
        • Driver alert in case of crash
        • Trip recording widget
        • Location sharing
      • Android
        • Get started
        • Working hours
        • Driver alert in case of crash
        • Trip recording widget
        • Location sharing
    • REST services
      • Trip
      • References
    • Trip Simulator
      • iOS
      • Android
  • PERMISSIONS UTILS
    • Introduction
    • User interface
      • iOS
        • Get started
        • Main configurations
      • Android
        • Get started
        • Main configurations
  • COMMON UI
    • Introduction
    • iOS
      • Get started
    • Android
      • Get started
    • References
  • DRIVER DATA
    • Introduction
    • iOS
      • Get started
      • References (iOS)
    • Android
      • Get started
      • References (Android)
    • User interface
      • iOS
        • Get started
        • Advanced configurations
        • Trips widgets
        • My Synthesis
        • My Driver Profile
      • Android
        • Get Started
        • Advanced configurations
        • Trips widgets
        • My Synthesis
        • My Driver Profile
  • Driver Data Timeline UI
    • Introduction
    • iOS
      • Get started
    • Android
      • Get started
  • Vehicle
    • Introduction
    • iOS
      • Get started
      • Vehicle management
      • Beacon management
      • Bluetooth device management
      • Odometer
      • References (iOS)
    • Android
      • Get started
      • Vehicle management
      • Beacon management
      • Bluetooth device management
      • Odometer
      • References (Android)
    • User interface
      • iOS
        • Get started
        • Main configurations
        • Advanced configurations
      • Android
        • Get started
        • Main configurations
        • Advanced configurations
  • DRIVER ACHIEVEMENT
    • Introduction
    • iOS
      • Get started
    • Android
      • Get Started
    • User interface
      • iOS
      • Android
  • CHALLENGE
    • Introduction
    • Important challenge rules
    • iOS
      • Get started
      • References (iOS)
    • Android
      • Get started
      • References (Android)
    • User interface
      • iOS
        • Get started
      • Android
        • Get started
  • GROUP
    • Introduction
    • iOS
      • Get started
    • Android
      • Get started
  • React Native
    • Get started
    • Integration
  • Flutter
    • Get started
    • Integration
  • Push services
    • Introduction
    • Push Trip Data
    • Push Deleted trip
    • Push Crash Data
    • Push Diagnosis Data
  • ADMIN SERVICES
    • Beacon
      • Add
      • Replace
      • Delete
      • Configuration
    • Challenges
      • List of challenges
      • Challenge details
      • Registered users
      • Challenge ranking
      • Users' progress
      • Definitions
    • Customer
      • Activity timeline
    • Driver
      • Timeline
      • Synthesis
      • Identity
      • Status
      • Add or update a metadata
      • Vehicles
      • Profile
      • Application diagnoses
    • Drivers
      • Account
      • Statistics
      • Ranking
      • Expired accounts
    • Group
      • Timeline
      • Synthesis
    • Trips
      • Add or update a metadata
      • Delete a metadata
    • Vehicle
      • Create
      • Characteristics
      • Configuration
      • Statistics
      • Update mileage
      • Tire and brake wear update
      • References
  • Crashes
    • Annotate a crash
    • Revoke crash location URL
  • ENTERPRISE SERVICES
    • Introduction
    • Teams
      • Create a team
      • List of teams
      • Enable or disable a team
    • Hyper-admins
      • Create a hyper-admin
      • List of hyper-admins
      • Delete a hyper-admin
    • Monitoring
      • Get a push trip data report
      • Get a push crash data report
      • Request to retry failed trips
      • Request to retry failed crashes
      • Get the status of a task
  • Release notes
    • Changelog
      • iOS
      • Android
      • UI iOS
      • UI Android
Powered by GitBook
On this page
  • Introduction
  • Principle
  • Configuration
  • Security
  • Automatic retry
  • Sample Message

Was this helpful?

Export as PDF
  1. Push services

Push Diagnosis Data

Introduction

The DriveKit SDK regularly collects information on the smartphone's configuration: application permissions, sensor statuses and any user-generated events.

The push diagnosis data service is designed to share all diagnosis data collected by the DriveKit SDK installed on each of your users' mobile applications with your platform.

These insights can be used to:

  • Identify users facing configuration issues, which may improve the onboarding experience

  • Detect trip recording issues caused by user events (logout, app uninstallation, phone shutdown...)

Principle

The diagnosis data push service sends the diagnosis events right after they are transmitted by the DriveKit SDK to the DriveQuant platform. The process is described below:

  • The DriveKit SDK collects the diagnosis data, which is stored locally on the user's phone.

  • The DriveKit SDK sends the diagnosis data to the DriveQuant platform at least one a day. There is no precise time for data retrieval, as this depends on the state of the application and the smartphone.

  • If you subscribe to the push diagnosis data service, the data is transmitted to your platform as soon as it is received and stored on the DriveQuant platform.

Diagnostic push can be sent even if there are no updates to the status of the diagnostic indicators. The push is triggered by the SDK. The SDK still information once a day even if there are no changes in diagnostic indicators. An empty push indicates there is no changes. The advantage of making one push per day is that the message, even if empty, confirms that the application is still installed and active on the user's phone.

All diagnostic events are shared after an initial installation and initialization of the DriveKit SDK. The diagnosis data push is not immediate, but delayed by at least 30 minutes to give the user time to grant permissions.

Configuration

Diagnosis events data is sent as a POST request to a client URL. The URL must be provided to DriveQuant in order to set up and activate the push diagnosis data service.

If the service returns a 200 HTTP code while the data has not been accepted by the client server, then there will be no further attempt to send the data.

Security

Automatic retry

DriveQuant will retry to push the diagnosis data if an HTTP error was previously received. In order to avoid too many consecutive retries, the push diagnosis data replay will be performed once a day from the day after a failed attempt, until the trip deletion has been accepted. Also, the failed events will be sent every time the SDK sends an update, before sending any new event. If after 30 days the trip deletion has not been accepted, the data will be discarded.

Sample Message

The body of the request is a JSON object with a set of fields containing the user unique identifier, the user's smartphone data, and a list of the events collected by the SDK, divided into 4 categories:

  1. permissions: events related to the application’s permissions

  2. sensors: events related to the smartphone’s sensors

  3. settings: events related to the smartphone’s configuration

  4. events: events related to user's events (login/logout, app install/uninstall, smartphone on/off)

The table below lists the types of diagnosis data and their possible values.

Category
Type
Possible values

permissions

NOTIFICATION_ACCESS

GRANTED / DENIED

permissions

LOCATION_ACCESS

GRANTED / DENIED

permissions

BLUETOOTH_ACCESS

GRANTED / DENIED

permissions

ACTIVITY_ACCESS

GRANTED / DENIED

sensors

GPS_SENSOR

ENABLED / DISABLED

sensors

BLUETOOTH_SENSOR

ENABLED / DISABLED

settings

LOW_POWER_MODE

ENABLED / DISABLED

settings

PERMISSIONS_AUTO_DELETE

ENABLED / DISABLED

settings

BATTERY_OPTIMISATION

ENABLED / DISABLED

events

PHONE_STATE

TURNED_ON / TURNED_OFF

events

APP_STATE

INSTALLED / UNINSTALLED

events

LOGIN_STATE

LOGGED_IN / LOGGED_OUT

Sample message (click to expand)
{
    "userId": "john.doe@drivequant.com",
    "installationId": "9cc02aaa-92b4-cbd2-73fb-3dda6243dddf",
    "smartphoneData": {
        "phoneModel": "iPhone 15 Pro",
        "appBuildNumber": "1032",
        "appVersion": "5.2.1",
        "osVersion": "17.4.1",
        "osType": "iOS",
        "sdkVersion": "2.1",
        "lastUpdate": "2024-05-21T08:52:53.470+0000"
    },
    "permissions": [
        {
            "date": "2024-05-20T12:15:32.000+0000",
            "type": "NOTIFICATION_ACCESS",
            "value": "DENIED"
        },
        {
            "date": "2024-05-20T14:15:32.000+0000",
            "type": "NOTIFICATION_ACCESS",
            "value": "GRANTED"
        },
        {
            "date": "2024-05-20T12:15:24.000+0000",
            "type": "BLUETOOTH_ACCESS",
            "value": "DENIED"
        },
        {
            "date": "2024-05-20T14:15:24.000+0000",
            "type": "BLUETOOTH_ACCESS",
            "value": "GRANTED"
        },
        {
            "date": "2024-05-20T12:15:26.000+0000",
            "type": "ACTIVITY_ACCESS",
            "value": "DENIED"
        },
        {
            "date": "2024-05-20T14:15:26.000+0000",
            "type": "ACTIVITY_ACCESS",
            "value": "GRANTED"
        },
        {
            "date": "2024-05-20T12:15:22.000+0000",
            "type": "LOCATION_ACCESS",
            "value": "DENIED"
        },
        {
            "date": "2024-05-20T14:15:22.000+0000",
            "type": "LOCATION_ACCESS",
            "value": "GRANTED"
        }
    ],
    "sensors": [
        {
            "date": "2024-05-20T12:14:22.000+0000",
            "type": "GPS_SENSOR",
            "value": "DISABLED"
        },
        {
            "date": "2024-05-20T14:14:22.000+0000",
            "type": "GPS_SENSOR",
            "value": "ENABLED"
        },
        {
            "date": "2024-05-20T13:15:02.000+0000",
            "type": "BLUETOOTH_SENSOR",
            "value": "DISABLED"
        },
        {
            "date": "2024-05-20T13:15:22.000+0000",
            "type": "BLUETOOTH_SENSOR",
            "value": "ENABLED"
        }
    ],
    "settings": [
        {
            "date": "2024-05-20T11:44:00.000+0000",
            "type": "LOW_POWER_MODE",
            "value": "ENABLED"
        },
        {
            "date": "2024-05-20T12:03:27.000+0000",
            "type": "LOW_POWER_MODE",
            "value": "DISABLED"
        }
    ],
    "events": [
        {
            "date": "2024-05-15T13:25:22.000+0000",
            "type": "PHONE_STATE",
            "value": "TURNED_OFF"
        },
        {
            "date": "2024-05-15T13:28:22.000+0000",
            "type": "PHONE_STATE",
            "value": "TURNED_ON"
        },
        {
            "date": "2024-05-10T14:15:22.000+0000",
            "type": "APP_STATE",
            "value": "INSTALLED"
        },
        {
            "date": "2024-05-12T08:34:21.000+0000",
            "type": "APP_STATE",
            "value": "UNINSTALLED"
        },
        {
            "date": "2024-05-18T11:12:46.000+0000",
            "type": "APP_STATE",
            "value": "INSTALLED"
        },
        {
            "date": "2024-05-10T14:20:02.000+0000",
            "type": "LOGIN_STATE",
            "value": "LOGGED_IN"
        },
        {
            "date": "2024-05-12T08:32:11.000+0000",
            "type": "LOGIN_STATE",
            "value": "LOGGED_OUT"
        },
        {
            "date": "2024-05-18T11:15:35.000+0000",
            "type": "LOGIN_STATE",
            "value": "LOGGED_IN"
        }
    ]
}

PreviousPush Crash DataNextBeacon

Last updated 27 days ago

Was this helpful?

An example of data in JSON format is given .

It is mandatory to configure an HTTP response code. If the POST request is accepted, we expect a http status code 200 (OK). Any other code will be considered as a failure, and the service will attempt to send the diagnosis events data again as defined in the .

See in parent section.

The OpenAPI specification can be downloaded in OpenAPI YAML format.

here
at the end of this section
Automatic retry section
Security