📝 fix: plannings endpoints — document verified behavior, drop 404-on-empty gotcha #58
Loading…
Reference in a new issue
No description provided.
Delete branch "docs/plannings-endpoint-verified"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Re-verified live on 2026-09-06 with the probe account (1 site, 19 real devices, 13 device kinds) before touching the docs — both ROADMAP §1 claims about
/api/planningsturned out to be wrong:Findings
GET /api/plannings?deviceId={id}→ 200 on all 19 devices (paginated;contentempty for 17, one planning each for the washing machine & dishwasher). The claimed systematic500 Internal erroris not reproducible.GET /api/plannings?siteId={id}→ 200 paginated (no trailing slash). The trailing-slash variant/api/plannings/?siteId=→ 404No static resource api/plannings.— Spring's static-handler fallthrough. It 404s even for a site that has plannings, so the "404 on empty list" gotcha was a misdiagnosis.siteIdappears ignored — bogus or absent id still returns the authenticated user's plannings.Changes
docs/energy.comwatt.com/misc-endpoints.md— plannings section rewritten with the verified behaviour + dated correction notes (repo convention)docs/energy.comwatt.com/README.md— dropped the misdiagnosed gotcha (gotchas list) and corrected the 404 row in the error conventionsROADMAP.md— removed the two resolved §1 itemsDocs-only, no code. Tests: 133 passed.
Follow-up (out of scope here): ROADMAP §2.5 still says "Do not offer the
?deviceId=variant (500)" — that premise is now known false; should be updated when theget_plannings()client method is designed.WIP: 📝 fix: plannings endpoints — document verified behavior, drop 404-on-empty gotchato 📝 fix: plannings endpoints — document verified behavior, drop 404-on-empty gotcha05d97a860826dcc6c374