
How it works...
Let's now understand the steps we performed. We initiated this by creating a console application and configured it for the Azure IoT Hub solution. The idea behind this was look at a simple operation for device management.
In this section, we started with a simple operation for the provision of the device by adding it to the IoT Hub. We needed to create a connection to the IoT Hub first. The next step will creating the object of the registry manager. This registry manager object is used to perform the device identity operations.
Once we are connected with IoT Hub using the SDK, we can perform operations such as adding a device, deleting a device, and getting a device; these methods are asynchronous ones.
IoT Hub also connects with Azure Blob storage for bulk operations, such as exporting all devices or importing all devices; this works on JSON format only. The entire set of IoT devices gets exported in this way.