I’m trying to take this InfluxDB Query:
SELECT integral("value",1h) AS "energy" FROM "home_assistant"."autogen"."kW" WHERE time > now()-7d AND "entity_id"='powerwall_site_now'
And convert it into a sensor. Using the influxdb sensor syntax I’m not sure how to pass the parameters to integral.