What is an API?

A RESTful API is a web service from which an app can receive data. Typically, when you are dealing with APIs, such as YELP, they tend to change often. For our purposes, we want to use static files so that we can work on this project without having to be concerned about changes to the API. Therefore, most of the data we are going to use comes from the site, http://opentable.herokuapp.com/, which is not managed full time and does not change often. The site's API, however, is missing some data that we need; therefore, I have updated these files (which are in the project files for this chapter) to include that missing data.

APIs are typically in JSON format, and working with them is similar to working with plists. The transition from one to the other should be pretty seamless. Let's get familiar with the JSON format.