{-# 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.AppEngine.Apps.AuthorizedCertificates.Create
(
AppsAuthorizedCertificatesCreateResource
, appsAuthorizedCertificatesCreate
, AppsAuthorizedCertificatesCreate
, aaccXgafv
, aaccUploadProtocol
, aaccAccessToken
, aaccUploadType
, aaccPayload
, aaccAppsId
, aaccCallback
) where
import Network.Google.AppEngine.Types
import Network.Google.Prelude
type AppsAuthorizedCertificatesCreateResource =
"v1" :>
"apps" :>
Capture "appsId" Text :>
"authorizedCertificates" :>
QueryParam "$.xgafv" Xgafv :>
QueryParam "upload_protocol" Text :>
QueryParam "access_token" Text :>
QueryParam "uploadType" Text :>
QueryParam "callback" Text :>
QueryParam "alt" AltJSON :>
ReqBody '[JSON] AuthorizedCertificate :>
Post '[JSON] AuthorizedCertificate
data AppsAuthorizedCertificatesCreate = AppsAuthorizedCertificatesCreate'
{ _aaccXgafv :: !(Maybe Xgafv)
, _aaccUploadProtocol :: !(Maybe Text)
, _aaccAccessToken :: !(Maybe Text)
, _aaccUploadType :: !(Maybe Text)
, _aaccPayload :: !AuthorizedCertificate
, _aaccAppsId :: !Text
, _aaccCallback :: !(Maybe Text)
} deriving (Eq,Show,Data,Typeable,Generic)
appsAuthorizedCertificatesCreate
:: AuthorizedCertificate
-> Text
-> AppsAuthorizedCertificatesCreate
appsAuthorizedCertificatesCreate pAaccPayload_ pAaccAppsId_ =
AppsAuthorizedCertificatesCreate'
{ _aaccXgafv = Nothing
, _aaccUploadProtocol = Nothing
, _aaccAccessToken = Nothing
, _aaccUploadType = Nothing
, _aaccPayload = pAaccPayload_
, _aaccAppsId = pAaccAppsId_
, _aaccCallback = Nothing
}
aaccXgafv :: Lens' AppsAuthorizedCertificatesCreate (Maybe Xgafv)
aaccXgafv
= lens _aaccXgafv (\ s a -> s{_aaccXgafv = a})
aaccUploadProtocol :: Lens' AppsAuthorizedCertificatesCreate (Maybe Text)
aaccUploadProtocol
= lens _aaccUploadProtocol
(\ s a -> s{_aaccUploadProtocol = a})
aaccAccessToken :: Lens' AppsAuthorizedCertificatesCreate (Maybe Text)
aaccAccessToken
= lens _aaccAccessToken
(\ s a -> s{_aaccAccessToken = a})
aaccUploadType :: Lens' AppsAuthorizedCertificatesCreate (Maybe Text)
aaccUploadType
= lens _aaccUploadType
(\ s a -> s{_aaccUploadType = a})
aaccPayload :: Lens' AppsAuthorizedCertificatesCreate AuthorizedCertificate
aaccPayload
= lens _aaccPayload (\ s a -> s{_aaccPayload = a})
aaccAppsId :: Lens' AppsAuthorizedCertificatesCreate Text
aaccAppsId
= lens _aaccAppsId (\ s a -> s{_aaccAppsId = a})
aaccCallback :: Lens' AppsAuthorizedCertificatesCreate (Maybe Text)
aaccCallback
= lens _aaccCallback (\ s a -> s{_aaccCallback = a})
instance GoogleRequest
AppsAuthorizedCertificatesCreate where
type Rs AppsAuthorizedCertificatesCreate =
AuthorizedCertificate
type Scopes AppsAuthorizedCertificatesCreate =
'["https://www.googleapis.com/auth/cloud-platform"]
requestClient AppsAuthorizedCertificatesCreate'{..}
= go _aaccAppsId _aaccXgafv _aaccUploadProtocol
_aaccAccessToken
_aaccUploadType
_aaccCallback
(Just AltJSON)
_aaccPayload
appEngineService
where go
= buildClient
(Proxy ::
Proxy AppsAuthorizedCertificatesCreateResource)
mempty