This is a single archived entry from Stefan Tilkov’s blog. For more up-to-date content, check out my author page at INNOQ, which has more information about me and also contains a list of published talks, podcasts, and articles. Or you can check out the full archive.

REST Not for Humans?

Stefan Tilkov,

Dave Thomas writes (emphasis mine):

Does that mean I’m down on the RESTful, CRUD based approach to application development? Not at all. For some categories of application, I think it’s a great way of structuring your code. But REST isn’t designed for talking to people.

Huh?

That’s definitely the first time I’ve heard this assertion — usually, it’s just the other way around.

There’s nothing unRESTful in returning an HTML “view” representation at http://example.com/employees/1, and a form to edit the same resource at http://example.com/employees/1;edit — provided you view these two things as different resources, and not two representations of the same resource. This is is a somewhat philosophical question. Even more importantly, reducing REST to back-end logic only seems to stress the (pretty broken) CRUD analogy way too much for my taste, which will ultimately lead to misunderstandings.