This REST API call will retrieve a list of all items of the book resource type. The response's JSON format in our example consists of an array of the book resource type. However, this return format is not the only way to return items. An alternate but more popular format consists of a JSON object with key "data" that consists of the actual results and any further keys that the server might want to send back in the response.
Let's now look at the simple format we will be using in our example:
// Request GET "<URL>/api/books/" // Response [ { "id": "1", "title": "book1", "link": "http://link-to-book-1.com" }, { "id": "2", "title": "book2", "link": "http://link-to-book-2.com" } ]