1

When someone has asked me in an interview preparation 'What is RESTful?' are they referring to Rest Api?

REST is an architecture style for designing networked applications. An architectural style called REST (Representational State Transfer) advocates that web applications should use HTTP as it was originally envisioned. Lookups should use GETrequests. PUT, POST, and DELETE requests should be used for creation, mutation, and deletion.

Sami Kuhmonen
  • 30,146
  • 9
  • 61
  • 74
John
  • 3,965
  • 21
  • 77
  • 163

1 Answers1

2

In common use, "restful" means applying the principles of Representational State Transfer as originally proposed by Roy Fielding. For the most part, this is grey scale. Few applications fully implement every principle for the full application.

In contrast, when people say "REST API" they usually mean an HTTP computer-to-computer API for automated requests and responses. These APIs may not be restful at all (i.e. they may be stateful).

The two terms overlap somewhat. HTTP 1.1 and later were designed with restful principles in mind.

Summary: When someone asks if you have a REST API, they usually want to know whether you have some easily parsed computer-facing API over HTTP (as opposed to a human-facing HTML API). However, if someone asks whether your application is restful, they are usually referring to the architectural principles.

Raymond Hettinger
  • 216,523
  • 63
  • 388
  • 485