{-# 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.DNS.ResourceRecordSets.List
(
ResourceRecordSetsListResource
, resourceRecordSetsList
, ResourceRecordSetsList
, rrslProject
, rrslName
, rrslPageToken
, rrslType
, rrslManagedZone
, rrslMaxResults
) where
import Network.Google.DNS.Types
import Network.Google.Prelude
type ResourceRecordSetsListResource =
"dns" :>
"v2beta1" :>
"projects" :>
Capture "project" Text :>
"managedZones" :>
Capture "managedZone" Text :>
"rrsets" :>
QueryParam "name" Text :>
QueryParam "pageToken" Text :>
QueryParam "type" Text :>
QueryParam "maxResults" (Textual Int32) :>
QueryParam "alt" AltJSON :>
Get '[JSON] ResourceRecordSetsListResponse
data ResourceRecordSetsList = ResourceRecordSetsList'
{ _rrslProject :: !Text
, _rrslName :: !(Maybe Text)
, _rrslPageToken :: !(Maybe Text)
, _rrslType :: !(Maybe Text)
, _rrslManagedZone :: !Text
, _rrslMaxResults :: !(Maybe (Textual Int32))
} deriving (Eq,Show,Data,Typeable,Generic)
resourceRecordSetsList
:: Text
-> Text
-> ResourceRecordSetsList
resourceRecordSetsList pRrslProject_ pRrslManagedZone_ =
ResourceRecordSetsList'
{ _rrslProject = pRrslProject_
, _rrslName = Nothing
, _rrslPageToken = Nothing
, _rrslType = Nothing
, _rrslManagedZone = pRrslManagedZone_
, _rrslMaxResults = Nothing
}
rrslProject :: Lens' ResourceRecordSetsList Text
rrslProject
= lens _rrslProject (\ s a -> s{_rrslProject = a})
rrslName :: Lens' ResourceRecordSetsList (Maybe Text)
rrslName = lens _rrslName (\ s a -> s{_rrslName = a})
rrslPageToken :: Lens' ResourceRecordSetsList (Maybe Text)
rrslPageToken
= lens _rrslPageToken
(\ s a -> s{_rrslPageToken = a})
rrslType :: Lens' ResourceRecordSetsList (Maybe Text)
rrslType = lens _rrslType (\ s a -> s{_rrslType = a})
rrslManagedZone :: Lens' ResourceRecordSetsList Text
rrslManagedZone
= lens _rrslManagedZone
(\ s a -> s{_rrslManagedZone = a})
rrslMaxResults :: Lens' ResourceRecordSetsList (Maybe Int32)
rrslMaxResults
= lens _rrslMaxResults
(\ s a -> s{_rrslMaxResults = a})
. mapping _Coerce
instance GoogleRequest ResourceRecordSetsList where
type Rs ResourceRecordSetsList =
ResourceRecordSetsListResponse
type Scopes ResourceRecordSetsList =
'["https://www.googleapis.com/auth/cloud-platform",
"https://www.googleapis.com/auth/cloud-platform.read-only",
"https://www.googleapis.com/auth/ndev.clouddns.readonly",
"https://www.googleapis.com/auth/ndev.clouddns.readwrite"]
requestClient ResourceRecordSetsList'{..}
= go _rrslProject _rrslManagedZone _rrslName
_rrslPageToken
_rrslType
_rrslMaxResults
(Just AltJSON)
dNSService
where go
= buildClient
(Proxy :: Proxy ResourceRecordSetsListResource)
mempty