Security - CarKey Check
Security: CarKey Check require the following security schemes to be valid
- 🔓 Authentication
References: check-out 🔑 CarKey component list of APIs.
CarKey is a security feature that perform a check to make sure the user is in possession of the vehicle keys.
An activated CarKey is required in order to use remote commands & vehicle status. Check out Service Activation Steps to get assistance accessing remote command.
This has to be performed only once, in order to unlock the service, but it’s not required each time the user needs to perform a remote action.
Requirements #
To activate CarKey on the user account, the following requirements need to be fulfills:
- 📱 The mobile phone is connected with Bluetooth to the vehicle.
- 🔑 The vehicle’s keys are in possession of the user.
- 🚗 The user is inside the vehicle (with key and phone).
Check Carkey status #
Before activating a CarKey, you can check if it’s already activated. If it’s already activated, you don’t need to launch the process again.
In order to check a CarKey with get-pims.vehicle.carkey, you must select a vehicle using this API:
1
2
3
4
5
6
pims.set("pims.vehicle.vin",
mapOf( /* parameters */
Pair("vin", "VR1AB12C3D45678909")
)
) { message -> /* handle message */ }
1
2
3
4
5
6
pims.set(api: "pims.vehicle.vin",
parameters: [
"vin": "VR1AB12C3D45678909"
]
) { (message) in /* handle message */ }
1
2
3
4
5
6
// representation of the `succeeded` dictionary object message as JSON
{
"transactionId": "953cfefb-bc72",
"status": "SUCCEEDED",
"result": null
}
false
Note: This API has been released in SDK version 2.3. Before v2.3, get-pims.vehicle.carkey would include a VIN parameter. Check-out the changelog.
Then, we can check CarKey status:
1
2
3
pims.get("pims.vehicle.carkey"
) { message -> /* handle message */ }
1
2
3
pims.get(api: "pims.vehicle.carkey"
) { (message) in /* handle message */ }
1
2
3
4
5
6
7
8
9
10
// representation of the `succeeded` dictionary object message as JSON
{
"transactionId": "953cfefb-bc72",
"status": "SUCCEEDED",
"result": {
"isCarKeyVerified": "true",
"cvsStatus": "active",
"maxReactivationDate": "2021-07-29T22:25:09.898Z"
}
}
false
Activate CarKey #
When CarKey conditions are met, we can perform a CarKey activation using the following API:
Info: CarKey needs to be activated only once. The activation of CarKey is stored in the user account and the related services are unlocked.
1
2
3
pims.set("pims.vehicle.carkey "
) { message -> /* handle message */ }
1
2
3
pims.set(api: "pims.vehicle.carkey "
) { (message) in /* handle message */ }
1
2
3
4
5
6
7
8
9
10
11
// representation of the `succeeded` dictionary object message as JSON
{
"transactionId": "953cfefb-bc72",
"status": "SUCCEEDED",
"result": {
"hasCarKey": "true",
"vin": "VR1AB12C3D45678909",
"securityCode": "c2hhemFtCg==",
"securityExpiration": "2021-07-29T22:25:09.898Z"
}
}
false