{-# 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.Services.Versions.Create
(
AppsServicesVersionsCreateResource
, appsServicesVersionsCreate
, AppsServicesVersionsCreate
, asvcXgafv
, asvcUploadProtocol
, asvcAccessToken
, asvcUploadType
, asvcPayload
, asvcAppsId
, asvcServicesId
, asvcCallback
) where
import Network.Google.AppEngine.Types
import Network.Google.Prelude
type AppsServicesVersionsCreateResource =
"v1" :>
"apps" :>
Capture "appsId" Text :>
"services" :>
Capture "servicesId" Text :>
"versions" :>
QueryParam "$.xgafv" Xgafv :>
QueryParam "upload_protocol" Text :>
QueryParam "access_token" Text :>
QueryParam "uploadType" Text :>
QueryParam "callback" Text :>
QueryParam "alt" AltJSON :>
ReqBody '[JSON] Version :> Post '[JSON] Operation
data AppsServicesVersionsCreate = AppsServicesVersionsCreate'
{ _asvcXgafv :: !(Maybe Xgafv)
, _asvcUploadProtocol :: !(Maybe Text)
, _asvcAccessToken :: !(Maybe Text)
, _asvcUploadType :: !(Maybe Text)
, _asvcPayload :: !Version
, _asvcAppsId :: !Text
, _asvcServicesId :: !Text
, _asvcCallback :: !(Maybe Text)
} deriving (Eq,Show,Data,Typeable,Generic)
appsServicesVersionsCreate
:: Version
-> Text
-> Text
-> AppsServicesVersionsCreate
appsServicesVersionsCreate pAsvcPayload_ pAsvcAppsId_ pAsvcServicesId_ =
AppsServicesVersionsCreate'
{ _asvcXgafv = Nothing
, _asvcUploadProtocol = Nothing
, _asvcAccessToken = Nothing
, _asvcUploadType = Nothing
, _asvcPayload = pAsvcPayload_
, _asvcAppsId = pAsvcAppsId_
, _asvcServicesId = pAsvcServicesId_
, _asvcCallback = Nothing
}
asvcXgafv :: Lens' AppsServicesVersionsCreate (Maybe Xgafv)
asvcXgafv
= lens _asvcXgafv (\ s a -> s{_asvcXgafv = a})
asvcUploadProtocol :: Lens' AppsServicesVersionsCreate (Maybe Text)
asvcUploadProtocol
= lens _asvcUploadProtocol
(\ s a -> s{_asvcUploadProtocol = a})
asvcAccessToken :: Lens' AppsServicesVersionsCreate (Maybe Text)
asvcAccessToken
= lens _asvcAccessToken
(\ s a -> s{_asvcAccessToken = a})
asvcUploadType :: Lens' AppsServicesVersionsCreate (Maybe Text)
asvcUploadType
= lens _asvcUploadType
(\ s a -> s{_asvcUploadType = a})
asvcPayload :: Lens' AppsServicesVersionsCreate Version
asvcPayload
= lens _asvcPayload (\ s a -> s{_asvcPayload = a})
asvcAppsId :: Lens' AppsServicesVersionsCreate Text
asvcAppsId
= lens _asvcAppsId (\ s a -> s{_asvcAppsId = a})
asvcServicesId :: Lens' AppsServicesVersionsCreate Text
asvcServicesId
= lens _asvcServicesId
(\ s a -> s{_asvcServicesId = a})
asvcCallback :: Lens' AppsServicesVersionsCreate (Maybe Text)
asvcCallback
= lens _asvcCallback (\ s a -> s{_asvcCallback = a})
instance GoogleRequest AppsServicesVersionsCreate
where
type Rs AppsServicesVersionsCreate = Operation
type Scopes AppsServicesVersionsCreate =
'["https://www.googleapis.com/auth/cloud-platform"]
requestClient AppsServicesVersionsCreate'{..}
= go _asvcAppsId _asvcServicesId _asvcXgafv
_asvcUploadProtocol
_asvcAccessToken
_asvcUploadType
_asvcCallback
(Just AltJSON)
_asvcPayload
appEngineService
where go
= buildClient
(Proxy :: Proxy AppsServicesVersionsCreateResource)
mempty