{-# 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.YouTube.I18nRegions.List
(
I18nRegionsListResource
, i18nRegionsList
, I18nRegionsList
, irlPart
, irlHl
) where
import Network.Google.Prelude
import Network.Google.YouTube.Types
type I18nRegionsListResource =
"youtube" :>
"v3" :>
"i18nRegions" :>
QueryParam "part" Text :>
QueryParam "hl" Text :>
QueryParam "alt" AltJSON :>
Get '[JSON] I18nRegionListResponse
data I18nRegionsList = I18nRegionsList'
{ _irlPart :: !Text
, _irlHl :: !Text
} deriving (Eq,Show,Data,Typeable,Generic)
i18nRegionsList
:: Text
-> I18nRegionsList
i18nRegionsList pIrlPart_ =
I18nRegionsList'
{ _irlPart = pIrlPart_
, _irlHl = "en_US"
}
irlPart :: Lens' I18nRegionsList Text
irlPart = lens _irlPart (\ s a -> s{_irlPart = a})
irlHl :: Lens' I18nRegionsList Text
irlHl = lens _irlHl (\ s a -> s{_irlHl = a})
instance GoogleRequest I18nRegionsList where
type Rs I18nRegionsList = I18nRegionListResponse
type Scopes I18nRegionsList =
'["https://www.googleapis.com/auth/youtube",
"https://www.googleapis.com/auth/youtube.force-ssl",
"https://www.googleapis.com/auth/youtube.readonly",
"https://www.googleapis.com/auth/youtubepartner"]
requestClient I18nRegionsList'{..}
= go (Just _irlPart) (Just _irlHl) (Just AltJSON)
youTubeService
where go
= buildClient
(Proxy :: Proxy I18nRegionsListResource)
mempty