-- Hoogle documentation, generated by Haddock
-- See Hoogle, http://www.haskell.org/hoogle/
-- | Access data at OpenWeatherMap
--
-- Client library and command-line utility to access OpenWeatherMap
-- https://openweathermap.org
@package openweathermap
@version 0.0.0
module Web.OpenWeatherMap.Types.Wind
data Wind
Wind :: Double -> Double -> Wind
[speed] :: Wind -> Double
[deg] :: Wind -> Double
instance Data.Aeson.Types.FromJSON.FromJSON Web.OpenWeatherMap.Types.Wind.Wind
instance GHC.Generics.Generic Web.OpenWeatherMap.Types.Wind.Wind
instance GHC.Show.Show Web.OpenWeatherMap.Types.Wind.Wind
module Web.OpenWeatherMap.Types.Weather
data Weather
Weather :: Int -> String -> String -> String -> Weather
[id] :: Weather -> Int
[main] :: Weather -> String
[description] :: Weather -> String
[icon] :: Weather -> String
instance Data.Aeson.Types.FromJSON.FromJSON Web.OpenWeatherMap.Types.Weather.Weather
instance GHC.Generics.Generic Web.OpenWeatherMap.Types.Weather.Weather
instance GHC.Show.Show Web.OpenWeatherMap.Types.Weather.Weather
module Web.OpenWeatherMap.Types.Sys
data Sys
Sys :: Double -> Maybe String -> Int -> Int -> Sys
[message] :: Sys -> Double
[country] :: Sys -> Maybe String
[sunrise] :: Sys -> Int
[sunset] :: Sys -> Int
instance Data.Aeson.Types.FromJSON.FromJSON Web.OpenWeatherMap.Types.Sys.Sys
instance GHC.Generics.Generic Web.OpenWeatherMap.Types.Sys.Sys
instance GHC.Show.Show Web.OpenWeatherMap.Types.Sys.Sys
module Web.OpenWeatherMap.Types.Main
data Main
Main :: Double -> Double -> Double -> Double -> Double -> Maybe Double -> Maybe Double -> Main
[temp] :: Main -> Double
[pressure] :: Main -> Double
[humidity] :: Main -> Double
[temp_min] :: Main -> Double
[temp_max] :: Main -> Double
[sea_level] :: Main -> Maybe Double
[grnd_level] :: Main -> Maybe Double
instance Data.Aeson.Types.FromJSON.FromJSON Web.OpenWeatherMap.Types.Main.Main
instance GHC.Generics.Generic Web.OpenWeatherMap.Types.Main.Main
instance GHC.Show.Show Web.OpenWeatherMap.Types.Main.Main
module Web.OpenWeatherMap.Types.Coord
data Coord
Coord :: Double -> Double -> Coord
[lon] :: Coord -> Double
[lat] :: Coord -> Double
instance Data.Aeson.Types.FromJSON.FromJSON Web.OpenWeatherMap.Types.Coord.Coord
instance GHC.Generics.Generic Web.OpenWeatherMap.Types.Coord.Coord
instance GHC.Show.Show Web.OpenWeatherMap.Types.Coord.Coord
module Web.OpenWeatherMap.Types.Clouds
data Clouds
Clouds :: Double -> Clouds
[all] :: Clouds -> Double
instance Data.Aeson.Types.FromJSON.FromJSON Web.OpenWeatherMap.Types.Clouds.Clouds
instance GHC.Generics.Generic Web.OpenWeatherMap.Types.Clouds.Clouds
instance GHC.Show.Show Web.OpenWeatherMap.Types.Clouds.Clouds
module Web.OpenWeatherMap.Types.CurrentWeather
-- | Response to requests for current weather. Refer to
-- https://openweathermap.org/current.
data CurrentWeather
CurrentWeather :: Coord -> [Weather] -> String -> Main -> Wind -> Clouds -> Int -> Sys -> Int -> String -> Int -> CurrentWeather
[coord] :: CurrentWeather -> Coord
[weather] :: CurrentWeather -> [Weather]
[base] :: CurrentWeather -> String
[main] :: CurrentWeather -> Main
[wind] :: CurrentWeather -> Wind
[clouds] :: CurrentWeather -> Clouds
[dt] :: CurrentWeather -> Int
[sys] :: CurrentWeather -> Sys
[id] :: CurrentWeather -> Int
[name] :: CurrentWeather -> String
[cod] :: CurrentWeather -> Int
instance Data.Aeson.Types.FromJSON.FromJSON Web.OpenWeatherMap.Types.CurrentWeather.CurrentWeather
instance GHC.Generics.Generic Web.OpenWeatherMap.Types.CurrentWeather.CurrentWeather
instance GHC.Show.Show Web.OpenWeatherMap.Types.CurrentWeather.CurrentWeather
-- | Direct API functions. For API key (a.k.a appid) refer to
-- http://openweathermap.org/appid.
module Web.OpenWeatherMap.API
-- | Request current weather in the city.
weatherByName :: Maybe String -> Maybe String -> ClientM CurrentWeather
-- | Request current weather at the geographic coordinates (in decimal
-- degrees).
weatherByCoord :: Maybe Double -> Maybe Double -> Maybe String -> ClientM CurrentWeather
-- | High-level client functions perfoming requests to OpenWeatherMap API.
module Web.OpenWeatherMap.Client
-- | Various way to specify location.
data Location
-- | City name.
Name :: String -> Location
-- | Geographic coordinates: latitude and longitude.
Coord :: Double -> Double -> Location
-- | Make a request to OpenWeatherMap API and return current weather in
-- given location.
getWeather :: String -> Location -> IO (Either ServantError CurrentWeather)