Page:
Energy endpoints
Pages
API SMHI
API Sudoku
API TimeEdit
Accessibility Testing
Api documentation
Bat/Ps
Branch Creation
C# Coding Convention
CSS Coding Convention
Coding Conventions
Creating new databases
Dapper
Dictionary API
Documentation for service endpoints
Documentation of useTemperature and mock sensor
Energy endpoints
Environment
Evaluation react-grid-layout
Evaluation Localization
Evaluation Password hashing
Evaluation Testing framework
Evaluation of Logging Frameworks
Formatter
Frontend model
Generic Diagram for Sensor data flow
Home
How to- Creating Databases in Docker
Implementing different Styles
Implementing new Services (and Mockups)
Implementing new Views
Installation script documentation
Installation
Integration testing utilizing testcontainers, xUnit and ASP.NET core web testservers
Issues
JSON Coding Convention
Jest Testing
Layout endpoints
Linux
Localization
Login endpoints
Mac
Menu Endpoints
Middleware model
Mock API Ceation Guidelines
Mockup models
Model Tools and Standards
Parking endpoints
React/JavaScript Coding Convention
React
Reviews
Room booking endpoints
SQL Coding Convention
Scheduled Database tasks
Scripting Coding Convention
Seasonal theme
Secrets and .env
Server Access
Server-DeploymentUnix
Server-DeploymentWindows
Server-Hardware/Benchmarks
Service/API models
System models
System requirements
Temperature endpoints
Testing API with Bruno
Testing Architecture
Testing frontend for Mobile devices
Testing frontend with Playwright
Testing methodology
Themes
Trivia API
Västtrafik API
Webpage Design
Windows
file endpoints
pg_cron and scheduled database jobs
xUnit Testing
No results
9
Energy endpoints
b24idalu edited this page 2026-05-28 08:44:51 +00:00
Energy endpoints
- /energy/health
- /energy/all/{esensorid}
- /energy/total
- /energy/total/{esensorid}
- /energy/total/{esensorid}/{year}/{month}
- /energy/total/{year}/{month}
- /energy/latest/{esensorid}
- /energy/sensors
GET /energy/health
Path to endpoint
GET /energy/health
Required values
None
Return values
Returns a JSON array:
- "OK"
When no error occurs
- Returns an okay
- Status: 200 OK
When error occurs
- If service is not running will not return anything
GET /energy/all/{esensorid}
Path to endpoint
GET /energy/all/{esensorid}
Required values
- esensorid: sensor id
Return values
Returns a JSON array:
- esensorid: sensor name
- timestamp: time of reading
- kilowatt: energy usage
When no error occurs
- Returns all energy sensor data
- Status: 200 OK
When error occurs
- Server failure or database issue
- Status: 500
GET /energy/total
Path to endpoint
GET /energy/total
Required values
None
Return values
Returns a JSON array:
- esensorid: sensor name
- timestamp: time of reading
- kilowatt: monthly energy (all sensors)
When no error occurs
- Returns monthly energy data for all sensors
- Status: 200 OK
When error occurs
- No data available
- Status: 404 Not Found
GET /energy/total/{esensorid}
Path to endpoint
GET /energy/total/{esensorid}
Required values
- esensorid: sensor id
Return values
Returns a JSON array:
- esensorid: sensor name
- timestamp: time of reading
- kilowatt: total energy
When no error occurs
- Returns total energy data for one sensor
- Status: 200 OK
When error occurs
- No data found for sensor or sensor not found
- Status: 404 Not Found
GET /energy/total/{esensorid}/{year}/{month}
Path to endpoint
GET /energy/total/{esensorid}/{year}/{month}
Required values
- esensorid: sensor id
- year: year
- month: month
Return values
Returns a JSON array:
- esensorid: sensor name
- timestamp: time of reading
- kilowatt: total monthly energy (all sensors)
When no error occurs
- Returns monthly energy data for all sensors
- Status: 200 OK
When error occurs
- No data found for sensors during this month
- Status: 404 Not Found
GET /energy/total/{year}/{month}
Path to endpoint
GET /energy/total/{year}/{month}
Required values
- year: year
- month: month
Return values
Returns a JSON array:
- esensorid: empty string
- timestamp: time of reading
- kilowatt: total energy monthly
When no error occurs
- Returns total monthly energy data for all sensors
- Status: 200 OK
When error occurs
- No data found for sensors during this month
- Status: 404 Not Found
GET /energy/latest/{esensorid}
Path to endpoint
GET /energy/latest/{esensorid}
Required values
- esensorid: sensor id
Return values
Returns a JSON array:
- esensorid: empty string
- timestamp: time of reading
- kilowatt: latest energy data for a sensor
When no error occurs
- Returns latest energy data for one sensor
- Status: 200 OK
When error occurs
- No latest energy data or invalid esensorid
- Status: 404 Not Found
GET /energy/sensors
Path to endpoint
GET /energy/sensors
Required values
None
Return values
Returns a JSON array:
- esensorid: for all sensors
When no error occurs
- Returns all sensors
- Status: 200 OK
When error occurs
- No sensors exist or database error
- Status: 404 Not Found
1. Setup
2. Standards
- Coding Conventions
- Issues
- Branch creation
- Reviews
- Implementation Standards
- [WIP] Creating new databases
- Localization
3. Models and Diagrams
4. Testing
- Testing methodology
- Testing Architecture
- Testing frontend with Playwright
- Integration testing utilizing testcontainers, xUnit and ASP.NET core webhost
5. Documentation
- Documentation for service endpoints
- API documentation
- Webpage Design
- Secrets and .env
- Evaluations
- Installation and Rebuild script documentation
6. Guides and How-to's
7. Micro Service Mockup Api
- Guidelines Mircro Service Mockup
- Documentation of useTemperature/useTemperatureTimeSeries mockup sensor