{-# 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.Directory.Users.List
(
UsersListResource
, usersList
, UsersList
, ulEvent
, ulOrderBy
, ulViewType
, ulCustomFieldMask
, ulDomain
, ulShowDeleted
, ulSortOrder
, ulCustomer
, ulQuery
, ulProjection
, ulPageToken
, ulMaxResults
) where
import Network.Google.Directory.Types
import Network.Google.Prelude
type UsersListResource =
"admin" :>
"directory" :>
"v1" :>
"users" :>
QueryParam "event" UsersListEvent :>
QueryParam "orderBy" UsersListOrderBy :>
QueryParam "viewType" UsersListViewType :>
QueryParam "customFieldMask" Text :>
QueryParam "domain" Text :>
QueryParam "showDeleted" Text :>
QueryParam "sortOrder" UsersListSortOrder :>
QueryParam "customer" Text :>
QueryParam "query" Text :>
QueryParam "projection" UsersListProjection :>
QueryParam "pageToken" Text :>
QueryParam "maxResults" (Textual Int32) :>
QueryParam "alt" AltJSON :>
Get '[JSON] Users
data UsersList = UsersList'
{ _ulEvent :: !(Maybe UsersListEvent)
, _ulOrderBy :: !(Maybe UsersListOrderBy)
, _ulViewType :: !UsersListViewType
, _ulCustomFieldMask :: !(Maybe Text)
, _ulDomain :: !(Maybe Text)
, _ulShowDeleted :: !(Maybe Text)
, _ulSortOrder :: !(Maybe UsersListSortOrder)
, _ulCustomer :: !(Maybe Text)
, _ulQuery :: !(Maybe Text)
, _ulProjection :: !UsersListProjection
, _ulPageToken :: !(Maybe Text)
, _ulMaxResults :: !(Maybe (Textual Int32))
} deriving (Eq,Show,Data,Typeable,Generic)
usersList
:: UsersList
usersList =
UsersList'
{ _ulEvent = Nothing
, _ulOrderBy = Nothing
, _ulViewType = AdminView
, _ulCustomFieldMask = Nothing
, _ulDomain = Nothing
, _ulShowDeleted = Nothing
, _ulSortOrder = Nothing
, _ulCustomer = Nothing
, _ulQuery = Nothing
, _ulProjection = ULPBasic
, _ulPageToken = Nothing
, _ulMaxResults = Nothing
}
ulEvent :: Lens' UsersList (Maybe UsersListEvent)
ulEvent = lens _ulEvent (\ s a -> s{_ulEvent = a})
ulOrderBy :: Lens' UsersList (Maybe UsersListOrderBy)
ulOrderBy
= lens _ulOrderBy (\ s a -> s{_ulOrderBy = a})
ulViewType :: Lens' UsersList UsersListViewType
ulViewType
= lens _ulViewType (\ s a -> s{_ulViewType = a})
ulCustomFieldMask :: Lens' UsersList (Maybe Text)
ulCustomFieldMask
= lens _ulCustomFieldMask
(\ s a -> s{_ulCustomFieldMask = a})
ulDomain :: Lens' UsersList (Maybe Text)
ulDomain = lens _ulDomain (\ s a -> s{_ulDomain = a})
ulShowDeleted :: Lens' UsersList (Maybe Text)
ulShowDeleted
= lens _ulShowDeleted
(\ s a -> s{_ulShowDeleted = a})
ulSortOrder :: Lens' UsersList (Maybe UsersListSortOrder)
ulSortOrder
= lens _ulSortOrder (\ s a -> s{_ulSortOrder = a})
ulCustomer :: Lens' UsersList (Maybe Text)
ulCustomer
= lens _ulCustomer (\ s a -> s{_ulCustomer = a})
ulQuery :: Lens' UsersList (Maybe Text)
ulQuery = lens _ulQuery (\ s a -> s{_ulQuery = a})
ulProjection :: Lens' UsersList UsersListProjection
ulProjection
= lens _ulProjection (\ s a -> s{_ulProjection = a})
ulPageToken :: Lens' UsersList (Maybe Text)
ulPageToken
= lens _ulPageToken (\ s a -> s{_ulPageToken = a})
ulMaxResults :: Lens' UsersList (Maybe Int32)
ulMaxResults
= lens _ulMaxResults (\ s a -> s{_ulMaxResults = a})
. mapping _Coerce
instance GoogleRequest UsersList where
type Rs UsersList = Users
type Scopes UsersList =
'["https://www.googleapis.com/auth/admin.directory.user",
"https://www.googleapis.com/auth/admin.directory.user.readonly"]
requestClient UsersList'{..}
= go _ulEvent _ulOrderBy (Just _ulViewType)
_ulCustomFieldMask
_ulDomain
_ulShowDeleted
_ulSortOrder
_ulCustomer
_ulQuery
(Just _ulProjection)
_ulPageToken
_ulMaxResults
(Just AltJSON)
directoryService
where go
= buildClient (Proxy :: Proxy UsersListResource)
mempty