GET /api/networks --> returns an array of all networks
GET /api/networks/:networkId --> returns an array of all stations belonging to a network
GET /api/stations/:stationId --> returns details of a specific stationId
GET /api/stations/:stationId/reviews --> returns all reviews in an array for that station
PUT /api/stations/:stationId --> returns the details of a specific station with an updated empty_slots field
-
{ emptySlots: Number, closed: Bool, safe: Bool }
POST /api/reviews/:networkId/:stationId
- accepts json
-
- Design the schema for the database
- Provide an API to list the networks
- Provide an API to get details on a specific network
- Provide an API to update the available slots in a specific location
- Provide an API to update that a location is closed
- Provide an API to update that a location is not safe for use
- Provide an API to allow users to share reviews on a specific location (no sign in needed).
You should be using the initial citibike API for seeding your data, you should not use it in any other way. In real time, the API should query your database and not communicate with the citybike API.
This means, you will need to create a seeding script that will consume the citibike API and fill your database with initial data in dev.