reading-notes

REST

REST is a set of architectural constraints, not a protocol or a standard. API developers can implement REST in a variety of ways.

When a client request is made via a RESTful API, it transfers a representation of the state of the resource to the requester or endpoint. This information, or representation, is delivered in one of several formats via HTTP: JSON (Javascript Object Notation), HTML, XLT, Python, PHP, or plain text. JSON is the most generally popular programming language to use because, despite its name, it’s language-agnostic, as well as readable by both humans and machines. *

REST stands for representational state transfer and was created by computer scientist Roy Fielding

In order for an API to be considered RESTful, it has to conform to these criteria:

Examples of API servers :

  1. locationiq which has some endpoints that helps in the determination of different locations around the world using the latitude and longitude lines. These end points might render all of the information about a specific location using JSON format as well as the map and routing for that location.
  2. weatherbit provides information about the weather in JSON format
  3. moviedb has a huge movie database, To register for an API key, click the from within your account settings page. You can also view the screenshots below for help:
  1. yelp The endpoint of this server returns up to 1000 businesses based on the provided search criteria. It has some basic information about the business.