Energy Price Chart Automation with Power by the Hour

Hi everyone! I’ve been working on a cool project to create a daily energy price chart using the Power by the Hour App. It’s been a fun challenge, and I wanted to share my setup in case it helps anyone else. :seedling:

What I Achieved

Every day, when new energy prices are released, my system automatically generates a chart and sends it to me as a notification. It’s super handy for planning when to use energy more efficiently! :bulb:

How It Works

Here’s a quick breakdown of the process:

  1. Power by the Hour App: This app signals when new prices are available and provides the necessary data.
  2. HomeyScript: I wrote a script to convert the price data into a format that can be used to generate a chart.
  3. Image Charts: I use this free online tool to create the actual chart image. The configuration is sent via a URL encoded with the chart settings.
  4. Image Grabber App: This app fetches the generated chart image.
  5. Notification: The final chart is sent to me as a notification.

Tools I Used

  • Power by the Hour App: For real-time energy price data.
  • HomeyScript: To process the data and generate the chart URL.
  • Image Charts: For creating the visual chart.
  • Image Grabber App: To fetch the chart image.

Flow Overview

  1. The Power by the Hour App detects new prices and triggers the flow.
  2. The HomeyScript card converts the price data into a URL for the chart.
  3. The Image Grabber App fetches the chart image.
  4. A notification is sent with the chart attached.

HomeyScript Details

The script does a few key things:

  • Converts the price data into a format that Image Charts can understand.
  • Sets up the chart appearance, including colors based on price ranges.
  • Adds data labels for the cheapest and most expensive hours.

Result

On my iPhone, I can long-press the notification to view the full chart. It’s a neat way to get a quick overview of energy prices without opening multiple apps! :iphone:

Final Thoughts

This project was a great way to combine a few different apps and scripts to create something really useful. I hope this inspires someone else to try something similar or improve upon my setup! If you have any questions or suggestions, feel free to reach out! :blush:

Happy automating! :rocket: