Skip to content

Commit ea7533b

Browse files
committed
Edits
1 parent 9100cf2 commit ea7533b

File tree

2 files changed

+4
-12
lines changed

2 files changed

+4
-12
lines changed

includes/iot-hub-howto-module-twins-node.md

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -338,11 +338,7 @@ You can connect a backend service to IoT Hub using the following methods:
338338
339339
Use [fromConnectionString](/javascript/api/azure-iothub/registry?#azure-iothub-registry-fromconnectionstring) to connect to IoT hub.
340340
341-
The SDK methods in this section require this shared access policy permission:
342-
343-
* **Registry Write** - required to add a module (or device) to the IoT Hub registry
344-
345-
As a parameter to `CreateFromConnectionString`, supply a shared access policy connection string that includes these permissions. For more information about shared access policies, see [Control access to IoT Hub with shared access signatures](/azure/iot-hub/authenticate-authorize-sas).
341+
The `update` method used in this section requires the **Service Connect** shared access policy permission to add desired properties to a module. As a parameter to `fromConnectionString`, supply a shared access policy connection string that includes **Service Connect** permission. For more information about shared access policies, see [Control access to IoT Hub with shared access signatures](/azure/iot-hub/authenticate-authorize-sas).
346342
347343
```javascript
348344
let connectionString = '{IoT hub shared access policy connection string}';
@@ -363,9 +359,9 @@ To update a module identity twin:
363359
364360
1. Format a patch that contains the module identity twin update. The patch is formatted in JSON as described in [Twin class](/javascript/api/azure-iothub/twin). A backend service patch contains desired property updates. For more patch format information, see [Tags and properties format](/azure/iot-hub/iot-hub-devguide-device-twins#tags-and-properties-format).
365361
366-
1. Call [updateModuleTwin](/javascript/api/azure-iothub/registry?&#azure-iothub-registry-updatemoduletwin-1) to update the module identity twin with the patch.
362+
1. Call [update](/javascript/api/azure-iothub/twin?#azure-iothub-twin-update) to update the module identity twin with the patch.
367363
368-
In this example, the module identity twin is retrieved for `myDeviceId` and `myModuleId`. Then a patch is applied to the twins that contains `updateTime`, `firmwareVersion`, and `weather` information.
364+
In this example, the module identity twin is retrieved for `myDeviceId` and `myModuleId`. Then a patch is applied to the twins that contains `climate` information.
369365
370366
```javascript
371367
// Insert your device ID and moduleId here.

includes/iot-hub-howto-module-twins-python.md

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -177,11 +177,7 @@ You can connect a backend service to IoT Hub using the following methods:
177177

178178
Connect to IoT hub using [from_connection_string](/python/api/azure-iot-hub/azure.iot.hub.iothubregistrymanager?#azure-iot-hub-iothubregistrymanager-from-connection-string).
179179

180-
The SDK methods in this section require this shared access policy permission:
181-
182-
* **Service Connect** - required to add desired properties to a module
183-
184-
As a parameter to `CreateFromConnectionString`, supply a shared access policy connection string that includes these permissions. For more information about shared access policies, see [Control access to IoT Hub with shared access signatures](/azure/iot-hub/authenticate-authorize-sas).
180+
The `update_module_twin` method used in this section requires the **Service Connect** shared access policy permission to add desired properties to a module. As a parameter to `from_connection_string`, supply a shared access policy connection string that includes **Service Connect** permission. For more information about shared access policies, see [Control access to IoT Hub with shared access signatures](/azure/iot-hub/authenticate-authorize-sas).
185181

186182
For example:
187183

0 commit comments

Comments
 (0)