November 2017
Intermediate to advanced
670 pages
17h 35m
English
If we have our RESTful server running on port 8000, we can open our web browser to http://localhost:8000/cars/1 and see the following:
{ "index": 1, "car": "Honda Accord ES2"}
This is a representation of an IndexedCar struct. It has an index and a car make and model string.
Here's the actual IndexedCar struct in types.go:
IndexedCar struct { Index int `json:"index"` Car string` json:"car"`}