{-# 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.Classroom.Courses.Aliases.List
(
CoursesAliasesListResource
, coursesAliasesList
, CoursesAliasesList
, calaXgafv
, calaUploadProtocol
, calaCourseId
, calaAccessToken
, calaUploadType
, calaPageToken
, calaPageSize
, calaCallback
) where
import Network.Google.Classroom.Types
import Network.Google.Prelude
type CoursesAliasesListResource =
"v1" :>
"courses" :>
Capture "courseId" Text :>
"aliases" :>
QueryParam "$.xgafv" Xgafv :>
QueryParam "upload_protocol" Text :>
QueryParam "access_token" Text :>
QueryParam "uploadType" Text :>
QueryParam "pageToken" Text :>
QueryParam "pageSize" (Textual Int32) :>
QueryParam "callback" Text :>
QueryParam "alt" AltJSON :>
Get '[JSON] ListCourseAliasesResponse
data CoursesAliasesList = CoursesAliasesList'
{ _calaXgafv :: !(Maybe Xgafv)
, _calaUploadProtocol :: !(Maybe Text)
, _calaCourseId :: !Text
, _calaAccessToken :: !(Maybe Text)
, _calaUploadType :: !(Maybe Text)
, _calaPageToken :: !(Maybe Text)
, _calaPageSize :: !(Maybe (Textual Int32))
, _calaCallback :: !(Maybe Text)
} deriving (Eq,Show,Data,Typeable,Generic)
coursesAliasesList
:: Text
-> CoursesAliasesList
coursesAliasesList pCalaCourseId_ =
CoursesAliasesList'
{ _calaXgafv = Nothing
, _calaUploadProtocol = Nothing
, _calaCourseId = pCalaCourseId_
, _calaAccessToken = Nothing
, _calaUploadType = Nothing
, _calaPageToken = Nothing
, _calaPageSize = Nothing
, _calaCallback = Nothing
}
calaXgafv :: Lens' CoursesAliasesList (Maybe Xgafv)
calaXgafv
= lens _calaXgafv (\ s a -> s{_calaXgafv = a})
calaUploadProtocol :: Lens' CoursesAliasesList (Maybe Text)
calaUploadProtocol
= lens _calaUploadProtocol
(\ s a -> s{_calaUploadProtocol = a})
calaCourseId :: Lens' CoursesAliasesList Text
calaCourseId
= lens _calaCourseId (\ s a -> s{_calaCourseId = a})
calaAccessToken :: Lens' CoursesAliasesList (Maybe Text)
calaAccessToken
= lens _calaAccessToken
(\ s a -> s{_calaAccessToken = a})
calaUploadType :: Lens' CoursesAliasesList (Maybe Text)
calaUploadType
= lens _calaUploadType
(\ s a -> s{_calaUploadType = a})
calaPageToken :: Lens' CoursesAliasesList (Maybe Text)
calaPageToken
= lens _calaPageToken
(\ s a -> s{_calaPageToken = a})
calaPageSize :: Lens' CoursesAliasesList (Maybe Int32)
calaPageSize
= lens _calaPageSize (\ s a -> s{_calaPageSize = a})
. mapping _Coerce
calaCallback :: Lens' CoursesAliasesList (Maybe Text)
calaCallback
= lens _calaCallback (\ s a -> s{_calaCallback = a})
instance GoogleRequest CoursesAliasesList where
type Rs CoursesAliasesList =
ListCourseAliasesResponse
type Scopes CoursesAliasesList =
'["https://www.googleapis.com/auth/classroom.courses",
"https://www.googleapis.com/auth/classroom.courses.readonly"]
requestClient CoursesAliasesList'{..}
= go _calaCourseId _calaXgafv _calaUploadProtocol
_calaAccessToken
_calaUploadType
_calaPageToken
_calaPageSize
_calaCallback
(Just AltJSON)
classroomService
where go
= buildClient
(Proxy :: Proxy CoursesAliasesListResource)
mempty