Skip to content

Commit e79465f

Browse files
committed
edit api.yaml
1 parent 10e2e9f commit e79465f

File tree

1 file changed

+39
-1
lines changed

1 file changed

+39
-1
lines changed

api.yml

Lines changed: 39 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
openapi: 3.0.2
1+
openapi: 3.0.3
22
info:
33
title: OpenEVSE WiFi API
44
description: |
@@ -73,6 +73,42 @@ paths:
7373
offset: '+0000'
7474
tags:
7575
- Status
76+
post:
77+
operationId: postStatus
78+
summary: Update external data to EVSE status
79+
description: |
80+
The status endpoint can be called to post external data that should be updated by MQTT
81+
If MQTT is not an option, all external data needed can be updated from an HTTP POST request to /status endpoint.
82+
83+
Accepted parameters:
84+
{
85+
"voltage": int, // live voltage in V
86+
"shaper_live_pwr": int, // total household live power in W
87+
"solar": int, // divert solar production in W
88+
"grid_ie": int, // divert grid -import/+export in W
89+
"battery_level": int, // vehicle soc in %
90+
"battery_range": int, // vehicle range
91+
"time_to_full_charge" // vehicle charge ETA
92+
}
93+
94+
responses:
95+
'200':
96+
description: OK
97+
content:
98+
application/json:
99+
schema:
100+
$ref: ./models/Status.yaml
101+
examples:
102+
EVSE Status:
103+
"voltage": 220
104+
"shaper_live_pwr": 3400
105+
"solar": 3000
106+
"grid_ie": 3000
107+
"battery_level": 85
108+
"battery_range": 230
109+
"time_to_full_charge" 1590
110+
tags:
111+
- Status
76112
/ws:
77113
get:
78114
operationId: statusUpdates
@@ -87,6 +123,8 @@ paths:
87123
application/json:
88124
schema:
89125
$ref: ./models/Status.yaml
126+
'400':
127+
descritpion: Error
90128
tags:
91129
- Status
92130
/config:

0 commit comments

Comments
 (0)