Invoke Service¶
Invoke Service 节点控制下行的服务调用消息发送到 Kafka。
备注
使用该节点不会主动设置设备的测点;为此,需使用 Send Command 节点。
如果有对服务调用的信息进行用户自定义处理,但没有使用 Invoke Service 节点,将会导致信息发送 Kafka 失败,从而导致设备不能接收控制指令。
节点类型¶
EnOS。
输入和输出能力¶
该节点具有多个入口点和 2 个出口点 (成功/失败)。
节点属性¶
名称
该节点的名称。
描述
该节点的描述。
示例¶
输入示例¶
{
"MetaData": {
"messageType": "InvokeService",
"assetId": "assetId",
"deviceKey": "deviceKey",
"productKey": "productKey",
"orgId": "yourOrgId"
},
"Body": {
"payload": [
123,
34,
105,
100,
34,
58,
34,
51,
125
],
"code": 200,
"orgId": "yourOrgId",
"productKey": "productKey",
"deviceKey": "deviceKey",
"assetId": "assetId",
"method": "thing.service.yourServiceIdentifier",
"extProps": {
"gwDeviceKey": "deviceKey",
"gwProductKey": "productKey",
"%TRACE_ID%": "6eded0e8-786d-4127-be12-5d3d63f605aa"
}
}
}
输出示例¶
{
"MetaData": {
"messageType": "InvokeService",
"assetId": "assetId",
"deviceKey": "deviceKey",
"productKey": "productKey",
"orgId": "yourOrgId",
"componentResult": "Success"
},
"Body": {
"payload": [
123,
34,
105,
100,
34,
58,
34,
51,
125
],
"code": 200,
"orgId": "yourOrgId",
"productKey": "productKey",
"deviceKey": "deviceKey",
"assetId": "assetId",
"method": "thing.service.yourServiceIdentifier",
"extProps": {
"gwDeviceKey": "deviceKey",
"gwProductKey": "productKey",
"%TRACE_ID%": "6eded0e8-786d-4127-be12-5d3d63f605aa"
}
}
}