Flip Energy API
  1. Telemetry
Flip Energy API
  • Overview
  • Important concepts
  • Authentication
  • Enrollment process
  • End-user app design
  • Monitoring / Telemetry
  • Control
  • Change log
  • Mobile App API
    • Devices
      • Create Device
      • Read Devices
      • Read Device
      • Update Device
      • Delete Device
    • Enrollments
      • Create Enrollment
      • Read Enrollments
      • Read Enrollment
      • Delete Enrollment
    • Events
      • Read Events
      • Read Event
      • Update Event Participation
    • Programs
      • Read Programs
      • Read Program
    • Sites
      • Read Site
      • Update Site
  • Cloud API
    • Sites
      • Get Site Token
      • Get Sites
    • Commissioning
      • Commission Site And Devices
    • Sessions
      • Sessions
    • Commands
      • Command Created
      • Update Command Status
    • Programs
      • Read Programs
    • Telemetry
      • Report Battery Telemetry
        POST
    • Webhooks
      • Overview
      • List of events
      • Webhook headers
      • Schemas
        • Command
        • Enrollment
        • Event
  1. Telemetry

Report Battery Telemetry

Cloud Mock
https://mock.apidog.com/m1/479670-0-default
Cloud Mock
https://mock.apidog.com/m1/479670-0-default
POST
/v1/telemetry/BATTERY
Batch upload telemetry data points, with a maximum of 1,000 data points per request.
All the attributes must be sent.
In case the device was offline (is_online is set to false) and therefore no data was available, set all nullable attributes to null.
In case the device was online, all telemetry items must be supplied and must not be null.
The server will respond with a 200 in the majority of cases.
The response will list the status of saving each data point, using the same index each item had in the request.
If an item's status is FAILED, please correct the issue and resend it.
If the server does not understand the format of the request (i.e. the body is missing a list), then it will respond with a 400.

Request

Authorization
Provide your bearer token in the
Authorization
header when making requests to protected resources.
Example:
Authorization: Bearer ********************
Body Params application/json
start_time
string <date-time>
deprecated
Start time of the reporting interval of this report
duration_s
integer 
deprecated
Reporting interval duration, in seconds
telemetry
array[object (Telemetry) {20}] 
required
A per-device telemetry report
start_time
string <date-time>
required
duration_s
number 
required
device_id
string 
required
The unique ID you assigned to the device for which this telemetry report is generated.
last_is_online
boolean  | null 
optional
Is the device currently (as of the last data point for this interval) reachable and controllable from the cloud
last_mode
optional
The last mode active for the device at the end of the interval.
battery_last_power_charge_w
number  | null 
optional
Power consumed by the battery (charged) at the end of the interval, in watts.
>= 0
battery_last_power_discharge_w
number  | null 
optional
Power produced by the battery (discharged) at the end of the interval, in watts.
>= 0
battery_total_energy_charge_wh
number  | null 
optional
Total energy charged by the battery over the reporting interval, in watt-hours.
>= 0
battery_total_energy_discharge_wh
number  | null 
optional
Total energy discharged by the battery over the reporting interval, in watt-hours.
>= 0
battery_last_stored_energy_wh
number  | null 
optional
Energy stored in the battery at the end of the interval, in watt-hours.
>= 0
battery_last_capacity_energy_wh
number  | null 
optional
The maximum total amount of energy that can be stored in the battery at the end of the interval, taking into account its state of health, in watt-hours.
>= 0
battery_last_backup_reserve_percentage
number  | null 
deprecated
Backup reserve of the battery at the end of the interval, as a whole number from 0 to 100.
>= 0<= 100
battery_last_state_of_charge_percentage
number  | null 
optional
The state of charge of the battery at the end of the interval, as a whole number from 0 to 100. This can be provided as an alternative to battery_last_stored_energy_wh.
>= 0<= 100
battery_last_state_of_health_percentage
number  | null 
optional
The state of health of the battery at the end of the interval, as a whole number from 0 to 100. This can be provided as an alternative to battery_last_capacity_energy_wh.
>= 0<= 100
last_is_grid_online
boolean  | null 
optional
Is the grid for this site currently (as of the last data point for this interval) online (connected) or offline (disconnected / unavailable)
home_total_energy_wh
number  | null 
optional
Total energy consumed by the site over the reporting period, in watt-hours.
>= 0
home_last_power_w
number  | null 
optional
Power consumed by the home at the end of the interval, in watts.
>= 0
solar_total_energy_wh
number  | null 
optional
Total energy generated by the solar (photo-voltaic) devices at the site over the reporting interval, in watt-hours.
>= 0
solar_last_power_w
number  | null 
optional
Power generated by the solar PV at the end of the interval, in watts.
>= 0
oem_raw_data
object 
optional
Example
{
  "start_time": "2019-08-24T14:15:22Z",
  "duration_s": 0,
  "telemetry": [
    {
      "start_time": "2019-08-24T14:15:22Z",
      "duration_s": 0,
      "device_id": "string",
      "last_is_online": true,
      "last_mode": "BACKUP",
      "battery_last_power_charge_w": 0,
      "battery_last_power_discharge_w": 0,
      "battery_total_energy_charge_wh": 0,
      "battery_total_energy_discharge_wh": 0,
      "battery_last_stored_energy_wh": 0,
      "battery_last_capacity_energy_wh": 0,
      "battery_last_backup_reserve_percentage": 0,
      "battery_last_state_of_charge_percentage": 0,
      "battery_last_state_of_health_percentage": 0,
      "last_is_grid_online": true,
      "home_total_energy_wh": 0,
      "home_last_power_w": 0,
      "solar_total_energy_wh": 0,
      "solar_last_power_w": 0,
      "oem_raw_data": {
        "oem_identifier": "string"
      }
    }
  ]
}

Request samples

Shell
JavaScript
Java
Swift
Go
PHP
Python
HTTP
C
C#
Objective-C
Ruby
OCaml
Dart
R
Request Request Example
Shell
JavaScript
Java
Swift
curl --location --request POST 'https://mock.apidog.com/m1/479670-0-default/v1/telemetry/BATTERY' \
--header 'Content-Type: application/json' \
--data-raw '{
    "start_time": "2019-08-24T14:15:22Z",
    "duration_s": 0,
    "telemetry": [
        {
            "start_time": "2019-08-24T14:15:22Z",
            "duration_s": 0,
            "device_id": "string",
            "last_is_online": true,
            "last_mode": "BACKUP",
            "battery_last_power_charge_w": 0,
            "battery_last_power_discharge_w": 0,
            "battery_total_energy_charge_wh": 0,
            "battery_total_energy_discharge_wh": 0,
            "battery_last_stored_energy_wh": 0,
            "battery_last_capacity_energy_wh": 0,
            "battery_last_backup_reserve_percentage": 0,
            "battery_last_state_of_charge_percentage": 0,
            "battery_last_state_of_health_percentage": 0,
            "last_is_grid_online": true,
            "home_total_energy_wh": 0,
            "home_last_power_w": 0,
            "solar_total_energy_wh": 0,
            "solar_last_power_w": 0,
            "oem_raw_data": {
                "oem_identifier": "string"
            }
        }
    ]
}'

Responses

🟢200OK
application/json
Body
array of:
status
enum<string> 
required
Allowed values:
FAILEDOK
message
string  | null 
required
Example
[
  {
    "status": "FAILED",
    "message": "string"
  }
]
🟠400Invalid input
🟠404Record not found
Previous
Read Programs
Next
Overview
Built with