I'm trying to update Iothub device status using Rest API. Link: https://docs.microsoft.com/en-us/rest/api/iothub/service/createorupdatedevice
I was able to create a new device using it but not able to update anything.
Request:
{ "eTag": "NTkyMDYyMzsSU2", "status": "disabled", "deviceId": "xyz" }
Response:
{ "Message": "ErrorCode:DeviceAlreadyExists;A device with ID 'xyz' is already registered.", "ExceptionMessage": "Tracking ID:8a748b37ssda964671a75f0a3fb1ba5a7b-G:8-TimeStamp:04/29/2019 14:53:52" }