Water Meter with multiple readings per each LoRaWAN message payload

Hi, I’m trying to get readings into HA, from a water meter, via a LoRaWAN operator’s API, but I have several readings to log each time.

So far I can get the LoRaWAN payloads from the last n days, using a workflow with the n8n add-on: N8n.io integration
(Repository: GitHub - Rbillon59/home-assistant-addons: Repository of self made addons)

I’m not sure yet how I will get this into HA (as a sensor); at a first glance MQTT looks like the simplest option. But…

My issue here, is that everytime I query the server, I receive a number of payloads from the last day(s), and some of them I may have already processed before.
They all have a timestamp, but what’s more interesting, each payload includes the meter’s past 16 readings.

Meaning, when the meter sends a message - every 12h - it includes not only the current reading (cummulative total), but also the previous hourly consumption for the last 16 hours.
This way you know your consumption per hour, but the meter doesn’t need to send a message every hour (saves battery).
Also, if HA is down/offline, when it gets back online it can download all the “intermediate” data that otherwise would be lost.

This is all very neat, in theory, but given all of this, how can I:

  • tell HA that a new reading that I want to log, is not about now, but about a specific point in time?
  • filter which readings I’m supposed to send (add) to HA, or ignore?

Note: I can get around with some SQL Queries, but I’m not so sure of how HA calculates the cummulative sum / running total for a metering sensor, and how it will handle a Query injecting past values.
(and exactly how this can be done)

Anyone had such an experience where a “sensor” reports current and also past data?
Thanks all