public async Task <ActionResult <CityAdd> > AddCityInfo([FromBody] CityAdd cityToAdd) { var duplicate = await _service.FindDuplicate(cityToAdd.Name, cityToAdd.RegionName); if (duplicate == null) { var cityModel = _mapper.Map <City>(cityToAdd); _service.AddNewCity(cityModel); _service.SaveChanges(); return(Ok()); } else { return(BadRequest($"{cityToAdd.RegionName} already contains {cityToAdd.Name}.")); } }