Errors
Laravel-style error responses.
v1 returns the default Laravel error bodies. Branch on the HTTP status; the messages are for humans.
| Status | Body | Meaning |
|---|---|---|
| 401 | { "message": "Unauthenticated." } | Missing or unknown token |
| 403 | { "message": "No company is linked to this API user." } | The token's user has no company or customer |
| 404 | { "message": "Not Found" } | Unknown route |
| 410 | { "message": "...", "documentation": "..." } | Removed endpoint; documentation links to the migration guide |
| 422 | { "message": "...", "errors": { "start": ["..."] } } | Validation failed, for example a wrong date format on get-stats. Messages are in Dutch unless ?locale=en |
| 429 | { "message": "Too Many Attempts." } | Rate limit hit |
Always send Accept: application/json. Without it, some errors come back as HTML redirects to the login page.
Deprecation headers
Every v1 response, errors included, announces the deprecation (RFC 9745) and, once the end date is set, the sunset (RFC 8594):
Deprecation: true
Link: <https://developers.woodyou.care/docs/v1/migrating-to-v2>; rel="deprecation"
Sunset: Wed, 31 Mar 2027 00:00:00 GMTSunset only appears after the end date has been announced. Log it: after that date v1 stops answering.