{-# 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.Reseller.Customers.Get
(
CustomersGetResource
, customersGet
, CustomersGet
, cgCustomerId
) where
import Network.Google.AppsReseller.Types
import Network.Google.Prelude
type CustomersGetResource =
"apps" :>
"reseller" :>
"v1" :>
"customers" :>
Capture "customerId" Text :>
QueryParam "alt" AltJSON :> Get '[JSON] Customer
newtype CustomersGet = CustomersGet'
{ _cgCustomerId :: Text
} deriving (Eq,Show,Data,Typeable,Generic)
customersGet
:: Text
-> CustomersGet
customersGet pCgCustomerId_ =
CustomersGet'
{ _cgCustomerId = pCgCustomerId_
}
cgCustomerId :: Lens' CustomersGet Text
cgCustomerId
= lens _cgCustomerId (\ s a -> s{_cgCustomerId = a})
instance GoogleRequest CustomersGet where
type Rs CustomersGet = Customer
type Scopes CustomersGet =
'["https://www.googleapis.com/auth/apps.order",
"https://www.googleapis.com/auth/apps.order.readonly"]
requestClient CustomersGet'{..}
= go _cgCustomerId (Just AltJSON) appsResellerService
where go
= buildClient (Proxy :: Proxy CustomersGetResource)
mempty