Every story and comment from the Hacker News API, in a layout borrowed from 2001.
A comment on Best practices for REST API design (2020). Parent comment
Handling Post and Patch differently can at least give a general guideline for "overwriting vs keeping fields on update."
The localisation part is trivial if you consider that APIs are to be consumed by machines - much harder, if you assume they're used for GUIs.
Error handling is easy to define right, but so tedious to implement....
1+n can be improved by "guessing" which nested ressources are going to be fetched, and include them "by default."
But you're right that those are decisions that need to me made, and can quickly be agonised on without adding much value....
There are no comments on this comment yet.
Handling Post and Patch differently can at least give a general guideline for "overwriting vs keeping fields on update."
The localisation part is trivial if you consider that APIs are to be consumed by machines - much harder, if you assume they're used for GUIs.
Error handling is easy to define right, but so tedious to implement....
1+n can be improved by "guessing" which nested ressources are going to be fetched, and include them "by default."
But you're right that those are decisions that need to me made, and can quickly be agonised on without adding much value....