DigitalTwinOperations Class
DigitalTwinOperations operations.
- Inheritance
-
builtins.objectDigitalTwinOperations
Constructor
DigitalTwinOperations(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
get_digital_twin |
Gets a digital twin. |
invoke_component_command |
Invoke a digital twin command. Invoke a digital twin command. |
invoke_root_level_command |
Invoke a digital twin root level command. Invoke a digital twin root level command. |
update_digital_twin |
Updates a digital twin. |
get_digital_twin
Gets a digital twin.
get_digital_twin(id, custom_headers=None, raw=False, **operation_config)
Parameters
Name | Description |
---|---|
id
Required
|
Digital Twin ID. |
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>
|
object or ClientRawResponse if raw=true |
Exceptions
Type | Description |
---|---|
msrest.exceptions.HttpOperationError
|
invoke_component_command
Invoke a digital twin command.
Invoke a digital twin command.
invoke_component_command(id, component_path, command_name, payload, connect_timeout_in_seconds=None, response_timeout_in_seconds=None, custom_headers=None, raw=False, **operation_config)
Parameters
Name | Description |
---|---|
id
Required
|
|
component_path
Required
|
|
command_name
Required
|
|
payload
Required
|
|
connect_timeout_in_seconds
|
Maximum interval of time, in seconds, that the digital twin command will wait for the answer. Default value: None
|
response_timeout_in_seconds
|
Maximum interval of time, in seconds, that the digital twin command will wait for the answer. Default value: None
|
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>
|
object or ClientRawResponse if raw=true |
Exceptions
Type | Description |
---|---|
msrest.exceptions.HttpOperationError
|
invoke_root_level_command
Invoke a digital twin root level command.
Invoke a digital twin root level command.
invoke_root_level_command(id, command_name, payload, connect_timeout_in_seconds=None, response_timeout_in_seconds=None, custom_headers=None, raw=False, **operation_config)
Parameters
Name | Description |
---|---|
id
Required
|
|
command_name
Required
|
|
payload
Required
|
|
connect_timeout_in_seconds
|
Maximum interval of time, in seconds, that the digital twin command will wait for the answer. Default value: None
|
response_timeout_in_seconds
|
Maximum interval of time, in seconds, that the digital twin command will wait for the answer. Default value: None
|
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>
|
object or ClientRawResponse if raw=true |
Exceptions
Type | Description |
---|---|
msrest.exceptions.HttpOperationError
|
update_digital_twin
Updates a digital twin.
update_digital_twin(id, digital_twin_patch, if_match=None, custom_headers=None, raw=False, **operation_config)
Parameters
Name | Description |
---|---|
id
Required
|
Digital Twin ID. |
digital_twin_patch
Required
|
json-patch contents to update. |
if_match
|
Default value: None
|
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