The built-in inject
node has an option to send its message at a given time on selected days...
Wire that to the logic that reads the kWh value and pushes it to the database. InfluxDb is not the only database you could use, but it is nice for time-series data, like this. Since you want to keep a long-term history, I would say a database is the right tool, especially if you plan to query for the data later in order to build reports or graphs.
A lighter-weight solution would be to write the data into a CSV file, or a local file-based database like sqlitedb. Search the flows.nodered.org site for example flows that do something similar...