{-# 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.SafeBrowsing.EncodedFullHashes.Get
(
EncodedFullHashesGetResource
, encodedFullHashesGet
, EncodedFullHashesGet
, efhgClientId
, efhgXgafv
, efhgUploadProtocol
, efhgAccessToken
, efhgEncodedRequest
, efhgUploadType
, efhgClientVersion
, efhgCallback
) where
import Network.Google.Prelude
import Network.Google.SafeBrowsing.Types
type EncodedFullHashesGetResource =
"v4" :>
"encodedFullHashes" :>
Capture "encodedRequest" Bytes :>
QueryParam "clientId" Text :>
QueryParam "$.xgafv" Xgafv :>
QueryParam "upload_protocol" Text :>
QueryParam "access_token" Text :>
QueryParam "uploadType" Text :>
QueryParam "clientVersion" Text :>
QueryParam "callback" Text :>
QueryParam "alt" AltJSON :>
Get '[JSON] FindFullHashesResponse
data EncodedFullHashesGet = EncodedFullHashesGet'
{ _efhgClientId :: !(Maybe Text)
, _efhgXgafv :: !(Maybe Xgafv)
, _efhgUploadProtocol :: !(Maybe Text)
, _efhgAccessToken :: !(Maybe Text)
, _efhgEncodedRequest :: !Bytes
, _efhgUploadType :: !(Maybe Text)
, _efhgClientVersion :: !(Maybe Text)
, _efhgCallback :: !(Maybe Text)
} deriving (Eq,Show,Data,Typeable,Generic)
encodedFullHashesGet
:: ByteString
-> EncodedFullHashesGet
encodedFullHashesGet pEfhgEncodedRequest_ =
EncodedFullHashesGet'
{ _efhgClientId = Nothing
, _efhgXgafv = Nothing
, _efhgUploadProtocol = Nothing
, _efhgAccessToken = Nothing
, _efhgEncodedRequest = _Bytes # pEfhgEncodedRequest_
, _efhgUploadType = Nothing
, _efhgClientVersion = Nothing
, _efhgCallback = Nothing
}
efhgClientId :: Lens' EncodedFullHashesGet (Maybe Text)
efhgClientId
= lens _efhgClientId (\ s a -> s{_efhgClientId = a})
efhgXgafv :: Lens' EncodedFullHashesGet (Maybe Xgafv)
efhgXgafv
= lens _efhgXgafv (\ s a -> s{_efhgXgafv = a})
efhgUploadProtocol :: Lens' EncodedFullHashesGet (Maybe Text)
efhgUploadProtocol
= lens _efhgUploadProtocol
(\ s a -> s{_efhgUploadProtocol = a})
efhgAccessToken :: Lens' EncodedFullHashesGet (Maybe Text)
efhgAccessToken
= lens _efhgAccessToken
(\ s a -> s{_efhgAccessToken = a})
efhgEncodedRequest :: Lens' EncodedFullHashesGet ByteString
efhgEncodedRequest
= lens _efhgEncodedRequest
(\ s a -> s{_efhgEncodedRequest = a})
. _Bytes
efhgUploadType :: Lens' EncodedFullHashesGet (Maybe Text)
efhgUploadType
= lens _efhgUploadType
(\ s a -> s{_efhgUploadType = a})
efhgClientVersion :: Lens' EncodedFullHashesGet (Maybe Text)
efhgClientVersion
= lens _efhgClientVersion
(\ s a -> s{_efhgClientVersion = a})
efhgCallback :: Lens' EncodedFullHashesGet (Maybe Text)
efhgCallback
= lens _efhgCallback (\ s a -> s{_efhgCallback = a})
instance GoogleRequest EncodedFullHashesGet where
type Rs EncodedFullHashesGet = FindFullHashesResponse
type Scopes EncodedFullHashesGet = '[]
requestClient EncodedFullHashesGet'{..}
= go _efhgEncodedRequest _efhgClientId _efhgXgafv
_efhgUploadProtocol
_efhgAccessToken
_efhgUploadType
_efhgClientVersion
_efhgCallback
(Just AltJSON)
safeBrowsingService
where go
= buildClient
(Proxy :: Proxy EncodedFullHashesGetResource)
mempty