{-# 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.AndroidDeviceProvisioning.Partners.Devices.FindByOwner
(
PartnersDevicesFindByOwnerResource
, partnersDevicesFindByOwner
, PartnersDevicesFindByOwner
, pdfboXgafv
, pdfboUploadProtocol
, pdfboAccessToken
, pdfboPartnerId
, pdfboUploadType
, pdfboPayload
, pdfboCallback
) where
import Network.Google.AndroidDeviceProvisioning.Types
import Network.Google.Prelude
type PartnersDevicesFindByOwnerResource =
"v1" :>
"partners" :>
Capture "partnerId" (Textual Int64) :>
"devices:findByOwner" :>
QueryParam "$.xgafv" Xgafv :>
QueryParam "upload_protocol" Text :>
QueryParam "access_token" Text :>
QueryParam "uploadType" Text :>
QueryParam "callback" Text :>
QueryParam "alt" AltJSON :>
ReqBody '[JSON] FindDevicesByOwnerRequest :>
Post '[JSON] FindDevicesByOwnerResponse
data PartnersDevicesFindByOwner = PartnersDevicesFindByOwner'
{ _pdfboXgafv :: !(Maybe Xgafv)
, _pdfboUploadProtocol :: !(Maybe Text)
, _pdfboAccessToken :: !(Maybe Text)
, _pdfboPartnerId :: !(Textual Int64)
, _pdfboUploadType :: !(Maybe Text)
, _pdfboPayload :: !FindDevicesByOwnerRequest
, _pdfboCallback :: !(Maybe Text)
} deriving (Eq,Show,Data,Typeable,Generic)
partnersDevicesFindByOwner
:: Int64
-> FindDevicesByOwnerRequest
-> PartnersDevicesFindByOwner
partnersDevicesFindByOwner pPdfboPartnerId_ pPdfboPayload_ =
PartnersDevicesFindByOwner'
{ _pdfboXgafv = Nothing
, _pdfboUploadProtocol = Nothing
, _pdfboAccessToken = Nothing
, _pdfboPartnerId = _Coerce # pPdfboPartnerId_
, _pdfboUploadType = Nothing
, _pdfboPayload = pPdfboPayload_
, _pdfboCallback = Nothing
}
pdfboXgafv :: Lens' PartnersDevicesFindByOwner (Maybe Xgafv)
pdfboXgafv
= lens _pdfboXgafv (\ s a -> s{_pdfboXgafv = a})
pdfboUploadProtocol :: Lens' PartnersDevicesFindByOwner (Maybe Text)
pdfboUploadProtocol
= lens _pdfboUploadProtocol
(\ s a -> s{_pdfboUploadProtocol = a})
pdfboAccessToken :: Lens' PartnersDevicesFindByOwner (Maybe Text)
pdfboAccessToken
= lens _pdfboAccessToken
(\ s a -> s{_pdfboAccessToken = a})
pdfboPartnerId :: Lens' PartnersDevicesFindByOwner Int64
pdfboPartnerId
= lens _pdfboPartnerId
(\ s a -> s{_pdfboPartnerId = a})
. _Coerce
pdfboUploadType :: Lens' PartnersDevicesFindByOwner (Maybe Text)
pdfboUploadType
= lens _pdfboUploadType
(\ s a -> s{_pdfboUploadType = a})
pdfboPayload :: Lens' PartnersDevicesFindByOwner FindDevicesByOwnerRequest
pdfboPayload
= lens _pdfboPayload (\ s a -> s{_pdfboPayload = a})
pdfboCallback :: Lens' PartnersDevicesFindByOwner (Maybe Text)
pdfboCallback
= lens _pdfboCallback
(\ s a -> s{_pdfboCallback = a})
instance GoogleRequest PartnersDevicesFindByOwner
where
type Rs PartnersDevicesFindByOwner =
FindDevicesByOwnerResponse
type Scopes PartnersDevicesFindByOwner = '[]
requestClient PartnersDevicesFindByOwner'{..}
= go _pdfboPartnerId _pdfboXgafv _pdfboUploadProtocol
_pdfboAccessToken
_pdfboUploadType
_pdfboCallback
(Just AltJSON)
_pdfboPayload
androidDeviceProvisioningService
where go
= buildClient
(Proxy :: Proxy PartnersDevicesFindByOwnerResource)
mempty