Understanding Web API Protocols, Practices, and Styles

Design and Build Great Web APIs — by Mike Amundsen (17 / 127)

The Pragmatic Programmers
The Pragmatic Programmers

--

👈 Chapter 2 Understanding HTTP, REST, and APIs | TOC | Managing Files with Git 👉

Before jumping into the details of Git, let’s review the open standards and common practices that have helped make the Internet, and the web in particular, a great place to build and publish APIs. For that, I’ll cover three general topics:

  • The HTTP protocol
  • The common practices behind the success of the web
  • The REST style for designing and building HTTP-based applications
images/http/2020-09-12-http-circles.png

HTTP is an open standard that’s helped stabilize and power the web for about thirty years. HTTP isn’t the only open protocol used to build APIs on the Internet, but it is the most popular one to date, and we’ll use it for all the APIs in this book.

The web itself isn’t actually a standard. It’s more of a set of common patterns and practices initially established by Tim Berners-Lee when he first started to implement early versions of HTTP and HTML in 1989. Our APIs will follow those principles too.

Finally, Roy T. Fielding’s REST style for building applications over HTTP is even less than a standard or set of common…

--

--

The Pragmatic Programmers
The Pragmatic Programmers

We create timely, practical books and learning resources on classic and cutting-edge topics to help you practice your craft and accelerate your career.