Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

REST API changes breaks integration - please document resp. keep API stable #799

Closed
7 tasks
GallusMax opened this issue Mar 24, 2023 · 4 comments
Closed
7 tasks
Labels
documentation Improvements or additions to documentation question Further information is requested resolved issue resolved

Comments

@GallusMax
Copy link

Zur Integration in andere Systeme ist eine REST API schön. Wenn die sich ändert, wirds schwierig..
Mir ist an den aktuellen Leistungswerten gelegen.

Mit dem aktiellen Release 0.5.66 war die Integration in ein Victron System recht einfach, weil andere Projekte die Werte unter /live auswerten .

Jetzt kommt der Bruch: in der Development Version (hier: 0.5.104) finden sich unter /live keine "live" Werte mehr. Scheinbar sind die Leistungsdaten nach /record/live umgezogen.
Selbstvertändlich sind Strukturänderungen manchmal sinnvoll, JSON Arrays sind nicht immer der Hit.

Dennoch meine Bitte:

  • Beibehalten der einmal gewählten Schnittstellen - zumindest innerhalb einer Versionsreihe (von 0.5.66 nach 0.5 .xx?)
  • Neue Strukturen dokumentieren und
  • idealerweise zunächst parallel unter neuer URL anbieten, vorhandene für den Releasewechsel abkündigen

Frage: was war die Motivation für die Array Struktur ? Parsern wird der Zugang so nicht leichter, oder?
{
"fld": "U_DC",
"unit": "V",
"val": "30.10"
},

Hardware

  • [ x] ESP8266
  • ESP32
  • Raspberry Pi

Software

  • [x ] AhoyDTU
  • OpenDTU

Version / Git SHA:

https://github.com/lumapu/ahoy/commits/25695fc
Version: 0.5.104 (dev)
Github Hash: 25695fc

Build & Flash Method:

  • Arduino
  • ESP Tools
  • [x ] Platform IO

Desktop OS:

  • [ x] Linux
  • Windows
  • Mac OS
@dtuuser
Copy link

dtuuser commented Mar 24, 2023

Hallo GallusMax,
vielleicht ist #737 hilfreich
Gruß

@lumapu
Copy link
Owner

lumapu commented Mar 25, 2023

Beibehalten der einmal gewählten Schnittstellen - zumindest innerhalb einer Versionsreihe (von 0.5.66 nach 0.5 .xx?)
Neue Strukturen dokumentieren und
idealerweise zunächst parallel unter neuer URL anbieten, vorhandene für den Releasewechsel abkündigen

würde ich sehr gerne machen, geht aber nicht in jedem Fall. Man beachte aber auch, dass wir hier sehr stark begrenzt an Ressourcen sind und daher auch die Änderungen rühren. Bei der Dokumentation können wir uns noch verbessern.

@lumapu lumapu added documentation Improvements or additions to documentation question Further information is requested resolved issue resolved labels Mar 25, 2023
@lumapu lumapu closed this as completed Mar 27, 2023
@dsteinkopf
Copy link

Ist die neue JSON-Struktur irgendwo dokumentiert? Ggf. freut mich auch ein Link auf eine hilfreiche Quellcode-Stelle. Danke sehr!

@lumapu
Copy link
Owner

lumapu commented Mar 28, 2023

Dokumentation hinkt leider etwas hinterher, hier der Quellcode

https://github.com/lumapu/ahoy/blob/main/src/web/RestApi.h

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation question Further information is requested resolved issue resolved
Projects
None yet
Development

No branches or pull requests

4 participants