Energy_Management_V2

Get the quarter-hour energy totals of a single energy management device.

The active/reactive values are absolute cumulative counters (totalizers)
as read from the meter, not the consumption of each period. To get the
consumption of an interval, subtract the value at the start from the value
at the end.

You can enter a range of dates to get the data for that period.

/v2/energy_managements/<dev-id>/?start=XXX&end=XXX

Arguments

  • dev_id [*]: Device id number

  • start: (Optional) (yyyy-mm-dd hh:ii:ss) Start date of search interval.
    If you only enter the start date it will show the reading of that moment.

  • end: (Optional) (yyyy-mm-dd hh:ii:ss) End date of search interval.
    Can not be greater than the current date or the difference
    between dates can not be greater than 32 days
  • fields: (Optional) Comma-separated list of variables to return, with or
    without the table prefix (e.g. active_imported). Datetime and
    devices_id are always returned. Unknown fields return 400.

Response

JSON object with the result. May return the following errors:

  • 404 Not found : No device found or don't have rights to get data
  • 400 Bad Dates: Dates entered are incorrect

Example

GET /v2/energy_managements/5/ HTTP/1.1
Host: apiexternal.mvscada.app
MV-API-Key: xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
Content-Type: application/json

Response

{
    "plant": 1,
    "devices_id": 5,
    "start": "2026-10-16 10:30:00",
    "end": "",
    "energy_managements": [
        {
            "devices_id": 5,
            "data_energy_management_datetime": "2026-10-16 10:30:00",
            "data_energy_management_active_imported": 123456,
            "data_energy_management_active_exported": 789012,
            "data_energy_management_reactive_Q1": 10,
            "data_energy_management_reactive_Q2": 20,
            "data_energy_management_reactive_Q3": 30,
            "data_energy_management_reactive_Q4": 40,
            "data_energy_management_dst": 0
        }
    ]
}

Other examples

Get all data between requested dates

/v2/energy_managements/<dev-id>/?start=2026-03-30 08:00:00&end=2026-03-31 08:00:00


Get the quarter-hour energy totals of several energy management devices of the same plant.

Same values as /v2/energy_managements/<dev-id>/ (absolute cumulative counters).

/v2/energy_managements/?gid=XXX&start=XXX&end=XXX
/v2/energy_managements/?ids=XXX,YYY&start=XXX&end=XXX

Arguments

  • gid: Group (plant) id: returns all its energy management devices. Use gid or ids.
  • ids: Comma-separated device ids, all from the same plant.
  • start: (Optional) (yyyy-mm-dd hh:ii:ss) Start date of search interval.
    If you only enter the start date it will show the reading of that moment.
    Defaults to the current quarter.
  • end: (Optional) (yyyy-mm-dd hh:ii:ss) End date of search interval.
    Can not be greater than the current date or the difference
    between dates can not be greater than 1 day
  • fields: (Optional) Comma-separated list of variables to return, with or
    without the table prefix (e.g. active_imported). Datetime and
    devices_id are always returned. Unknown fields return 400.

Response

JSON object with the result, rows ordered by devices_id and datetime.
May return the following errors:

  • 404 Not found : No device found or don't have rights to get data
  • 400 Bad request: gid/ids, dates or fields are incorrect

Example

GET /v2/energy_managements/?gid=1&start=2026-10-16%2000:00:00&end=2026-10-16%2023:59:59&fields=active_imported,active_exported HTTP/1.1
Host: apiexternal.mvscada.app
MV-API-Key: xxxxxxxx-xxxx-xxxx-xxxx-xxxxxxxxxxxx
{
"group": 1,
"devices_id": [5, 6],
"start": "2026-10-16 00:00:00",
"end": "2026-10-16 23:59:59",
"energy_managements": [
    {"devices_id": 5, "data_energy_management_datetime": "2026-10-16 00:00:00", "data_energy_management_active_imported": 123456, "data_energy_management_active_exported": 789012},
    ...
]
}