3 ms·
Being RESTful and the data encoding used are largely orthogonal aspects of an API. Wikipedia RESTful article says: > The formal REST constraints are as follow
by elcritch 1y ago
Being RESTful and the data encoding used are largely orthogonal aspects of an API.
Wikipedia RESTful article says:
> The formal REST constraints are as follows:[10]
> Client/Server – Clients are separated from servers by a well-defined interface
> Stateless – A specific client does not consume server storage when the client is "at rest"
> Cache – Responses indicate their own cacheability
> Uniform interface
> Layered system – A client cannot ordinarily tell whether it is connected directly to the end server, or to an intermediary along the way
- dustbunny 1y agoThe key line is actually this: >An application that adheres to the REST architectural constraints may be informally described as RESTful, although this term is more commonly associated with the design of HTTP-based APIs and what are widely considered best practices regarding the "verbs" (HTTP methods) a resource responds to, while having little to do with REST as originally formulated—and is often even at odds with the concept.
- elcritch 1y agoTaking that to mean you disagree. However using HTTP verbs has nothing to do with using JSON or not. Notice it says "HTTP" not "HTML" APIs.