0
votes

I am developing mobile application (android).I want to register new device on IoT hub Using REST API or SDK.The registration process will done by mobile application.for ex smartband. Most of available link on google showing azure CLI process to create device.but I want to create new device programatically using REST API.

Can we use device provision service for register new device ?

I am new in azure service.

1

1 Answers

0
votes

You could create or update the identity of a device in the identity registry of an IoT hub by following Service - Create Or Update Device.

PUT https://fully-qualified-iothubname.azure-devices.net/devices/{id}?api-version=2019-07-01-preview
Authorization: Token
{
  "deviceId": "{device id}"
}

For how to get the Token, please refer to Authentication.