nerdexam
Microsoft

AZ-204 · Question #63

Drag and Drop Question You are developing an IoT solution. The solution requires bidirectional communication between a .NET application and Azure IoT Hub. You need to obtain connection information…

The correct answer is az extension add --name <iot-extension-name>; az iot hub device-identity create --hub-name <iot-hub-name> --device-id <device-id>; az iot hub device-identity show-connection-string --hub-name <iot-hub-name> --device-id <device-id>. The correct three-command sequence is: (1) 'az extension add --name <iot-extension-name>' to install the Azure IoT CLI extension required for IoT Hub commands, (2) 'az iot hub device-identity create --hub-name <iot-hub-name> --device-id <device-id>' to register a new test…

Submitted by parkjh· Mar 30, 2026Implement IoT Hub device management and configure device connectivity using Azure CLI tools for Azure IoT Developer Specialty or AZ-204 (Developing Solutions for Microsoft Azure)

Question

Drag and Drop Question You are developing an IoT solution. The solution requires bidirectional communication between a .NET application and Azure IoT Hub. You need to obtain connection information for a single test device. Which three commands should you use to develop the solution? To answer, move the appropriate commands from the list of commands to the answer area and arrange them in the correct order. NOTE: Each correct selection is worth one point. Answer:

Exhibit

AZ-204 question #63 exhibit

Answer Area

Drag items

az iot hub device-identity show-connection-string --hub-name <iot-hub-name> --device-id <device-id>az iot hub device-identity export --hub-name <iot-hub-name> --device-id <device-id>az extension add --name <iot-extension-name>az iot hub device-identity create --hub-name <iot-hub-name> --device-id <device-id>az iot hub device-identity import --hub-name <iot-hub-name> --device-od <device-id>

Correct arrangement

  • az extension add --name <iot-extension-name>
  • az iot hub device-identity create --hub-name <iot-hub-name> --device-id <device-id>
  • az iot hub device-identity show-connection-string --hub-name <iot-hub-name> --device-id <device-id>

Explanation

The correct three-command sequence is: (1) 'az extension add --name <iot-extension-name>' to install the Azure IoT CLI extension required for IoT Hub commands, (2) 'az iot hub device-identity create --hub-name <iot-hub-name> --device-id <device-id>' to register a new test device in IoT Hub, and (3) 'az iot hub device-identity show-connection-string --hub-name <iot-hub-name> --device-id <device-id>' to retrieve the device connection string needed for bidirectional communication in the .NET application. This sequence follows the logical flow of: install prerequisites → create the device identity → retrieve connection credentials.

Topics

#Azure IoT Hub#Azure CLI#Device Identity Management#IoT Device Connectivity

Community Discussion

No community discussion yet for this question.

Full AZ-204 Practice