{-# 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.DoubleClickBidManager.Queries.CreateQuery
(
QueriesCreateQueryResource
, queriesCreateQuery
, QueriesCreateQuery
, qcqPayload
) where
import Network.Google.DoubleClickBids.Types
import Network.Google.Prelude
type QueriesCreateQueryResource =
"doubleclickbidmanager" :>
"v1" :>
"query" :>
QueryParam "alt" AltJSON :>
ReqBody '[JSON] Query :> Post '[JSON] Query
newtype QueriesCreateQuery = QueriesCreateQuery'
{ _qcqPayload :: Query
} deriving (Eq,Show,Data,Typeable,Generic)
queriesCreateQuery
:: Query
-> QueriesCreateQuery
queriesCreateQuery pQcqPayload_ =
QueriesCreateQuery'
{ _qcqPayload = pQcqPayload_
}
qcqPayload :: Lens' QueriesCreateQuery Query
qcqPayload
= lens _qcqPayload (\ s a -> s{_qcqPayload = a})
instance GoogleRequest QueriesCreateQuery where
type Rs QueriesCreateQuery = Query
type Scopes QueriesCreateQuery =
'["https://www.googleapis.com/auth/doubleclickbidmanager"]
requestClient QueriesCreateQuery'{..}
= go (Just AltJSON) _qcqPayload
doubleClickBidsService
where go
= buildClient
(Proxy :: Proxy QueriesCreateQueryResource)
mempty