python-openevse-http
A Python library for communicating with OpenEVSE chargers via the HTTP API on ESP8266 and ESP32-based WiFi modules.
Features
- Asynchronous: Built on
aiohttpfor non-blocking I/O. - WebSocket Support: Real-time updates for charger status.
- Firmware Support: Compatible with ESP8266 (2.x) and ESP32 (4.x+) WiFi firmware.
- Comprehensive API:
- Query status and configuration.
- Manage manual overrides.
- Control charging claims and limits.
- Handle schedules.
- Shaper Toggle: Enable or disable the grid shaper feature (requires firmware 4.0.0+).
- Time Synchronization & RTC: Manage time, timezone, and NTP sync (requires firmware 4.0.0+).
- Event Logs: Retrieve diagnostic log blocks and log event history (requires firmware 4.0.0+).
- Certificates: Manage SSL/TLS Root CA and client certificates (requires firmware 4.0.0+).
Installation
pip install python_openevse_http
Quick Start
import asyncio
import aiohttp
from openevsehttp import OpenEVSE
async def main():
async with aiohttp.ClientSession() as session:
charger = OpenEVSE("192.168.1.30", session=session)
await charger.update()
print(f"Charger State: {charger.status}")
print(f"Current Charge: {charger.charge_current}A")
if charger.shaper_active:
print("Shaper is active, disabling...")
else:
print("Shaper is inactive, enabling...")
await charger.toggle_shaper()
await charger.ws_disconnect()
if __name__ == "__main__":
asyncio.run(main())
HTTPS and SSL Verification Options
If your OpenEVSE WiFi/ethernet module uses HTTPS, you can configure the client to connect securely using the ssl=True parameter:
# Connect securely using HTTPS (validating SSL/TLS certificates)
charger = OpenEVSE(
"192.168.1.30",
session=session,
ssl=True,
)
Bypassing SSL Verification (Self-Signed Certificates)
To bypass certificate verification:
# Connect using HTTPS, and disable certificate verification
charger = OpenEVSE(
"192.168.1.30",
session=session,
ssl=True,
ssl_verify=False,
)
GitHub API Token (Optional)
When performing firmware update checks (charger.firmware_check()) or automatic firmware updates (charger.update_firmware()), the library queries GitHub's Releases API. To avoid hitting unauthenticated rate limits (60 requests/hour), you can supply a GitHub personal access token (PAT):
# Provide a GitHub token during client initialization
charger = OpenEVSE(
"192.168.1.30",
session=session,
github_token="ghp_your_github_token_here",
)
# Or set / update dynamically via property
charger.github_token = "ghp_your_github_token_here"
# Or pass per-call
latest = await charger.firmware_check(github_token="ghp_your_github_token_here")
API Support Matrix
| Endpoint | Methods | Supported | Description |
|---|---|---|---|
/status |
GET, POST | ✅ | Real-time status, sensors, and Vehicle SoC pushing |
/config |
GET, POST | ✅ | System and WiFi configuration |
/override |
GET, POST, PATCH, DELETE | ✅ | Manual charging overrides & current limits |
/claims |
GET, POST, DELETE | ✅ | Client-based charging claims |
/schedule |
GET, POST, DELETE | ✅ | Charging schedule management (v4.0.0+) |
/limit |
GET, POST, DELETE | ✅ | Charge limits (Time, Energy, SoC) |
/shaper |
POST | ✅ | Grid shaper control (v4.0.0+) |
/restart |
POST | ✅ | Reboot WiFi gateway or EVSE module |
/divertmode |
POST | ✅ | Solar divert mode control |
/r (RAPI) |
POST | ✅ | Direct RAPI command interface |
/ws |
GET | ✅ | WebSocket real-time updates |
/time |
GET, POST | ✅ | RTC and NTP time settings (v4.0.0+) |
/settime |
POST | ✅ | Legacy time setting interface (v3.x / fallback to $S1 on v2.x) |
/logs |
GET | ✅ | Event log block bounds and block events (v4.0.0+) |
/emeter |
DELETE | ❌ | Energy meter reset |
/wifi |
GET, POST | ❌ | Network scanning and AP configuration |
/tesla |
GET | ❌ | Tesla vehicle integration |
/certificates |
GET, POST, DELETE | ✅ | SSL/TLS certificate management (v4.0.0+) |
/schedule/plan |
GET | ✅ | Schedule planning and optimization (v4.1.0+) |
/update |
POST | ✅ | Firmware update interface |
/relay/recovery |
POST | ✅ | Stuck relay recovery cycle (v5.1.0+ / $FK) |
/relay/reset |
POST | ✅ | Relay contact-life health estimation reset (v5.1.0+ / $FH) |
/cabletemp |
GET, POST | ✅ | Cable temperature monitor configuration and status (v5.1.0+) |
/rfid/add |
POST | ✅ | RFID tag pairing mode (v4.0.0+) |
/rfid/users |
GET, POST, DELETE | ✅ | RFID tag to user mappings (v5.0.0+) |
✅ = Fully Supported | ⚠️ = Partial Support | ❌ = Not yet implemented
License
This project is licensed under the Apache-2.0 License.
Metadata
Release files for python-openevse-http 1.7.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| python_openevse_http-1.7.0.tar.gz | 100.9 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| python_openevse_http-1.7.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 145.5 kB
Release files / python_openevse_http-1.7.0.tar.gz
| Download URL | python_openevse_http-1.7.0.tar.gz |
|---|---|
| Size | 100.9 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
435d2dbda322a36f8300fcacc931cc7de8669ce09326a97f5a8d88968c224c77
|
|
BLAKE2b-256 checksum How to use checksums |
113468bf69660b832d75e6d1cdb2f1b60cbc4caf2bbd741bf1bc87c42b5dffb2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Sep 28, 2026.
Transparency logRelease files / python_openevse_http-1.7.0-py3-none-any.whl
| Download URL | python_openevse_http-1.7.0-py3-none-any.whl |
|---|---|
| Size | 44.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
fe7b2d219c1b28e90374fb178919ce1e2d62ad1f151c430256b03a3736f7fa41
|
|
BLAKE2b-256 checksum How to use checksums |
39580bb29183dcb2f880aad30fabe86430870149e3bd678498cdf7d579111b6c
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
Yes |
| Uploaded via |
twine/7.0.0 CPython/3.13.14
|
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
PyPI Publish Attestation
PyPI verified that this artifact, at this checksum, originated from the publisher listed below.
Signed by GitHub Actions, verified by PyPI on Sep 28, 2026.
Transparency log