{-# 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.AndroidEnterprise.Enterprises.SendTestPushNotification
(
EnterprisesSendTestPushNotificationResource
, enterprisesSendTestPushNotification
, EnterprisesSendTestPushNotification
, estpnEnterpriseId
) where
import Network.Google.AndroidEnterprise.Types
import Network.Google.Prelude
type EnterprisesSendTestPushNotificationResource =
"androidenterprise" :>
"v1" :>
"enterprises" :>
Capture "enterpriseId" Text :>
"sendTestPushNotification" :>
QueryParam "alt" AltJSON :>
Post '[JSON]
EnterprisesSendTestPushNotificationResponse
newtype EnterprisesSendTestPushNotification = EnterprisesSendTestPushNotification'
{ _estpnEnterpriseId :: Text
} deriving (Eq,Show,Data,Typeable,Generic)
enterprisesSendTestPushNotification
:: Text
-> EnterprisesSendTestPushNotification
enterprisesSendTestPushNotification pEstpnEnterpriseId_ =
EnterprisesSendTestPushNotification'
{ _estpnEnterpriseId = pEstpnEnterpriseId_
}
estpnEnterpriseId :: Lens' EnterprisesSendTestPushNotification Text
estpnEnterpriseId
= lens _estpnEnterpriseId
(\ s a -> s{_estpnEnterpriseId = a})
instance GoogleRequest
EnterprisesSendTestPushNotification where
type Rs EnterprisesSendTestPushNotification =
EnterprisesSendTestPushNotificationResponse
type Scopes EnterprisesSendTestPushNotification =
'["https://www.googleapis.com/auth/androidenterprise"]
requestClient
EnterprisesSendTestPushNotification'{..}
= go _estpnEnterpriseId (Just AltJSON)
androidEnterpriseService
where go
= buildClient
(Proxy ::
Proxy EnterprisesSendTestPushNotificationResource)
mempty