简体   繁体   English

在 ThingsBoard 中导出设备的遥测数据

[英]export telemetry data of a device in ThingsBoard

im using thingsboard community edition.我正在使用 thingsboard 社区版。

i want to know if there is a way to export all time series data of a device into csv or any other file format.我想知道是否有办法将设备的所有时间序列数据导出为 csv 或任何其他文件格式。 i need all the data to analyse it.我需要所有数据来分析它。

thingsboard Professional edition has this feature. thingsboard 专业版有这个功能。 but how about Community Edition?但是社区版呢?

Default csv/xls export is only available in the professional version.默认 csv/xls 导出仅在专业版中可用。

But you could use the REST api to acquire the historical data.但是您可以使用 REST api 来获取历史数据。

My reference below states:我的参考如下:

You can also fetch list of historical values for particular entity type and entity id using GET request to the following URL 您还可以使用对以下 URL 的 GET 请求获取特定实体类型和实体 ID 的历史值列表

http(s)://host:port/api/plugins/telemetry/{entityType}/{entityId}/values/timeseries?keys=key1,key2,key3&startTs=1479735870785&endTs=1479735871858&interval=60000&limit=100&agg=AVG

The supported parameters are described below:支持的参数描述如下:

keys - comma separated list of telemetry keys to fetch. keys - 要获取的遥测密钥的逗号分隔列表。

startTs - unix timestamp that identifies start of the interval in milliseconds. startTs - unix 时间戳,以毫秒为单位标识间隔的开始。

endTs - unix timestamp that identifies end of the interval in milliseconds. endTs - unix 时间戳,以毫秒为单位标识间隔结束。

interval - the aggregation interval, in milliseconds. interval - 聚合间隔,以毫秒为单位。

agg - the aggregation function. agg - 聚合 function。 One of MIN, MAX, AVG, SUM, COUNT, NONE. MIN、MAX、AVG、SUM、COUNT、NONE 之一。

limit - the max amount of data points to return or intervals to process. limit - 要返回的最大数据点数或要处理的时间间隔。

ThingsBoard will use startTs, endTs and interval to identify aggregation partitions or sub-queries and execute asynchronous queries to DB that leverage built-in aggregation functions." ThingsBoard 将使用 startTs、endTs 和 interval 来识别聚合分区或子查询,并对利用内置聚合函数的 DB 执行异步查询。”

Reference: Thingsboard docs: ts data values api参考: Thingsboard 文档:ts 数据值 api

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

相关问题 Thingsboard 是否默认将遥测数据存储到数据库中? - Does Thingsboard store telemetry data into database by default? Thingsboard我们可以处理收到的遥测数据并再次存储计算值 - Thingsboard Can we process the recieved telemetry data and again store computed value 将 Teltonika 设备连接到 Thingsboard - Connect a Teltonika device to Thingsboard ThingsBoard规则链将遥测重新发布到新主题 - ThingsBoard Rule Chains to re-publish telemetry to a new topic 为什么在通过命令行向 Thingsboard 设备发送数据时会出现错误(“状态”:405,“错误”:“方法不允许”) - Why do I get error ("status":405,"error":"Method Not Allowed") upon sending data to Thingsboard device via command line Thingsboard 的控制小部件声称“设备离线”。 - Thingsboard's control widgets claim that "Device is offline." Azure IoT Edge C++ 模块未将设备发送到云遥测 - Azure IoT Edge C++ module not sending device to cloud telemetry Thingsboard小部件图无法显示6-7小时以上的数据 - thingsboard widget graph unable to show data beyond 6-7hours 如何在 Thingsboard 警报小部件中过滤警报数据? - How can I filter alarm data in Thingsboard alarm widget? 物联网设备以遥测和双胞胎的形式发送信息。 then which has to be when 和有什么区别? - IoT device sends information as telemetry and twins. What is the difference between then which has to be when?
 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM