Node.js Telematics

The Telematics class handles all connectivity towards cars. In order to make use of it, an access certificate for a car must first have been downloaded. The class should not instantiated, instead it should be accessed through hmkit.telematics.

Table of Contents

Methods

Send a command to the car through telematics

Declaration

HMKit.telematics.sendCommand(data, accessCertificate)

Parameters

data

(Command) Data that corresponds to the Auto API

accessCertificate

(Object) The access certificate of the car

returns

Promise

Discussion

When the request has finished a Response class instance that corresponds to the sent command or a failure message is returned.

Example

const response = await hmkit.telematics.sendCommand(
    hmkit.commands.EngineCommand.turnOn(),
    accessCertificate
);