Cities Model

ActionMethodResourceDescription
Get allGET/countries/:country_id/citiesGet all cities with country_id.
GetGET/countries/:country_id/cities/:city_idGet city with id country_id and city_id.
Create POST/countries/:country_id/citiesCreate a city with country_id.
Update PUT/countries/:country_id/cities/:city_idUpdate city with country_id and city_id.
Delete DELETE/countries/:country_id/cities/:city_idDelete city with country_id and city_id.

The city model is composed of the following attributes:

AttributeTypeRequiredDescriptionWhereable
namestringno, required to create.The city's name.Yes
administrator_idintegernoThe city's administrator. (User ID)Yes
enabledbooleannoThe city's status.Yes