Пример #1
0
        public IActionResult GetClima(string nombreRegion)
        {
            try
            {
                Clima clima = WeatherHelper.GetClima(nombreRegion);


                return(Ok(clima));
            }
            catch (Exception)
            {
                return(StatusCode(StatusCodes.Status500InternalServerError));
            }
        }
Пример #2
0
        public IActionResult GetClima(float latitud, float longitud)
        {
            try
            {
                Clima clima = WeatherHelper.GetClima(latitud, longitud);


                return(Ok(clima));
            }
            catch (Exception)
            {
                return(StatusCode(StatusCodes.Status500InternalServerError));
            }
        }