Usage example with google api required imports import WeatherApi import WeatherApi.Google With handler in case server will alow you to make few requests with one connection > let h = mkWeatherHandler $ initApi "key" > getWeather h "moscow" Right (Weather {tempF = 75.0, tempC = 24.0, humidity = "Humidity: 25%", windCondition = "Wind: S at 16 mph", condition = "Clear"}) Simple case > getWeather' (initApi "key") "moscow" Right (Weather {tempF = 75.0, tempC = 24.0, humidity = "Humidity: 25%", windCondition = "Wind: S at 16 mph", condition = "Clear"})