List productions (filter by generator/date range)

GET /productions

List all productions, optionally filtered by generatorId and startDate/endDate (YYYY-MM-DD)

Query parameters

  • generatorId string

    Generator ID (UUID)

  • startDate string

    Start date (YYYY-MM-DD)

  • endDate string

    End date (YYYY-MM-DD)

Responses

  • 200 application/json

    OK

    Hide response attributes Show response attributes object
    • createdAt string
    • date string Required
    • generatorCapacity number
    • generatorId string
    • id string
    • isRenewable boolean
    • productionMw number Required

      Minimum value is 0.

    • typeName string
    • updatedAt string
  • 400 application/json

    Bad Request

    Hide response attributes Show response attributes object
    • code integer
    • error string
    • message string
  • 500 application/json

    Internal Server Error

    Hide response attributes Show response attributes object
    • code integer
    • error string
    • message string
GET /productions
curl \
 --request GET 'http://localhost/api/v1/productions'
Response examples (200)
[
  {
    "createdAt": "string",
    "date": "2025-09-03",
    "generatorCapacity": 100.5,
    "generatorId": "550e8400-e29b-41d4-a716-446655440001",
    "id": "550e8400-e29b-41d4-a716-446655440002",
    "isRenewable": true,
    "productionMw": 85.3,
    "typeName": "Solar",
    "updatedAt": "string"
  }
]
Response examples (400)
{
  "code": 400,
  "error": "Invalid input",
  "message": "The provided data is invalid"
}
Response examples (500)
{
  "code": 400,
  "error": "Invalid input",
  "message": "The provided data is invalid"
}