How to ProvisioningDeviceClient using React Native?

Shahanshah Alam 0 Reputation points
2024-04-02T07:55:43.18+00:00
Azure IoT Hub
Azure IoT Hub
An Azure service that enables bidirectional communication between internet of things (IoT) devices and applications.
1,190 questions
Azure IoT SDK
Azure IoT SDK
An Azure software development kit that facilitates building applications that connect to Azure IoT services.
222 questions
0 comments No comments
{count} votes

1 answer

Sort by: Most helpful
  1. Sander van de Velde | MVP 32,726 Reputation points MVP
    2024-04-02T12:36:59.3166667+00:00

    Hello @Alam, Shahanshah - Contractor {PEP},

    welcome to this moderated Azure community forum.

    I see both a TypeScript and a Javascript example. Please provide information about the programming language(s) you want to use in React. I expect both are possible...

    Connecting a device to an IoT Hub using the Device Provisioning Service is the preferred way.

    You need to choice either for single enrollments or group enrollments. Then you need to chose on of the available ways of securing the identity (either a symmetric key or a certificate).

    For development and testing purposes, an individual enrollment with a symmetric key is preferred due to simplicity.

    Check out this elaborate example based on Node.JS.

    It's recommended to try this example as-is first so you prove this example works as expected.

    From there, port that solution to you React environment.

    Finally, switch over to this X509 example.


    If the response helped, do "Accept Answer". If it doesn't work, please let us know the progress. All community members with similar issues will benefit by doing so. Your contribution is highly appreciated.

    1 person found this answer helpful.
    0 comments No comments

Your answer

Answers can be marked as Accepted Answers by the question author, which helps users to know the answer solved the author's problem.