Na klar. In NodeRed musst du aus der Palette node-red-contrib-discovery-meter installieren und dein Discovery-Meter im Configuration Node konfigurieren. Es gibt den Standard- und den Statistik-Abruf - den ersten rufe ich alle 10 Sekunden für die aktuellen Leistungswerte auf, während ich letzteren alle 5 Minuten für die Langzeitwerte abfrage.
Hier ist mein Flow, den du natürlich beliebig anpassen kannst:
[{"id":"8ddd2d27.936a","type":"tab","label":"Discovergy","disabled":false,"info":""},{"id":"65b7a70a.f1ca6","type":"tab","label":"Discovergy Stats","disabled":false,"info":""},{"id":"6236ec56.295c54","type":"server","name":"Home Assistant","version":1,"legacy":false,"addon":true,"rejectUnauthorizedCerts":true,"ha_boolean":"y|yes|true|on|home|open","connectionDelay":true,"cacheJson":true},{"id":"4d2f5c5e.10c5b4","type":"discovergy-config","name":"discovergy"},{"id":"cc0fa644.621218","type":"inject","z":"8ddd2d27.936a","name":"Timer 10 sec","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"10","crontab":"","once":true,"onceDelay":0.1,"topic":"","payload":"","payloadType":"date","x":132.60000610351562,"y":98,"wires":[["fece26ba.33d878"]]},{"id":"6fd8825c.a47b3c","type":"debug","z":"8ddd2d27.936a","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"payload","targetType":"msg","statusVal":"","statusType":"auto","x":761.6000556945801,"y":122.00000143051147,"wires":[]},{"id":"fece26ba.33d878","type":"Discovergy Meter","z":"8ddd2d27.936a","name":"discovergy","account":"4d2f5c5e.10c5b4","meterId":"43809a464ef04197b90de0f6fcab9e0a","firstReading":0,"firstReadingOut":0,"firstReadingDate":"2021-07-05","isProduction":false,"revenue":0,"amortization":0,"prodMeterId":"43809a464ef04197b90de0f6fcab9e0a","firstReadingProd":0,"x":335.00000381469727,"y":98.00000095367432,"wires":[["d42a468a.a52b68","6fd8825c.a47b3c","4d832c24.2fd594"]]},{"id":"d42a468a.a52b68","type":"change","z":"8ddd2d27.936a","name":"currentpower_w","rules":[{"t":"set","p":"payload","pt":"msg","to":"payload.latest.power_w","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":464.00000762939453,"y":196.00000381469727,"wires":[["d3ea19f2.48eee8"]]},{"id":"d3ea19f2.48eee8","type":"ha-entity","z":"8ddd2d27.936a","name":"currentPower","server":"6236ec56.295c54","version":1,"debugenabled":false,"outputs":1,"entityType":"sensor","config":[{"property":"name","value":"currentPower"},{"property":"device_class","value":"power"},{"property":"icon","value":""},{"property":"unit_of_measurement","value":"W"}],"state":"payload","stateType":"msg","attributes":[],"resend":true,"outputLocation":"","outputLocationType":"none","inputOverride":"allow","x":717.6000595092773,"y":199.00000381469727,"wires":[[]]},{"id":"4feebee7.9dad3","type":"inject","z":"65b7a70a.f1ca6","name":"Timer 5 min","props":[{"p":"payload"},{"p":"topic","vt":"str"}],"repeat":"300","crontab":"","once":true,"onceDelay":0.1,"topic":"statistics","payload":"","payloadType":"date","x":122.60000610351562,"y":98,"wires":[["ac6937e7.316e08"]]},{"id":"64ba18dd.3dab","type":"debug","z":"65b7a70a.f1ca6","name":"","active":true,"tosidebar":true,"console":false,"tostatus":false,"complete":"false","statusVal":"","statusType":"auto","x":630,"y":60,"wires":[]},{"id":"ac6937e7.316e08","type":"Discovergy Meter","z":"65b7a70a.f1ca6","name":"discovergy","account":"4d2f5c5e.10c5b4","meterId":"43809a464ef04197b90de0f6fcab9e0a","firstReading":0,"firstReadingOut":0,"firstReadingDate":"2021-07-05","isProduction":false,"revenue":0,"amortization":0,"prodMeterId":"43809a464ef04197b90de0f6fcab9e0a","firstReadingProd":0,"x":335.00000381469727,"y":98.00000095367432,"wires":[["d98278a1.a36ca","64ba18dd.3dab","abf4333a.c1cd5","c4fbf003.c3aa18","783a64dc.79a93c","1d0c93c3.bda31c","a8795ab1.e231f8","26b8931d.09e67c"]]},{"id":"d98278a1.a36ca","type":"change","z":"65b7a70a.f1ca6","name":"energy_wh_today","rules":[{"t":"set","p":"payload","pt":"msg","to":"payload.stats.today.energy_wh","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":330,"y":200,"wires":[["7fc8c42e.da017c"]]},{"id":"3147beac.e01052","type":"ha-entity","z":"65b7a70a.f1ca6","name":"energy_kwh_today","server":"6236ec56.295c54","version":1,"debugenabled":false,"outputs":1,"entityType":"sensor","config":[{"property":"name","value":"energy_kwh_today"},{"property":"device_class","value":"power"},{"property":"icon","value":""},{"property":"unit_of_measurement","value":"kWh"}],"state":"payload","stateType":"msg","attributes":[],"resend":true,"outputLocation":"","outputLocationType":"none","inputOverride":"allow","outputOnStateChange":false,"outputPayload":"","outputPayloadType":"str","x":745.9999923706055,"y":203.99999618530273,"wires":[[]]},{"id":"abf4333a.c1cd5","type":"change","z":"65b7a70a.f1ca6","name":"energy_wh_yesterday","rules":[{"t":"set","p":"payload","pt":"msg","to":"payload.stats.yesterday.energy_wh","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":323.99999237060547,"y":271.99999618530273,"wires":[["fe36d1be.7a4da8"]]},{"id":"c4fbf003.c3aa18","type":"change","z":"65b7a70a.f1ca6","name":"energy_wh_monthToDay","rules":[{"t":"set","p":"payload","pt":"msg","to":"payload.stats.monthToDay.energy_wh","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":314.99999237060547,"y":351.99999618530273,"wires":[["bb15a809.305a8"]]},{"id":"783a64dc.79a93c","type":"change","z":"65b7a70a.f1ca6","name":"energy_wh_yearToDay","rules":[{"t":"set","p":"payload","pt":"msg","to":"payload.stats.yearToDay.energy_wh","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":315.99999237060547,"y":483.99999618530273,"wires":[["22c7659b.890c22"]]},{"id":"59aaae27.a1adf8","type":"ha-entity","z":"65b7a70a.f1ca6","name":"energy_kwh_yesterday","server":"6236ec56.295c54","version":1,"debugenabled":false,"outputs":1,"entityType":"sensor","config":[{"property":"name","value":"energy_kwh_yesterday"},{"property":"device_class","value":"power"},{"property":"icon","value":""},{"property":"unit_of_measurement","value":"kWh"}],"state":"payload","stateType":"msg","attributes":[],"resend":true,"outputLocation":"","outputLocationType":"none","inputOverride":"allow","outputOnStateChange":false,"outputPayload":"","outputPayloadType":"str","x":755.9999923706055,"y":263.99999618530273,"wires":[[]]},{"id":"15fc6fbe.678cc","type":"ha-entity","z":"65b7a70a.f1ca6","name":"energy_kwh_monthToDay","server":"6236ec56.295c54","version":1,"debugenabled":false,"outputs":1,"entityType":"sensor","config":[{"property":"name","value":"energy_kwh_monthToDay"},{"property":"device_class","value":"power"},{"property":"icon","value":""},{"property":"unit_of_measurement","value":"kWh"}],"state":"payload","stateType":"msg","attributes":[],"resend":true,"outputLocation":"","outputLocationType":"none","inputOverride":"allow","outputOnStateChange":false,"outputPayload":"","outputPayloadType":"str","x":765.9999923706055,"y":343.99999618530273,"wires":[[]]},{"id":"aa38b2b3.569ab8","type":"ha-entity","z":"65b7a70a.f1ca6","name":"energy_kwh_yearToDay","server":"6236ec56.295c54","version":1,"debugenabled":false,"outputs":1,"entityType":"sensor","config":[{"property":"name","value":"energy_kwh_yearToDay"},{"property":"device_class","value":"power"},{"property":"icon","value":""},{"property":"unit_of_measurement","value":"kWh"}],"state":"payload","stateType":"msg","attributes":[],"resend":true,"outputLocation":"","outputLocationType":"none","inputOverride":"allow","outputOnStateChange":false,"outputPayload":"","outputPayloadType":"str","x":765.9999923706055,"y":483.99999618530273,"wires":[[]]},{"id":"1d0c93c3.bda31c","type":"change","z":"65b7a70a.f1ca6","name":"energyOut_wh_yearToDay","rules":[{"t":"set","p":"payload","pt":"msg","to":"payload.stats.yearToDay.energyOut_wh","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":325.99999237060547,"y":543.9999961853027,"wires":[["3312f0c8.0fb6b"]]},{"id":"f2b3840f.bad47","type":"ha-entity","z":"65b7a70a.f1ca6","name":"energyOut_kwh_yearToDay","server":"6236ec56.295c54","version":1,"debugenabled":false,"outputs":1,"entityType":"sensor","config":[{"property":"name","value":"energyOut_kwh_yearToDay"},{"property":"device_class","value":"power"},{"property":"icon","value":""},{"property":"unit_of_measurement","value":"kWh"}],"state":"payload","stateType":"msg","attributes":[],"resend":true,"outputLocation":"","outputLocationType":"none","inputOverride":"allow","outputOnStateChange":false,"outputPayload":"","outputPayloadType":"str","x":775.9999923706055,"y":543.9999961853027,"wires":[[]]},{"id":"7fc8c42e.da017c","type":"unit-converter","z":"65b7a70a.f1ca6","category":"energy","inputUnit":"Wh","outputUnit":"kWh","inputField":"payload","outputField":"payload","inputFieldType":"msg","outputFieldType":"msg","roundOutputField":true,"outputFieldDecimals":2,"name":"","x":535.9999923706055,"y":203.99999618530273,"wires":[["3147beac.e01052"]]},{"id":"fe36d1be.7a4da8","type":"unit-converter","z":"65b7a70a.f1ca6","category":"energy","inputUnit":"Wh","outputUnit":"kWh","inputField":"payload","outputField":"payload","inputFieldType":"msg","outputFieldType":"msg","roundOutputField":true,"outputFieldDecimals":2,"name":"","x":535.9999923706055,"y":263.99999618530273,"wires":[["59aaae27.a1adf8"]]},{"id":"bb15a809.305a8","type":"unit-converter","z":"65b7a70a.f1ca6","category":"energy","inputUnit":"Wh","outputUnit":"kWh","inputField":"payload","outputField":"payload","inputFieldType":"msg","outputFieldType":"msg","roundOutputField":true,"outputFieldDecimals":2,"name":"","x":535.9999923706055,"y":343.99999618530273,"wires":[["15fc6fbe.678cc"]]},{"id":"22c7659b.890c22","type":"unit-converter","z":"65b7a70a.f1ca6","category":"energy","inputUnit":"Wh","outputUnit":"kWh","inputField":"payload","outputField":"payload","inputFieldType":"msg","outputFieldType":"msg","roundOutputField":true,"outputFieldDecimals":2,"name":"","x":535.9999923706055,"y":483.99999618530273,"wires":[["aa38b2b3.569ab8"]]},{"id":"3312f0c8.0fb6b","type":"unit-converter","z":"65b7a70a.f1ca6","category":"energy","inputUnit":"Wh","outputUnit":"kWh","inputField":"payload","outputField":"payload","inputFieldType":"msg","outputFieldType":"msg","roundOutputField":true,"outputFieldDecimals":"4","name":"","x":535.9999923706055,"y":543.9999961853027,"wires":[["f2b3840f.bad47"]]},{"id":"4d832c24.2fd594","type":"change","z":"8ddd2d27.936a","name":"energy_wh","rules":[{"t":"set","p":"payload","pt":"msg","to":"payload.latest.energy_wh","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":390,"y":280,"wires":[["3a9e2c75.d5bd3c"]]},{"id":"3a9e2c75.d5bd3c","type":"unit-converter","z":"8ddd2d27.936a","category":"energy","inputUnit":"Wh","outputUnit":"kWh","inputField":"payload","outputField":"payload","inputFieldType":"msg","outputFieldType":"msg","roundOutputField":false,"outputFieldDecimals":2,"name":"","x":580,"y":300,"wires":[["4b412f67.726b3"]]},{"id":"4b412f67.726b3","type":"ha-entity","z":"8ddd2d27.936a","name":"energy_kwh","server":"6236ec56.295c54","version":1,"debugenabled":false,"outputs":1,"entityType":"sensor","config":[{"property":"name","value":"energy_kwh"},{"property":"device_class","value":"power"},{"property":"icon","value":""},{"property":"unit_of_measurement","value":"kWh"}],"state":"payload","stateType":"msg","attributes":[],"resend":true,"outputLocation":"","outputLocationType":"none","inputOverride":"allow","outputOnStateChange":false,"outputPayload":"","outputPayloadType":"str","x":690,"y":360,"wires":[[]]},{"id":"a8795ab1.e231f8","type":"change","z":"65b7a70a.f1ca6","name":"energy_wh_lastMonth","rules":[{"t":"set","p":"payload","pt":"msg","to":"payload.stats.lastMonth.energy_wh","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":300,"y":420,"wires":[["489619b2.ba37c8"]]},{"id":"489619b2.ba37c8","type":"unit-converter","z":"65b7a70a.f1ca6","category":"energy","inputUnit":"Wh","outputUnit":"kWh","inputField":"payload","outputField":"payload","inputFieldType":"msg","outputFieldType":"msg","roundOutputField":true,"outputFieldDecimals":2,"name":"","x":540,"y":420,"wires":[["a0acf781.292818"]]},{"id":"a0acf781.292818","type":"ha-entity","z":"65b7a70a.f1ca6","name":"energy_kwh_lastMonth","server":"6236ec56.295c54","version":1,"debugenabled":false,"outputs":1,"entityType":"sensor","config":[{"property":"name","value":"energy_kwh_lastMonth"},{"property":"device_class","value":"power"},{"property":"icon","value":""},{"property":"unit_of_measurement","value":"kWh"}],"state":"payload","stateType":"msg","attributes":[],"resend":true,"outputLocation":"","outputLocationType":"none","inputOverride":"allow","outputOnStateChange":false,"outputPayload":"","outputPayloadType":"str","x":770,"y":420,"wires":[[]]},{"id":"26b8931d.09e67c","type":"change","z":"65b7a70a.f1ca6","name":"energyOut_wh_today","rules":[{"t":"set","p":"payload","pt":"msg","to":"payload.stats.today.energyOut_wh","tot":"msg"}],"action":"","property":"","from":"","to":"","reg":false,"x":320,"y":600,"wires":[["9b284cb2.0bfb48"]]},{"id":"9b284cb2.0bfb48","type":"unit-converter","z":"65b7a70a.f1ca6","category":"energy","inputUnit":"Wh","outputUnit":"kWh","inputField":"payload","outputField":"payload","inputFieldType":"msg","outputFieldType":"msg","roundOutputField":true,"outputFieldDecimals":"4","name":"","x":540,"y":600,"wires":[["be690bec.8a7b28"]]},{"id":"be690bec.8a7b28","type":"ha-entity","z":"65b7a70a.f1ca6","name":"energyOut_kwh_today","server":"6236ec56.295c54","version":1,"debugenabled":false,"outputs":1,"entityType":"sensor","config":[{"property":"name","value":"energyOut_kwh_today"},{"property":"device_class","value":"power"},{"property":"icon","value":""},{"property":"unit_of_measurement","value":"kWh"}],"state":"payload","stateType":"msg","attributes":[],"resend":true,"outputLocation":"","outputLocationType":"none","inputOverride":"allow","outputOnStateChange":false,"outputPayload":"","outputPayloadType":"str","x":760,"y":620,"wires":[[]]}]
Sag Bescheid, falls du weitere Infos benötigst.