json :: (MonadThrow m, MonadIO m, FromJSON a) => Session -> Request -> m a
json session req =
  doRequest True session req httpJSONEither processBody
  where
    processBody (Left e) = throwM e
    processBody (Right res) = return res
json :: (MonadThrow m, MonadIO m, FromJSON a) => Session -> Request -> m a
json session req =
  doRequest True session req httpJSONEither processBody
  where
    processBody (Left e) = throwM e
    processBody (Right res) = return res
json session req =
  doRequest True session req httpJSONEither processBody
  where
    processBody (Left e) = throwM e
    processBody (Right res) = return res