A textbook introduction to RESTful Web Services, the Web and the HTTP protocol. There has been a lot of hype about REST lately, but very few people understand how to implement RESTful Web Services correctly and how the Web actually works. Presented at ThoughtWorks.
16. HYPERTEXT MARKUP LANGUAGE
16
<!doctype html>
<html>
<head>
<title>Example Hypertext Document</title>
</head>
<body>
<div>
<h1>Example Hypertext Document</h1>
<p>This is an example hypertext document to be
used for illustrative purposes.</p>
<p><a href=“http://example.org”>
Example Hyperlink</a></p>
</div>
</body>
</html>
26. RESOURCES
26
▫︎Can also represent abstract concepts:
▫︎Employees in a enterprise
▫︎Money transfers
▫︎Products in a online store
▫︎Calendar appointments
▫︎User accounts
43. HTTP CONTENT TYPES
43
▫︎Determine the type of the HTTP payload
▫︎text/html - HTML
▫︎text/plain - Plain Text
▫︎audio/mpeg3 - MP3 files
▫︎application/xml - XML
▫︎…
85. UNIFORM INTERFACE
85
▫︎Create: POST /employees
▫︎Read: GET /employees/alice
▫︎Update: PUT /employees/alice
▫︎Delete: DELETE /employees/alice
▫︎List: GET /employees
86. UNIFORM INTERFACE
86
▫︎Create: POST /resource
▫︎Read: GET /resource/{name}
▫︎Update: PUT /resource/{name}
▫︎Delete: DELETE /resource/{name}
▫︎List: GET /resource