DigitalTwinClient.InvokeComponentCommandAsync Method
Definition
Important
Some information relates to prerelease product that may be substantially modified before it’s released. Microsoft makes no warranties, express or implied, with respect to the information provided here.
Invoke a command on a component of a digital twin.
public virtual System.Threading.Tasks.Task<Microsoft.Rest.HttpOperationResponse<Microsoft.Azure.Devices.DigitalTwinCommandResponse,Microsoft.Azure.Devices.DigitalTwinInvokeCommandHeaders>> InvokeComponentCommandAsync (string digitalTwinId, string componentName, string commandName, string payload = default, Microsoft.Azure.Devices.DigitalTwinInvokeCommandRequestOptions requestOptions = default, System.Threading.CancellationToken cancellationToken = default);
abstract member InvokeComponentCommandAsync : string * string * string * string * Microsoft.Azure.Devices.DigitalTwinInvokeCommandRequestOptions * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Rest.HttpOperationResponse<Microsoft.Azure.Devices.DigitalTwinCommandResponse, Microsoft.Azure.Devices.DigitalTwinInvokeCommandHeaders>>
override this.InvokeComponentCommandAsync : string * string * string * string * Microsoft.Azure.Devices.DigitalTwinInvokeCommandRequestOptions * System.Threading.CancellationToken -> System.Threading.Tasks.Task<Microsoft.Rest.HttpOperationResponse<Microsoft.Azure.Devices.DigitalTwinCommandResponse, Microsoft.Azure.Devices.DigitalTwinInvokeCommandHeaders>>
Public Overridable Function InvokeComponentCommandAsync (digitalTwinId As String, componentName As String, commandName As String, Optional payload As String = Nothing, Optional requestOptions As DigitalTwinInvokeCommandRequestOptions = Nothing, Optional cancellationToken As CancellationToken = Nothing) As Task(Of HttpOperationResponse(Of DigitalTwinCommandResponse, DigitalTwinInvokeCommandHeaders))
Parameters
- digitalTwinId
- String
The Id of the digital twin.
- componentName
- String
The component name under which the command is defined.
- commandName
- String
The command to be invoked.
- payload
- String
The command payload.
- requestOptions
- DigitalTwinInvokeCommandRequestOptions
The optional settings for this request.
- cancellationToken
- CancellationToken
The cancellationToken.
Returns
The application/json command invocation response and the http response.
Applies to
Совместная работа с нами на GitHub
Источник этого содержимого можно найти на GitHub, где также можно создавать и просматривать проблемы и запросы на вытягивание. Дополнительные сведения см. в нашем руководстве для участников.
Azure SDK for .NET