Skip to main content

Cities Model

A city belongs to a country and can be associated with an administrator and dropdown options. See the operation guide for complete operation schemas; this guide summarizes shared concepts.

Operations​

ActionMethodResource
ListGET/countries/{country}/cities
FindGET/countries/{country}/cities/{city}
CreatePOST/countries/{country}/cities
UpdatePUT/countries/{country}/cities/{city}
DeleteDELETE/countries/{country}/cities/{city}

Shared concepts​

  • name is required when a city is created and can be used in supported filters.
  • country_id identifies the parent country. For create and update requests, country_id comes from the route parameter before validation.
  • administrator_id can associate a user with the city and may be null.
  • enabled controls the city's status.
  • country, administrator, and options are relationships that list and find requests can expand through params.

The city operations described here are limited to role levels 0 and 1; do not assume broader access. Field presence varies by operation and requested relations, so this is not a complete response schema.