{-# 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.AdExchangeBuyer.Proposals.Get
(
ProposalsGetResource
, proposalsGet
, ProposalsGet
, pgProposalId
) where
import Network.Google.AdExchangeBuyer.Types
import Network.Google.Prelude
type ProposalsGetResource =
"adexchangebuyer" :>
"v1.4" :>
"proposals" :>
Capture "proposalId" Text :>
QueryParam "alt" AltJSON :> Get '[JSON] Proposal
newtype ProposalsGet = ProposalsGet'
{ _pgProposalId :: Text
} deriving (Eq,Show,Data,Typeable,Generic)
proposalsGet
:: Text
-> ProposalsGet
proposalsGet pPgProposalId_ =
ProposalsGet'
{ _pgProposalId = pPgProposalId_
}
pgProposalId :: Lens' ProposalsGet Text
pgProposalId
= lens _pgProposalId (\ s a -> s{_pgProposalId = a})
instance GoogleRequest ProposalsGet where
type Rs ProposalsGet = Proposal
type Scopes ProposalsGet =
'["https://www.googleapis.com/auth/adexchange.buyer"]
requestClient ProposalsGet'{..}
= go _pgProposalId (Just AltJSON)
adExchangeBuyerService
where go
= buildClient (Proxy :: Proxy ProposalsGetResource)
mempty