HowTo Ecosuite API
Guide for developers building integrations directly with Ecosuite.
This will help you get started on your first Ecosuite integration, from conceptual understanding to practical implementation. Foundationally it is useful to understand that under the covers, Ecosuite is implemented using SolarNetwork as it's data historian. To some degree, this can be considered an implementation detail which could be ignored. But! If you are dealing with a large and sophisticated integration, it will be useful to understand this more fully before you start developing. If you do wish to know more about SolarNetwork and the lower level APIs that it offeres, you can start that journey here. Otherwise, please carry on below as Ecosuite's own API will likely deliver what you need.
1. Understanding Ecosuite's API
The API provides RESTful endpoints for project and time-series data.
API Documentation: High-level introduction to capabilities like data analysis and automation.
OpenAPI Specification: Detailed technical schema for resources like media, storage, and user groups.
3. Test Your Calls
Before writing code, use interactive tools to verify and understand those requests fully:
Sample Payloads: Reference the OpenAPI docs to see example JSON requests for common tasks.
4. Implement and Develop: API Starter Pack
For rapid prototyping, use the Ecosuite API Starter Pack. This CLI tool automates data fetching and organizes outputs.
Requirements
Python 3.9+ (3.12 recommended)
Network access to https://api.ecosuite.io
Run the dependency install:
Authentication
Running the Script
Execute the script and follow interactive prompts:
Run the script:
Output Structure
Responses are saved as JSON files in the output/ directory, organized by <ProjectName> or _global. Each file includes a meta block with the original URL, parameters, and status code.
5. Reference: Common API Endpoints
The following endpoints are frequently used for data extraction:
Project
/projects/{projectId}
Metadata
Energy
/energy/datums/projects/{projectId}
Aggregated time-series data
Readings
/energy/readings
Raw sensor readings
Forecast
/energy/datums/generation/predicted/
Forecasted generation (agg=day)
Weather
/weather/datums/projects/{projectId}
Weather time-series
Global
/events
Portfolio-wide event logs
Users
/users
User directory access
6. Support and Next Steps
Case Studies: Review applications like SolarQuant for machine learning examples.
Contact: For direct assistance, email api@ecosuite.io.
Resources
SolarNetwork Foundations: SolarNetwork Developer Portal, SolarNetwork GitHub Wiki, and the SolarNetwork API Explorer.
Ecosuite API References: Ecosuite API Documentation and the OpenAPI Specification (YML/Swagger).
Development Tools: Ecosuite Python API Client and the Ecosuite API Starter Pack
Last updated