{-# LANGUAGE DataKinds #-}
{-# LANGUAGE DeriveDataTypeable #-}
{-# LANGUAGE DeriveGeneric #-}
{-# LANGUAGE FlexibleInstances #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# LANGUAGE OverloadedStrings #-}
{-# LANGUAGE RecordWildCards #-}
{-# LANGUAGE TypeFamilies #-}
{-# LANGUAGE TypeOperators #-}
{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
{-# OPTIONS_GHC -fno-warn-unused-binds #-}
{-# OPTIONS_GHC -fno-warn-unused-imports #-}
module Network.Google.Resource.Books.Layers.Get
(
LayersGetResource
, layersGet
, LayersGet
, lgContentVersion
, lgVolumeId
, lgSource
, lgSummaryId
) where
import Network.Google.Books.Types
import Network.Google.Prelude
type LayersGetResource =
"books" :>
"v1" :>
"volumes" :>
Capture "volumeId" Text :>
"layersummary" :>
Capture "summaryId" Text :>
QueryParam "contentVersion" Text :>
QueryParam "source" Text :>
QueryParam "alt" AltJSON :> Get '[JSON] Layersummary
data LayersGet = LayersGet'
{ _lgContentVersion :: !(Maybe Text)
, _lgVolumeId :: !Text
, _lgSource :: !(Maybe Text)
, _lgSummaryId :: !Text
} deriving (Eq,Show,Data,Typeable,Generic)
layersGet
:: Text
-> Text
-> LayersGet
layersGet pLgVolumeId_ pLgSummaryId_ =
LayersGet'
{ _lgContentVersion = Nothing
, _lgVolumeId = pLgVolumeId_
, _lgSource = Nothing
, _lgSummaryId = pLgSummaryId_
}
lgContentVersion :: Lens' LayersGet (Maybe Text)
lgContentVersion
= lens _lgContentVersion
(\ s a -> s{_lgContentVersion = a})
lgVolumeId :: Lens' LayersGet Text
lgVolumeId
= lens _lgVolumeId (\ s a -> s{_lgVolumeId = a})
lgSource :: Lens' LayersGet (Maybe Text)
lgSource = lens _lgSource (\ s a -> s{_lgSource = a})
lgSummaryId :: Lens' LayersGet Text
lgSummaryId
= lens _lgSummaryId (\ s a -> s{_lgSummaryId = a})
instance GoogleRequest LayersGet where
type Rs LayersGet = Layersummary
type Scopes LayersGet =
'["https://www.googleapis.com/auth/books"]
requestClient LayersGet'{..}
= go _lgVolumeId _lgSummaryId _lgContentVersion
_lgSource
(Just AltJSON)
booksService
where go
= buildClient (Proxy :: Proxy LayersGetResource)
mempty