IOT边缘 IOTEDGE-添加数采模板:响应示例

时间:2024-06-20 17:14:28

响应示例

状态码: 200

OK

{
  "tpl_id" : "sys_general_opcua",
  "name" : "sys_general_opcua",
  "description" : "通用opcua模板",
  "datasource_meta" : {
    "config_tabs" : [ {
      "key" : "connection_info",
      "name" : "连接信息",
      "description" : "连接信息",
      "config_items" : [ {
        "key" : "endpoint",
        "name" : "服务端点",
        "description" : "服务完整URL",
        "example" : "opc.tcp://127.0.0.1:53530/OPCUA"
      }, {
        "key" : "username",
        "name" : "用户名",
        "description" : "OPCUA服务器认证用户名",
        "example" : "admin"
      }, {
        "key" : "password",
        "name" : "密码",
        "description" : "OPCUA服务器认证密码",
        "data_type" : "string"
      } ]
    }, {
      "key" : "collection_paras",
      "name" : "连接附加参数",
      "description" : "连接附加参数",
      "config_items" : [ {
        "key" : "default_cycle",
        "name" : "采集周期",
        "description" : "采集周期"
      } ]
    } ],
    "default_values" : {
      "drivername" : "OPCUA"
    }
  },
  "point_meta" : {
    "config_items" : [ {
      "key" : "address",
      "name" : "点位地址",
      "description" : "采集点位的地址",
      "example" : "ns=2;s=Root/Motor/Voltage"
    }, {
      "key" : "data_type",
      "name" : "点位值的数据类型",
      "description" : "点位地址存储值的数据类型"
    }, {
      "key" : "cycle",
      "name" : "点位采集周期",
      "description" : "点位采集周期"
    } ]
  }
}
support.huaweicloud.com/api-iotedge/AddOtTemplates.html