Critique of REST?

There’s no complecting. A URL is just that. A uniform resource location. It could as well be opaque.

Here’s Fieldings critique on how REST is being misused that also sheds some light on putting information into URLs or how clients are supposed to build URLs.
http://roy.gbiv.com/untangled/2008/rest-apis-must-be-hypertext-driven

In particular:

A REST API must not define fixed resource names or hierarchies (an obvious coupling of client and server). Servers must have the freedom to control their own namespace. Instead, allow servers to instruct clients on how to construct appropriate URIs, such as is done in HTML forms and URI templates, by defining those instructions within media types and link relations.

Unfortunately many RESTish APIs rely on out-of-band information exclusively. Mostly because it is deemed too much work for both server and client to use HATEOS to guide a client.

2 Likes