{-# 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.DataTransfer.Applications.Get
(
ApplicationsGetResource
, applicationsGet
, ApplicationsGet
, agApplicationId
) where
import Network.Google.DataTransfer.Types
import Network.Google.Prelude
type ApplicationsGetResource =
"admin" :>
"datatransfer" :>
"v1" :>
"applications" :>
Capture "applicationId" (Textual Int64) :>
QueryParam "alt" AltJSON :> Get '[JSON] Application
newtype ApplicationsGet = ApplicationsGet'
{ _agApplicationId :: Textual Int64
} deriving (Eq,Show,Data,Typeable,Generic)
applicationsGet
:: Int64
-> ApplicationsGet
applicationsGet pAgApplicationId_ =
ApplicationsGet'
{ _agApplicationId = _Coerce # pAgApplicationId_
}
agApplicationId :: Lens' ApplicationsGet Int64
agApplicationId
= lens _agApplicationId
(\ s a -> s{_agApplicationId = a})
. _Coerce
instance GoogleRequest ApplicationsGet where
type Rs ApplicationsGet = Application
type Scopes ApplicationsGet =
'["https://www.googleapis.com/auth/admin.datatransfer",
"https://www.googleapis.com/auth/admin.datatransfer.readonly"]
requestClient ApplicationsGet'{..}
= go _agApplicationId (Just AltJSON)
dataTransferService
where go
= buildClient
(Proxy :: Proxy ApplicationsGetResource)
mempty