REST (Representational State Transfer) is a style of software architecture for distributed hypermedia systems such as the World Wide Web. It has increased in popularity relative to RPC architectures such as SOAP due to the intrinsic de-coupling of client from server that comes from having a uniform interface between heterogeneous systems.
(Not to be confused with restructuredtext or reST)
REST (REpresentational State Transfer) is an architectural style that uses identification of resources; manipulation of resources through representations; self-descriptive messages, and hypermedia as the engine of application state, to build distributed systems that are scalable and resilient to change.
The term was introduced and defined in 2000 by Roy Fielding in his doctoral dissertation. Fielding is one of the principal authors of the Hypertext Transfer Protocol (HTTP
) specification versions 1.0 and 1.1.
In simple language, REST
is an alternative to SOAP
based web services. Where SOAP
tries to model the exchange between client and server as calls to objects, REST
tries to be faithful to the web domain.
Resources
- Representational state transfer, on Wikipedia,
- Architectural Styles and
the Design of Network-based Software Architectures, Fielding's dissertation introducing
REST
, and his clarification regarding the necessary usage of hyper-text inREST
APIs - implementing-rest on Google Code.
- implementing-rest with Spring.
- How to GET a Cup of Coffee
Examples
A website's RESTful api is queried to find out information on a user, specified by a numerical ID.
Request Type: GET
http://www.api.website.com/users/12345
Returns, in a json format for this example:
{"username" : "theuser",
"userid" : 12345,
"first" : "George",
"last" : "Washington"}
Question Index
Searching
REST search interface and the idempotency of GET
RESTful URL design for search
Best practice for implementing long-running searches with REST
Querystring in REST Resource url
What is the best way to create RESTful complex queries?
Question on REST conventions: retrieving information where lots of params are needed
Resource Design
How to design a RESTful collection resource?
RESTful design of a resource with binary states
RESTFful/Resource Oriented Design
RESTful resource - accepts a list of objects
RESTful API creates a globally unique resource
REST's 'resource communication mechanisms' and 'on-the-fly' improvement of a client's knowledge of them
How to move a REST resource?
Media Types
REST Media type explosion
Creating hypermedia links in a custom media-type
Custom content types: XLink vs. Atom
Books
Related tags
- web-services
- http
- soap
- odata
- api
- restructuredtext (unrelated technology, but similar acronym)