Mismatch between data from Telegraf and Influx

Good to know, that this function is kind of inbuilt. As you see in this Topic, I had a python script to do exactly this: Understanding Telegraf

Anyway, this is the output from the “output_file.txt”, we adjusted the parser script to only return the values for today and yesterday:

mqtt_consumer,device_id=TF00006,host=Fred,mac=XXXXXXXXXXXX,msg_id=3070,plugs=MyTopic num=30,energy_list_30d=90,time_plug="2025-08-14T12:49:22+00:00" 1755122400
mqtt_consumer,device_id=TF00006,host=Fred,mac=XXXXXXXXXXXX,msg_id=3070,plugs=MyTopic num=30,energy_list_30d=171,time_plug="2025-08-14T12:49:22+00:00" 1755036000

This is the original message sent out from the Broker:

{
  "msg_id" : 3070,
  "device_info" : {
    "device_id" : "TF00006",
    "mac" : "XXXXXXXXXXXX"
  },
  "data" : {
    "timestamp" : "2025-08-14T12:49:22+00:00",
    "num" : 30,
    "energy" : [ 90, 171, 170, 178, 172, 171, 158, 146, 154, 147, 145, 139, 146, 147, 146, 161, 159, 184, 164, 164, 172, 159, 146, 163, 183, 181, 159, 152, 158, 144 ]
  }
}

And the numbers are correct, except inside of influx.