Skip to content

pablogarciaprado/solar-edge-api-enricher

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

2 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

SolarEdge API Enricher

A Python toolkit for analyzing and visualizing SolarEdge solar panel data, with a focus on optimizing electricity consumption and costs.

Overview

This project provides an enhanced wrapper around the SolarEdge Monitoring API to extract, analyze, and visualize solar panel performance data. While it supports various metrics available through the API, it has been primarily tailored to analyze Purchased Power consumption patterns.

Prerequisites

API Credentials To use this tool, you'll need:

  1. A SolarEdge API key
  2. Your Site ID

These can be obtained through your SolarEdge monitoring platform. Store your credentials in a credentials.json file:

{
    "api_key": "YOUR_API_KEY",
    "site_id": YOUR_SITE_ID
}

For more information on obtaining these credentials:

Project Structure

api_enricher.py

The core functionality is implemented in the SolarEdgeAPIEnricher class, which provides:

  • Monthly data aggregation
  • Power consumption analysis
  • Advanced visualization using Plotly
  • Data transformation utilities
  • Spaghetti plots for daily power profiles

demo.ipynb

A Jupyter notebook demonstrating the usage of the API enricher, including:

  • Setting up the API connection
  • Fetching power consumption data
  • Creating visualizations
  • Sample analysis workflows

Installation

git clone https://github.com/yourusername/solar-edge-api-enricher.git
cd solar-edge-api-enricher
pip install -r requirements.txt

Quick Start

from api_enricher import SolarEdgeAPIEnricher
import json

# Load credentials
with open('credentials.json') as f:
    credentials = json.load(f)

# Initialize the enricher
enricher = SolarEdgeAPIEnricher(
    api_key=credentials['api_key'],
    site_id=credentials['site_id']
)

Example Output

Example Output

Contributing & Future Steps

Feel free to fork this repository and submit pull requests to extend the functionality. Some interesting areas for expansion include:

  • Additional metric analysis
  • More visualization options
  • Cost optimization algorithms
  • Real-time monitoring features

For more ideas, you might find the SolarEdge Monitoring Server API guide very useful.

About

Enhanced wrapper around the SolarEdge Monitoring API to extract, analyze, and visualize solar panel performance data

Topics

Resources

Stars

Watchers

Forks

Contributors