CloudToDeviceMessagesOperations Class
CloudToDeviceMessagesOperations operations.
- Inheritance
-
builtins.objectCloudToDeviceMessagesOperations
Constructor
CloudToDeviceMessagesOperations(client, config, serializer, deserializer)
Parameters
Name | Description |
---|---|
client
Required
|
Client for service requests. |
config
Required
|
Configuration of service client. |
serializer
Required
|
An object model serializer. |
deserializer
Required
|
An object model deserializer. |
Variables
Name | Description |
---|---|
api_version
|
Version of the Api. Constant value: "2021-04-12". |
Methods
abandon_feedback_notification |
Abandons the lock on a cloud-to-device feedback message. See https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-messaging for more information. |
complete_feedback_notification |
Completes the cloud-to-device feedback message. A completed message is deleted from the feedback queue of the service. See https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-messaging for more information. |
purge_cloud_to_device_message_queue |
Deletes all the pending commands for a device in the IoT Hub. |
receive_feedback_notification |
Gets the feedback for cloud-to-device messages. See https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-messaging for more information. This capability is only available in the standard tier IoT Hub. For more information, see Choose the right IoT Hub tier. |
abandon_feedback_notification
Abandons the lock on a cloud-to-device feedback message. See https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-messaging for more information.
abandon_feedback_notification(lock_token, custom_headers=None, raw=False, **operation_config)
Parameters
Name | Description |
---|---|
lock_token
Required
|
The lock token obtained when the cloud-to-device message is received. |
custom_headers
|
headers that will be added to the request Default value: None
|
raw
|
returns the direct response alongside the deserialized response Default value: False
|
operation_config
Required
|
Operation configuration overrides. |
Returns
Type | Description |
---|---|
None,
<xref:msrest.pipeline.ClientRawResponse>
|
None or ClientRawResponse if raw=true |
Exceptions
Type | Description |
---|---|
msrest.exceptions.HttpOperationError
|
complete_feedback_notification
Completes the cloud-to-device feedback message. A completed message is deleted from the feedback queue of the service. See https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-messaging for more information.
complete_feedback_notification(lock_token, custom_headers=None, raw=False, **operation_config)
Parameters
Name | Description |
---|---|
lock_token
Required
|
The lock token obtained when the cloud-to-device message is received. This is used to resolve race conditions when completing a feedback message. |
custom_headers
|
headers that will be added to the request Default value: None
|
raw
|
returns the direct response alongside the deserialized response Default value: False
|
operation_config
Required
|
Operation configuration overrides. |
Returns
Type | Description |
---|---|
None,
<xref:msrest.pipeline.ClientRawResponse>
|
None or ClientRawResponse if raw=true |
Exceptions
Type | Description |
---|---|
msrest.exceptions.HttpOperationError
|
purge_cloud_to_device_message_queue
Deletes all the pending commands for a device in the IoT Hub.
purge_cloud_to_device_message_queue(id, custom_headers=None, raw=False, **operation_config)
Parameters
Name | Description |
---|---|
id
Required
|
The unique identifier of the device. |
custom_headers
|
headers that will be added to the request Default value: None
|
raw
|
returns the direct response alongside the deserialized response Default value: False
|
operation_config
Required
|
Operation configuration overrides. |
Returns
Type | Description |
---|---|
<xref:msrest.pipeline.ClientRawResponse>
|
PurgeMessageQueueResult or ClientRawResponse if raw=true |
Exceptions
Type | Description |
---|---|
msrest.exceptions.HttpOperationError
|
receive_feedback_notification
Gets the feedback for cloud-to-device messages. See https://docs.microsoft.com/azure/iot-hub/iot-hub-devguide-messaging for more information. This capability is only available in the standard tier IoT Hub. For more information, see Choose the right IoT Hub tier.
receive_feedback_notification(custom_headers=None, raw=False, **operation_config)
Parameters
Name | Description |
---|---|
custom_headers
|
headers that will be added to the request Default value: None
|
raw
|
returns the direct response alongside the deserialized response Default value: False
|
operation_config
Required
|
Operation configuration overrides. |
Returns
Type | Description |
---|---|
None,
<xref:msrest.pipeline.ClientRawResponse>
|
None or ClientRawResponse if raw=true |
Exceptions
Type | Description |
---|---|
msrest.exceptions.HttpOperationError
|
Attributes
models
models = <module 'azure.iot.hub.protocol.models' from 'C:\\hostedtoolcache\\windows\\Python\\3.11.9\\x64\\Lib\\site-packages\\azure\\iot\\hub\\protocol\\models\\__init__.py'>
Azure SDK for Python