In version 5.7.2001 of the MyGeotab API there will be a breaking change to remove the Device property HardwareId. This will facilitate the decoupling of SerialNumber and HardwareId and is designed to cause the least inconvenience to existing integrations as possible.
As a result of decoupling the Hardware ID and serial number, it will no longer be possible to decode a given serial number to a corresponding hardware ID or encode a serial number by using the device type and hardware ID. This is something older versions of the NuGet package do implicitly when deserializing the device JSON to a device object, and it becomes a problem when an integration using an older NuGet package version receives a hardware ID from the server.
Problems can occur if the client encodes the hardware ID to an incorrect serial number. This causes issues when trying to Set devices using the older NuGet package because it sends a different serial number than it receives. If a hardware ID is received by the API, it will be ignored and the serial number will be taken as the source of truth.
In order to prevent breaking existing integrations using older versions of the NuGet package we must no longer return hardware ID in the device object JSON. For continuity, the 5.7.2001 NuGet package will retain its hardware ID property, though its value will always be null.
Removing hardware ID means many integrations using older NuGet packages will continue to function normally but integrations using hardware ID may be accessing a null or nonexistent hardware ID from the JSON payload. As a precaution you may need to adjust your integration in following ways:
- Do not encode or decode serial from/to hardware ID.
- Do not expect hardware ID to be present in JSON payload.
- If using an older NuGet package, do not use the hardware ID of the Device object. It may be incorrect.