tesla-0.7.4.0: Tesla API client.
Safe HaskellSafe-Inferred
LanguageHaskell2010

Tesla.Energy

Description

Access of energy-specific APIs.

Synopsis

Documentation

runEnergy :: MonadIO m => IO AuthInfo -> EnergyID -> Energy m a -> m a Source #

Run a Energy Monad with the given Vehicle ID

siteData :: (FromJSON j, MonadIO m) => Energy m j Source #

Fetch the "live_status" describing the current active state of an energy site.

siteConfig :: (FromJSON j, MonadIO m) => Energy m j Source #

Fetch the "site_info" describing the basic configuration of an energy site.

data Energy m a Source #

Energy Monad for accessing energy-specific things.

Instances

Instances details
MonadFail m => MonadFail (Energy m) Source # 
Instance details

Defined in Tesla.Energy

Methods

fail :: String -> Energy m a #

MonadIO m => MonadIO (Energy m) Source # 
Instance details

Defined in Tesla.Energy

Methods

liftIO :: IO a -> Energy m a #

Applicative m => Applicative (Energy m) Source # 
Instance details

Defined in Tesla.Energy

Methods

pure :: a -> Energy m a #

(<*>) :: Energy m (a -> b) -> Energy m a -> Energy m b #

liftA2 :: (a -> b -> c) -> Energy m a -> Energy m b -> Energy m c #

(*>) :: Energy m a -> Energy m b -> Energy m b #

(<*) :: Energy m a -> Energy m b -> Energy m a #

Functor m => Functor (Energy m) Source # 
Instance details

Defined in Tesla.Energy

Methods

fmap :: (a -> b) -> Energy m a -> Energy m b #

(<$) :: a -> Energy m b -> Energy m a #

Monad m => Monad (Energy m) Source # 
Instance details

Defined in Tesla.Energy

Methods

(>>=) :: Energy m a -> (a -> Energy m b) -> Energy m b #

(>>) :: Energy m a -> Energy m b -> Energy m b #

return :: a -> Energy m a #

MonadCatch m => MonadCatch (Energy m) Source # 
Instance details

Defined in Tesla.Energy

Methods

catch :: Exception e => Energy m a -> (e -> Energy m a) -> Energy m a #

MonadMask m => MonadMask (Energy m) Source # 
Instance details

Defined in Tesla.Energy

Methods

mask :: ((forall a. Energy m a -> Energy m a) -> Energy m b) -> Energy m b #

uninterruptibleMask :: ((forall a. Energy m a -> Energy m a) -> Energy m b) -> Energy m b #

generalBracket :: Energy m a -> (a -> ExitCase b -> Energy m c) -> (a -> Energy m b) -> Energy m (b, c) #

MonadThrow m => MonadThrow (Energy m) Source # 
Instance details

Defined in Tesla.Energy

Methods

throwM :: Exception e => e -> Energy m a #

MonadLogger m => MonadLogger (Energy m) Source # 
Instance details

Defined in Tesla.Energy

Methods

monadLoggerLog :: ToLogStr msg => Loc -> LogSource -> LogLevel -> msg -> Energy m ()

MonadUnliftIO m => MonadUnliftIO (Energy m) Source # 
Instance details

Defined in Tesla.Energy

Methods

withRunInIO :: ((forall a. Energy m a -> IO a) -> IO b) -> Energy m b

Orphan instances

(Monad m, MonadIO m, MonadReader EnergyEnv m) => HasTeslaAuth m Source # 
Instance details