{-# 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.AndroidPublisher.Edits.APKs.Addexternallyhosted
(
EditsAPKsAddexternallyhostedResource
, editsAPKsAddexternallyhosted
, EditsAPKsAddexternallyhosted
, eapkaPackageName
, eapkaPayload
, eapkaEditId
) where
import Network.Google.AndroidPublisher.Types
import Network.Google.Prelude
type EditsAPKsAddexternallyhostedResource =
"androidpublisher" :>
"v3" :>
"applications" :>
Capture "packageName" Text :>
"edits" :>
Capture "editId" Text :>
"apks" :>
"externallyHosted" :>
QueryParam "alt" AltJSON :>
ReqBody '[JSON] APKsAddExternallyHostedRequest :>
Post '[JSON] APKsAddExternallyHostedResponse
data EditsAPKsAddexternallyhosted = EditsAPKsAddexternallyhosted'
{ _eapkaPackageName :: !Text
, _eapkaPayload :: !APKsAddExternallyHostedRequest
, _eapkaEditId :: !Text
} deriving (Eq,Show,Data,Typeable,Generic)
editsAPKsAddexternallyhosted
:: Text
-> APKsAddExternallyHostedRequest
-> Text
-> EditsAPKsAddexternallyhosted
editsAPKsAddexternallyhosted pEapkaPackageName_ pEapkaPayload_ pEapkaEditId_ =
EditsAPKsAddexternallyhosted'
{ _eapkaPackageName = pEapkaPackageName_
, _eapkaPayload = pEapkaPayload_
, _eapkaEditId = pEapkaEditId_
}
eapkaPackageName :: Lens' EditsAPKsAddexternallyhosted Text
eapkaPackageName
= lens _eapkaPackageName
(\ s a -> s{_eapkaPackageName = a})
eapkaPayload :: Lens' EditsAPKsAddexternallyhosted APKsAddExternallyHostedRequest
eapkaPayload
= lens _eapkaPayload (\ s a -> s{_eapkaPayload = a})
eapkaEditId :: Lens' EditsAPKsAddexternallyhosted Text
eapkaEditId
= lens _eapkaEditId (\ s a -> s{_eapkaEditId = a})
instance GoogleRequest EditsAPKsAddexternallyhosted
where
type Rs EditsAPKsAddexternallyhosted =
APKsAddExternallyHostedResponse
type Scopes EditsAPKsAddexternallyhosted =
'["https://www.googleapis.com/auth/androidpublisher"]
requestClient EditsAPKsAddexternallyhosted'{..}
= go _eapkaPackageName _eapkaEditId (Just AltJSON)
_eapkaPayload
androidPublisherService
where go
= buildClient
(Proxy :: Proxy EditsAPKsAddexternallyhostedResource)
mempty