gogol-customsearch 0.5.0 → 1.0.0
raw patch · 15 files changed
+3225/−4073 lines, 15 filesdep −basedep ~gogol-coresetup-changed
Dependencies removed: base
Dependency ranges changed: gogol-core
Files
- README.md +2/−2
- Setup.hs +2/−1
- gen/Gogol/CustomSearch.hs +161/−0
- gen/Gogol/CustomSearch/Internal/Product.hs +1374/−0
- gen/Gogol/CustomSearch/Internal/Sum.hs +887/−0
- gen/Gogol/CustomSearch/Search/Cse/List.hs +293/−0
- gen/Gogol/CustomSearch/Search/Cse/Siterestrict/List.hs +302/−0
- gen/Gogol/CustomSearch/Types.hs +152/−0
- gen/Network/Google/CustomSearch.hs +0/−265
- gen/Network/Google/CustomSearch/Types.hs +0/−247
- gen/Network/Google/CustomSearch/Types/Product.hs +0/−1435
- gen/Network/Google/CustomSearch/Types/Sum.hs +0/−1076
- gen/Network/Google/Resource/Search/CSE/List.hs +0/−496
- gen/Network/Google/Resource/Search/CSE/Siterestrict/List.hs +0/−514
- gogol-customsearch.cabal +52/−37
README.md view
@@ -8,12 +8,12 @@ ## Version -`0.5.0`+`1.0.0` ## Description -A client library for the Google CustomSearch.+A client library for the Google Custom Search. ## Contribute
Setup.hs view
@@ -1,2 +1,3 @@-import Distribution.Simple+import Distribution.Simple+ main = defaultMain
+ gen/Gogol/CustomSearch.hs view
@@ -0,0 +1,161 @@+{-# LANGUAGE DataKinds #-}+{-# LANGUAGE DerivingStrategies #-}+{-# LANGUAGE DuplicateRecordFields #-}+{-# LANGUAGE ImportQualifiedPost #-}+{-# LANGUAGE LambdaCase #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE PatternSynonyms #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE TypeFamilies #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}+{-# OPTIONS_GHC -fno-warn-name-shadowing #-}+{-# OPTIONS_GHC -fno-warn-unused-binds #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- |+-- Module : Gogol.CustomSearch+-- Copyright : (c) 2015-2025 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay <brendan.g.hay+gogol@gmail.com>+-- Toni Cebrián <toni@tonicebrian.com>+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Searches over a website or collection of websites+--+-- /See:/ <https://developers.google.com/custom-search/v1/introduction Custom Search API Reference>+module Gogol.CustomSearch+ ( -- * Configuration+ customSearchService,++ -- * Resources++ -- ** search.cse.list+ SearchCseListResource,+ SearchCseList (..),+ newSearchCseList,++ -- ** search.cse.siterestrict.list+ SearchCseSiterestrictListResource,+ SearchCseSiterestrictList (..),+ newSearchCseSiterestrictList,++ -- * Types++ -- ** Xgafv+ Xgafv (..),++ -- ** Promotion+ Promotion (..),+ newPromotion,++ -- ** Promotion_BodyLinesItem+ Promotion_BodyLinesItem (..),+ newPromotion_BodyLinesItem,++ -- ** Promotion_Image+ Promotion_Image (..),+ newPromotion_Image,++ -- ** Result+ Result (..),+ newResult,++ -- ** Result_Image+ Result_Image (..),+ newResult_Image,++ -- ** Result_LabelsItem+ Result_LabelsItem (..),+ newResult_LabelsItem,++ -- ** Result_Pagemap+ Result_Pagemap (..),+ newResult_Pagemap,++ -- ** Search+ Search (..),+ newSearch,++ -- ** Search_Context+ Search_Context (..),+ newSearch_Context,++ -- ** Search_Queries+ Search_Queries (..),+ newSearch_Queries,++ -- ** Search_Queries_NextPageItem+ Search_Queries_NextPageItem (..),+ newSearch_Queries_NextPageItem,++ -- ** Search_Queries_PreviousPageItem+ Search_Queries_PreviousPageItem (..),+ newSearch_Queries_PreviousPageItem,++ -- ** Search_Queries_RequestItem+ Search_Queries_RequestItem (..),+ newSearch_Queries_RequestItem,++ -- ** Search_SearchInformation+ Search_SearchInformation (..),+ newSearch_SearchInformation,++ -- ** Search_Spelling+ Search_Spelling (..),+ newSearch_Spelling,++ -- ** Search_Url+ Search_Url (..),+ newSearch_Url,++ -- ** CseListImgColorType+ CseListImgColorType (..),++ -- ** CseListImgDominantColor+ CseListImgDominantColor (..),++ -- ** CseListImgSize+ CseListImgSize (..),++ -- ** CseListImgType+ CseListImgType (..),++ -- ** CseListSafe+ CseListSafe (..),++ -- ** CseListSearchType+ CseListSearchType (..),++ -- ** CseListSiteSearchFilter+ CseListSiteSearchFilter (..),++ -- ** CseSiterestrictListImgColorType+ CseSiterestrictListImgColorType (..),++ -- ** CseSiterestrictListImgDominantColor+ CseSiterestrictListImgDominantColor (..),++ -- ** CseSiterestrictListImgSize+ CseSiterestrictListImgSize (..),++ -- ** CseSiterestrictListImgType+ CseSiterestrictListImgType (..),++ -- ** CseSiterestrictListSafe+ CseSiterestrictListSafe (..),++ -- ** CseSiterestrictListSearchType+ CseSiterestrictListSearchType (..),++ -- ** CseSiterestrictListSiteSearchFilter+ CseSiterestrictListSiteSearchFilter (..),+ )+where++import Gogol.CustomSearch.Search.Cse.List+import Gogol.CustomSearch.Search.Cse.Siterestrict.List+import Gogol.CustomSearch.Types
+ gen/Gogol/CustomSearch/Internal/Product.hs view
@@ -0,0 +1,1374 @@+{-# LANGUAGE DataKinds #-}+{-# LANGUAGE DerivingStrategies #-}+{-# LANGUAGE DuplicateRecordFields #-}+{-# LANGUAGE ImportQualifiedPost #-}+{-# LANGUAGE LambdaCase #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE PatternSynonyms #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE TypeFamilies #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}+{-# OPTIONS_GHC -fno-warn-name-shadowing #-}+{-# OPTIONS_GHC -fno-warn-unused-binds #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- |+-- Module : Gogol.CustomSearch.Internal.Product+-- Copyright : (c) 2015-2025 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay <brendan.g.hay+gogol@gmail.com>+-- Toni Cebrián <toni@tonicebrian.com>+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+module Gogol.CustomSearch.Internal.Product+ ( -- * Promotion+ Promotion (..),+ newPromotion,++ -- * Promotion_BodyLinesItem+ Promotion_BodyLinesItem (..),+ newPromotion_BodyLinesItem,++ -- * Promotion_Image+ Promotion_Image (..),+ newPromotion_Image,++ -- * Result+ Result (..),+ newResult,++ -- * Result_Image+ Result_Image (..),+ newResult_Image,++ -- * Result_LabelsItem+ Result_LabelsItem (..),+ newResult_LabelsItem,++ -- * Result_Pagemap+ Result_Pagemap (..),+ newResult_Pagemap,++ -- * Search+ Search (..),+ newSearch,++ -- * Search_Context+ Search_Context (..),+ newSearch_Context,++ -- * Search_Queries+ Search_Queries (..),+ newSearch_Queries,++ -- * Search_Queries_NextPageItem+ Search_Queries_NextPageItem (..),+ newSearch_Queries_NextPageItem,++ -- * Search_Queries_PreviousPageItem+ Search_Queries_PreviousPageItem (..),+ newSearch_Queries_PreviousPageItem,++ -- * Search_Queries_RequestItem+ Search_Queries_RequestItem (..),+ newSearch_Queries_RequestItem,++ -- * Search_SearchInformation+ Search_SearchInformation (..),+ newSearch_SearchInformation,++ -- * Search_Spelling+ Search_Spelling (..),+ newSearch_Spelling,++ -- * Search_Url+ Search_Url (..),+ newSearch_Url,+ )+where++import Gogol.CustomSearch.Internal.Sum+import Gogol.Prelude qualified as Core++-- | Promotion result.+--+-- /See:/ 'newPromotion' smart constructor.+data Promotion = Promotion+ { -- | An array of block objects for this promotion.+ bodyLines :: (Core.Maybe [Promotion_BodyLinesItem]),+ -- | An abridged version of this search\'s result URL, e.g. www.example.com.+ displayLink :: (Core.Maybe Core.Text),+ -- | The title of the promotion, in HTML.+ htmlTitle :: (Core.Maybe Core.Text),+ -- | Image belonging to a promotion.+ image :: (Core.Maybe Promotion_Image),+ -- | The URL of the promotion.+ link :: (Core.Maybe Core.Text),+ -- | The title of the promotion.+ title :: (Core.Maybe Core.Text)+ }+ deriving (Core.Eq, Core.Show, Core.Generic)++-- | Creates a value of 'Promotion' with the minimum fields required to make a request.+newPromotion ::+ Promotion+newPromotion =+ Promotion+ { bodyLines = Core.Nothing,+ displayLink = Core.Nothing,+ htmlTitle = Core.Nothing,+ image = Core.Nothing,+ link = Core.Nothing,+ title = Core.Nothing+ }++instance Core.FromJSON Promotion where+ parseJSON =+ Core.withObject+ "Promotion"+ ( \o ->+ Promotion+ Core.<$> (o Core..:? "bodyLines")+ Core.<*> (o Core..:? "displayLink")+ Core.<*> (o Core..:? "htmlTitle")+ Core.<*> (o Core..:? "image")+ Core.<*> (o Core..:? "link")+ Core.<*> (o Core..:? "title")+ )++instance Core.ToJSON Promotion where+ toJSON Promotion {..} =+ Core.object+ ( Core.catMaybes+ [ ("bodyLines" Core..=) Core.<$> bodyLines,+ ("displayLink" Core..=) Core.<$> displayLink,+ ("htmlTitle" Core..=) Core.<$> htmlTitle,+ ("image" Core..=) Core.<$> image,+ ("link" Core..=) Core.<$> link,+ ("title" Core..=) Core.<$> title+ ]+ )++-- | Block object belonging to a promotion.+--+-- /See:/ 'newPromotion_BodyLinesItem' smart constructor.+data Promotion_BodyLinesItem = Promotion_BodyLinesItem+ { -- | The block object\'s text in HTML, if it has text.+ htmlTitle :: (Core.Maybe Core.Text),+ -- | The anchor text of the block object\'s link, if it has a link.+ link :: (Core.Maybe Core.Text),+ -- | The block object\'s text, if it has text.+ title :: (Core.Maybe Core.Text),+ -- | The URL of the block object\'s link, if it has one.+ url :: (Core.Maybe Core.Text)+ }+ deriving (Core.Eq, Core.Show, Core.Generic)++-- | Creates a value of 'Promotion_BodyLinesItem' with the minimum fields required to make a request.+newPromotion_BodyLinesItem ::+ Promotion_BodyLinesItem+newPromotion_BodyLinesItem =+ Promotion_BodyLinesItem+ { htmlTitle = Core.Nothing,+ link = Core.Nothing,+ title = Core.Nothing,+ url = Core.Nothing+ }++instance Core.FromJSON Promotion_BodyLinesItem where+ parseJSON =+ Core.withObject+ "Promotion_BodyLinesItem"+ ( \o ->+ Promotion_BodyLinesItem+ Core.<$> (o Core..:? "htmlTitle")+ Core.<*> (o Core..:? "link")+ Core.<*> (o Core..:? "title")+ Core.<*> (o Core..:? "url")+ )++instance Core.ToJSON Promotion_BodyLinesItem where+ toJSON Promotion_BodyLinesItem {..} =+ Core.object+ ( Core.catMaybes+ [ ("htmlTitle" Core..=) Core.<$> htmlTitle,+ ("link" Core..=) Core.<$> link,+ ("title" Core..=) Core.<$> title,+ ("url" Core..=) Core.<$> url+ ]+ )++-- | Image belonging to a promotion.+--+-- /See:/ 'newPromotion_Image' smart constructor.+data Promotion_Image = Promotion_Image+ { -- | Image height in pixels.+ height :: (Core.Maybe Core.Int32),+ -- | URL of the image for this promotion link.+ source :: (Core.Maybe Core.Text),+ -- | Image width in pixels.+ width :: (Core.Maybe Core.Int32)+ }+ deriving (Core.Eq, Core.Show, Core.Generic)++-- | Creates a value of 'Promotion_Image' with the minimum fields required to make a request.+newPromotion_Image ::+ Promotion_Image+newPromotion_Image =+ Promotion_Image+ { height = Core.Nothing,+ source = Core.Nothing,+ width = Core.Nothing+ }++instance Core.FromJSON Promotion_Image where+ parseJSON =+ Core.withObject+ "Promotion_Image"+ ( \o ->+ Promotion_Image+ Core.<$> (o Core..:? "height")+ Core.<*> (o Core..:? "source")+ Core.<*> (o Core..:? "width")+ )++instance Core.ToJSON Promotion_Image where+ toJSON Promotion_Image {..} =+ Core.object+ ( Core.catMaybes+ [ ("height" Core..=) Core.<$> height,+ ("source" Core..=) Core.<$> source,+ ("width" Core..=) Core.<$> width+ ]+ )++-- | A custom search result.+--+-- /See:/ 'newResult' smart constructor.+data Result = Result+ { -- | Indicates the ID of Google\'s cached version of the search result.+ cacheId :: (Core.Maybe Core.Text),+ -- | An abridged version of this search result’s URL, e.g. www.example.com.+ displayLink :: (Core.Maybe Core.Text),+ -- | The file format of the search result.+ fileFormat :: (Core.Maybe Core.Text),+ -- | The URL displayed after the snippet for each search result.+ formattedUrl :: (Core.Maybe Core.Text),+ -- | The HTML-formatted URL displayed after the snippet for each search result.+ htmlFormattedUrl :: (Core.Maybe Core.Text),+ -- | The snippet of the search result, in HTML.+ htmlSnippet :: (Core.Maybe Core.Text),+ -- | The title of the search result, in HTML.+ htmlTitle :: (Core.Maybe Core.Text),+ -- | Image belonging to a custom search result.+ image :: (Core.Maybe Result_Image),+ -- | A unique identifier for the type of current object. For this API, it is @customsearch#result.@+ kind :: (Core.Maybe Core.Text),+ -- | Encapsulates all information about refinement labels.+ labels :: (Core.Maybe [Result_LabelsItem]),+ -- | The full URL to which the search result is pointing, e.g. http:\/\/www.example.com\/foo\/bar.+ link :: (Core.Maybe Core.Text),+ -- | The MIME type of the search result.+ mime :: (Core.Maybe Core.Text),+ -- | Contains <https://developers.google.com/custom-search/docs/structured_data#pagemaps PageMap> information for this search result.+ pagemap :: (Core.Maybe Result_Pagemap),+ -- | The snippet of the search result, in plain text.+ snippet :: (Core.Maybe Core.Text),+ -- | The title of the search result, in plain text.+ title :: (Core.Maybe Core.Text)+ }+ deriving (Core.Eq, Core.Show, Core.Generic)++-- | Creates a value of 'Result' with the minimum fields required to make a request.+newResult ::+ Result+newResult =+ Result+ { cacheId = Core.Nothing,+ displayLink = Core.Nothing,+ fileFormat = Core.Nothing,+ formattedUrl = Core.Nothing,+ htmlFormattedUrl = Core.Nothing,+ htmlSnippet = Core.Nothing,+ htmlTitle = Core.Nothing,+ image = Core.Nothing,+ kind = Core.Nothing,+ labels = Core.Nothing,+ link = Core.Nothing,+ mime = Core.Nothing,+ pagemap = Core.Nothing,+ snippet = Core.Nothing,+ title = Core.Nothing+ }++instance Core.FromJSON Result where+ parseJSON =+ Core.withObject+ "Result"+ ( \o ->+ Result+ Core.<$> (o Core..:? "cacheId")+ Core.<*> (o Core..:? "displayLink")+ Core.<*> (o Core..:? "fileFormat")+ Core.<*> (o Core..:? "formattedUrl")+ Core.<*> (o Core..:? "htmlFormattedUrl")+ Core.<*> (o Core..:? "htmlSnippet")+ Core.<*> (o Core..:? "htmlTitle")+ Core.<*> (o Core..:? "image")+ Core.<*> (o Core..:? "kind")+ Core.<*> (o Core..:? "labels")+ Core.<*> (o Core..:? "link")+ Core.<*> (o Core..:? "mime")+ Core.<*> (o Core..:? "pagemap")+ Core.<*> (o Core..:? "snippet")+ Core.<*> (o Core..:? "title")+ )++instance Core.ToJSON Result where+ toJSON Result {..} =+ Core.object+ ( Core.catMaybes+ [ ("cacheId" Core..=) Core.<$> cacheId,+ ("displayLink" Core..=) Core.<$> displayLink,+ ("fileFormat" Core..=) Core.<$> fileFormat,+ ("formattedUrl" Core..=) Core.<$> formattedUrl,+ ("htmlFormattedUrl" Core..=) Core.<$> htmlFormattedUrl,+ ("htmlSnippet" Core..=) Core.<$> htmlSnippet,+ ("htmlTitle" Core..=) Core.<$> htmlTitle,+ ("image" Core..=) Core.<$> image,+ ("kind" Core..=) Core.<$> kind,+ ("labels" Core..=) Core.<$> labels,+ ("link" Core..=) Core.<$> link,+ ("mime" Core..=) Core.<$> mime,+ ("pagemap" Core..=) Core.<$> pagemap,+ ("snippet" Core..=) Core.<$> snippet,+ ("title" Core..=) Core.<$> title+ ]+ )++-- | Image belonging to a custom search result.+--+-- /See:/ 'newResult_Image' smart constructor.+data Result_Image = Result_Image+ { -- | The size of the image, in bytes.+ byteSize :: (Core.Maybe Core.Int32),+ -- | A URL pointing to the webpage hosting the image.+ contextLink :: (Core.Maybe Core.Text),+ -- | The height of the image, in pixels.+ height :: (Core.Maybe Core.Int32),+ -- | The height of the thumbnail image, in pixels.+ thumbnailHeight :: (Core.Maybe Core.Int32),+ -- | A URL to the thumbnail image.+ thumbnailLink :: (Core.Maybe Core.Text),+ -- | The width of the thumbnail image, in pixels.+ thumbnailWidth :: (Core.Maybe Core.Int32),+ -- | The width of the image, in pixels.+ width :: (Core.Maybe Core.Int32)+ }+ deriving (Core.Eq, Core.Show, Core.Generic)++-- | Creates a value of 'Result_Image' with the minimum fields required to make a request.+newResult_Image ::+ Result_Image+newResult_Image =+ Result_Image+ { byteSize = Core.Nothing,+ contextLink = Core.Nothing,+ height = Core.Nothing,+ thumbnailHeight = Core.Nothing,+ thumbnailLink = Core.Nothing,+ thumbnailWidth = Core.Nothing,+ width = Core.Nothing+ }++instance Core.FromJSON Result_Image where+ parseJSON =+ Core.withObject+ "Result_Image"+ ( \o ->+ Result_Image+ Core.<$> (o Core..:? "byteSize")+ Core.<*> (o Core..:? "contextLink")+ Core.<*> (o Core..:? "height")+ Core.<*> (o Core..:? "thumbnailHeight")+ Core.<*> (o Core..:? "thumbnailLink")+ Core.<*> (o Core..:? "thumbnailWidth")+ Core.<*> (o Core..:? "width")+ )++instance Core.ToJSON Result_Image where+ toJSON Result_Image {..} =+ Core.object+ ( Core.catMaybes+ [ ("byteSize" Core..=) Core.<$> byteSize,+ ("contextLink" Core..=) Core.<$> contextLink,+ ("height" Core..=) Core.<$> height,+ ("thumbnailHeight" Core..=) Core.<$> thumbnailHeight,+ ("thumbnailLink" Core..=) Core.<$> thumbnailLink,+ ("thumbnailWidth" Core..=) Core.<$> thumbnailWidth,+ ("width" Core..=) Core.<$> width+ ]+ )++-- | Refinement label associated with a custom search result.+--+-- /See:/ 'newResult_LabelsItem' smart constructor.+data Result_LabelsItem = Result_LabelsItem+ { -- | The display name of a refinement label. This is the name you should display in your user interface.+ displayName :: (Core.Maybe Core.Text),+ -- | Refinement label and the associated refinement operation.+ labelWithOp :: (Core.Maybe Core.Text),+ -- | The name of a refinement label, which you can use to refine searches. Don\'t display this in your user interface; instead, use displayName.+ name :: (Core.Maybe Core.Text)+ }+ deriving (Core.Eq, Core.Show, Core.Generic)++-- | Creates a value of 'Result_LabelsItem' with the minimum fields required to make a request.+newResult_LabelsItem ::+ Result_LabelsItem+newResult_LabelsItem =+ Result_LabelsItem+ { displayName = Core.Nothing,+ labelWithOp = Core.Nothing,+ name = Core.Nothing+ }++instance Core.FromJSON Result_LabelsItem where+ parseJSON =+ Core.withObject+ "Result_LabelsItem"+ ( \o ->+ Result_LabelsItem+ Core.<$> (o Core..:? "displayName")+ Core.<*> (o Core..:? "label_with_op")+ Core.<*> (o Core..:? "name")+ )++instance Core.ToJSON Result_LabelsItem where+ toJSON Result_LabelsItem {..} =+ Core.object+ ( Core.catMaybes+ [ ("displayName" Core..=) Core.<$> displayName,+ ("label_with_op" Core..=) Core.<$> labelWithOp,+ ("name" Core..=) Core.<$> name+ ]+ )++-- | Contains <https://developers.google.com/custom-search/docs/structured_data#pagemaps PageMap> information for this search result.+--+-- /See:/ 'newResult_Pagemap' smart constructor.+newtype Result_Pagemap = Result_Pagemap+ { -- | Properties of the object.+ additional :: (Core.HashMap Core.Text Core.Value)+ }+ deriving (Core.Eq, Core.Show, Core.Generic)++-- | Creates a value of 'Result_Pagemap' with the minimum fields required to make a request.+newResult_Pagemap ::+ -- | Properties of the object. See 'additional'.+ Core.HashMap Core.Text Core.Value ->+ Result_Pagemap+newResult_Pagemap additional =+ Result_Pagemap {additional = additional}++instance Core.FromJSON Result_Pagemap where+ parseJSON =+ Core.withObject+ "Result_Pagemap"+ (\o -> Result_Pagemap Core.<$> (Core.parseJSONObject o))++instance Core.ToJSON Result_Pagemap where+ toJSON Result_Pagemap {..} = Core.toJSON additional++-- | Response to a custom search request.+--+-- /See:/ 'newSearch' smart constructor.+data Search = Search+ { -- | Metadata and refinements associated with the given search engine, including: * The name of the search engine that was used for the query. * A set of <https://developers.google.com/custom-search/docs/refinements#create facet objects> (refinements) you can use for refining a search.+ context :: (Core.Maybe Search_Context),+ -- | The current set of custom search results.+ items :: (Core.Maybe [Result]),+ -- | Unique identifier for the type of current object. For this API, it is customsearch#search.+ kind :: (Core.Maybe Core.Text),+ -- | The set of <https://developers.google.com/custom-search/docs/promotions promotions>. Present only if the custom search engine\'s configuration files define any promotions for the given query.+ promotions :: (Core.Maybe [Promotion]),+ -- | Query metadata for the previous, current, and next pages of results.+ queries :: (Core.Maybe Search_Queries),+ -- | Metadata about a search operation.+ searchInformation :: (Core.Maybe Search_SearchInformation),+ -- | Spell correction information for a query.+ spelling :: (Core.Maybe Search_Spelling),+ -- | OpenSearch template and URL.+ url :: (Core.Maybe Search_Url)+ }+ deriving (Core.Eq, Core.Show, Core.Generic)++-- | Creates a value of 'Search' with the minimum fields required to make a request.+newSearch ::+ Search+newSearch =+ Search+ { context = Core.Nothing,+ items = Core.Nothing,+ kind = Core.Nothing,+ promotions = Core.Nothing,+ queries = Core.Nothing,+ searchInformation = Core.Nothing,+ spelling = Core.Nothing,+ url = Core.Nothing+ }++instance Core.FromJSON Search where+ parseJSON =+ Core.withObject+ "Search"+ ( \o ->+ Search+ Core.<$> (o Core..:? "context")+ Core.<*> (o Core..:? "items")+ Core.<*> (o Core..:? "kind")+ Core.<*> (o Core..:? "promotions")+ Core.<*> (o Core..:? "queries")+ Core.<*> (o Core..:? "searchInformation")+ Core.<*> (o Core..:? "spelling")+ Core.<*> (o Core..:? "url")+ )++instance Core.ToJSON Search where+ toJSON Search {..} =+ Core.object+ ( Core.catMaybes+ [ ("context" Core..=) Core.<$> context,+ ("items" Core..=) Core.<$> items,+ ("kind" Core..=) Core.<$> kind,+ ("promotions" Core..=) Core.<$> promotions,+ ("queries" Core..=) Core.<$> queries,+ ("searchInformation" Core..=) Core.<$> searchInformation,+ ("spelling" Core..=) Core.<$> spelling,+ ("url" Core..=) Core.<$> url+ ]+ )++-- | Metadata and refinements associated with the given search engine, including: * The name of the search engine that was used for the query. * A set of <https://developers.google.com/custom-search/docs/refinements#create facet objects> (refinements) you can use for refining a search.+--+-- /See:/ 'newSearch_Context' smart constructor.+newtype Search_Context = Search_Context+ { -- | Properties of the object.+ additional :: (Core.HashMap Core.Text Core.Value)+ }+ deriving (Core.Eq, Core.Show, Core.Generic)++-- | Creates a value of 'Search_Context' with the minimum fields required to make a request.+newSearch_Context ::+ -- | Properties of the object. See 'additional'.+ Core.HashMap Core.Text Core.Value ->+ Search_Context+newSearch_Context additional =+ Search_Context {additional = additional}++instance Core.FromJSON Search_Context where+ parseJSON =+ Core.withObject+ "Search_Context"+ (\o -> Search_Context Core.<$> (Core.parseJSONObject o))++instance Core.ToJSON Search_Context where+ toJSON Search_Context {..} = Core.toJSON additional++-- | Query metadata for the previous, current, and next pages of results.+--+-- /See:/ 'newSearch_Queries' smart constructor.+data Search_Queries = Search_Queries+ { -- | Metadata representing the next page of results, if applicable.+ nextPage :: (Core.Maybe [Search_Queries_NextPageItem]),+ -- | Metadata representing the previous page of results, if applicable.+ previousPage :: (Core.Maybe [Search_Queries_PreviousPageItem]),+ -- | Metadata representing the current request.+ request' :: (Core.Maybe [Search_Queries_RequestItem])+ }+ deriving (Core.Eq, Core.Show, Core.Generic)++-- | Creates a value of 'Search_Queries' with the minimum fields required to make a request.+newSearch_Queries ::+ Search_Queries+newSearch_Queries =+ Search_Queries+ { nextPage = Core.Nothing,+ previousPage = Core.Nothing,+ request' = Core.Nothing+ }++instance Core.FromJSON Search_Queries where+ parseJSON =+ Core.withObject+ "Search_Queries"+ ( \o ->+ Search_Queries+ Core.<$> (o Core..:? "nextPage")+ Core.<*> (o Core..:? "previousPage")+ Core.<*> (o Core..:? "request")+ )++instance Core.ToJSON Search_Queries where+ toJSON Search_Queries {..} =+ Core.object+ ( Core.catMaybes+ [ ("nextPage" Core..=) Core.<$> nextPage,+ ("previousPage" Core..=) Core.<$> previousPage,+ ("request" Core..=) Core.<$> request'+ ]+ )++-- | Custom search request metadata.+--+-- /See:/ 'newSearch_Queries_NextPageItem' smart constructor.+data Search_Queries_NextPageItem = Search_Queries_NextPageItem+ { -- | Number of search results returned in this set.+ count :: (Core.Maybe Core.Int32),+ -- | Restricts search results to documents originating in a particular country. You may use <https://developers.google.com/custom-search/docs/json_api_reference#BooleanOrSearch Boolean operators> in the @cr@ parameter\'s value. Google WebSearch determines the country of a document by analyzing the following: * The top-level domain (TLD) of the document\'s URL. * The geographic location of the web server\'s IP address. See <https://developers.google.com/custom-search/docs/json_api_reference#countryCollections Country (cr) Parameter Values> for a list of valid values for this parameter.+ cr :: (Core.Maybe Core.Text),+ -- | The identifier of an engine created using the Programmable Search Engine <https://programmablesearchengine.google.com/ Control Panel>. This is a custom property not defined in the OpenSearch spec. This parameter is __required__.+ cx :: (Core.Maybe Core.Text),+ -- | Restricts results to URLs based on date. Supported values include: * @d[number]@: requests results from the specified number of past days. * @w[number]@: requests results from the specified number of past weeks. * @m[number]@: requests results from the specified number of past months. * @y[number]@: requests results from the specified number of past years.+ dateRestrict :: (Core.Maybe Core.Text),+ -- | Enables or disables the <https://developers.google.com/custom-search/docs/json_api_reference#chineseSearch Simplified and Traditional Chinese Search> feature. Supported values are: * @0@: enabled (default) * @1@: disabled+ disableCnTwTranslation :: (Core.Maybe Core.Text),+ -- | Identifies a phrase that all documents in the search results must contain.+ exactTerms :: (Core.Maybe Core.Text),+ -- | Identifies a word or phrase that should not appear in any documents in the search results.+ excludeTerms :: (Core.Maybe Core.Text),+ -- | Restricts results to files of a specified extension. Filetypes supported by Google include: * Adobe Portable Document Format (@pdf@) * Adobe PostScript (@ps@) * Lotus 1-2-3 (@wk1@, @wk2@, @wk3@, @wk4@, @wk5@, @wki@, @wks@, @wku@) * Lotus WordPro (@lwp@) * Macwrite (@mw@) * Microsoft Excel (@xls@) * Microsoft PowerPoint (@ppt@) * Microsoft Word (@doc@) * Microsoft Works (@wks@, @wps@, @wdb@) * Microsoft Write (@wri@) * Rich Text Format (@rtf@) * Shockwave Flash (@swf@) * Text (@ans@, @txt@). Additional filetypes may be added in the future. An up-to-date list can always be found in Google\'s <https://support.google.com/webmasters/answer/35287 file type FAQ>.+ fileType :: (Core.Maybe Core.Text),+ -- | Activates or deactivates the automatic filtering of Google search results. See <https://developers.google.com/custom-search/docs/json_api_reference#automaticFiltering Automatic Filtering> for more information about Google\'s search results filters. Valid values for this parameter are: * @0@: Disabled * @1@: Enabled (default) __Note__: By default, Google applies filtering to all search results to improve the quality of those results.+ filter :: (Core.Maybe Core.Text),+ -- | Boosts search results whose country of origin matches the parameter value. See <https://developers.google.com/custom-search/docs/json_api_reference#countryCodes Country Codes> for a list of valid values. Specifying a @gl@ parameter value in WebSearch requests should improve the relevance of results. This is particularly true for international customers and, even more specifically, for customers in English-speaking countries other than the United States.+ gl :: (Core.Maybe Core.Text),+ -- | Specifies the Google domain (for example, google.com, google.de, or google.fr) to which the search should be limited.+ googleHost :: (Core.Maybe Core.Text),+ -- | Specifies the ending value for a search range. Use @cse:lowRange@ and @cse:highrange@ to append an inclusive search range of @lowRange...highRange@ to the query.+ highRange :: (Core.Maybe Core.Text),+ -- | Specifies the interface language (host language) of your user interface. Explicitly setting this parameter improves the performance and the quality of your search results. See the <https://developers.google.com/custom-search/docs/json_api_reference#wsInterfaceLanguages Interface Languages> section of <https://developers.google.com/custom-search/docs/json_api_reference#wsInternationalizing Internationalizing Queries and Results Presentation> for more information, and <https://developers.google.com/custom-search/docs/json_api_reference#interfaceLanguages Supported Interface Languages> for a list of supported languages.+ hl :: (Core.Maybe Core.Text),+ -- | Appends the specified query terms to the query, as if they were combined with a logical @AND@ operator.+ hq :: (Core.Maybe Core.Text),+ -- | Restricts results to images of a specified color type. Supported values are: * @mono@ (black and white) * @gray@ (grayscale) * @color@ (color)+ imgColorType :: (Core.Maybe Core.Text),+ -- | Restricts results to images with a specific dominant color. Supported values are: * @red@ * @orange@ * @yellow@ * @green@ * @teal@ * @blue@ * @purple@ * @pink@ * @white@ * @gray@ * @black@ * @brown@+ imgDominantColor :: (Core.Maybe Core.Text),+ -- | Restricts results to images of a specified size. Supported values are: * @icon@ (small) * @small | medium | large | xlarge@ (medium) * @xxlarge@ (large) * @huge@ (extra-large)+ imgSize :: (Core.Maybe Core.Text),+ -- | Restricts results to images of a specified type. Supported values are: * @clipart@ (Clip art) * @face@ (Face) * @lineart@ (Line drawing) * @photo@ (Photo) * @animated@ (Animated) * @stock@ (Stock)+ imgType :: (Core.Maybe Core.Text),+ -- | The character encoding supported for search requests.+ inputEncoding :: (Core.Maybe Core.Text),+ -- | The language of the search results.+ language :: (Core.Maybe Core.Text),+ -- | Specifies that all results should contain a link to a specific URL.+ linkSite :: (Core.Maybe Core.Text),+ -- | Specifies the starting value for a search range. Use @cse:lowRange@ and @cse:highrange@ to append an inclusive search range of @lowRange...highRange@ to the query.+ lowRange :: (Core.Maybe Core.Text),+ -- | Provides additional search terms to check for in a document, where each document in the search results must contain at least one of the additional search terms. You can also use the <https://developers.google.com/custom-search/docs/json_api_reference#BooleanOrSearch Boolean OR> query term for this type of query.+ orTerms :: (Core.Maybe Core.Text),+ -- | The character encoding supported for search results.+ outputEncoding :: (Core.Maybe Core.Text),+ -- | Specifies that all search results should be pages that are related to the specified URL. The parameter value should be a URL.+ relatedSite :: (Core.Maybe Core.Text),+ -- | Filters based on licensing. Supported values include: * @cc_publicdomain@ * @cc_attribute@ * @cc_sharealike@ * @cc_noncommercial@ * @cc_nonderived@+ rights :: (Core.Maybe Core.Text),+ -- | Specifies the <https://developers.google.com/custom-search/docs/json_api_reference#safeSearchLevels SafeSearch level> used for filtering out adult results. This is a custom property not defined in the OpenSearch spec. Valid parameter values are: * @\"off\"@: Disable SafeSearch * @\"active\"@: Enable SafeSearch+ safe :: (Core.Maybe Core.Text),+ -- | The search terms entered by the user.+ searchTerms :: (Core.Maybe Core.Text),+ -- | Allowed values are @web@ or @image@. If unspecified, results are limited to webpages.+ searchType :: (Core.Maybe Core.Text),+ -- | Restricts results to URLs from a specified site.+ siteSearch :: (Core.Maybe Core.Text),+ -- | Specifies whether to include or exclude results from the site named in the @sitesearch@ parameter. Supported values are: * @i@: include content from site * @e@: exclude content from site+ siteSearchFilter :: (Core.Maybe Core.Text),+ -- | Specifies that results should be sorted according to the specified expression. For example, sort by date.+ sort :: (Core.Maybe Core.Text),+ -- | The index of the current set of search results into the total set of results, where the index of the first result is 1.+ startIndex :: (Core.Maybe Core.Int32),+ -- | The page number of this set of results, where the page length is set by the @count@ property.+ startPage :: (Core.Maybe Core.Int32),+ -- | A description of the query.+ title :: (Core.Maybe Core.Text),+ -- | Estimated number of total search results. May not be accurate.+ totalResults :: (Core.Maybe Core.Int64)+ }+ deriving (Core.Eq, Core.Show, Core.Generic)++-- | Creates a value of 'Search_Queries_NextPageItem' with the minimum fields required to make a request.+newSearch_Queries_NextPageItem ::+ Search_Queries_NextPageItem+newSearch_Queries_NextPageItem =+ Search_Queries_NextPageItem+ { count = Core.Nothing,+ cr = Core.Nothing,+ cx = Core.Nothing,+ dateRestrict = Core.Nothing,+ disableCnTwTranslation = Core.Nothing,+ exactTerms = Core.Nothing,+ excludeTerms = Core.Nothing,+ fileType = Core.Nothing,+ filter = Core.Nothing,+ gl = Core.Nothing,+ googleHost = Core.Nothing,+ highRange = Core.Nothing,+ hl = Core.Nothing,+ hq = Core.Nothing,+ imgColorType = Core.Nothing,+ imgDominantColor = Core.Nothing,+ imgSize = Core.Nothing,+ imgType = Core.Nothing,+ inputEncoding = Core.Nothing,+ language = Core.Nothing,+ linkSite = Core.Nothing,+ lowRange = Core.Nothing,+ orTerms = Core.Nothing,+ outputEncoding = Core.Nothing,+ relatedSite = Core.Nothing,+ rights = Core.Nothing,+ safe = Core.Nothing,+ searchTerms = Core.Nothing,+ searchType = Core.Nothing,+ siteSearch = Core.Nothing,+ siteSearchFilter = Core.Nothing,+ sort = Core.Nothing,+ startIndex = Core.Nothing,+ startPage = Core.Nothing,+ title = Core.Nothing,+ totalResults = Core.Nothing+ }++instance Core.FromJSON Search_Queries_NextPageItem where+ parseJSON =+ Core.withObject+ "Search_Queries_NextPageItem"+ ( \o ->+ Search_Queries_NextPageItem+ Core.<$> (o Core..:? "count")+ Core.<*> (o Core..:? "cr")+ Core.<*> (o Core..:? "cx")+ Core.<*> (o Core..:? "dateRestrict")+ Core.<*> (o Core..:? "disableCnTwTranslation")+ Core.<*> (o Core..:? "exactTerms")+ Core.<*> (o Core..:? "excludeTerms")+ Core.<*> (o Core..:? "fileType")+ Core.<*> (o Core..:? "filter")+ Core.<*> (o Core..:? "gl")+ Core.<*> (o Core..:? "googleHost")+ Core.<*> (o Core..:? "highRange")+ Core.<*> (o Core..:? "hl")+ Core.<*> (o Core..:? "hq")+ Core.<*> (o Core..:? "imgColorType")+ Core.<*> (o Core..:? "imgDominantColor")+ Core.<*> (o Core..:? "imgSize")+ Core.<*> (o Core..:? "imgType")+ Core.<*> (o Core..:? "inputEncoding")+ Core.<*> (o Core..:? "language")+ Core.<*> (o Core..:? "linkSite")+ Core.<*> (o Core..:? "lowRange")+ Core.<*> (o Core..:? "orTerms")+ Core.<*> (o Core..:? "outputEncoding")+ Core.<*> (o Core..:? "relatedSite")+ Core.<*> (o Core..:? "rights")+ Core.<*> (o Core..:? "safe")+ Core.<*> (o Core..:? "searchTerms")+ Core.<*> (o Core..:? "searchType")+ Core.<*> (o Core..:? "siteSearch")+ Core.<*> (o Core..:? "siteSearchFilter")+ Core.<*> (o Core..:? "sort")+ Core.<*> (o Core..:? "startIndex")+ Core.<*> (o Core..:? "startPage")+ Core.<*> (o Core..:? "title")+ Core.<*> (o Core..:? "totalResults" Core.<&> Core.fmap Core.fromAsText)+ )++instance Core.ToJSON Search_Queries_NextPageItem where+ toJSON Search_Queries_NextPageItem {..} =+ Core.object+ ( Core.catMaybes+ [ ("count" Core..=) Core.<$> count,+ ("cr" Core..=) Core.<$> cr,+ ("cx" Core..=) Core.<$> cx,+ ("dateRestrict" Core..=) Core.<$> dateRestrict,+ ("disableCnTwTranslation" Core..=) Core.<$> disableCnTwTranslation,+ ("exactTerms" Core..=) Core.<$> exactTerms,+ ("excludeTerms" Core..=) Core.<$> excludeTerms,+ ("fileType" Core..=) Core.<$> fileType,+ ("filter" Core..=) Core.<$> filter,+ ("gl" Core..=) Core.<$> gl,+ ("googleHost" Core..=) Core.<$> googleHost,+ ("highRange" Core..=) Core.<$> highRange,+ ("hl" Core..=) Core.<$> hl,+ ("hq" Core..=) Core.<$> hq,+ ("imgColorType" Core..=) Core.<$> imgColorType,+ ("imgDominantColor" Core..=) Core.<$> imgDominantColor,+ ("imgSize" Core..=) Core.<$> imgSize,+ ("imgType" Core..=) Core.<$> imgType,+ ("inputEncoding" Core..=) Core.<$> inputEncoding,+ ("language" Core..=) Core.<$> language,+ ("linkSite" Core..=) Core.<$> linkSite,+ ("lowRange" Core..=) Core.<$> lowRange,+ ("orTerms" Core..=) Core.<$> orTerms,+ ("outputEncoding" Core..=) Core.<$> outputEncoding,+ ("relatedSite" Core..=) Core.<$> relatedSite,+ ("rights" Core..=) Core.<$> rights,+ ("safe" Core..=) Core.<$> safe,+ ("searchTerms" Core..=) Core.<$> searchTerms,+ ("searchType" Core..=) Core.<$> searchType,+ ("siteSearch" Core..=) Core.<$> siteSearch,+ ("siteSearchFilter" Core..=) Core.<$> siteSearchFilter,+ ("sort" Core..=) Core.<$> sort,+ ("startIndex" Core..=) Core.<$> startIndex,+ ("startPage" Core..=) Core.<$> startPage,+ ("title" Core..=) Core.<$> title,+ ("totalResults" Core..=) Core.. Core.AsText Core.<$> totalResults+ ]+ )++-- | Custom search request metadata.+--+-- /See:/ 'newSearch_Queries_PreviousPageItem' smart constructor.+data Search_Queries_PreviousPageItem = Search_Queries_PreviousPageItem+ { -- | Number of search results returned in this set.+ count :: (Core.Maybe Core.Int32),+ -- | Restricts search results to documents originating in a particular country. You may use <https://developers.google.com/custom-search/docs/json_api_reference#BooleanOrSearch Boolean operators> in the @cr@ parameter\'s value. Google WebSearch determines the country of a document by analyzing the following: * The top-level domain (TLD) of the document\'s URL. * The geographic location of the web server\'s IP address. See <https://developers.google.com/custom-search/docs/json_api_reference#countryCollections Country (cr) Parameter Values> for a list of valid values for this parameter.+ cr :: (Core.Maybe Core.Text),+ -- | The identifier of an engine created using the Programmable Search Engine <https://programmablesearchengine.google.com/ Control Panel>. This is a custom property not defined in the OpenSearch spec. This parameter is __required__.+ cx :: (Core.Maybe Core.Text),+ -- | Restricts results to URLs based on date. Supported values include: * @d[number]@: requests results from the specified number of past days. * @w[number]@: requests results from the specified number of past weeks. * @m[number]@: requests results from the specified number of past months. * @y[number]@: requests results from the specified number of past years.+ dateRestrict :: (Core.Maybe Core.Text),+ -- | Enables or disables the <https://developers.google.com/custom-search/docs/json_api_reference#chineseSearch Simplified and Traditional Chinese Search> feature. Supported values are: * @0@: enabled (default) * @1@: disabled+ disableCnTwTranslation :: (Core.Maybe Core.Text),+ -- | Identifies a phrase that all documents in the search results must contain.+ exactTerms :: (Core.Maybe Core.Text),+ -- | Identifies a word or phrase that should not appear in any documents in the search results.+ excludeTerms :: (Core.Maybe Core.Text),+ -- | Restricts results to files of a specified extension. Filetypes supported by Google include: * Adobe Portable Document Format (@pdf@) * Adobe PostScript (@ps@) * Lotus 1-2-3 (@wk1@, @wk2@, @wk3@, @wk4@, @wk5@, @wki@, @wks@, @wku@) * Lotus WordPro (@lwp@) * Macwrite (@mw@) * Microsoft Excel (@xls@) * Microsoft PowerPoint (@ppt@) * Microsoft Word (@doc@) * Microsoft Works (@wks@, @wps@, @wdb@) * Microsoft Write (@wri@) * Rich Text Format (@rtf@) * Shockwave Flash (@swf@) * Text (@ans@, @txt@). Additional filetypes may be added in the future. An up-to-date list can always be found in Google\'s <https://support.google.com/webmasters/answer/35287 file type FAQ>.+ fileType :: (Core.Maybe Core.Text),+ -- | Activates or deactivates the automatic filtering of Google search results. See <https://developers.google.com/custom-search/docs/json_api_reference#automaticFiltering Automatic Filtering> for more information about Google\'s search results filters. Valid values for this parameter are: * @0@: Disabled * @1@: Enabled (default) __Note__: By default, Google applies filtering to all search results to improve the quality of those results.+ filter :: (Core.Maybe Core.Text),+ -- | Boosts search results whose country of origin matches the parameter value. See <https://developers.google.com/custom-search/docs/json_api_reference#countryCodes Country Codes> for a list of valid values. Specifying a @gl@ parameter value in WebSearch requests should improve the relevance of results. This is particularly true for international customers and, even more specifically, for customers in English-speaking countries other than the United States.+ gl :: (Core.Maybe Core.Text),+ -- | Specifies the Google domain (for example, google.com, google.de, or google.fr) to which the search should be limited.+ googleHost :: (Core.Maybe Core.Text),+ -- | Specifies the ending value for a search range. Use @cse:lowRange@ and @cse:highrange@ to append an inclusive search range of @lowRange...highRange@ to the query.+ highRange :: (Core.Maybe Core.Text),+ -- | Specifies the interface language (host language) of your user interface. Explicitly setting this parameter improves the performance and the quality of your search results. See the <https://developers.google.com/custom-search/docs/json_api_reference#wsInterfaceLanguages Interface Languages> section of <https://developers.google.com/custom-search/docs/json_api_reference#wsInternationalizing Internationalizing Queries and Results Presentation> for more information, and <https://developers.google.com/custom-search/docs/json_api_reference#interfaceLanguages Supported Interface Languages> for a list of supported languages.+ hl :: (Core.Maybe Core.Text),+ -- | Appends the specified query terms to the query, as if they were combined with a logical @AND@ operator.+ hq :: (Core.Maybe Core.Text),+ -- | Restricts results to images of a specified color type. Supported values are: * @mono@ (black and white) * @gray@ (grayscale) * @color@ (color)+ imgColorType :: (Core.Maybe Core.Text),+ -- | Restricts results to images with a specific dominant color. Supported values are: * @red@ * @orange@ * @yellow@ * @green@ * @teal@ * @blue@ * @purple@ * @pink@ * @white@ * @gray@ * @black@ * @brown@+ imgDominantColor :: (Core.Maybe Core.Text),+ -- | Restricts results to images of a specified size. Supported values are: * @icon@ (small) * @small | medium | large | xlarge@ (medium) * @xxlarge@ (large) * @huge@ (extra-large)+ imgSize :: (Core.Maybe Core.Text),+ -- | Restricts results to images of a specified type. Supported values are: * @clipart@ (Clip art) * @face@ (Face) * @lineart@ (Line drawing) * @photo@ (Photo) * @animated@ (Animated) * @stock@ (Stock)+ imgType :: (Core.Maybe Core.Text),+ -- | The character encoding supported for search requests.+ inputEncoding :: (Core.Maybe Core.Text),+ -- | The language of the search results.+ language :: (Core.Maybe Core.Text),+ -- | Specifies that all results should contain a link to a specific URL.+ linkSite :: (Core.Maybe Core.Text),+ -- | Specifies the starting value for a search range. Use @cse:lowRange@ and @cse:highrange@ to append an inclusive search range of @lowRange...highRange@ to the query.+ lowRange :: (Core.Maybe Core.Text),+ -- | Provides additional search terms to check for in a document, where each document in the search results must contain at least one of the additional search terms. You can also use the <https://developers.google.com/custom-search/docs/json_api_reference#BooleanOrSearch Boolean OR> query term for this type of query.+ orTerms :: (Core.Maybe Core.Text),+ -- | The character encoding supported for search results.+ outputEncoding :: (Core.Maybe Core.Text),+ -- | Specifies that all search results should be pages that are related to the specified URL. The parameter value should be a URL.+ relatedSite :: (Core.Maybe Core.Text),+ -- | Filters based on licensing. Supported values include: * @cc_publicdomain@ * @cc_attribute@ * @cc_sharealike@ * @cc_noncommercial@ * @cc_nonderived@+ rights :: (Core.Maybe Core.Text),+ -- | Specifies the <https://developers.google.com/custom-search/docs/json_api_reference#safeSearchLevels SafeSearch level> used for filtering out adult results. This is a custom property not defined in the OpenSearch spec. Valid parameter values are: * @\"off\"@: Disable SafeSearch * @\"active\"@: Enable SafeSearch+ safe :: (Core.Maybe Core.Text),+ -- | The search terms entered by the user.+ searchTerms :: (Core.Maybe Core.Text),+ -- | Allowed values are @web@ or @image@. If unspecified, results are limited to webpages.+ searchType :: (Core.Maybe Core.Text),+ -- | Restricts results to URLs from a specified site.+ siteSearch :: (Core.Maybe Core.Text),+ -- | Specifies whether to include or exclude results from the site named in the @sitesearch@ parameter. Supported values are: * @i@: include content from site * @e@: exclude content from site+ siteSearchFilter :: (Core.Maybe Core.Text),+ -- | Specifies that results should be sorted according to the specified expression. For example, sort by date.+ sort :: (Core.Maybe Core.Text),+ -- | The index of the current set of search results into the total set of results, where the index of the first result is 1.+ startIndex :: (Core.Maybe Core.Int32),+ -- | The page number of this set of results, where the page length is set by the @count@ property.+ startPage :: (Core.Maybe Core.Int32),+ -- | A description of the query.+ title :: (Core.Maybe Core.Text),+ -- | Estimated number of total search results. May not be accurate.+ totalResults :: (Core.Maybe Core.Int64)+ }+ deriving (Core.Eq, Core.Show, Core.Generic)++-- | Creates a value of 'Search_Queries_PreviousPageItem' with the minimum fields required to make a request.+newSearch_Queries_PreviousPageItem ::+ Search_Queries_PreviousPageItem+newSearch_Queries_PreviousPageItem =+ Search_Queries_PreviousPageItem+ { count = Core.Nothing,+ cr = Core.Nothing,+ cx = Core.Nothing,+ dateRestrict = Core.Nothing,+ disableCnTwTranslation = Core.Nothing,+ exactTerms = Core.Nothing,+ excludeTerms = Core.Nothing,+ fileType = Core.Nothing,+ filter = Core.Nothing,+ gl = Core.Nothing,+ googleHost = Core.Nothing,+ highRange = Core.Nothing,+ hl = Core.Nothing,+ hq = Core.Nothing,+ imgColorType = Core.Nothing,+ imgDominantColor = Core.Nothing,+ imgSize = Core.Nothing,+ imgType = Core.Nothing,+ inputEncoding = Core.Nothing,+ language = Core.Nothing,+ linkSite = Core.Nothing,+ lowRange = Core.Nothing,+ orTerms = Core.Nothing,+ outputEncoding = Core.Nothing,+ relatedSite = Core.Nothing,+ rights = Core.Nothing,+ safe = Core.Nothing,+ searchTerms = Core.Nothing,+ searchType = Core.Nothing,+ siteSearch = Core.Nothing,+ siteSearchFilter = Core.Nothing,+ sort = Core.Nothing,+ startIndex = Core.Nothing,+ startPage = Core.Nothing,+ title = Core.Nothing,+ totalResults = Core.Nothing+ }++instance Core.FromJSON Search_Queries_PreviousPageItem where+ parseJSON =+ Core.withObject+ "Search_Queries_PreviousPageItem"+ ( \o ->+ Search_Queries_PreviousPageItem+ Core.<$> (o Core..:? "count")+ Core.<*> (o Core..:? "cr")+ Core.<*> (o Core..:? "cx")+ Core.<*> (o Core..:? "dateRestrict")+ Core.<*> (o Core..:? "disableCnTwTranslation")+ Core.<*> (o Core..:? "exactTerms")+ Core.<*> (o Core..:? "excludeTerms")+ Core.<*> (o Core..:? "fileType")+ Core.<*> (o Core..:? "filter")+ Core.<*> (o Core..:? "gl")+ Core.<*> (o Core..:? "googleHost")+ Core.<*> (o Core..:? "highRange")+ Core.<*> (o Core..:? "hl")+ Core.<*> (o Core..:? "hq")+ Core.<*> (o Core..:? "imgColorType")+ Core.<*> (o Core..:? "imgDominantColor")+ Core.<*> (o Core..:? "imgSize")+ Core.<*> (o Core..:? "imgType")+ Core.<*> (o Core..:? "inputEncoding")+ Core.<*> (o Core..:? "language")+ Core.<*> (o Core..:? "linkSite")+ Core.<*> (o Core..:? "lowRange")+ Core.<*> (o Core..:? "orTerms")+ Core.<*> (o Core..:? "outputEncoding")+ Core.<*> (o Core..:? "relatedSite")+ Core.<*> (o Core..:? "rights")+ Core.<*> (o Core..:? "safe")+ Core.<*> (o Core..:? "searchTerms")+ Core.<*> (o Core..:? "searchType")+ Core.<*> (o Core..:? "siteSearch")+ Core.<*> (o Core..:? "siteSearchFilter")+ Core.<*> (o Core..:? "sort")+ Core.<*> (o Core..:? "startIndex")+ Core.<*> (o Core..:? "startPage")+ Core.<*> (o Core..:? "title")+ Core.<*> (o Core..:? "totalResults" Core.<&> Core.fmap Core.fromAsText)+ )++instance Core.ToJSON Search_Queries_PreviousPageItem where+ toJSON Search_Queries_PreviousPageItem {..} =+ Core.object+ ( Core.catMaybes+ [ ("count" Core..=) Core.<$> count,+ ("cr" Core..=) Core.<$> cr,+ ("cx" Core..=) Core.<$> cx,+ ("dateRestrict" Core..=) Core.<$> dateRestrict,+ ("disableCnTwTranslation" Core..=) Core.<$> disableCnTwTranslation,+ ("exactTerms" Core..=) Core.<$> exactTerms,+ ("excludeTerms" Core..=) Core.<$> excludeTerms,+ ("fileType" Core..=) Core.<$> fileType,+ ("filter" Core..=) Core.<$> filter,+ ("gl" Core..=) Core.<$> gl,+ ("googleHost" Core..=) Core.<$> googleHost,+ ("highRange" Core..=) Core.<$> highRange,+ ("hl" Core..=) Core.<$> hl,+ ("hq" Core..=) Core.<$> hq,+ ("imgColorType" Core..=) Core.<$> imgColorType,+ ("imgDominantColor" Core..=) Core.<$> imgDominantColor,+ ("imgSize" Core..=) Core.<$> imgSize,+ ("imgType" Core..=) Core.<$> imgType,+ ("inputEncoding" Core..=) Core.<$> inputEncoding,+ ("language" Core..=) Core.<$> language,+ ("linkSite" Core..=) Core.<$> linkSite,+ ("lowRange" Core..=) Core.<$> lowRange,+ ("orTerms" Core..=) Core.<$> orTerms,+ ("outputEncoding" Core..=) Core.<$> outputEncoding,+ ("relatedSite" Core..=) Core.<$> relatedSite,+ ("rights" Core..=) Core.<$> rights,+ ("safe" Core..=) Core.<$> safe,+ ("searchTerms" Core..=) Core.<$> searchTerms,+ ("searchType" Core..=) Core.<$> searchType,+ ("siteSearch" Core..=) Core.<$> siteSearch,+ ("siteSearchFilter" Core..=) Core.<$> siteSearchFilter,+ ("sort" Core..=) Core.<$> sort,+ ("startIndex" Core..=) Core.<$> startIndex,+ ("startPage" Core..=) Core.<$> startPage,+ ("title" Core..=) Core.<$> title,+ ("totalResults" Core..=) Core.. Core.AsText Core.<$> totalResults+ ]+ )++-- | Custom search request metadata.+--+-- /See:/ 'newSearch_Queries_RequestItem' smart constructor.+data Search_Queries_RequestItem = Search_Queries_RequestItem+ { -- | Number of search results returned in this set.+ count :: (Core.Maybe Core.Int32),+ -- | Restricts search results to documents originating in a particular country. You may use <https://developers.google.com/custom-search/docs/json_api_reference#BooleanOrSearch Boolean operators> in the @cr@ parameter\'s value. Google WebSearch determines the country of a document by analyzing the following: * The top-level domain (TLD) of the document\'s URL. * The geographic location of the web server\'s IP address. See <https://developers.google.com/custom-search/docs/json_api_reference#countryCollections Country (cr) Parameter Values> for a list of valid values for this parameter.+ cr :: (Core.Maybe Core.Text),+ -- | The identifier of an engine created using the Programmable Search Engine <https://programmablesearchengine.google.com/ Control Panel>. This is a custom property not defined in the OpenSearch spec. This parameter is __required__.+ cx :: (Core.Maybe Core.Text),+ -- | Restricts results to URLs based on date. Supported values include: * @d[number]@: requests results from the specified number of past days. * @w[number]@: requests results from the specified number of past weeks. * @m[number]@: requests results from the specified number of past months. * @y[number]@: requests results from the specified number of past years.+ dateRestrict :: (Core.Maybe Core.Text),+ -- | Enables or disables the <https://developers.google.com/custom-search/docs/json_api_reference#chineseSearch Simplified and Traditional Chinese Search> feature. Supported values are: * @0@: enabled (default) * @1@: disabled+ disableCnTwTranslation :: (Core.Maybe Core.Text),+ -- | Identifies a phrase that all documents in the search results must contain.+ exactTerms :: (Core.Maybe Core.Text),+ -- | Identifies a word or phrase that should not appear in any documents in the search results.+ excludeTerms :: (Core.Maybe Core.Text),+ -- | Restricts results to files of a specified extension. Filetypes supported by Google include: * Adobe Portable Document Format (@pdf@) * Adobe PostScript (@ps@) * Lotus 1-2-3 (@wk1@, @wk2@, @wk3@, @wk4@, @wk5@, @wki@, @wks@, @wku@) * Lotus WordPro (@lwp@) * Macwrite (@mw@) * Microsoft Excel (@xls@) * Microsoft PowerPoint (@ppt@) * Microsoft Word (@doc@) * Microsoft Works (@wks@, @wps@, @wdb@) * Microsoft Write (@wri@) * Rich Text Format (@rtf@) * Shockwave Flash (@swf@) * Text (@ans@, @txt@). Additional filetypes may be added in the future. An up-to-date list can always be found in Google\'s <https://support.google.com/webmasters/answer/35287 file type FAQ>.+ fileType :: (Core.Maybe Core.Text),+ -- | Activates or deactivates the automatic filtering of Google search results. See <https://developers.google.com/custom-search/docs/json_api_reference#automaticFiltering Automatic Filtering> for more information about Google\'s search results filters. Valid values for this parameter are: * @0@: Disabled * @1@: Enabled (default) __Note__: By default, Google applies filtering to all search results to improve the quality of those results.+ filter :: (Core.Maybe Core.Text),+ -- | Boosts search results whose country of origin matches the parameter value. See <https://developers.google.com/custom-search/docs/json_api_reference#countryCodes Country Codes> for a list of valid values. Specifying a @gl@ parameter value in WebSearch requests should improve the relevance of results. This is particularly true for international customers and, even more specifically, for customers in English-speaking countries other than the United States.+ gl :: (Core.Maybe Core.Text),+ -- | Specifies the Google domain (for example, google.com, google.de, or google.fr) to which the search should be limited.+ googleHost :: (Core.Maybe Core.Text),+ -- | Specifies the ending value for a search range. Use @cse:lowRange@ and @cse:highrange@ to append an inclusive search range of @lowRange...highRange@ to the query.+ highRange :: (Core.Maybe Core.Text),+ -- | Specifies the interface language (host language) of your user interface. Explicitly setting this parameter improves the performance and the quality of your search results. See the <https://developers.google.com/custom-search/docs/json_api_reference#wsInterfaceLanguages Interface Languages> section of <https://developers.google.com/custom-search/docs/json_api_reference#wsInternationalizing Internationalizing Queries and Results Presentation> for more information, and <https://developers.google.com/custom-search/docs/json_api_reference#interfaceLanguages Supported Interface Languages> for a list of supported languages.+ hl :: (Core.Maybe Core.Text),+ -- | Appends the specified query terms to the query, as if they were combined with a logical @AND@ operator.+ hq :: (Core.Maybe Core.Text),+ -- | Restricts results to images of a specified color type. Supported values are: * @mono@ (black and white) * @gray@ (grayscale) * @color@ (color)+ imgColorType :: (Core.Maybe Core.Text),+ -- | Restricts results to images with a specific dominant color. Supported values are: * @red@ * @orange@ * @yellow@ * @green@ * @teal@ * @blue@ * @purple@ * @pink@ * @white@ * @gray@ * @black@ * @brown@+ imgDominantColor :: (Core.Maybe Core.Text),+ -- | Restricts results to images of a specified size. Supported values are: * @icon@ (small) * @small | medium | large | xlarge@ (medium) * @xxlarge@ (large) * @huge@ (extra-large)+ imgSize :: (Core.Maybe Core.Text),+ -- | Restricts results to images of a specified type. Supported values are: * @clipart@ (Clip art) * @face@ (Face) * @lineart@ (Line drawing) * @photo@ (Photo) * @animated@ (Animated) * @stock@ (Stock)+ imgType :: (Core.Maybe Core.Text),+ -- | The character encoding supported for search requests.+ inputEncoding :: (Core.Maybe Core.Text),+ -- | The language of the search results.+ language :: (Core.Maybe Core.Text),+ -- | Specifies that all results should contain a link to a specific URL.+ linkSite :: (Core.Maybe Core.Text),+ -- | Specifies the starting value for a search range. Use @cse:lowRange@ and @cse:highrange@ to append an inclusive search range of @lowRange...highRange@ to the query.+ lowRange :: (Core.Maybe Core.Text),+ -- | Provides additional search terms to check for in a document, where each document in the search results must contain at least one of the additional search terms. You can also use the <https://developers.google.com/custom-search/docs/json_api_reference#BooleanOrSearch Boolean OR> query term for this type of query.+ orTerms :: (Core.Maybe Core.Text),+ -- | The character encoding supported for search results.+ outputEncoding :: (Core.Maybe Core.Text),+ -- | Specifies that all search results should be pages that are related to the specified URL. The parameter value should be a URL.+ relatedSite :: (Core.Maybe Core.Text),+ -- | Filters based on licensing. Supported values include: * @cc_publicdomain@ * @cc_attribute@ * @cc_sharealike@ * @cc_noncommercial@ * @cc_nonderived@+ rights :: (Core.Maybe Core.Text),+ -- | Specifies the <https://developers.google.com/custom-search/docs/json_api_reference#safeSearchLevels SafeSearch level> used for filtering out adult results. This is a custom property not defined in the OpenSearch spec. Valid parameter values are: * @\"off\"@: Disable SafeSearch * @\"active\"@: Enable SafeSearch+ safe :: (Core.Maybe Core.Text),+ -- | The search terms entered by the user.+ searchTerms :: (Core.Maybe Core.Text),+ -- | Allowed values are @web@ or @image@. If unspecified, results are limited to webpages.+ searchType :: (Core.Maybe Core.Text),+ -- | Restricts results to URLs from a specified site.+ siteSearch :: (Core.Maybe Core.Text),+ -- | Specifies whether to include or exclude results from the site named in the @sitesearch@ parameter. Supported values are: * @i@: include content from site * @e@: exclude content from site+ siteSearchFilter :: (Core.Maybe Core.Text),+ -- | Specifies that results should be sorted according to the specified expression. For example, sort by date.+ sort :: (Core.Maybe Core.Text),+ -- | The index of the current set of search results into the total set of results, where the index of the first result is 1.+ startIndex :: (Core.Maybe Core.Int32),+ -- | The page number of this set of results, where the page length is set by the @count@ property.+ startPage :: (Core.Maybe Core.Int32),+ -- | A description of the query.+ title :: (Core.Maybe Core.Text),+ -- | Estimated number of total search results. May not be accurate.+ totalResults :: (Core.Maybe Core.Int64)+ }+ deriving (Core.Eq, Core.Show, Core.Generic)++-- | Creates a value of 'Search_Queries_RequestItem' with the minimum fields required to make a request.+newSearch_Queries_RequestItem ::+ Search_Queries_RequestItem+newSearch_Queries_RequestItem =+ Search_Queries_RequestItem+ { count = Core.Nothing,+ cr = Core.Nothing,+ cx = Core.Nothing,+ dateRestrict = Core.Nothing,+ disableCnTwTranslation = Core.Nothing,+ exactTerms = Core.Nothing,+ excludeTerms = Core.Nothing,+ fileType = Core.Nothing,+ filter = Core.Nothing,+ gl = Core.Nothing,+ googleHost = Core.Nothing,+ highRange = Core.Nothing,+ hl = Core.Nothing,+ hq = Core.Nothing,+ imgColorType = Core.Nothing,+ imgDominantColor = Core.Nothing,+ imgSize = Core.Nothing,+ imgType = Core.Nothing,+ inputEncoding = Core.Nothing,+ language = Core.Nothing,+ linkSite = Core.Nothing,+ lowRange = Core.Nothing,+ orTerms = Core.Nothing,+ outputEncoding = Core.Nothing,+ relatedSite = Core.Nothing,+ rights = Core.Nothing,+ safe = Core.Nothing,+ searchTerms = Core.Nothing,+ searchType = Core.Nothing,+ siteSearch = Core.Nothing,+ siteSearchFilter = Core.Nothing,+ sort = Core.Nothing,+ startIndex = Core.Nothing,+ startPage = Core.Nothing,+ title = Core.Nothing,+ totalResults = Core.Nothing+ }++instance Core.FromJSON Search_Queries_RequestItem where+ parseJSON =+ Core.withObject+ "Search_Queries_RequestItem"+ ( \o ->+ Search_Queries_RequestItem+ Core.<$> (o Core..:? "count")+ Core.<*> (o Core..:? "cr")+ Core.<*> (o Core..:? "cx")+ Core.<*> (o Core..:? "dateRestrict")+ Core.<*> (o Core..:? "disableCnTwTranslation")+ Core.<*> (o Core..:? "exactTerms")+ Core.<*> (o Core..:? "excludeTerms")+ Core.<*> (o Core..:? "fileType")+ Core.<*> (o Core..:? "filter")+ Core.<*> (o Core..:? "gl")+ Core.<*> (o Core..:? "googleHost")+ Core.<*> (o Core..:? "highRange")+ Core.<*> (o Core..:? "hl")+ Core.<*> (o Core..:? "hq")+ Core.<*> (o Core..:? "imgColorType")+ Core.<*> (o Core..:? "imgDominantColor")+ Core.<*> (o Core..:? "imgSize")+ Core.<*> (o Core..:? "imgType")+ Core.<*> (o Core..:? "inputEncoding")+ Core.<*> (o Core..:? "language")+ Core.<*> (o Core..:? "linkSite")+ Core.<*> (o Core..:? "lowRange")+ Core.<*> (o Core..:? "orTerms")+ Core.<*> (o Core..:? "outputEncoding")+ Core.<*> (o Core..:? "relatedSite")+ Core.<*> (o Core..:? "rights")+ Core.<*> (o Core..:? "safe")+ Core.<*> (o Core..:? "searchTerms")+ Core.<*> (o Core..:? "searchType")+ Core.<*> (o Core..:? "siteSearch")+ Core.<*> (o Core..:? "siteSearchFilter")+ Core.<*> (o Core..:? "sort")+ Core.<*> (o Core..:? "startIndex")+ Core.<*> (o Core..:? "startPage")+ Core.<*> (o Core..:? "title")+ Core.<*> (o Core..:? "totalResults" Core.<&> Core.fmap Core.fromAsText)+ )++instance Core.ToJSON Search_Queries_RequestItem where+ toJSON Search_Queries_RequestItem {..} =+ Core.object+ ( Core.catMaybes+ [ ("count" Core..=) Core.<$> count,+ ("cr" Core..=) Core.<$> cr,+ ("cx" Core..=) Core.<$> cx,+ ("dateRestrict" Core..=) Core.<$> dateRestrict,+ ("disableCnTwTranslation" Core..=) Core.<$> disableCnTwTranslation,+ ("exactTerms" Core..=) Core.<$> exactTerms,+ ("excludeTerms" Core..=) Core.<$> excludeTerms,+ ("fileType" Core..=) Core.<$> fileType,+ ("filter" Core..=) Core.<$> filter,+ ("gl" Core..=) Core.<$> gl,+ ("googleHost" Core..=) Core.<$> googleHost,+ ("highRange" Core..=) Core.<$> highRange,+ ("hl" Core..=) Core.<$> hl,+ ("hq" Core..=) Core.<$> hq,+ ("imgColorType" Core..=) Core.<$> imgColorType,+ ("imgDominantColor" Core..=) Core.<$> imgDominantColor,+ ("imgSize" Core..=) Core.<$> imgSize,+ ("imgType" Core..=) Core.<$> imgType,+ ("inputEncoding" Core..=) Core.<$> inputEncoding,+ ("language" Core..=) Core.<$> language,+ ("linkSite" Core..=) Core.<$> linkSite,+ ("lowRange" Core..=) Core.<$> lowRange,+ ("orTerms" Core..=) Core.<$> orTerms,+ ("outputEncoding" Core..=) Core.<$> outputEncoding,+ ("relatedSite" Core..=) Core.<$> relatedSite,+ ("rights" Core..=) Core.<$> rights,+ ("safe" Core..=) Core.<$> safe,+ ("searchTerms" Core..=) Core.<$> searchTerms,+ ("searchType" Core..=) Core.<$> searchType,+ ("siteSearch" Core..=) Core.<$> siteSearch,+ ("siteSearchFilter" Core..=) Core.<$> siteSearchFilter,+ ("sort" Core..=) Core.<$> sort,+ ("startIndex" Core..=) Core.<$> startIndex,+ ("startPage" Core..=) Core.<$> startPage,+ ("title" Core..=) Core.<$> title,+ ("totalResults" Core..=) Core.. Core.AsText Core.<$> totalResults+ ]+ )++-- | Metadata about a search operation.+--+-- /See:/ 'newSearch_SearchInformation' smart constructor.+data Search_SearchInformation = Search_SearchInformation+ { -- | The time taken for the server to return search results, formatted according to locale style.+ formattedSearchTime :: (Core.Maybe Core.Text),+ -- | The total number of search results, formatted according to locale style.+ formattedTotalResults :: (Core.Maybe Core.Text),+ -- | The time taken for the server to return search results.+ searchTime :: (Core.Maybe Core.Double),+ -- | The total number of search results returned by the query.+ totalResults :: (Core.Maybe Core.Text)+ }+ deriving (Core.Eq, Core.Show, Core.Generic)++-- | Creates a value of 'Search_SearchInformation' with the minimum fields required to make a request.+newSearch_SearchInformation ::+ Search_SearchInformation+newSearch_SearchInformation =+ Search_SearchInformation+ { formattedSearchTime = Core.Nothing,+ formattedTotalResults = Core.Nothing,+ searchTime = Core.Nothing,+ totalResults = Core.Nothing+ }++instance Core.FromJSON Search_SearchInformation where+ parseJSON =+ Core.withObject+ "Search_SearchInformation"+ ( \o ->+ Search_SearchInformation+ Core.<$> (o Core..:? "formattedSearchTime")+ Core.<*> (o Core..:? "formattedTotalResults")+ Core.<*> (o Core..:? "searchTime")+ Core.<*> (o Core..:? "totalResults")+ )++instance Core.ToJSON Search_SearchInformation where+ toJSON Search_SearchInformation {..} =+ Core.object+ ( Core.catMaybes+ [ ("formattedSearchTime" Core..=) Core.<$> formattedSearchTime,+ ("formattedTotalResults" Core..=) Core.<$> formattedTotalResults,+ ("searchTime" Core..=) Core.<$> searchTime,+ ("totalResults" Core..=) Core.<$> totalResults+ ]+ )++-- | Spell correction information for a query.+--+-- /See:/ 'newSearch_Spelling' smart constructor.+data Search_Spelling = Search_Spelling+ { -- | The corrected query.+ correctedQuery :: (Core.Maybe Core.Text),+ -- | The corrected query, formatted in HTML.+ htmlCorrectedQuery :: (Core.Maybe Core.Text)+ }+ deriving (Core.Eq, Core.Show, Core.Generic)++-- | Creates a value of 'Search_Spelling' with the minimum fields required to make a request.+newSearch_Spelling ::+ Search_Spelling+newSearch_Spelling =+ Search_Spelling+ { correctedQuery = Core.Nothing,+ htmlCorrectedQuery = Core.Nothing+ }++instance Core.FromJSON Search_Spelling where+ parseJSON =+ Core.withObject+ "Search_Spelling"+ ( \o ->+ Search_Spelling+ Core.<$> (o Core..:? "correctedQuery")+ Core.<*> (o Core..:? "htmlCorrectedQuery")+ )++instance Core.ToJSON Search_Spelling where+ toJSON Search_Spelling {..} =+ Core.object+ ( Core.catMaybes+ [ ("correctedQuery" Core..=) Core.<$> correctedQuery,+ ("htmlCorrectedQuery" Core..=) Core.<$> htmlCorrectedQuery+ ]+ )++-- | OpenSearch template and URL.+--+-- /See:/ 'newSearch_Url' smart constructor.+data Search_Url = Search_Url+ { -- | The actual <http://www.opensearch.org/specifications/opensearch/1.1#opensearch_url_template_syntax OpenSearch template> for this API.+ template :: (Core.Maybe Core.Text),+ -- | The MIME type of the OpenSearch URL template for the Custom Search JSON API.+ type' :: (Core.Maybe Core.Text)+ }+ deriving (Core.Eq, Core.Show, Core.Generic)++-- | Creates a value of 'Search_Url' with the minimum fields required to make a request.+newSearch_Url ::+ Search_Url+newSearch_Url =+ Search_Url {template = Core.Nothing, type' = Core.Nothing}++instance Core.FromJSON Search_Url where+ parseJSON =+ Core.withObject+ "Search_Url"+ ( \o ->+ Search_Url+ Core.<$> (o Core..:? "template")+ Core.<*> (o Core..:? "type")+ )++instance Core.ToJSON Search_Url where+ toJSON Search_Url {..} =+ Core.object+ ( Core.catMaybes+ [ ("template" Core..=) Core.<$> template,+ ("type" Core..=) Core.<$> type'+ ]+ )
+ gen/Gogol/CustomSearch/Internal/Sum.hs view
@@ -0,0 +1,887 @@+{-# LANGUAGE DataKinds #-}+{-# LANGUAGE DerivingStrategies #-}+{-# LANGUAGE DuplicateRecordFields #-}+{-# LANGUAGE ImportQualifiedPost #-}+{-# LANGUAGE LambdaCase #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE PatternSynonyms #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE TypeFamilies #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}+{-# OPTIONS_GHC -fno-warn-name-shadowing #-}+{-# OPTIONS_GHC -fno-warn-unused-binds #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- |+-- Module : Gogol.CustomSearch.Internal.Sum+-- Copyright : (c) 2015-2025 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay <brendan.g.hay+gogol@gmail.com>+-- Toni Cebrián <toni@tonicebrian.com>+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+module Gogol.CustomSearch.Internal.Sum+ ( -- * Xgafv+ Xgafv+ ( Xgafv_1,+ Xgafv_2,+ ..+ ),++ -- * CseListImgColorType+ CseListImgColorType+ ( CseListImgColorType_ImgColorTypeUndefined,+ CseListImgColorType_Mono,+ CseListImgColorType_Gray,+ CseListImgColorType_Color,+ CseListImgColorType_Trans,+ ..+ ),++ -- * CseListImgDominantColor+ CseListImgDominantColor+ ( CseListImgDominantColor_ImgDominantColorUndefined,+ CseListImgDominantColor_Black,+ CseListImgDominantColor_Blue,+ CseListImgDominantColor_Brown,+ CseListImgDominantColor_Gray,+ CseListImgDominantColor_Green,+ CseListImgDominantColor_Orange,+ CseListImgDominantColor_Pink,+ CseListImgDominantColor_Purple,+ CseListImgDominantColor_Red,+ CseListImgDominantColor_Teal,+ CseListImgDominantColor_White,+ CseListImgDominantColor_Yellow,+ ..+ ),++ -- * CseListImgSize+ CseListImgSize+ ( CseListImgSize_ImgSizeUndefined,+ CseListImgSize_Huge,+ CseListImgSize_Icon,+ CseListImgSize_Large,+ CseListImgSize_Medium,+ CseListImgSize_Small,+ CseListImgSize_Xlarge,+ CseListImgSize_Xxlarge,+ ..+ ),++ -- * CseListImgType+ CseListImgType+ ( CseListImgType_ImgTypeUndefined,+ CseListImgType_Clipart,+ CseListImgType_Face,+ CseListImgType_Lineart,+ CseListImgType_Stock,+ CseListImgType_Photo,+ CseListImgType_Animated,+ ..+ ),++ -- * CseListSafe+ CseListSafe+ ( CseListSafe_SafeUndefined,+ CseListSafe_Active,+ CseListSafe_High,+ CseListSafe_Medium,+ CseListSafe_Off,+ ..+ ),++ -- * CseListSearchType+ CseListSearchType+ ( CseListSearchType_SearchTypeUndefined,+ CseListSearchType_Image,+ ..+ ),++ -- * CseListSiteSearchFilter+ CseListSiteSearchFilter+ ( CseListSiteSearchFilter_SiteSearchFilterUndefined,+ CseListSiteSearchFilter_E,+ CseListSiteSearchFilter_I,+ ..+ ),++ -- * CseSiterestrictListImgColorType+ CseSiterestrictListImgColorType+ ( CseSiterestrictListImgColorType_ImgColorTypeUndefined,+ CseSiterestrictListImgColorType_Mono,+ CseSiterestrictListImgColorType_Gray,+ CseSiterestrictListImgColorType_Color,+ CseSiterestrictListImgColorType_Trans,+ ..+ ),++ -- * CseSiterestrictListImgDominantColor+ CseSiterestrictListImgDominantColor+ ( CseSiterestrictListImgDominantColor_ImgDominantColorUndefined,+ CseSiterestrictListImgDominantColor_Black,+ CseSiterestrictListImgDominantColor_Blue,+ CseSiterestrictListImgDominantColor_Brown,+ CseSiterestrictListImgDominantColor_Gray,+ CseSiterestrictListImgDominantColor_Green,+ CseSiterestrictListImgDominantColor_Orange,+ CseSiterestrictListImgDominantColor_Pink,+ CseSiterestrictListImgDominantColor_Purple,+ CseSiterestrictListImgDominantColor_Red,+ CseSiterestrictListImgDominantColor_Teal,+ CseSiterestrictListImgDominantColor_White,+ CseSiterestrictListImgDominantColor_Yellow,+ ..+ ),++ -- * CseSiterestrictListImgSize+ CseSiterestrictListImgSize+ ( CseSiterestrictListImgSize_ImgSizeUndefined,+ CseSiterestrictListImgSize_Huge,+ CseSiterestrictListImgSize_Icon,+ CseSiterestrictListImgSize_Large,+ CseSiterestrictListImgSize_Medium,+ CseSiterestrictListImgSize_Small,+ CseSiterestrictListImgSize_Xlarge,+ CseSiterestrictListImgSize_Xxlarge,+ ..+ ),++ -- * CseSiterestrictListImgType+ CseSiterestrictListImgType+ ( CseSiterestrictListImgType_ImgTypeUndefined,+ CseSiterestrictListImgType_Clipart,+ CseSiterestrictListImgType_Face,+ CseSiterestrictListImgType_Lineart,+ CseSiterestrictListImgType_Stock,+ CseSiterestrictListImgType_Photo,+ CseSiterestrictListImgType_Animated,+ ..+ ),++ -- * CseSiterestrictListSafe+ CseSiterestrictListSafe+ ( CseSiterestrictListSafe_SafeUndefined,+ CseSiterestrictListSafe_Active,+ CseSiterestrictListSafe_High,+ CseSiterestrictListSafe_Medium,+ CseSiterestrictListSafe_Off,+ ..+ ),++ -- * CseSiterestrictListSearchType+ CseSiterestrictListSearchType+ ( CseSiterestrictListSearchType_SearchTypeUndefined,+ CseSiterestrictListSearchType_Image,+ ..+ ),++ -- * CseSiterestrictListSiteSearchFilter+ CseSiterestrictListSiteSearchFilter+ ( CseSiterestrictListSiteSearchFilter_SiteSearchFilterUndefined,+ CseSiterestrictListSiteSearchFilter_E,+ CseSiterestrictListSiteSearchFilter_I,+ ..+ ),+ )+where++import Gogol.Prelude qualified as Core++-- | V1 error format.+newtype Xgafv = Xgafv {fromXgafv :: Core.Text}+ deriving stock (Core.Show, Core.Read, Core.Eq, Core.Ord, Core.Generic)+ deriving newtype+ ( Core.Hashable,+ Core.ToHttpApiData,+ Core.FromHttpApiData,+ Core.ToJSON,+ Core.ToJSONKey,+ Core.FromJSON,+ Core.FromJSONKey+ )++-- | v1 error format+pattern Xgafv_1 :: Xgafv+pattern Xgafv_1 = Xgafv "1"++-- | v2 error format+pattern Xgafv_2 :: Xgafv+pattern Xgafv_2 = Xgafv "2"++{-# COMPLETE+ Xgafv_1,+ Xgafv_2,+ Xgafv+ #-}++-- | Returns black and white, grayscale, transparent, or color images. Acceptable values are: * @\"color\"@ * @\"gray\"@ * @\"mono\"@: black and white * @\"trans\"@: transparent background+newtype CseListImgColorType = CseListImgColorType {fromCseListImgColorType :: Core.Text}+ deriving stock (Core.Show, Core.Read, Core.Eq, Core.Ord, Core.Generic)+ deriving newtype+ ( Core.Hashable,+ Core.ToHttpApiData,+ Core.FromHttpApiData,+ Core.ToJSON,+ Core.ToJSONKey,+ Core.FromJSON,+ Core.FromJSONKey+ )++-- | No image color type specified.+pattern CseListImgColorType_ImgColorTypeUndefined :: CseListImgColorType+pattern CseListImgColorType_ImgColorTypeUndefined = CseListImgColorType "imgColorTypeUndefined"++-- | Black and white images only.+pattern CseListImgColorType_Mono :: CseListImgColorType+pattern CseListImgColorType_Mono = CseListImgColorType "mono"++-- | Grayscale images only.+pattern CseListImgColorType_Gray :: CseListImgColorType+pattern CseListImgColorType_Gray = CseListImgColorType "gray"++-- | Color images only.+pattern CseListImgColorType_Color :: CseListImgColorType+pattern CseListImgColorType_Color = CseListImgColorType "color"++-- | Images with transparent background+pattern CseListImgColorType_Trans :: CseListImgColorType+pattern CseListImgColorType_Trans = CseListImgColorType "trans"++{-# COMPLETE+ CseListImgColorType_ImgColorTypeUndefined,+ CseListImgColorType_Mono,+ CseListImgColorType_Gray,+ CseListImgColorType_Color,+ CseListImgColorType_Trans,+ CseListImgColorType+ #-}++-- | Returns images of a specific dominant color. Acceptable values are: * @\"black\"@ * @\"blue\"@ * @\"brown\"@ * @\"gray\"@ * @\"green\"@ * @\"orange\"@ * @\"pink\"@ * @\"purple\"@ * @\"red\"@ * @\"teal\"@ * @\"white\"@ * @\"yellow\"@+newtype CseListImgDominantColor = CseListImgDominantColor {fromCseListImgDominantColor :: Core.Text}+ deriving stock (Core.Show, Core.Read, Core.Eq, Core.Ord, Core.Generic)+ deriving newtype+ ( Core.Hashable,+ Core.ToHttpApiData,+ Core.FromHttpApiData,+ Core.ToJSON,+ Core.ToJSONKey,+ Core.FromJSON,+ Core.FromJSONKey+ )++-- | No dominant color specified.+pattern CseListImgDominantColor_ImgDominantColorUndefined :: CseListImgDominantColor+pattern CseListImgDominantColor_ImgDominantColorUndefined = CseListImgDominantColor "imgDominantColorUndefined"++-- | Predominantly black images only.+pattern CseListImgDominantColor_Black :: CseListImgDominantColor+pattern CseListImgDominantColor_Black = CseListImgDominantColor "black"++-- | Predominantly blue images only.+pattern CseListImgDominantColor_Blue :: CseListImgDominantColor+pattern CseListImgDominantColor_Blue = CseListImgDominantColor "blue"++-- | Predominantly brown images only.+pattern CseListImgDominantColor_Brown :: CseListImgDominantColor+pattern CseListImgDominantColor_Brown = CseListImgDominantColor "brown"++-- | Predominantly gray images only.+pattern CseListImgDominantColor_Gray :: CseListImgDominantColor+pattern CseListImgDominantColor_Gray = CseListImgDominantColor "gray"++-- | Predominantly green images only.+pattern CseListImgDominantColor_Green :: CseListImgDominantColor+pattern CseListImgDominantColor_Green = CseListImgDominantColor "green"++-- | Predominantly orange images only.+pattern CseListImgDominantColor_Orange :: CseListImgDominantColor+pattern CseListImgDominantColor_Orange = CseListImgDominantColor "orange"++-- | Predominantly pink images only.+pattern CseListImgDominantColor_Pink :: CseListImgDominantColor+pattern CseListImgDominantColor_Pink = CseListImgDominantColor "pink"++-- | Predominantly purple images only.+pattern CseListImgDominantColor_Purple :: CseListImgDominantColor+pattern CseListImgDominantColor_Purple = CseListImgDominantColor "purple"++-- | Predominantly red images only.+pattern CseListImgDominantColor_Red :: CseListImgDominantColor+pattern CseListImgDominantColor_Red = CseListImgDominantColor "red"++-- | Predominantly teal images only.+pattern CseListImgDominantColor_Teal :: CseListImgDominantColor+pattern CseListImgDominantColor_Teal = CseListImgDominantColor "teal"++-- | Predominantly white images only.+pattern CseListImgDominantColor_White :: CseListImgDominantColor+pattern CseListImgDominantColor_White = CseListImgDominantColor "white"++-- | Predominantly yellow images only.+pattern CseListImgDominantColor_Yellow :: CseListImgDominantColor+pattern CseListImgDominantColor_Yellow = CseListImgDominantColor "yellow"++{-# COMPLETE+ CseListImgDominantColor_ImgDominantColorUndefined,+ CseListImgDominantColor_Black,+ CseListImgDominantColor_Blue,+ CseListImgDominantColor_Brown,+ CseListImgDominantColor_Gray,+ CseListImgDominantColor_Green,+ CseListImgDominantColor_Orange,+ CseListImgDominantColor_Pink,+ CseListImgDominantColor_Purple,+ CseListImgDominantColor_Red,+ CseListImgDominantColor_Teal,+ CseListImgDominantColor_White,+ CseListImgDominantColor_Yellow,+ CseListImgDominantColor+ #-}++-- | Returns images of a specified size. Acceptable values are: * @\"huge\"@ * @\"icon\"@ * @\"large\"@ * @\"medium\"@ * @\"small\"@ * @\"xlarge\"@ * @\"xxlarge\"@+newtype CseListImgSize = CseListImgSize {fromCseListImgSize :: Core.Text}+ deriving stock (Core.Show, Core.Read, Core.Eq, Core.Ord, Core.Generic)+ deriving newtype+ ( Core.Hashable,+ Core.ToHttpApiData,+ Core.FromHttpApiData,+ Core.ToJSON,+ Core.ToJSONKey,+ Core.FromJSON,+ Core.FromJSONKey+ )++-- | No image size specified.+pattern CseListImgSize_ImgSizeUndefined :: CseListImgSize+pattern CseListImgSize_ImgSizeUndefined = CseListImgSize "imgSizeUndefined"++-- | Only the largest possible images.+pattern CseListImgSize_Huge :: CseListImgSize+pattern CseListImgSize_Huge = CseListImgSize "HUGE"++-- | Only very small icon-sized images.+pattern CseListImgSize_Icon :: CseListImgSize+pattern CseListImgSize_Icon = CseListImgSize "ICON"++-- | Only large images.+pattern CseListImgSize_Large :: CseListImgSize+pattern CseListImgSize_Large = CseListImgSize "LARGE"++-- | Only medium images.+pattern CseListImgSize_Medium :: CseListImgSize+pattern CseListImgSize_Medium = CseListImgSize "MEDIUM"++-- | Only small images.+pattern CseListImgSize_Small :: CseListImgSize+pattern CseListImgSize_Small = CseListImgSize "SMALL"++-- | Only very large images.+pattern CseListImgSize_Xlarge :: CseListImgSize+pattern CseListImgSize_Xlarge = CseListImgSize "XLARGE"++-- | Only extremely large images.+pattern CseListImgSize_Xxlarge :: CseListImgSize+pattern CseListImgSize_Xxlarge = CseListImgSize "XXLARGE"++{-# COMPLETE+ CseListImgSize_ImgSizeUndefined,+ CseListImgSize_Huge,+ CseListImgSize_Icon,+ CseListImgSize_Large,+ CseListImgSize_Medium,+ CseListImgSize_Small,+ CseListImgSize_Xlarge,+ CseListImgSize_Xxlarge,+ CseListImgSize+ #-}++-- | Returns images of a type. Acceptable values are: * @\"clipart\"@ * @\"face\"@ * @\"lineart\"@ * @\"stock\"@ * @\"photo\"@ * @\"animated\"@+newtype CseListImgType = CseListImgType {fromCseListImgType :: Core.Text}+ deriving stock (Core.Show, Core.Read, Core.Eq, Core.Ord, Core.Generic)+ deriving newtype+ ( Core.Hashable,+ Core.ToHttpApiData,+ Core.FromHttpApiData,+ Core.ToJSON,+ Core.ToJSONKey,+ Core.FromJSON,+ Core.FromJSONKey+ )++-- | No image type specified.+pattern CseListImgType_ImgTypeUndefined :: CseListImgType+pattern CseListImgType_ImgTypeUndefined = CseListImgType "imgTypeUndefined"++-- | Clipart-style images only.+pattern CseListImgType_Clipart :: CseListImgType+pattern CseListImgType_Clipart = CseListImgType "clipart"++-- | Images of faces only.+pattern CseListImgType_Face :: CseListImgType+pattern CseListImgType_Face = CseListImgType "face"++-- | Line art images only.+pattern CseListImgType_Lineart :: CseListImgType+pattern CseListImgType_Lineart = CseListImgType "lineart"++-- | Stock images only.+pattern CseListImgType_Stock :: CseListImgType+pattern CseListImgType_Stock = CseListImgType "stock"++-- | Photo images only.+pattern CseListImgType_Photo :: CseListImgType+pattern CseListImgType_Photo = CseListImgType "photo"++-- | Animated images only.+pattern CseListImgType_Animated :: CseListImgType+pattern CseListImgType_Animated = CseListImgType "animated"++{-# COMPLETE+ CseListImgType_ImgTypeUndefined,+ CseListImgType_Clipart,+ CseListImgType_Face,+ CseListImgType_Lineart,+ CseListImgType_Stock,+ CseListImgType_Photo,+ CseListImgType_Animated,+ CseListImgType+ #-}++-- | Search safety level. Acceptable values are: * @\"active\"@: Enables SafeSearch filtering. * @\"off\"@: Disables SafeSearch filtering. (default)+newtype CseListSafe = CseListSafe {fromCseListSafe :: Core.Text}+ deriving stock (Core.Show, Core.Read, Core.Eq, Core.Ord, Core.Generic)+ deriving newtype+ ( Core.Hashable,+ Core.ToHttpApiData,+ Core.FromHttpApiData,+ Core.ToJSON,+ Core.ToJSONKey,+ Core.FromJSON,+ Core.FromJSONKey+ )++-- | SafeSearch mode unspecified. (Falls back to engine\'s configuration.)+pattern CseListSafe_SafeUndefined :: CseListSafe+pattern CseListSafe_SafeUndefined = CseListSafe "safeUndefined"++-- | Turn SafeSearch on.+pattern CseListSafe_Active :: CseListSafe+pattern CseListSafe_Active = CseListSafe "active"++-- | Deprecated, equivalent to \"active\".+pattern CseListSafe_High :: CseListSafe+pattern CseListSafe_High = CseListSafe "high"++-- | Deprecated, equivalent to \"active\".+pattern CseListSafe_Medium :: CseListSafe+pattern CseListSafe_Medium = CseListSafe "medium"++-- | Turn SafeSearch off.+pattern CseListSafe_Off :: CseListSafe+pattern CseListSafe_Off = CseListSafe "off"++{-# COMPLETE+ CseListSafe_SafeUndefined,+ CseListSafe_Active,+ CseListSafe_High,+ CseListSafe_Medium,+ CseListSafe_Off,+ CseListSafe+ #-}++-- | Specifies the search type: @image@. If unspecified, results are limited to webpages. Acceptable values are: * @\"image\"@: custom image search.+newtype CseListSearchType = CseListSearchType {fromCseListSearchType :: Core.Text}+ deriving stock (Core.Show, Core.Read, Core.Eq, Core.Ord, Core.Generic)+ deriving newtype+ ( Core.Hashable,+ Core.ToHttpApiData,+ Core.FromHttpApiData,+ Core.ToJSON,+ Core.ToJSONKey,+ Core.FromJSON,+ Core.FromJSONKey+ )++-- | Search type unspecified (defaults to web search).+pattern CseListSearchType_SearchTypeUndefined :: CseListSearchType+pattern CseListSearchType_SearchTypeUndefined = CseListSearchType "searchTypeUndefined"++-- | Image search.+pattern CseListSearchType_Image :: CseListSearchType+pattern CseListSearchType_Image = CseListSearchType "image"++{-# COMPLETE+ CseListSearchType_SearchTypeUndefined,+ CseListSearchType_Image,+ CseListSearchType+ #-}++-- | Controls whether to include or exclude results from the site named in the @siteSearch@ parameter. Acceptable values are: * @\"e\"@: exclude * @\"i\"@: include+newtype CseListSiteSearchFilter = CseListSiteSearchFilter {fromCseListSiteSearchFilter :: Core.Text}+ deriving stock (Core.Show, Core.Read, Core.Eq, Core.Ord, Core.Generic)+ deriving newtype+ ( Core.Hashable,+ Core.ToHttpApiData,+ Core.FromHttpApiData,+ Core.ToJSON,+ Core.ToJSONKey,+ Core.FromJSON,+ Core.FromJSONKey+ )++-- | Filter mode unspecified.+pattern CseListSiteSearchFilter_SiteSearchFilterUndefined :: CseListSiteSearchFilter+pattern CseListSiteSearchFilter_SiteSearchFilterUndefined = CseListSiteSearchFilter "siteSearchFilterUndefined"++-- | Exclude results from the listed sites.+pattern CseListSiteSearchFilter_E :: CseListSiteSearchFilter+pattern CseListSiteSearchFilter_E = CseListSiteSearchFilter "e"++-- | Include only results from the listed sites.+pattern CseListSiteSearchFilter_I :: CseListSiteSearchFilter+pattern CseListSiteSearchFilter_I = CseListSiteSearchFilter "i"++{-# COMPLETE+ CseListSiteSearchFilter_SiteSearchFilterUndefined,+ CseListSiteSearchFilter_E,+ CseListSiteSearchFilter_I,+ CseListSiteSearchFilter+ #-}++-- | Returns black and white, grayscale, transparent, or color images. Acceptable values are: * @\"color\"@ * @\"gray\"@ * @\"mono\"@: black and white * @\"trans\"@: transparent background+newtype CseSiterestrictListImgColorType = CseSiterestrictListImgColorType {fromCseSiterestrictListImgColorType :: Core.Text}+ deriving stock (Core.Show, Core.Read, Core.Eq, Core.Ord, Core.Generic)+ deriving newtype+ ( Core.Hashable,+ Core.ToHttpApiData,+ Core.FromHttpApiData,+ Core.ToJSON,+ Core.ToJSONKey,+ Core.FromJSON,+ Core.FromJSONKey+ )++-- | No image color type specified.+pattern CseSiterestrictListImgColorType_ImgColorTypeUndefined :: CseSiterestrictListImgColorType+pattern CseSiterestrictListImgColorType_ImgColorTypeUndefined = CseSiterestrictListImgColorType "imgColorTypeUndefined"++-- | Black and white images only.+pattern CseSiterestrictListImgColorType_Mono :: CseSiterestrictListImgColorType+pattern CseSiterestrictListImgColorType_Mono = CseSiterestrictListImgColorType "mono"++-- | Grayscale images only.+pattern CseSiterestrictListImgColorType_Gray :: CseSiterestrictListImgColorType+pattern CseSiterestrictListImgColorType_Gray = CseSiterestrictListImgColorType "gray"++-- | Color images only.+pattern CseSiterestrictListImgColorType_Color :: CseSiterestrictListImgColorType+pattern CseSiterestrictListImgColorType_Color = CseSiterestrictListImgColorType "color"++-- | Images with transparent background+pattern CseSiterestrictListImgColorType_Trans :: CseSiterestrictListImgColorType+pattern CseSiterestrictListImgColorType_Trans = CseSiterestrictListImgColorType "trans"++{-# COMPLETE+ CseSiterestrictListImgColorType_ImgColorTypeUndefined,+ CseSiterestrictListImgColorType_Mono,+ CseSiterestrictListImgColorType_Gray,+ CseSiterestrictListImgColorType_Color,+ CseSiterestrictListImgColorType_Trans,+ CseSiterestrictListImgColorType+ #-}++-- | Returns images of a specific dominant color. Acceptable values are: * @\"black\"@ * @\"blue\"@ * @\"brown\"@ * @\"gray\"@ * @\"green\"@ * @\"orange\"@ * @\"pink\"@ * @\"purple\"@ * @\"red\"@ * @\"teal\"@ * @\"white\"@ * @\"yellow\"@+newtype CseSiterestrictListImgDominantColor = CseSiterestrictListImgDominantColor {fromCseSiterestrictListImgDominantColor :: Core.Text}+ deriving stock (Core.Show, Core.Read, Core.Eq, Core.Ord, Core.Generic)+ deriving newtype+ ( Core.Hashable,+ Core.ToHttpApiData,+ Core.FromHttpApiData,+ Core.ToJSON,+ Core.ToJSONKey,+ Core.FromJSON,+ Core.FromJSONKey+ )++-- | No dominant color specified.+pattern CseSiterestrictListImgDominantColor_ImgDominantColorUndefined :: CseSiterestrictListImgDominantColor+pattern CseSiterestrictListImgDominantColor_ImgDominantColorUndefined = CseSiterestrictListImgDominantColor "imgDominantColorUndefined"++-- | Predominantly black images only.+pattern CseSiterestrictListImgDominantColor_Black :: CseSiterestrictListImgDominantColor+pattern CseSiterestrictListImgDominantColor_Black = CseSiterestrictListImgDominantColor "black"++-- | Predominantly blue images only.+pattern CseSiterestrictListImgDominantColor_Blue :: CseSiterestrictListImgDominantColor+pattern CseSiterestrictListImgDominantColor_Blue = CseSiterestrictListImgDominantColor "blue"++-- | Predominantly brown images only.+pattern CseSiterestrictListImgDominantColor_Brown :: CseSiterestrictListImgDominantColor+pattern CseSiterestrictListImgDominantColor_Brown = CseSiterestrictListImgDominantColor "brown"++-- | Predominantly gray images only.+pattern CseSiterestrictListImgDominantColor_Gray :: CseSiterestrictListImgDominantColor+pattern CseSiterestrictListImgDominantColor_Gray = CseSiterestrictListImgDominantColor "gray"++-- | Predominantly green images only.+pattern CseSiterestrictListImgDominantColor_Green :: CseSiterestrictListImgDominantColor+pattern CseSiterestrictListImgDominantColor_Green = CseSiterestrictListImgDominantColor "green"++-- | Predominantly orange images only.+pattern CseSiterestrictListImgDominantColor_Orange :: CseSiterestrictListImgDominantColor+pattern CseSiterestrictListImgDominantColor_Orange = CseSiterestrictListImgDominantColor "orange"++-- | Predominantly pink images only.+pattern CseSiterestrictListImgDominantColor_Pink :: CseSiterestrictListImgDominantColor+pattern CseSiterestrictListImgDominantColor_Pink = CseSiterestrictListImgDominantColor "pink"++-- | Predominantly purple images only.+pattern CseSiterestrictListImgDominantColor_Purple :: CseSiterestrictListImgDominantColor+pattern CseSiterestrictListImgDominantColor_Purple = CseSiterestrictListImgDominantColor "purple"++-- | Predominantly red images only.+pattern CseSiterestrictListImgDominantColor_Red :: CseSiterestrictListImgDominantColor+pattern CseSiterestrictListImgDominantColor_Red = CseSiterestrictListImgDominantColor "red"++-- | Predominantly teal images only.+pattern CseSiterestrictListImgDominantColor_Teal :: CseSiterestrictListImgDominantColor+pattern CseSiterestrictListImgDominantColor_Teal = CseSiterestrictListImgDominantColor "teal"++-- | Predominantly white images only.+pattern CseSiterestrictListImgDominantColor_White :: CseSiterestrictListImgDominantColor+pattern CseSiterestrictListImgDominantColor_White = CseSiterestrictListImgDominantColor "white"++-- | Predominantly yellow images only.+pattern CseSiterestrictListImgDominantColor_Yellow :: CseSiterestrictListImgDominantColor+pattern CseSiterestrictListImgDominantColor_Yellow = CseSiterestrictListImgDominantColor "yellow"++{-# COMPLETE+ CseSiterestrictListImgDominantColor_ImgDominantColorUndefined,+ CseSiterestrictListImgDominantColor_Black,+ CseSiterestrictListImgDominantColor_Blue,+ CseSiterestrictListImgDominantColor_Brown,+ CseSiterestrictListImgDominantColor_Gray,+ CseSiterestrictListImgDominantColor_Green,+ CseSiterestrictListImgDominantColor_Orange,+ CseSiterestrictListImgDominantColor_Pink,+ CseSiterestrictListImgDominantColor_Purple,+ CseSiterestrictListImgDominantColor_Red,+ CseSiterestrictListImgDominantColor_Teal,+ CseSiterestrictListImgDominantColor_White,+ CseSiterestrictListImgDominantColor_Yellow,+ CseSiterestrictListImgDominantColor+ #-}++-- | Returns images of a specified size. Acceptable values are: * @\"huge\"@ * @\"icon\"@ * @\"large\"@ * @\"medium\"@ * @\"small\"@ * @\"xlarge\"@ * @\"xxlarge\"@+newtype CseSiterestrictListImgSize = CseSiterestrictListImgSize {fromCseSiterestrictListImgSize :: Core.Text}+ deriving stock (Core.Show, Core.Read, Core.Eq, Core.Ord, Core.Generic)+ deriving newtype+ ( Core.Hashable,+ Core.ToHttpApiData,+ Core.FromHttpApiData,+ Core.ToJSON,+ Core.ToJSONKey,+ Core.FromJSON,+ Core.FromJSONKey+ )++-- | No image size specified.+pattern CseSiterestrictListImgSize_ImgSizeUndefined :: CseSiterestrictListImgSize+pattern CseSiterestrictListImgSize_ImgSizeUndefined = CseSiterestrictListImgSize "imgSizeUndefined"++-- | Only the largest possible images.+pattern CseSiterestrictListImgSize_Huge :: CseSiterestrictListImgSize+pattern CseSiterestrictListImgSize_Huge = CseSiterestrictListImgSize "HUGE"++-- | Only very small icon-sized images.+pattern CseSiterestrictListImgSize_Icon :: CseSiterestrictListImgSize+pattern CseSiterestrictListImgSize_Icon = CseSiterestrictListImgSize "ICON"++-- | Only large images.+pattern CseSiterestrictListImgSize_Large :: CseSiterestrictListImgSize+pattern CseSiterestrictListImgSize_Large = CseSiterestrictListImgSize "LARGE"++-- | Only medium images.+pattern CseSiterestrictListImgSize_Medium :: CseSiterestrictListImgSize+pattern CseSiterestrictListImgSize_Medium = CseSiterestrictListImgSize "MEDIUM"++-- | Only small images.+pattern CseSiterestrictListImgSize_Small :: CseSiterestrictListImgSize+pattern CseSiterestrictListImgSize_Small = CseSiterestrictListImgSize "SMALL"++-- | Only very large images.+pattern CseSiterestrictListImgSize_Xlarge :: CseSiterestrictListImgSize+pattern CseSiterestrictListImgSize_Xlarge = CseSiterestrictListImgSize "XLARGE"++-- | Only extremely large images.+pattern CseSiterestrictListImgSize_Xxlarge :: CseSiterestrictListImgSize+pattern CseSiterestrictListImgSize_Xxlarge = CseSiterestrictListImgSize "XXLARGE"++{-# COMPLETE+ CseSiterestrictListImgSize_ImgSizeUndefined,+ CseSiterestrictListImgSize_Huge,+ CseSiterestrictListImgSize_Icon,+ CseSiterestrictListImgSize_Large,+ CseSiterestrictListImgSize_Medium,+ CseSiterestrictListImgSize_Small,+ CseSiterestrictListImgSize_Xlarge,+ CseSiterestrictListImgSize_Xxlarge,+ CseSiterestrictListImgSize+ #-}++-- | Returns images of a type. Acceptable values are: * @\"clipart\"@ * @\"face\"@ * @\"lineart\"@ * @\"stock\"@ * @\"photo\"@ * @\"animated\"@+newtype CseSiterestrictListImgType = CseSiterestrictListImgType {fromCseSiterestrictListImgType :: Core.Text}+ deriving stock (Core.Show, Core.Read, Core.Eq, Core.Ord, Core.Generic)+ deriving newtype+ ( Core.Hashable,+ Core.ToHttpApiData,+ Core.FromHttpApiData,+ Core.ToJSON,+ Core.ToJSONKey,+ Core.FromJSON,+ Core.FromJSONKey+ )++-- | No image type specified.+pattern CseSiterestrictListImgType_ImgTypeUndefined :: CseSiterestrictListImgType+pattern CseSiterestrictListImgType_ImgTypeUndefined = CseSiterestrictListImgType "imgTypeUndefined"++-- | Clipart-style images only.+pattern CseSiterestrictListImgType_Clipart :: CseSiterestrictListImgType+pattern CseSiterestrictListImgType_Clipart = CseSiterestrictListImgType "clipart"++-- | Images of faces only.+pattern CseSiterestrictListImgType_Face :: CseSiterestrictListImgType+pattern CseSiterestrictListImgType_Face = CseSiterestrictListImgType "face"++-- | Line art images only.+pattern CseSiterestrictListImgType_Lineart :: CseSiterestrictListImgType+pattern CseSiterestrictListImgType_Lineart = CseSiterestrictListImgType "lineart"++-- | Stock images only.+pattern CseSiterestrictListImgType_Stock :: CseSiterestrictListImgType+pattern CseSiterestrictListImgType_Stock = CseSiterestrictListImgType "stock"++-- | Photo images only.+pattern CseSiterestrictListImgType_Photo :: CseSiterestrictListImgType+pattern CseSiterestrictListImgType_Photo = CseSiterestrictListImgType "photo"++-- | Animated images only.+pattern CseSiterestrictListImgType_Animated :: CseSiterestrictListImgType+pattern CseSiterestrictListImgType_Animated = CseSiterestrictListImgType "animated"++{-# COMPLETE+ CseSiterestrictListImgType_ImgTypeUndefined,+ CseSiterestrictListImgType_Clipart,+ CseSiterestrictListImgType_Face,+ CseSiterestrictListImgType_Lineart,+ CseSiterestrictListImgType_Stock,+ CseSiterestrictListImgType_Photo,+ CseSiterestrictListImgType_Animated,+ CseSiterestrictListImgType+ #-}++-- | Search safety level. Acceptable values are: * @\"active\"@: Enables SafeSearch filtering. * @\"off\"@: Disables SafeSearch filtering. (default)+newtype CseSiterestrictListSafe = CseSiterestrictListSafe {fromCseSiterestrictListSafe :: Core.Text}+ deriving stock (Core.Show, Core.Read, Core.Eq, Core.Ord, Core.Generic)+ deriving newtype+ ( Core.Hashable,+ Core.ToHttpApiData,+ Core.FromHttpApiData,+ Core.ToJSON,+ Core.ToJSONKey,+ Core.FromJSON,+ Core.FromJSONKey+ )++-- | SafeSearch mode unspecified. (Falls back to engine\'s configuration.)+pattern CseSiterestrictListSafe_SafeUndefined :: CseSiterestrictListSafe+pattern CseSiterestrictListSafe_SafeUndefined = CseSiterestrictListSafe "safeUndefined"++-- | Turn SafeSearch on.+pattern CseSiterestrictListSafe_Active :: CseSiterestrictListSafe+pattern CseSiterestrictListSafe_Active = CseSiterestrictListSafe "active"++-- | Deprecated, equivalent to \"active\".+pattern CseSiterestrictListSafe_High :: CseSiterestrictListSafe+pattern CseSiterestrictListSafe_High = CseSiterestrictListSafe "high"++-- | Deprecated, equivalent to \"active\".+pattern CseSiterestrictListSafe_Medium :: CseSiterestrictListSafe+pattern CseSiterestrictListSafe_Medium = CseSiterestrictListSafe "medium"++-- | Turn SafeSearch off.+pattern CseSiterestrictListSafe_Off :: CseSiterestrictListSafe+pattern CseSiterestrictListSafe_Off = CseSiterestrictListSafe "off"++{-# COMPLETE+ CseSiterestrictListSafe_SafeUndefined,+ CseSiterestrictListSafe_Active,+ CseSiterestrictListSafe_High,+ CseSiterestrictListSafe_Medium,+ CseSiterestrictListSafe_Off,+ CseSiterestrictListSafe+ #-}++-- | Specifies the search type: @image@. If unspecified, results are limited to webpages. Acceptable values are: * @\"image\"@: custom image search.+newtype CseSiterestrictListSearchType = CseSiterestrictListSearchType {fromCseSiterestrictListSearchType :: Core.Text}+ deriving stock (Core.Show, Core.Read, Core.Eq, Core.Ord, Core.Generic)+ deriving newtype+ ( Core.Hashable,+ Core.ToHttpApiData,+ Core.FromHttpApiData,+ Core.ToJSON,+ Core.ToJSONKey,+ Core.FromJSON,+ Core.FromJSONKey+ )++-- | Search type unspecified (defaults to web search).+pattern CseSiterestrictListSearchType_SearchTypeUndefined :: CseSiterestrictListSearchType+pattern CseSiterestrictListSearchType_SearchTypeUndefined = CseSiterestrictListSearchType "searchTypeUndefined"++-- | Image search.+pattern CseSiterestrictListSearchType_Image :: CseSiterestrictListSearchType+pattern CseSiterestrictListSearchType_Image = CseSiterestrictListSearchType "image"++{-# COMPLETE+ CseSiterestrictListSearchType_SearchTypeUndefined,+ CseSiterestrictListSearchType_Image,+ CseSiterestrictListSearchType+ #-}++-- | Controls whether to include or exclude results from the site named in the @siteSearch@ parameter. Acceptable values are: * @\"e\"@: exclude * @\"i\"@: include+newtype CseSiterestrictListSiteSearchFilter = CseSiterestrictListSiteSearchFilter {fromCseSiterestrictListSiteSearchFilter :: Core.Text}+ deriving stock (Core.Show, Core.Read, Core.Eq, Core.Ord, Core.Generic)+ deriving newtype+ ( Core.Hashable,+ Core.ToHttpApiData,+ Core.FromHttpApiData,+ Core.ToJSON,+ Core.ToJSONKey,+ Core.FromJSON,+ Core.FromJSONKey+ )++-- | Filter mode unspecified.+pattern CseSiterestrictListSiteSearchFilter_SiteSearchFilterUndefined :: CseSiterestrictListSiteSearchFilter+pattern CseSiterestrictListSiteSearchFilter_SiteSearchFilterUndefined = CseSiterestrictListSiteSearchFilter "siteSearchFilterUndefined"++-- | Exclude results from the listed sites.+pattern CseSiterestrictListSiteSearchFilter_E :: CseSiterestrictListSiteSearchFilter+pattern CseSiterestrictListSiteSearchFilter_E = CseSiterestrictListSiteSearchFilter "e"++-- | Include only results from the listed sites.+pattern CseSiterestrictListSiteSearchFilter_I :: CseSiterestrictListSiteSearchFilter+pattern CseSiterestrictListSiteSearchFilter_I = CseSiterestrictListSiteSearchFilter "i"++{-# COMPLETE+ CseSiterestrictListSiteSearchFilter_SiteSearchFilterUndefined,+ CseSiterestrictListSiteSearchFilter_E,+ CseSiterestrictListSiteSearchFilter_I,+ CseSiterestrictListSiteSearchFilter+ #-}
+ gen/Gogol/CustomSearch/Search/Cse/List.hs view
@@ -0,0 +1,293 @@+{-# LANGUAGE DataKinds #-}+{-# LANGUAGE DerivingStrategies #-}+{-# LANGUAGE DuplicateRecordFields #-}+{-# LANGUAGE ImportQualifiedPost #-}+{-# LANGUAGE LambdaCase #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE PatternSynonyms #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE TypeFamilies #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}+{-# OPTIONS_GHC -fno-warn-name-shadowing #-}+{-# OPTIONS_GHC -fno-warn-unused-binds #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- |+-- Module : Gogol.CustomSearch.Search.Cse.List+-- Copyright : (c) 2015-2025 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay <brendan.g.hay+gogol@gmail.com>+-- Toni Cebrián <toni@tonicebrian.com>+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Returns metadata about the search performed, metadata about the engine used for the search, and the search results.+--+-- /See:/ <https://developers.google.com/custom-search/v1/introduction Custom Search API Reference> for @search.cse.list@.+module Gogol.CustomSearch.Search.Cse.List+ ( -- * Resource+ SearchCseListResource,++ -- ** Constructing a Request+ SearchCseList (..),+ newSearchCseList,+ )+where++import Gogol.CustomSearch.Types+import Gogol.Prelude qualified as Core++-- | A resource alias for @search.cse.list@ method which the+-- 'SearchCseList' request conforms to.+type SearchCseListResource =+ "customsearch"+ Core.:> "v1"+ Core.:> Core.QueryParam "$.xgafv" Xgafv+ Core.:> Core.QueryParam "access_token" Core.Text+ Core.:> Core.QueryParam "c2coff" Core.Text+ Core.:> Core.QueryParam "callback" Core.Text+ Core.:> Core.QueryParam "cr" Core.Text+ Core.:> Core.QueryParam "cx" Core.Text+ Core.:> Core.QueryParam "dateRestrict" Core.Text+ Core.:> Core.QueryParam "enableAlternateSearchHandler" Core.Bool+ Core.:> Core.QueryParam "exactTerms" Core.Text+ Core.:> Core.QueryParam "excludeTerms" Core.Text+ Core.:> Core.QueryParam "fileType" Core.Text+ Core.:> Core.QueryParam "filter" Core.Text+ Core.:> Core.QueryParam "gl" Core.Text+ Core.:> Core.QueryParam "googlehost" Core.Text+ Core.:> Core.QueryParam "highRange" Core.Text+ Core.:> Core.QueryParam "hl" Core.Text+ Core.:> Core.QueryParam "hq" Core.Text+ Core.:> Core.QueryParam "imgColorType" CseListImgColorType+ Core.:> Core.QueryParam+ "imgDominantColor"+ CseListImgDominantColor+ Core.:> Core.QueryParam "imgSize" CseListImgSize+ Core.:> Core.QueryParam "imgType" CseListImgType+ Core.:> Core.QueryParam "linkSite" Core.Text+ Core.:> Core.QueryParam "lowRange" Core.Text+ Core.:> Core.QueryParam "lr" Core.Text+ Core.:> Core.QueryParam "num" Core.Int32+ Core.:> Core.QueryParam "orTerms" Core.Text+ Core.:> Core.QueryParam "q" Core.Text+ Core.:> Core.QueryParam+ "relatedSite"+ Core.Text+ Core.:> Core.QueryParam "rights" Core.Text+ Core.:> Core.QueryParam+ "safe"+ CseListSafe+ Core.:> Core.QueryParam+ "searchType"+ CseListSearchType+ Core.:> Core.QueryParam+ "siteSearch"+ Core.Text+ Core.:> Core.QueryParam+ "siteSearchFilter"+ CseListSiteSearchFilter+ Core.:> Core.QueryParam+ "snippetLength"+ Core.Int32+ Core.:> Core.QueryParam+ "sort"+ Core.Text+ Core.:> Core.QueryParam+ "start"+ Core.Word32+ Core.:> Core.QueryParam+ "uploadType"+ Core.Text+ Core.:> Core.QueryParam+ "upload_protocol"+ Core.Text+ Core.:> Core.QueryParam+ "alt"+ Core.AltJSON+ Core.:> Core.Get+ '[Core.JSON]+ Search++-- | Returns metadata about the search performed, metadata about the engine used for the search, and the search results.+--+-- /See:/ 'newSearchCseList' smart constructor.+data SearchCseList = SearchCseList+ { -- | V1 error format.+ xgafv :: (Core.Maybe Xgafv),+ -- | OAuth access token.+ accessToken :: (Core.Maybe Core.Text),+ -- | Enables or disables <https://developers.google.com/custom-search/docs/json_api_reference#chineseSearch Simplified and Traditional Chinese Search>. The default value for this parameter is 0 (zero), meaning that the feature is enabled. Supported values are: * @1@: Disabled * @0@: Enabled (default)+ c2coff :: (Core.Maybe Core.Text),+ -- | JSONP+ callback :: (Core.Maybe Core.Text),+ -- | Restricts search results to documents originating in a particular country. You may use <https://developers.google.com/custom-search/docs/json_api_reference#booleanOperators Boolean operators> in the cr parameter\'s value. Google Search determines the country of a document by analyzing: * the top-level domain (TLD) of the document\'s URL * the geographic location of the Web server\'s IP address See the <https://developers.google.com/custom-search/docs/json_api_reference#countryCollections Country Parameter Values> page for a list of valid values for this parameter.+ cr :: (Core.Maybe Core.Text),+ -- | The Programmable Search Engine ID to use for this request.+ cx :: (Core.Maybe Core.Text),+ -- | Restricts results to URLs based on date. Supported values include: * @d[number]@: requests results from the specified number of past days. * @w[number]@: requests results from the specified number of past weeks. * @m[number]@: requests results from the specified number of past months. * @y[number]@: requests results from the specified number of past years.+ dateRestrict :: (Core.Maybe Core.Text),+ -- | Optional. Enables routing of Programmable Search Engine requests to an alternate search handler.+ enableAlternateSearchHandler :: (Core.Maybe Core.Bool),+ -- | Identifies a phrase that all documents in the search results must contain.+ exactTerms :: (Core.Maybe Core.Text),+ -- | Identifies a word or phrase that should not appear in any documents in the search results.+ excludeTerms :: (Core.Maybe Core.Text),+ -- | Restricts results to files of a specified extension. A list of file types indexable by Google can be found in Search Console <https://support.google.com/webmasters/answer/35287 Help Center>.+ fileType :: (Core.Maybe Core.Text),+ -- | Controls turning on or off the duplicate content filter. * See <https://developers.google.com/custom-search/docs/json_api_reference#automaticFiltering Automatic Filtering> for more information about Google\'s search results filters. Note that host crowding filtering applies only to multi-site searches. * By default, Google applies filtering to all search results to improve the quality of those results. Acceptable values are: * @0@: Turns off duplicate content filter. * @1@: Turns on duplicate content filter.+ filter :: (Core.Maybe Core.Text),+ -- | Geolocation of end user. * The @gl@ parameter value is a two-letter country code. The @gl@ parameter boosts search results whose country of origin matches the parameter value. See the <https://developers.google.com/custom-search/docs/json_api_reference#countryCodes Country Codes> page for a list of valid values. * Specifying a @gl@ parameter value should lead to more relevant results. This is particularly true for international customers and, even more specifically, for customers in English- speaking countries other than the United States.+ gl :: (Core.Maybe Core.Text),+ -- | __Deprecated__. Use the @gl@ parameter for a similar effect. The local Google domain (for example, google.com, google.de, or google.fr) to use to perform the search.+ googlehost :: (Core.Maybe Core.Text),+ -- | Specifies the ending value for a search range. * Use @lowRange@ and @highRange@ to append an inclusive search range of @lowRange...highRange@ to the query.+ highRange :: (Core.Maybe Core.Text),+ -- | Sets the user interface language. * Explicitly setting this parameter improves the performance and the quality of your search results. * See the <https://developers.google.com/custom-search/docs/json_api_reference#wsInterfaceLanguages Interface Languages> section of <https://developers.google.com/custom-search/docs/json_api_reference#wsInternationalizing Internationalizing Queries and Results Presentation> for more information, and <https://developers.google.com/custom-search/docs/json_api_reference#interfaceLanguages Supported Interface Languages> for a list of supported languages.+ hl :: (Core.Maybe Core.Text),+ -- | Appends the specified query terms to the query, as if they were combined with a logical AND operator.+ hq :: (Core.Maybe Core.Text),+ -- | Returns black and white, grayscale, transparent, or color images. Acceptable values are: * @\"color\"@ * @\"gray\"@ * @\"mono\"@: black and white * @\"trans\"@: transparent background+ imgColorType :: (Core.Maybe CseListImgColorType),+ -- | Returns images of a specific dominant color. Acceptable values are: * @\"black\"@ * @\"blue\"@ * @\"brown\"@ * @\"gray\"@ * @\"green\"@ * @\"orange\"@ * @\"pink\"@ * @\"purple\"@ * @\"red\"@ * @\"teal\"@ * @\"white\"@ * @\"yellow\"@+ imgDominantColor :: (Core.Maybe CseListImgDominantColor),+ -- | Returns images of a specified size. Acceptable values are: * @\"huge\"@ * @\"icon\"@ * @\"large\"@ * @\"medium\"@ * @\"small\"@ * @\"xlarge\"@ * @\"xxlarge\"@+ imgSize :: (Core.Maybe CseListImgSize),+ -- | Returns images of a type. Acceptable values are: * @\"clipart\"@ * @\"face\"@ * @\"lineart\"@ * @\"stock\"@ * @\"photo\"@ * @\"animated\"@+ imgType :: (Core.Maybe CseListImgType),+ -- | Specifies that all search results should contain a link to a particular URL.+ linkSite :: (Core.Maybe Core.Text),+ -- | Specifies the starting value for a search range. Use @lowRange@ and @highRange@ to append an inclusive search range of @lowRange...highRange@ to the query.+ lowRange :: (Core.Maybe Core.Text),+ -- | Restricts the search to documents written in a particular language (e.g., @lr=lang_ja@). Acceptable values are: * @\"lang_ar\"@: Arabic * @\"lang_bg\"@: Bulgarian * @\"lang_ca\"@: Catalan * @\"lang_cs\"@: Czech * @\"lang_da\"@: Danish * @\"lang_de\"@: German * @\"lang_el\"@: Greek * @\"lang_en\"@: English * @\"lang_es\"@: Spanish * @\"lang_et\"@: Estonian * @\"lang_fi\"@: Finnish * @\"lang_fr\"@: French * @\"lang_hr\"@: Croatian * @\"lang_hu\"@: Hungarian * @\"lang_id\"@: Indonesian * @\"lang_is\"@: Icelandic * @\"lang_it\"@: Italian * @\"lang_iw\"@: Hebrew * @\"lang_ja\"@: Japanese * @\"lang_ko\"@: Korean * @\"lang_lt\"@: Lithuanian * @\"lang_lv\"@: Latvian * @\"lang_nl\"@: Dutch * @\"lang_no\"@: Norwegian * @\"lang_pl\"@: Polish * @\"lang_pt\"@: Portuguese * @\"lang_ro\"@: Romanian * @\"lang_ru\"@: Russian * @\"lang_sk\"@: Slovak * @\"lang_sl\"@: Slovenian * @\"lang_sr\"@: Serbian * @\"lang_sv\"@: Swedish * @\"lang_tr\"@: Turkish * @\"lang_zh-CN\"@: Chinese (Simplified) * @\"lang_zh-TW\"@: Chinese+ -- (Traditional)+ lr :: (Core.Maybe Core.Text),+ -- | Number of search results to return. * Valid values are integers between 1 and 10, inclusive.+ num :: (Core.Maybe Core.Int32),+ -- | Provides additional search terms to check for in a document, where each document in the search results must contain at least one of the additional search terms.+ orTerms :: (Core.Maybe Core.Text),+ -- | Query+ q :: (Core.Maybe Core.Text),+ -- | Deprecated.+ relatedSite :: (Core.Maybe Core.Text),+ -- | Filters based on licensing. Supported values include: @cc_publicdomain@, @cc_attribute@, @cc_sharealike@, @cc_noncommercial@, @cc_nonderived@ and combinations of these. See <https://wiki.creativecommons.org/wiki/CC_Search_integration typical combinations>.+ rights :: (Core.Maybe Core.Text),+ -- | Search safety level. Acceptable values are: * @\"active\"@: Enables SafeSearch filtering. * @\"off\"@: Disables SafeSearch filtering. (default)+ safe :: (Core.Maybe CseListSafe),+ -- | Specifies the search type: @image@. If unspecified, results are limited to webpages. Acceptable values are: * @\"image\"@: custom image search.+ searchType :: (Core.Maybe CseListSearchType),+ -- | Specifies a given site which should always be included or excluded from results (see @siteSearchFilter@ parameter, below).+ siteSearch :: (Core.Maybe Core.Text),+ -- | Controls whether to include or exclude results from the site named in the @siteSearch@ parameter. Acceptable values are: * @\"e\"@: exclude * @\"i\"@: include+ siteSearchFilter :: (Core.Maybe CseListSiteSearchFilter),+ -- | Optional. Maximum length of snippet text, in characters, to be returned with results. Note: this feature is limited to specific engines. * Valid values are integers between 161 and 1000, inclusive.+ snippetLength :: (Core.Maybe Core.Int32),+ -- | The sort expression to apply to the results. The sort parameter specifies that the results be sorted according to the specified expression i.e. sort by date. <https://developers.google.com/custom-search/docs/structured_search#sort-by-attribute Example: sort=date>.+ sort :: (Core.Maybe Core.Text),+ -- | The index of the first result to return. The default number of results per page is 10, so @&start=11@ would start at the top of the second page of results. __Note__: The JSON API will never return more than 100 results, even if more than 100 documents match the query, so setting the sum of @start + num@ to a number greater than 100 will produce an error. Also note that the maximum value for @num@ is 10.+ start :: (Core.Maybe Core.Word32),+ -- | Legacy upload protocol for media (e.g. \"media\", \"multipart\").+ uploadType :: (Core.Maybe Core.Text),+ -- | Upload protocol for media (e.g. \"raw\", \"multipart\").+ uploadProtocol :: (Core.Maybe Core.Text)+ }+ deriving (Core.Eq, Core.Show, Core.Generic)++-- | Creates a value of 'SearchCseList' with the minimum fields required to make a request.+newSearchCseList ::+ SearchCseList+newSearchCseList =+ SearchCseList+ { xgafv = Core.Nothing,+ accessToken = Core.Nothing,+ c2coff = Core.Nothing,+ callback = Core.Nothing,+ cr = Core.Nothing,+ cx = Core.Nothing,+ dateRestrict = Core.Nothing,+ enableAlternateSearchHandler = Core.Nothing,+ exactTerms = Core.Nothing,+ excludeTerms = Core.Nothing,+ fileType = Core.Nothing,+ filter = Core.Nothing,+ gl = Core.Nothing,+ googlehost = Core.Nothing,+ highRange = Core.Nothing,+ hl = Core.Nothing,+ hq = Core.Nothing,+ imgColorType = Core.Nothing,+ imgDominantColor = Core.Nothing,+ imgSize = Core.Nothing,+ imgType = Core.Nothing,+ linkSite = Core.Nothing,+ lowRange = Core.Nothing,+ lr = Core.Nothing,+ num = Core.Nothing,+ orTerms = Core.Nothing,+ q = Core.Nothing,+ relatedSite = Core.Nothing,+ rights = Core.Nothing,+ safe = Core.Nothing,+ searchType = Core.Nothing,+ siteSearch = Core.Nothing,+ siteSearchFilter = Core.Nothing,+ snippetLength = Core.Nothing,+ sort = Core.Nothing,+ start = Core.Nothing,+ uploadType = Core.Nothing,+ uploadProtocol = Core.Nothing+ }++instance Core.GoogleRequest SearchCseList where+ type Rs SearchCseList = Search+ type Scopes SearchCseList = '[]+ requestClient SearchCseList {..} =+ go+ xgafv+ accessToken+ c2coff+ callback+ cr+ cx+ dateRestrict+ enableAlternateSearchHandler+ exactTerms+ excludeTerms+ fileType+ filter+ gl+ googlehost+ highRange+ hl+ hq+ imgColorType+ imgDominantColor+ imgSize+ imgType+ linkSite+ lowRange+ lr+ num+ orTerms+ q+ relatedSite+ rights+ safe+ searchType+ siteSearch+ siteSearchFilter+ snippetLength+ sort+ start+ uploadType+ uploadProtocol+ (Core.Just Core.AltJSON)+ customSearchService+ where+ go =+ Core.buildClient+ (Core.Proxy :: Core.Proxy SearchCseListResource)+ Core.mempty
+ gen/Gogol/CustomSearch/Search/Cse/Siterestrict/List.hs view
@@ -0,0 +1,302 @@+{-# LANGUAGE DataKinds #-}+{-# LANGUAGE DerivingStrategies #-}+{-# LANGUAGE DuplicateRecordFields #-}+{-# LANGUAGE ImportQualifiedPost #-}+{-# LANGUAGE LambdaCase #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE PatternSynonyms #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE TypeFamilies #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}+{-# OPTIONS_GHC -fno-warn-name-shadowing #-}+{-# OPTIONS_GHC -fno-warn-unused-binds #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- |+-- Module : Gogol.CustomSearch.Search.Cse.Siterestrict.List+-- Copyright : (c) 2015-2025 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay <brendan.g.hay+gogol@gmail.com>+-- Toni Cebrián <toni@tonicebrian.com>+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Returns metadata about the search performed, metadata about the engine used for the search, and the search results. Uses a small set of url patterns.+--+-- /See:/ <https://developers.google.com/custom-search/v1/introduction Custom Search API Reference> for @search.cse.siterestrict.list@.+module Gogol.CustomSearch.Search.Cse.Siterestrict.List+ ( -- * Resource+ SearchCseSiterestrictListResource,++ -- ** Constructing a Request+ SearchCseSiterestrictList (..),+ newSearchCseSiterestrictList,+ )+where++import Gogol.CustomSearch.Types+import Gogol.Prelude qualified as Core++-- | A resource alias for @search.cse.siterestrict.list@ method which the+-- 'SearchCseSiterestrictList' request conforms to.+type SearchCseSiterestrictListResource =+ "customsearch"+ Core.:> "v1"+ Core.:> "siterestrict"+ Core.:> Core.QueryParam "$.xgafv" Xgafv+ Core.:> Core.QueryParam "access_token" Core.Text+ Core.:> Core.QueryParam "c2coff" Core.Text+ Core.:> Core.QueryParam "callback" Core.Text+ Core.:> Core.QueryParam "cr" Core.Text+ Core.:> Core.QueryParam "cx" Core.Text+ Core.:> Core.QueryParam "dateRestrict" Core.Text+ Core.:> Core.QueryParam "enableAlternateSearchHandler" Core.Bool+ Core.:> Core.QueryParam "exactTerms" Core.Text+ Core.:> Core.QueryParam "excludeTerms" Core.Text+ Core.:> Core.QueryParam "fileType" Core.Text+ Core.:> Core.QueryParam "filter" Core.Text+ Core.:> Core.QueryParam "gl" Core.Text+ Core.:> Core.QueryParam "googlehost" Core.Text+ Core.:> Core.QueryParam "highRange" Core.Text+ Core.:> Core.QueryParam "hl" Core.Text+ Core.:> Core.QueryParam "hq" Core.Text+ Core.:> Core.QueryParam+ "imgColorType"+ CseSiterestrictListImgColorType+ Core.:> Core.QueryParam+ "imgDominantColor"+ CseSiterestrictListImgDominantColor+ Core.:> Core.QueryParam+ "imgSize"+ CseSiterestrictListImgSize+ Core.:> Core.QueryParam+ "imgType"+ CseSiterestrictListImgType+ Core.:> Core.QueryParam "linkSite" Core.Text+ Core.:> Core.QueryParam "lowRange" Core.Text+ Core.:> Core.QueryParam "lr" Core.Text+ Core.:> Core.QueryParam "num" Core.Int32+ Core.:> Core.QueryParam "orTerms" Core.Text+ Core.:> Core.QueryParam "q" Core.Text+ Core.:> Core.QueryParam+ "relatedSite"+ Core.Text+ Core.:> Core.QueryParam+ "rights"+ Core.Text+ Core.:> Core.QueryParam+ "safe"+ CseSiterestrictListSafe+ Core.:> Core.QueryParam+ "searchType"+ CseSiterestrictListSearchType+ Core.:> Core.QueryParam+ "siteSearch"+ Core.Text+ Core.:> Core.QueryParam+ "siteSearchFilter"+ CseSiterestrictListSiteSearchFilter+ Core.:> Core.QueryParam+ "snippetLength"+ Core.Int32+ Core.:> Core.QueryParam+ "sort"+ Core.Text+ Core.:> Core.QueryParam+ "start"+ Core.Word32+ Core.:> Core.QueryParam+ "uploadType"+ Core.Text+ Core.:> Core.QueryParam+ "upload_protocol"+ Core.Text+ Core.:> Core.QueryParam+ "alt"+ Core.AltJSON+ Core.:> Core.Get+ '[Core.JSON]+ Search++-- | Returns metadata about the search performed, metadata about the engine used for the search, and the search results. Uses a small set of url patterns.+--+-- /See:/ 'newSearchCseSiterestrictList' smart constructor.+data SearchCseSiterestrictList = SearchCseSiterestrictList+ { -- | V1 error format.+ xgafv :: (Core.Maybe Xgafv),+ -- | OAuth access token.+ accessToken :: (Core.Maybe Core.Text),+ -- | Enables or disables <https://developers.google.com/custom-search/docs/json_api_reference#chineseSearch Simplified and Traditional Chinese Search>. The default value for this parameter is 0 (zero), meaning that the feature is enabled. Supported values are: * @1@: Disabled * @0@: Enabled (default)+ c2coff :: (Core.Maybe Core.Text),+ -- | JSONP+ callback :: (Core.Maybe Core.Text),+ -- | Restricts search results to documents originating in a particular country. You may use <https://developers.google.com/custom-search/docs/json_api_reference#booleanOperators Boolean operators> in the cr parameter\'s value. Google Search determines the country of a document by analyzing: * the top-level domain (TLD) of the document\'s URL * the geographic location of the Web server\'s IP address See the <https://developers.google.com/custom-search/docs/json_api_reference#countryCollections Country Parameter Values> page for a list of valid values for this parameter.+ cr :: (Core.Maybe Core.Text),+ -- | The Programmable Search Engine ID to use for this request.+ cx :: (Core.Maybe Core.Text),+ -- | Restricts results to URLs based on date. Supported values include: * @d[number]@: requests results from the specified number of past days. * @w[number]@: requests results from the specified number of past weeks. * @m[number]@: requests results from the specified number of past months. * @y[number]@: requests results from the specified number of past years.+ dateRestrict :: (Core.Maybe Core.Text),+ -- | Optional. Enables routing of Programmable Search Engine requests to an alternate search handler.+ enableAlternateSearchHandler :: (Core.Maybe Core.Bool),+ -- | Identifies a phrase that all documents in the search results must contain.+ exactTerms :: (Core.Maybe Core.Text),+ -- | Identifies a word or phrase that should not appear in any documents in the search results.+ excludeTerms :: (Core.Maybe Core.Text),+ -- | Restricts results to files of a specified extension. A list of file types indexable by Google can be found in Search Console <https://support.google.com/webmasters/answer/35287 Help Center>.+ fileType :: (Core.Maybe Core.Text),+ -- | Controls turning on or off the duplicate content filter. * See <https://developers.google.com/custom-search/docs/json_api_reference#automaticFiltering Automatic Filtering> for more information about Google\'s search results filters. Note that host crowding filtering applies only to multi-site searches. * By default, Google applies filtering to all search results to improve the quality of those results. Acceptable values are: * @0@: Turns off duplicate content filter. * @1@: Turns on duplicate content filter.+ filter :: (Core.Maybe Core.Text),+ -- | Geolocation of end user. * The @gl@ parameter value is a two-letter country code. The @gl@ parameter boosts search results whose country of origin matches the parameter value. See the <https://developers.google.com/custom-search/docs/json_api_reference#countryCodes Country Codes> page for a list of valid values. * Specifying a @gl@ parameter value should lead to more relevant results. This is particularly true for international customers and, even more specifically, for customers in English- speaking countries other than the United States.+ gl :: (Core.Maybe Core.Text),+ -- | __Deprecated__. Use the @gl@ parameter for a similar effect. The local Google domain (for example, google.com, google.de, or google.fr) to use to perform the search.+ googlehost :: (Core.Maybe Core.Text),+ -- | Specifies the ending value for a search range. * Use @lowRange@ and @highRange@ to append an inclusive search range of @lowRange...highRange@ to the query.+ highRange :: (Core.Maybe Core.Text),+ -- | Sets the user interface language. * Explicitly setting this parameter improves the performance and the quality of your search results. * See the <https://developers.google.com/custom-search/docs/json_api_reference#wsInterfaceLanguages Interface Languages> section of <https://developers.google.com/custom-search/docs/json_api_reference#wsInternationalizing Internationalizing Queries and Results Presentation> for more information, and <https://developers.google.com/custom-search/docs/json_api_reference#interfaceLanguages Supported Interface Languages> for a list of supported languages.+ hl :: (Core.Maybe Core.Text),+ -- | Appends the specified query terms to the query, as if they were combined with a logical AND operator.+ hq :: (Core.Maybe Core.Text),+ -- | Returns black and white, grayscale, transparent, or color images. Acceptable values are: * @\"color\"@ * @\"gray\"@ * @\"mono\"@: black and white * @\"trans\"@: transparent background+ imgColorType :: (Core.Maybe CseSiterestrictListImgColorType),+ -- | Returns images of a specific dominant color. Acceptable values are: * @\"black\"@ * @\"blue\"@ * @\"brown\"@ * @\"gray\"@ * @\"green\"@ * @\"orange\"@ * @\"pink\"@ * @\"purple\"@ * @\"red\"@ * @\"teal\"@ * @\"white\"@ * @\"yellow\"@+ imgDominantColor :: (Core.Maybe CseSiterestrictListImgDominantColor),+ -- | Returns images of a specified size. Acceptable values are: * @\"huge\"@ * @\"icon\"@ * @\"large\"@ * @\"medium\"@ * @\"small\"@ * @\"xlarge\"@ * @\"xxlarge\"@+ imgSize :: (Core.Maybe CseSiterestrictListImgSize),+ -- | Returns images of a type. Acceptable values are: * @\"clipart\"@ * @\"face\"@ * @\"lineart\"@ * @\"stock\"@ * @\"photo\"@ * @\"animated\"@+ imgType :: (Core.Maybe CseSiterestrictListImgType),+ -- | Specifies that all search results should contain a link to a particular URL.+ linkSite :: (Core.Maybe Core.Text),+ -- | Specifies the starting value for a search range. Use @lowRange@ and @highRange@ to append an inclusive search range of @lowRange...highRange@ to the query.+ lowRange :: (Core.Maybe Core.Text),+ -- | Restricts the search to documents written in a particular language (e.g., @lr=lang_ja@). Acceptable values are: * @\"lang_ar\"@: Arabic * @\"lang_bg\"@: Bulgarian * @\"lang_ca\"@: Catalan * @\"lang_cs\"@: Czech * @\"lang_da\"@: Danish * @\"lang_de\"@: German * @\"lang_el\"@: Greek * @\"lang_en\"@: English * @\"lang_es\"@: Spanish * @\"lang_et\"@: Estonian * @\"lang_fi\"@: Finnish * @\"lang_fr\"@: French * @\"lang_hr\"@: Croatian * @\"lang_hu\"@: Hungarian * @\"lang_id\"@: Indonesian * @\"lang_is\"@: Icelandic * @\"lang_it\"@: Italian * @\"lang_iw\"@: Hebrew * @\"lang_ja\"@: Japanese * @\"lang_ko\"@: Korean * @\"lang_lt\"@: Lithuanian * @\"lang_lv\"@: Latvian * @\"lang_nl\"@: Dutch * @\"lang_no\"@: Norwegian * @\"lang_pl\"@: Polish * @\"lang_pt\"@: Portuguese * @\"lang_ro\"@: Romanian * @\"lang_ru\"@: Russian * @\"lang_sk\"@: Slovak * @\"lang_sl\"@: Slovenian * @\"lang_sr\"@: Serbian * @\"lang_sv\"@: Swedish * @\"lang_tr\"@: Turkish * @\"lang_zh-CN\"@: Chinese (Simplified) * @\"lang_zh-TW\"@: Chinese+ -- (Traditional)+ lr :: (Core.Maybe Core.Text),+ -- | Number of search results to return. * Valid values are integers between 1 and 10, inclusive.+ num :: (Core.Maybe Core.Int32),+ -- | Provides additional search terms to check for in a document, where each document in the search results must contain at least one of the additional search terms.+ orTerms :: (Core.Maybe Core.Text),+ -- | Query+ q :: (Core.Maybe Core.Text),+ -- | Deprecated.+ relatedSite :: (Core.Maybe Core.Text),+ -- | Filters based on licensing. Supported values include: @cc_publicdomain@, @cc_attribute@, @cc_sharealike@, @cc_noncommercial@, @cc_nonderived@ and combinations of these. See <https://wiki.creativecommons.org/wiki/CC_Search_integration typical combinations>.+ rights :: (Core.Maybe Core.Text),+ -- | Search safety level. Acceptable values are: * @\"active\"@: Enables SafeSearch filtering. * @\"off\"@: Disables SafeSearch filtering. (default)+ safe :: (Core.Maybe CseSiterestrictListSafe),+ -- | Specifies the search type: @image@. If unspecified, results are limited to webpages. Acceptable values are: * @\"image\"@: custom image search.+ searchType :: (Core.Maybe CseSiterestrictListSearchType),+ -- | Specifies a given site which should always be included or excluded from results (see @siteSearchFilter@ parameter, below).+ siteSearch :: (Core.Maybe Core.Text),+ -- | Controls whether to include or exclude results from the site named in the @siteSearch@ parameter. Acceptable values are: * @\"e\"@: exclude * @\"i\"@: include+ siteSearchFilter :: (Core.Maybe CseSiterestrictListSiteSearchFilter),+ -- | Optional. Maximum length of snippet text, in characters, to be returned with results. Note: this feature is limited to specific engines. * Valid values are integers between 161 and 1000, inclusive.+ snippetLength :: (Core.Maybe Core.Int32),+ -- | The sort expression to apply to the results. The sort parameter specifies that the results be sorted according to the specified expression i.e. sort by date. <https://developers.google.com/custom-search/docs/structured_search#sort-by-attribute Example: sort=date>.+ sort :: (Core.Maybe Core.Text),+ -- | The index of the first result to return. The default number of results per page is 10, so @&start=11@ would start at the top of the second page of results. __Note__: The JSON API will never return more than 100 results, even if more than 100 documents match the query, so setting the sum of @start + num@ to a number greater than 100 will produce an error. Also note that the maximum value for @num@ is 10.+ start :: (Core.Maybe Core.Word32),+ -- | Legacy upload protocol for media (e.g. \"media\", \"multipart\").+ uploadType :: (Core.Maybe Core.Text),+ -- | Upload protocol for media (e.g. \"raw\", \"multipart\").+ uploadProtocol :: (Core.Maybe Core.Text)+ }+ deriving (Core.Eq, Core.Show, Core.Generic)++-- | Creates a value of 'SearchCseSiterestrictList' with the minimum fields required to make a request.+newSearchCseSiterestrictList ::+ SearchCseSiterestrictList+newSearchCseSiterestrictList =+ SearchCseSiterestrictList+ { xgafv = Core.Nothing,+ accessToken = Core.Nothing,+ c2coff = Core.Nothing,+ callback = Core.Nothing,+ cr = Core.Nothing,+ cx = Core.Nothing,+ dateRestrict = Core.Nothing,+ enableAlternateSearchHandler = Core.Nothing,+ exactTerms = Core.Nothing,+ excludeTerms = Core.Nothing,+ fileType = Core.Nothing,+ filter = Core.Nothing,+ gl = Core.Nothing,+ googlehost = Core.Nothing,+ highRange = Core.Nothing,+ hl = Core.Nothing,+ hq = Core.Nothing,+ imgColorType = Core.Nothing,+ imgDominantColor = Core.Nothing,+ imgSize = Core.Nothing,+ imgType = Core.Nothing,+ linkSite = Core.Nothing,+ lowRange = Core.Nothing,+ lr = Core.Nothing,+ num = Core.Nothing,+ orTerms = Core.Nothing,+ q = Core.Nothing,+ relatedSite = Core.Nothing,+ rights = Core.Nothing,+ safe = Core.Nothing,+ searchType = Core.Nothing,+ siteSearch = Core.Nothing,+ siteSearchFilter = Core.Nothing,+ snippetLength = Core.Nothing,+ sort = Core.Nothing,+ start = Core.Nothing,+ uploadType = Core.Nothing,+ uploadProtocol = Core.Nothing+ }++instance Core.GoogleRequest SearchCseSiterestrictList where+ type Rs SearchCseSiterestrictList = Search+ type Scopes SearchCseSiterestrictList = '[]+ requestClient SearchCseSiterestrictList {..} =+ go+ xgafv+ accessToken+ c2coff+ callback+ cr+ cx+ dateRestrict+ enableAlternateSearchHandler+ exactTerms+ excludeTerms+ fileType+ filter+ gl+ googlehost+ highRange+ hl+ hq+ imgColorType+ imgDominantColor+ imgSize+ imgType+ linkSite+ lowRange+ lr+ num+ orTerms+ q+ relatedSite+ rights+ safe+ searchType+ siteSearch+ siteSearchFilter+ snippetLength+ sort+ start+ uploadType+ uploadProtocol+ (Core.Just Core.AltJSON)+ customSearchService+ where+ go =+ Core.buildClient+ (Core.Proxy :: Core.Proxy SearchCseSiterestrictListResource)+ Core.mempty
+ gen/Gogol/CustomSearch/Types.hs view
@@ -0,0 +1,152 @@+{-# LANGUAGE DataKinds #-}+{-# LANGUAGE DerivingStrategies #-}+{-# LANGUAGE DuplicateRecordFields #-}+{-# LANGUAGE ImportQualifiedPost #-}+{-# LANGUAGE LambdaCase #-}+{-# LANGUAGE OverloadedStrings #-}+{-# LANGUAGE PatternSynonyms #-}+{-# LANGUAGE RecordWildCards #-}+{-# LANGUAGE StrictData #-}+{-# LANGUAGE TypeFamilies #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}+{-# OPTIONS_GHC -fno-warn-name-shadowing #-}+{-# OPTIONS_GHC -fno-warn-unused-binds #-}+{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-unused-matches #-}++-- |+-- Module : Gogol.CustomSearch.Types+-- Copyright : (c) 2015-2025 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay <brendan.g.hay+gogol@gmail.com>+-- Toni Cebrián <toni@tonicebrian.com>+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+module Gogol.CustomSearch.Types+ ( -- * Configuration+ customSearchService,++ -- * Types++ -- ** Xgafv+ Xgafv (..),++ -- ** Promotion+ Promotion (..),+ newPromotion,++ -- ** Promotion_BodyLinesItem+ Promotion_BodyLinesItem (..),+ newPromotion_BodyLinesItem,++ -- ** Promotion_Image+ Promotion_Image (..),+ newPromotion_Image,++ -- ** Result+ Result (..),+ newResult,++ -- ** Result_Image+ Result_Image (..),+ newResult_Image,++ -- ** Result_LabelsItem+ Result_LabelsItem (..),+ newResult_LabelsItem,++ -- ** Result_Pagemap+ Result_Pagemap (..),+ newResult_Pagemap,++ -- ** Search+ Search (..),+ newSearch,++ -- ** Search_Context+ Search_Context (..),+ newSearch_Context,++ -- ** Search_Queries+ Search_Queries (..),+ newSearch_Queries,++ -- ** Search_Queries_NextPageItem+ Search_Queries_NextPageItem (..),+ newSearch_Queries_NextPageItem,++ -- ** Search_Queries_PreviousPageItem+ Search_Queries_PreviousPageItem (..),+ newSearch_Queries_PreviousPageItem,++ -- ** Search_Queries_RequestItem+ Search_Queries_RequestItem (..),+ newSearch_Queries_RequestItem,++ -- ** Search_SearchInformation+ Search_SearchInformation (..),+ newSearch_SearchInformation,++ -- ** Search_Spelling+ Search_Spelling (..),+ newSearch_Spelling,++ -- ** Search_Url+ Search_Url (..),+ newSearch_Url,++ -- ** CseListImgColorType+ CseListImgColorType (..),++ -- ** CseListImgDominantColor+ CseListImgDominantColor (..),++ -- ** CseListImgSize+ CseListImgSize (..),++ -- ** CseListImgType+ CseListImgType (..),++ -- ** CseListSafe+ CseListSafe (..),++ -- ** CseListSearchType+ CseListSearchType (..),++ -- ** CseListSiteSearchFilter+ CseListSiteSearchFilter (..),++ -- ** CseSiterestrictListImgColorType+ CseSiterestrictListImgColorType (..),++ -- ** CseSiterestrictListImgDominantColor+ CseSiterestrictListImgDominantColor (..),++ -- ** CseSiterestrictListImgSize+ CseSiterestrictListImgSize (..),++ -- ** CseSiterestrictListImgType+ CseSiterestrictListImgType (..),++ -- ** CseSiterestrictListSafe+ CseSiterestrictListSafe (..),++ -- ** CseSiterestrictListSearchType+ CseSiterestrictListSearchType (..),++ -- ** CseSiterestrictListSiteSearchFilter+ CseSiterestrictListSiteSearchFilter (..),+ )+where++import Gogol.CustomSearch.Internal.Product+import Gogol.CustomSearch.Internal.Sum+import Gogol.Prelude qualified as Core++-- | Default request referring to version @v1@ of the Custom Search API. This contains the host and root path used as a starting point for constructing service requests.+customSearchService :: Core.ServiceConfig+customSearchService =+ Core.defaultService+ (Core.ServiceId "customsearch:v1")+ "customsearch.googleapis.com"
− gen/Network/Google/CustomSearch.hs
@@ -1,265 +0,0 @@-{-# LANGUAGE DataKinds #-}-{-# LANGUAGE NoImplicitPrelude #-}-{-# LANGUAGE TypeOperators #-}--{-# OPTIONS_GHC -fno-warn-unused-imports #-}-{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}---- |--- Module : Network.Google.CustomSearch--- Copyright : (c) 2015-2016 Brendan Hay--- License : Mozilla Public License, v. 2.0.--- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>--- Stability : auto-generated--- Portability : non-portable (GHC extensions)------ Searches over a website or collection of websites------ /See:/ <https://developers.google.com/custom-search/v1/using_rest CustomSearch API Reference>-module Network.Google.CustomSearch- (- -- * Service Configuration- customSearchService-- -- * API Declaration- , CustomSearchAPI-- -- * Resources-- -- ** search.cse.list- , module Network.Google.Resource.Search.CSE.List-- -- ** search.cse.siterestrict.list- , module Network.Google.Resource.Search.CSE.Siterestrict.List-- -- * Types-- -- ** CSEListImgType- , CSEListImgType (..)-- -- ** PromotionImage- , PromotionImage- , promotionImage- , piHeight- , piWidth- , piSource-- -- ** Context- , Context- , context- , cFacets- , cTitle-- -- ** CSEListSiteSearchFilter- , CSEListSiteSearchFilter (..)-- -- ** SearchQueries- , SearchQueries- , searchQueries- , sqAddtional-- -- ** ResultPagemapAdditionalItem- , ResultPagemapAdditionalItem- , resultPagemapAdditionalItem- , rpaiAddtional-- -- ** SearchURL- , SearchURL- , searchURL- , suType- , suTemplate-- -- ** CSESiterestrictListFilter- , CSESiterestrictListFilter (..)-- -- ** SearchSpelling- , SearchSpelling- , searchSpelling- , ssCorrectedQuery- , ssHTMLCorrectedQuery-- -- ** CSESiterestrictListImgType- , CSESiterestrictListImgType (..)-- -- ** CSEListImgDominantColor- , CSEListImgDominantColor (..)-- -- ** ResultImage- , ResultImage- , resultImage- , riThumbnailLink- , riHeight- , riByteSize- , riContextLink- , riThumbnailHeight- , riWidth- , riThumbnailWidth-- -- ** CSEListSafe- , CSEListSafe (..)-- -- ** CSESiterestrictListImgSize- , CSESiterestrictListImgSize (..)-- -- ** ResultPagemap- , ResultPagemap- , resultPagemap- , rpAddtional-- -- ** CSESiterestrictListImgColorType- , CSESiterestrictListImgColorType (..)-- -- ** CSEListImgColorType- , CSEListImgColorType (..)-- -- ** CSESiterestrictListSafe- , CSESiterestrictListSafe (..)-- -- ** Result- , Result- , result- , rMime- , rImage- , rPagemap- , rDisplayLink- , rFileFormat- , rSnippet- , rKind- , rLink- , rHTMLSnippet- , rHTMLFormattedURL- , rCacheId- , rFormattedURL- , rHTMLTitle- , rLabels- , rTitle-- -- ** ResultLabelsItem- , ResultLabelsItem- , resultLabelsItem- , rliName- , rliDisplayName- , rliLabelWithOp-- -- ** CSESiterestrictListImgDominantColor- , CSESiterestrictListImgDominantColor (..)-- -- ** SearchSearchInformation- , SearchSearchInformation- , searchSearchInformation- , ssiSearchTime- , ssiFormattedSearchTime- , ssiTotalResults- , ssiFormattedTotalResults-- -- ** CSEListFilter- , CSEListFilter (..)-- -- ** Query- , Query- , query- , qImgDominantColor- , qOutputEncoding- , qSiteSearchFilter- , qInputEncoding- , qOrTerms- , qSearchTerms- , qStartPage- , qRights- , qCount- , qExcludeTerms- , qFileType- , qSearchType- , qGoogleHost- , qDisableCnTwTranslation- , qRelatedSite- , qHl- , qSort- , qLanguage- , qSiteSearch- , qFilter- , qTotalResults- , qDateRestrict- , qTitle- , qLinkSite- , qLowRange- , qImgType- , qGl- , qCx- , qImgColorType- , qImgSize- , qExactTerms- , qStartIndex- , qCr- , qSafe- , qHq- , qHighRange-- -- ** CSESiterestrictListSiteSearchFilter- , CSESiterestrictListSiteSearchFilter (..)-- -- ** PromotionBodyLinesItem- , PromotionBodyLinesItem- , promotionBodyLinesItem- , pbliLink- , pbliURL- , pbliHTMLTitle- , pbliTitle-- -- ** Promotion- , Promotion- , promotion- , pImage- , pDisplayLink- , pBodyLines- , pLink- , pHTMLTitle- , pTitle-- -- ** CSESiterestrictListLr- , CSESiterestrictListLr (..)-- -- ** CSESiterestrictListSearchType- , CSESiterestrictListSearchType (..)-- -- ** Search- , Search- , search- , sQueries- , sContext- , sKind- , sURL- , sItems- , sSearchInformation- , sPromotions- , sSpelling-- -- ** CSEListLr- , CSEListLr (..)-- -- ** ContextFacetsItemItem- , ContextFacetsItemItem- , contextFacetsItemItem- , cfiiAnchor- , cfiiLabelWithOp- , cfiiLabel-- -- ** CSEListSearchType- , CSEListSearchType (..)-- -- ** CSEListImgSize- , CSEListImgSize (..)- ) where--import Network.Google.CustomSearch.Types-import Network.Google.Prelude-import Network.Google.Resource.Search.CSE.List-import Network.Google.Resource.Search.CSE.Siterestrict.List--{- $resources-TODO--}---- | Represents the entirety of the methods and resources available for the CustomSearch API service.-type CustomSearchAPI =- CSESiterestrictListResource :<|> CSEListResource
− gen/Network/Google/CustomSearch/Types.hs
@@ -1,247 +0,0 @@-{-# LANGUAGE DataKinds #-}-{-# LANGUAGE DeriveDataTypeable #-}-{-# LANGUAGE DeriveGeneric #-}-{-# LANGUAGE NoImplicitPrelude #-}-{-# LANGUAGE OverloadedStrings #-}--{-# OPTIONS_GHC -fno-warn-unused-imports #-}---- |--- Module : Network.Google.CustomSearch.Types--- Copyright : (c) 2015-2016 Brendan Hay--- License : Mozilla Public License, v. 2.0.--- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>--- Stability : auto-generated--- Portability : non-portable (GHC extensions)----module Network.Google.CustomSearch.Types- (- -- * Service Configuration- customSearchService-- -- * CSEListImgType- , CSEListImgType (..)-- -- * PromotionImage- , PromotionImage- , promotionImage- , piHeight- , piWidth- , piSource-- -- * Context- , Context- , context- , cFacets- , cTitle-- -- * CSEListSiteSearchFilter- , CSEListSiteSearchFilter (..)-- -- * SearchQueries- , SearchQueries- , searchQueries- , sqAddtional-- -- * ResultPagemapAdditionalItem- , ResultPagemapAdditionalItem- , resultPagemapAdditionalItem- , rpaiAddtional-- -- * SearchURL- , SearchURL- , searchURL- , suType- , suTemplate-- -- * CSESiterestrictListFilter- , CSESiterestrictListFilter (..)-- -- * SearchSpelling- , SearchSpelling- , searchSpelling- , ssCorrectedQuery- , ssHTMLCorrectedQuery-- -- * CSESiterestrictListImgType- , CSESiterestrictListImgType (..)-- -- * CSEListImgDominantColor- , CSEListImgDominantColor (..)-- -- * ResultImage- , ResultImage- , resultImage- , riThumbnailLink- , riHeight- , riByteSize- , riContextLink- , riThumbnailHeight- , riWidth- , riThumbnailWidth-- -- * CSEListSafe- , CSEListSafe (..)-- -- * CSESiterestrictListImgSize- , CSESiterestrictListImgSize (..)-- -- * ResultPagemap- , ResultPagemap- , resultPagemap- , rpAddtional-- -- * CSESiterestrictListImgColorType- , CSESiterestrictListImgColorType (..)-- -- * CSEListImgColorType- , CSEListImgColorType (..)-- -- * CSESiterestrictListSafe- , CSESiterestrictListSafe (..)-- -- * Result- , Result- , result- , rMime- , rImage- , rPagemap- , rDisplayLink- , rFileFormat- , rSnippet- , rKind- , rLink- , rHTMLSnippet- , rHTMLFormattedURL- , rCacheId- , rFormattedURL- , rHTMLTitle- , rLabels- , rTitle-- -- * ResultLabelsItem- , ResultLabelsItem- , resultLabelsItem- , rliName- , rliDisplayName- , rliLabelWithOp-- -- * CSESiterestrictListImgDominantColor- , CSESiterestrictListImgDominantColor (..)-- -- * SearchSearchInformation- , SearchSearchInformation- , searchSearchInformation- , ssiSearchTime- , ssiFormattedSearchTime- , ssiTotalResults- , ssiFormattedTotalResults-- -- * CSEListFilter- , CSEListFilter (..)-- -- * Query- , Query- , query- , qImgDominantColor- , qOutputEncoding- , qSiteSearchFilter- , qInputEncoding- , qOrTerms- , qSearchTerms- , qStartPage- , qRights- , qCount- , qExcludeTerms- , qFileType- , qSearchType- , qGoogleHost- , qDisableCnTwTranslation- , qRelatedSite- , qHl- , qSort- , qLanguage- , qSiteSearch- , qFilter- , qTotalResults- , qDateRestrict- , qTitle- , qLinkSite- , qLowRange- , qImgType- , qGl- , qCx- , qImgColorType- , qImgSize- , qExactTerms- , qStartIndex- , qCr- , qSafe- , qHq- , qHighRange-- -- * CSESiterestrictListSiteSearchFilter- , CSESiterestrictListSiteSearchFilter (..)-- -- * PromotionBodyLinesItem- , PromotionBodyLinesItem- , promotionBodyLinesItem- , pbliLink- , pbliURL- , pbliHTMLTitle- , pbliTitle-- -- * Promotion- , Promotion- , promotion- , pImage- , pDisplayLink- , pBodyLines- , pLink- , pHTMLTitle- , pTitle-- -- * CSESiterestrictListLr- , CSESiterestrictListLr (..)-- -- * CSESiterestrictListSearchType- , CSESiterestrictListSearchType (..)-- -- * Search- , Search- , search- , sQueries- , sContext- , sKind- , sURL- , sItems- , sSearchInformation- , sPromotions- , sSpelling-- -- * CSEListLr- , CSEListLr (..)-- -- * ContextFacetsItemItem- , ContextFacetsItemItem- , contextFacetsItemItem- , cfiiAnchor- , cfiiLabelWithOp- , cfiiLabel-- -- * CSEListSearchType- , CSEListSearchType (..)-- -- * CSEListImgSize- , CSEListImgSize (..)- ) where--import Network.Google.CustomSearch.Types.Product-import Network.Google.CustomSearch.Types.Sum-import Network.Google.Prelude---- | Default request referring to version 'v1' of the CustomSearch API. This contains the host and root path used as a starting point for constructing service requests.-customSearchService :: ServiceConfig-customSearchService- = defaultService (ServiceId "customsearch:v1")- "www.googleapis.com"
− gen/Network/Google/CustomSearch/Types/Product.hs
@@ -1,1435 +0,0 @@-{-# LANGUAGE DeriveDataTypeable #-}-{-# LANGUAGE DeriveGeneric #-}-{-# LANGUAGE NoImplicitPrelude #-}-{-# LANGUAGE OverloadedStrings #-}-{-# LANGUAGE RecordWildCards #-}--{-# OPTIONS_GHC -fno-warn-unused-binds #-}-{-# OPTIONS_GHC -fno-warn-unused-imports #-}---- |--- Module : Network.Google.CustomSearch.Types.Product--- Copyright : (c) 2015-2016 Brendan Hay--- License : Mozilla Public License, v. 2.0.--- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>--- Stability : auto-generated--- Portability : non-portable (GHC extensions)----module Network.Google.CustomSearch.Types.Product where--import Network.Google.CustomSearch.Types.Sum-import Network.Google.Prelude------- /See:/ 'promotionImage' smart constructor.-data PromotionImage =- PromotionImage'- { _piHeight :: !(Maybe (Textual Int32))- , _piWidth :: !(Maybe (Textual Int32))- , _piSource :: !(Maybe Text)- }- deriving (Eq, Show, Data, Typeable, Generic)----- | Creates a value of 'PromotionImage' with the minimum fields required to make a request.------ Use one of the following lenses to modify other fields as desired:------ * 'piHeight'------ * 'piWidth'------ * 'piSource'-promotionImage- :: PromotionImage-promotionImage =- PromotionImage' {_piHeight = Nothing, _piWidth = Nothing, _piSource = Nothing}---piHeight :: Lens' PromotionImage (Maybe Int32)-piHeight- = lens _piHeight (\ s a -> s{_piHeight = a}) .- mapping _Coerce--piWidth :: Lens' PromotionImage (Maybe Int32)-piWidth- = lens _piWidth (\ s a -> s{_piWidth = a}) .- mapping _Coerce--piSource :: Lens' PromotionImage (Maybe Text)-piSource = lens _piSource (\ s a -> s{_piSource = a})--instance FromJSON PromotionImage where- parseJSON- = withObject "PromotionImage"- (\ o ->- PromotionImage' <$>- (o .:? "height") <*> (o .:? "width") <*>- (o .:? "source"))--instance ToJSON PromotionImage where- toJSON PromotionImage'{..}- = object- (catMaybes- [("height" .=) <$> _piHeight,- ("width" .=) <$> _piWidth,- ("source" .=) <$> _piSource])------- /See:/ 'context' smart constructor.-data Context =- Context'- { _cFacets :: !(Maybe [[ContextFacetsItemItem]])- , _cTitle :: !(Maybe Text)- }- deriving (Eq, Show, Data, Typeable, Generic)----- | Creates a value of 'Context' with the minimum fields required to make a request.------ Use one of the following lenses to modify other fields as desired:------ * 'cFacets'------ * 'cTitle'-context- :: Context-context = Context' {_cFacets = Nothing, _cTitle = Nothing}---cFacets :: Lens' Context [[ContextFacetsItemItem]]-cFacets- = lens _cFacets (\ s a -> s{_cFacets = a}) . _Default- . _Coerce--cTitle :: Lens' Context (Maybe Text)-cTitle = lens _cTitle (\ s a -> s{_cTitle = a})--instance FromJSON Context where- parseJSON- = withObject "Context"- (\ o ->- Context' <$>- (o .:? "facets" .!= mempty) <*> (o .:? "title"))--instance ToJSON Context where- toJSON Context'{..}- = object- (catMaybes- [("facets" .=) <$> _cFacets,- ("title" .=) <$> _cTitle])------- /See:/ 'searchQueries' smart constructor.-newtype SearchQueries =- SearchQueries'- { _sqAddtional :: HashMap Text [Query]- }- deriving (Eq, Show, Data, Typeable, Generic)----- | Creates a value of 'SearchQueries' with the minimum fields required to make a request.------ Use one of the following lenses to modify other fields as desired:------ * 'sqAddtional'-searchQueries- :: HashMap Text [Query] -- ^ 'sqAddtional'- -> SearchQueries-searchQueries pSqAddtional_ =- SearchQueries' {_sqAddtional = _Coerce # pSqAddtional_}---sqAddtional :: Lens' SearchQueries (HashMap Text [Query])-sqAddtional- = lens _sqAddtional (\ s a -> s{_sqAddtional = a}) .- _Coerce--instance FromJSON SearchQueries where- parseJSON- = withObject "SearchQueries"- (\ o -> SearchQueries' <$> (parseJSONObject o))--instance ToJSON SearchQueries where- toJSON = toJSON . _sqAddtional------- /See:/ 'resultPagemapAdditionalItem' smart constructor.-newtype ResultPagemapAdditionalItem =- ResultPagemapAdditionalItem'- { _rpaiAddtional :: HashMap Text JSONValue- }- deriving (Eq, Show, Data, Typeable, Generic)----- | Creates a value of 'ResultPagemapAdditionalItem' with the minimum fields required to make a request.------ Use one of the following lenses to modify other fields as desired:------ * 'rpaiAddtional'-resultPagemapAdditionalItem- :: HashMap Text JSONValue -- ^ 'rpaiAddtional'- -> ResultPagemapAdditionalItem-resultPagemapAdditionalItem pRpaiAddtional_ =- ResultPagemapAdditionalItem' {_rpaiAddtional = _Coerce # pRpaiAddtional_}---rpaiAddtional :: Lens' ResultPagemapAdditionalItem (HashMap Text JSONValue)-rpaiAddtional- = lens _rpaiAddtional- (\ s a -> s{_rpaiAddtional = a})- . _Coerce--instance FromJSON ResultPagemapAdditionalItem where- parseJSON- = withObject "ResultPagemapAdditionalItem"- (\ o ->- ResultPagemapAdditionalItem' <$> (parseJSONObject o))--instance ToJSON ResultPagemapAdditionalItem where- toJSON = toJSON . _rpaiAddtional------- /See:/ 'searchURL' smart constructor.-data SearchURL =- SearchURL'- { _suType :: !Text- , _suTemplate :: !Text- }- deriving (Eq, Show, Data, Typeable, Generic)----- | Creates a value of 'SearchURL' with the minimum fields required to make a request.------ Use one of the following lenses to modify other fields as desired:------ * 'suType'------ * 'suTemplate'-searchURL- :: SearchURL-searchURL =- SearchURL'- { _suType = "application/json"- , _suTemplate =- "https://www.googleapis.com/customsearch/v1?q={searchTerms}&num={count?}&start={startIndex?}&lr={language?}&safe={safe?}&cx={cx?}&sort={sort?}&filter={filter?}&gl={gl?}&cr={cr?}&googlehost={googleHost?}&c2coff={disableCnTwTranslation?}&hq={hq?}&hl={hl?}&siteSearch={siteSearch?}&siteSearchFilter={siteSearchFilter?}&exactTerms={exactTerms?}&excludeTerms={excludeTerms?}&linkSite={linkSite?}&orTerms={orTerms?}&relatedSite={relatedSite?}&dateRestrict={dateRestrict?}&lowRange={lowRange?}&highRange={highRange?}&searchType={searchType}&fileType={fileType?}&rights={rights?}&imgSize={imgSize?}&imgType={imgType?}&imgColorType={imgColorType?}&imgDominantColor={imgDominantColor?}&alt=json"- }---suType :: Lens' SearchURL Text-suType = lens _suType (\ s a -> s{_suType = a})--suTemplate :: Lens' SearchURL Text-suTemplate- = lens _suTemplate (\ s a -> s{_suTemplate = a})--instance FromJSON SearchURL where- parseJSON- = withObject "SearchURL"- (\ o ->- SearchURL' <$>- (o .:? "type" .!= "application/json") <*>- (o .:? "template" .!=- "https://www.googleapis.com/customsearch/v1?q={searchTerms}&num={count?}&start={startIndex?}&lr={language?}&safe={safe?}&cx={cx?}&sort={sort?}&filter={filter?}&gl={gl?}&cr={cr?}&googlehost={googleHost?}&c2coff={disableCnTwTranslation?}&hq={hq?}&hl={hl?}&siteSearch={siteSearch?}&siteSearchFilter={siteSearchFilter?}&exactTerms={exactTerms?}&excludeTerms={excludeTerms?}&linkSite={linkSite?}&orTerms={orTerms?}&relatedSite={relatedSite?}&dateRestrict={dateRestrict?}&lowRange={lowRange?}&highRange={highRange?}&searchType={searchType}&fileType={fileType?}&rights={rights?}&imgSize={imgSize?}&imgType={imgType?}&imgColorType={imgColorType?}&imgDominantColor={imgDominantColor?}&alt=json"))--instance ToJSON SearchURL where- toJSON SearchURL'{..}- = object- (catMaybes- [Just ("type" .= _suType),- Just ("template" .= _suTemplate)])------- /See:/ 'searchSpelling' smart constructor.-data SearchSpelling =- SearchSpelling'- { _ssCorrectedQuery :: !(Maybe Text)- , _ssHTMLCorrectedQuery :: !(Maybe Text)- }- deriving (Eq, Show, Data, Typeable, Generic)----- | Creates a value of 'SearchSpelling' with the minimum fields required to make a request.------ Use one of the following lenses to modify other fields as desired:------ * 'ssCorrectedQuery'------ * 'ssHTMLCorrectedQuery'-searchSpelling- :: SearchSpelling-searchSpelling =- SearchSpelling' {_ssCorrectedQuery = Nothing, _ssHTMLCorrectedQuery = Nothing}---ssCorrectedQuery :: Lens' SearchSpelling (Maybe Text)-ssCorrectedQuery- = lens _ssCorrectedQuery- (\ s a -> s{_ssCorrectedQuery = a})--ssHTMLCorrectedQuery :: Lens' SearchSpelling (Maybe Text)-ssHTMLCorrectedQuery- = lens _ssHTMLCorrectedQuery- (\ s a -> s{_ssHTMLCorrectedQuery = a})--instance FromJSON SearchSpelling where- parseJSON- = withObject "SearchSpelling"- (\ o ->- SearchSpelling' <$>- (o .:? "correctedQuery") <*>- (o .:? "htmlCorrectedQuery"))--instance ToJSON SearchSpelling where- toJSON SearchSpelling'{..}- = object- (catMaybes- [("correctedQuery" .=) <$> _ssCorrectedQuery,- ("htmlCorrectedQuery" .=) <$> _ssHTMLCorrectedQuery])------- /See:/ 'resultImage' smart constructor.-data ResultImage =- ResultImage'- { _riThumbnailLink :: !(Maybe Text)- , _riHeight :: !(Maybe (Textual Int32))- , _riByteSize :: !(Maybe (Textual Int32))- , _riContextLink :: !(Maybe Text)- , _riThumbnailHeight :: !(Maybe (Textual Int32))- , _riWidth :: !(Maybe (Textual Int32))- , _riThumbnailWidth :: !(Maybe (Textual Int32))- }- deriving (Eq, Show, Data, Typeable, Generic)----- | Creates a value of 'ResultImage' with the minimum fields required to make a request.------ Use one of the following lenses to modify other fields as desired:------ * 'riThumbnailLink'------ * 'riHeight'------ * 'riByteSize'------ * 'riContextLink'------ * 'riThumbnailHeight'------ * 'riWidth'------ * 'riThumbnailWidth'-resultImage- :: ResultImage-resultImage =- ResultImage'- { _riThumbnailLink = Nothing- , _riHeight = Nothing- , _riByteSize = Nothing- , _riContextLink = Nothing- , _riThumbnailHeight = Nothing- , _riWidth = Nothing- , _riThumbnailWidth = Nothing- }---riThumbnailLink :: Lens' ResultImage (Maybe Text)-riThumbnailLink- = lens _riThumbnailLink- (\ s a -> s{_riThumbnailLink = a})--riHeight :: Lens' ResultImage (Maybe Int32)-riHeight- = lens _riHeight (\ s a -> s{_riHeight = a}) .- mapping _Coerce--riByteSize :: Lens' ResultImage (Maybe Int32)-riByteSize- = lens _riByteSize (\ s a -> s{_riByteSize = a}) .- mapping _Coerce--riContextLink :: Lens' ResultImage (Maybe Text)-riContextLink- = lens _riContextLink- (\ s a -> s{_riContextLink = a})--riThumbnailHeight :: Lens' ResultImage (Maybe Int32)-riThumbnailHeight- = lens _riThumbnailHeight- (\ s a -> s{_riThumbnailHeight = a})- . mapping _Coerce--riWidth :: Lens' ResultImage (Maybe Int32)-riWidth- = lens _riWidth (\ s a -> s{_riWidth = a}) .- mapping _Coerce--riThumbnailWidth :: Lens' ResultImage (Maybe Int32)-riThumbnailWidth- = lens _riThumbnailWidth- (\ s a -> s{_riThumbnailWidth = a})- . mapping _Coerce--instance FromJSON ResultImage where- parseJSON- = withObject "ResultImage"- (\ o ->- ResultImage' <$>- (o .:? "thumbnailLink") <*> (o .:? "height") <*>- (o .:? "byteSize")- <*> (o .:? "contextLink")- <*> (o .:? "thumbnailHeight")- <*> (o .:? "width")- <*> (o .:? "thumbnailWidth"))--instance ToJSON ResultImage where- toJSON ResultImage'{..}- = object- (catMaybes- [("thumbnailLink" .=) <$> _riThumbnailLink,- ("height" .=) <$> _riHeight,- ("byteSize" .=) <$> _riByteSize,- ("contextLink" .=) <$> _riContextLink,- ("thumbnailHeight" .=) <$> _riThumbnailHeight,- ("width" .=) <$> _riWidth,- ("thumbnailWidth" .=) <$> _riThumbnailWidth])------- /See:/ 'resultPagemap' smart constructor.-newtype ResultPagemap =- ResultPagemap'- { _rpAddtional :: HashMap Text [ResultPagemapAdditionalItem]- }- deriving (Eq, Show, Data, Typeable, Generic)----- | Creates a value of 'ResultPagemap' with the minimum fields required to make a request.------ Use one of the following lenses to modify other fields as desired:------ * 'rpAddtional'-resultPagemap- :: HashMap Text [ResultPagemapAdditionalItem] -- ^ 'rpAddtional'- -> ResultPagemap-resultPagemap pRpAddtional_ =- ResultPagemap' {_rpAddtional = _Coerce # pRpAddtional_}---rpAddtional :: Lens' ResultPagemap (HashMap Text [ResultPagemapAdditionalItem])-rpAddtional- = lens _rpAddtional (\ s a -> s{_rpAddtional = a}) .- _Coerce--instance FromJSON ResultPagemap where- parseJSON- = withObject "ResultPagemap"- (\ o -> ResultPagemap' <$> (parseJSONObject o))--instance ToJSON ResultPagemap where- toJSON = toJSON . _rpAddtional------- /See:/ 'result' smart constructor.-data Result =- Result'- { _rMime :: !(Maybe Text)- , _rImage :: !(Maybe ResultImage)- , _rPagemap :: !(Maybe ResultPagemap)- , _rDisplayLink :: !(Maybe Text)- , _rFileFormat :: !(Maybe Text)- , _rSnippet :: !(Maybe Text)- , _rKind :: !Text- , _rLink :: !(Maybe Text)- , _rHTMLSnippet :: !(Maybe Text)- , _rHTMLFormattedURL :: !(Maybe Text)- , _rCacheId :: !(Maybe Text)- , _rFormattedURL :: !(Maybe Text)- , _rHTMLTitle :: !(Maybe Text)- , _rLabels :: !(Maybe [ResultLabelsItem])- , _rTitle :: !(Maybe Text)- }- deriving (Eq, Show, Data, Typeable, Generic)----- | Creates a value of 'Result' with the minimum fields required to make a request.------ Use one of the following lenses to modify other fields as desired:------ * 'rMime'------ * 'rImage'------ * 'rPagemap'------ * 'rDisplayLink'------ * 'rFileFormat'------ * 'rSnippet'------ * 'rKind'------ * 'rLink'------ * 'rHTMLSnippet'------ * 'rHTMLFormattedURL'------ * 'rCacheId'------ * 'rFormattedURL'------ * 'rHTMLTitle'------ * 'rLabels'------ * 'rTitle'-result- :: Result-result =- Result'- { _rMime = Nothing- , _rImage = Nothing- , _rPagemap = Nothing- , _rDisplayLink = Nothing- , _rFileFormat = Nothing- , _rSnippet = Nothing- , _rKind = "customsearch#result"- , _rLink = Nothing- , _rHTMLSnippet = Nothing- , _rHTMLFormattedURL = Nothing- , _rCacheId = Nothing- , _rFormattedURL = Nothing- , _rHTMLTitle = Nothing- , _rLabels = Nothing- , _rTitle = Nothing- }---rMime :: Lens' Result (Maybe Text)-rMime = lens _rMime (\ s a -> s{_rMime = a})--rImage :: Lens' Result (Maybe ResultImage)-rImage = lens _rImage (\ s a -> s{_rImage = a})--rPagemap :: Lens' Result (Maybe ResultPagemap)-rPagemap = lens _rPagemap (\ s a -> s{_rPagemap = a})--rDisplayLink :: Lens' Result (Maybe Text)-rDisplayLink- = lens _rDisplayLink (\ s a -> s{_rDisplayLink = a})--rFileFormat :: Lens' Result (Maybe Text)-rFileFormat- = lens _rFileFormat (\ s a -> s{_rFileFormat = a})--rSnippet :: Lens' Result (Maybe Text)-rSnippet = lens _rSnippet (\ s a -> s{_rSnippet = a})--rKind :: Lens' Result Text-rKind = lens _rKind (\ s a -> s{_rKind = a})--rLink :: Lens' Result (Maybe Text)-rLink = lens _rLink (\ s a -> s{_rLink = a})--rHTMLSnippet :: Lens' Result (Maybe Text)-rHTMLSnippet- = lens _rHTMLSnippet (\ s a -> s{_rHTMLSnippet = a})--rHTMLFormattedURL :: Lens' Result (Maybe Text)-rHTMLFormattedURL- = lens _rHTMLFormattedURL- (\ s a -> s{_rHTMLFormattedURL = a})--rCacheId :: Lens' Result (Maybe Text)-rCacheId = lens _rCacheId (\ s a -> s{_rCacheId = a})--rFormattedURL :: Lens' Result (Maybe Text)-rFormattedURL- = lens _rFormattedURL- (\ s a -> s{_rFormattedURL = a})--rHTMLTitle :: Lens' Result (Maybe Text)-rHTMLTitle- = lens _rHTMLTitle (\ s a -> s{_rHTMLTitle = a})--rLabels :: Lens' Result [ResultLabelsItem]-rLabels- = lens _rLabels (\ s a -> s{_rLabels = a}) . _Default- . _Coerce--rTitle :: Lens' Result (Maybe Text)-rTitle = lens _rTitle (\ s a -> s{_rTitle = a})--instance FromJSON Result where- parseJSON- = withObject "Result"- (\ o ->- Result' <$>- (o .:? "mime") <*> (o .:? "image") <*>- (o .:? "pagemap")- <*> (o .:? "displayLink")- <*> (o .:? "fileFormat")- <*> (o .:? "snippet")- <*> (o .:? "kind" .!= "customsearch#result")- <*> (o .:? "link")- <*> (o .:? "htmlSnippet")- <*> (o .:? "htmlFormattedUrl")- <*> (o .:? "cacheId")- <*> (o .:? "formattedUrl")- <*> (o .:? "htmlTitle")- <*> (o .:? "labels" .!= mempty)- <*> (o .:? "title"))--instance ToJSON Result where- toJSON Result'{..}- = object- (catMaybes- [("mime" .=) <$> _rMime, ("image" .=) <$> _rImage,- ("pagemap" .=) <$> _rPagemap,- ("displayLink" .=) <$> _rDisplayLink,- ("fileFormat" .=) <$> _rFileFormat,- ("snippet" .=) <$> _rSnippet,- Just ("kind" .= _rKind), ("link" .=) <$> _rLink,- ("htmlSnippet" .=) <$> _rHTMLSnippet,- ("htmlFormattedUrl" .=) <$> _rHTMLFormattedURL,- ("cacheId" .=) <$> _rCacheId,- ("formattedUrl" .=) <$> _rFormattedURL,- ("htmlTitle" .=) <$> _rHTMLTitle,- ("labels" .=) <$> _rLabels,- ("title" .=) <$> _rTitle])------- /See:/ 'resultLabelsItem' smart constructor.-data ResultLabelsItem =- ResultLabelsItem'- { _rliName :: !(Maybe Text)- , _rliDisplayName :: !(Maybe Text)- , _rliLabelWithOp :: !(Maybe Text)- }- deriving (Eq, Show, Data, Typeable, Generic)----- | Creates a value of 'ResultLabelsItem' with the minimum fields required to make a request.------ Use one of the following lenses to modify other fields as desired:------ * 'rliName'------ * 'rliDisplayName'------ * 'rliLabelWithOp'-resultLabelsItem- :: ResultLabelsItem-resultLabelsItem =- ResultLabelsItem'- {_rliName = Nothing, _rliDisplayName = Nothing, _rliLabelWithOp = Nothing}---rliName :: Lens' ResultLabelsItem (Maybe Text)-rliName = lens _rliName (\ s a -> s{_rliName = a})--rliDisplayName :: Lens' ResultLabelsItem (Maybe Text)-rliDisplayName- = lens _rliDisplayName- (\ s a -> s{_rliDisplayName = a})--rliLabelWithOp :: Lens' ResultLabelsItem (Maybe Text)-rliLabelWithOp- = lens _rliLabelWithOp- (\ s a -> s{_rliLabelWithOp = a})--instance FromJSON ResultLabelsItem where- parseJSON- = withObject "ResultLabelsItem"- (\ o ->- ResultLabelsItem' <$>- (o .:? "name") <*> (o .:? "displayName") <*>- (o .:? "label_with_op"))--instance ToJSON ResultLabelsItem where- toJSON ResultLabelsItem'{..}- = object- (catMaybes- [("name" .=) <$> _rliName,- ("displayName" .=) <$> _rliDisplayName,- ("label_with_op" .=) <$> _rliLabelWithOp])------- /See:/ 'searchSearchInformation' smart constructor.-data SearchSearchInformation =- SearchSearchInformation'- { _ssiSearchTime :: !(Maybe (Textual Double))- , _ssiFormattedSearchTime :: !(Maybe Text)- , _ssiTotalResults :: !(Maybe (Textual Int64))- , _ssiFormattedTotalResults :: !(Maybe Text)- }- deriving (Eq, Show, Data, Typeable, Generic)----- | Creates a value of 'SearchSearchInformation' with the minimum fields required to make a request.------ Use one of the following lenses to modify other fields as desired:------ * 'ssiSearchTime'------ * 'ssiFormattedSearchTime'------ * 'ssiTotalResults'------ * 'ssiFormattedTotalResults'-searchSearchInformation- :: SearchSearchInformation-searchSearchInformation =- SearchSearchInformation'- { _ssiSearchTime = Nothing- , _ssiFormattedSearchTime = Nothing- , _ssiTotalResults = Nothing- , _ssiFormattedTotalResults = Nothing- }---ssiSearchTime :: Lens' SearchSearchInformation (Maybe Double)-ssiSearchTime- = lens _ssiSearchTime- (\ s a -> s{_ssiSearchTime = a})- . mapping _Coerce--ssiFormattedSearchTime :: Lens' SearchSearchInformation (Maybe Text)-ssiFormattedSearchTime- = lens _ssiFormattedSearchTime- (\ s a -> s{_ssiFormattedSearchTime = a})--ssiTotalResults :: Lens' SearchSearchInformation (Maybe Int64)-ssiTotalResults- = lens _ssiTotalResults- (\ s a -> s{_ssiTotalResults = a})- . mapping _Coerce--ssiFormattedTotalResults :: Lens' SearchSearchInformation (Maybe Text)-ssiFormattedTotalResults- = lens _ssiFormattedTotalResults- (\ s a -> s{_ssiFormattedTotalResults = a})--instance FromJSON SearchSearchInformation where- parseJSON- = withObject "SearchSearchInformation"- (\ o ->- SearchSearchInformation' <$>- (o .:? "searchTime") <*>- (o .:? "formattedSearchTime")- <*> (o .:? "totalResults")- <*> (o .:? "formattedTotalResults"))--instance ToJSON SearchSearchInformation where- toJSON SearchSearchInformation'{..}- = object- (catMaybes- [("searchTime" .=) <$> _ssiSearchTime,- ("formattedSearchTime" .=) <$>- _ssiFormattedSearchTime,- ("totalResults" .=) <$> _ssiTotalResults,- ("formattedTotalResults" .=) <$>- _ssiFormattedTotalResults])------- /See:/ 'query' smart constructor.-data Query =- Query'- { _qImgDominantColor :: !(Maybe Text)- , _qOutputEncoding :: !(Maybe Text)- , _qSiteSearchFilter :: !(Maybe Text)- , _qInputEncoding :: !(Maybe Text)- , _qOrTerms :: !(Maybe Text)- , _qSearchTerms :: !(Maybe Text)- , _qStartPage :: !(Maybe (Textual Int32))- , _qRights :: !(Maybe Text)- , _qCount :: !(Maybe (Textual Int32))- , _qExcludeTerms :: !(Maybe Text)- , _qFileType :: !(Maybe Text)- , _qSearchType :: !(Maybe Text)- , _qGoogleHost :: !(Maybe Text)- , _qDisableCnTwTranslation :: !(Maybe Text)- , _qRelatedSite :: !(Maybe Text)- , _qHl :: !(Maybe Text)- , _qSort :: !(Maybe Text)- , _qLanguage :: !(Maybe Text)- , _qSiteSearch :: !(Maybe Text)- , _qFilter :: !(Maybe Text)- , _qTotalResults :: !(Maybe (Textual Int64))- , _qDateRestrict :: !(Maybe Text)- , _qTitle :: !(Maybe Text)- , _qLinkSite :: !(Maybe Text)- , _qLowRange :: !(Maybe Text)- , _qImgType :: !(Maybe Text)- , _qGl :: !(Maybe Text)- , _qCx :: !(Maybe Text)- , _qImgColorType :: !(Maybe Text)- , _qImgSize :: !(Maybe Text)- , _qExactTerms :: !(Maybe Text)- , _qStartIndex :: !(Maybe (Textual Int32))- , _qCr :: !(Maybe Text)- , _qSafe :: !(Maybe Text)- , _qHq :: !(Maybe Text)- , _qHighRange :: !(Maybe Text)- }- deriving (Eq, Show, Data, Typeable, Generic)----- | Creates a value of 'Query' with the minimum fields required to make a request.------ Use one of the following lenses to modify other fields as desired:------ * 'qImgDominantColor'------ * 'qOutputEncoding'------ * 'qSiteSearchFilter'------ * 'qInputEncoding'------ * 'qOrTerms'------ * 'qSearchTerms'------ * 'qStartPage'------ * 'qRights'------ * 'qCount'------ * 'qExcludeTerms'------ * 'qFileType'------ * 'qSearchType'------ * 'qGoogleHost'------ * 'qDisableCnTwTranslation'------ * 'qRelatedSite'------ * 'qHl'------ * 'qSort'------ * 'qLanguage'------ * 'qSiteSearch'------ * 'qFilter'------ * 'qTotalResults'------ * 'qDateRestrict'------ * 'qTitle'------ * 'qLinkSite'------ * 'qLowRange'------ * 'qImgType'------ * 'qGl'------ * 'qCx'------ * 'qImgColorType'------ * 'qImgSize'------ * 'qExactTerms'------ * 'qStartIndex'------ * 'qCr'------ * 'qSafe'------ * 'qHq'------ * 'qHighRange'-query- :: Query-query =- Query'- { _qImgDominantColor = Nothing- , _qOutputEncoding = Nothing- , _qSiteSearchFilter = Nothing- , _qInputEncoding = Nothing- , _qOrTerms = Nothing- , _qSearchTerms = Nothing- , _qStartPage = Nothing- , _qRights = Nothing- , _qCount = Nothing- , _qExcludeTerms = Nothing- , _qFileType = Nothing- , _qSearchType = Nothing- , _qGoogleHost = Nothing- , _qDisableCnTwTranslation = Nothing- , _qRelatedSite = Nothing- , _qHl = Nothing- , _qSort = Nothing- , _qLanguage = Nothing- , _qSiteSearch = Nothing- , _qFilter = Nothing- , _qTotalResults = Nothing- , _qDateRestrict = Nothing- , _qTitle = Nothing- , _qLinkSite = Nothing- , _qLowRange = Nothing- , _qImgType = Nothing- , _qGl = Nothing- , _qCx = Nothing- , _qImgColorType = Nothing- , _qImgSize = Nothing- , _qExactTerms = Nothing- , _qStartIndex = Nothing- , _qCr = Nothing- , _qSafe = Nothing- , _qHq = Nothing- , _qHighRange = Nothing- }---qImgDominantColor :: Lens' Query (Maybe Text)-qImgDominantColor- = lens _qImgDominantColor- (\ s a -> s{_qImgDominantColor = a})--qOutputEncoding :: Lens' Query (Maybe Text)-qOutputEncoding- = lens _qOutputEncoding- (\ s a -> s{_qOutputEncoding = a})--qSiteSearchFilter :: Lens' Query (Maybe Text)-qSiteSearchFilter- = lens _qSiteSearchFilter- (\ s a -> s{_qSiteSearchFilter = a})--qInputEncoding :: Lens' Query (Maybe Text)-qInputEncoding- = lens _qInputEncoding- (\ s a -> s{_qInputEncoding = a})--qOrTerms :: Lens' Query (Maybe Text)-qOrTerms = lens _qOrTerms (\ s a -> s{_qOrTerms = a})--qSearchTerms :: Lens' Query (Maybe Text)-qSearchTerms- = lens _qSearchTerms (\ s a -> s{_qSearchTerms = a})--qStartPage :: Lens' Query (Maybe Int32)-qStartPage- = lens _qStartPage (\ s a -> s{_qStartPage = a}) .- mapping _Coerce--qRights :: Lens' Query (Maybe Text)-qRights = lens _qRights (\ s a -> s{_qRights = a})--qCount :: Lens' Query (Maybe Int32)-qCount- = lens _qCount (\ s a -> s{_qCount = a}) .- mapping _Coerce--qExcludeTerms :: Lens' Query (Maybe Text)-qExcludeTerms- = lens _qExcludeTerms- (\ s a -> s{_qExcludeTerms = a})--qFileType :: Lens' Query (Maybe Text)-qFileType- = lens _qFileType (\ s a -> s{_qFileType = a})--qSearchType :: Lens' Query (Maybe Text)-qSearchType- = lens _qSearchType (\ s a -> s{_qSearchType = a})--qGoogleHost :: Lens' Query (Maybe Text)-qGoogleHost- = lens _qGoogleHost (\ s a -> s{_qGoogleHost = a})--qDisableCnTwTranslation :: Lens' Query (Maybe Text)-qDisableCnTwTranslation- = lens _qDisableCnTwTranslation- (\ s a -> s{_qDisableCnTwTranslation = a})--qRelatedSite :: Lens' Query (Maybe Text)-qRelatedSite- = lens _qRelatedSite (\ s a -> s{_qRelatedSite = a})--qHl :: Lens' Query (Maybe Text)-qHl = lens _qHl (\ s a -> s{_qHl = a})--qSort :: Lens' Query (Maybe Text)-qSort = lens _qSort (\ s a -> s{_qSort = a})--qLanguage :: Lens' Query (Maybe Text)-qLanguage- = lens _qLanguage (\ s a -> s{_qLanguage = a})--qSiteSearch :: Lens' Query (Maybe Text)-qSiteSearch- = lens _qSiteSearch (\ s a -> s{_qSiteSearch = a})--qFilter :: Lens' Query (Maybe Text)-qFilter = lens _qFilter (\ s a -> s{_qFilter = a})--qTotalResults :: Lens' Query (Maybe Int64)-qTotalResults- = lens _qTotalResults- (\ s a -> s{_qTotalResults = a})- . mapping _Coerce--qDateRestrict :: Lens' Query (Maybe Text)-qDateRestrict- = lens _qDateRestrict- (\ s a -> s{_qDateRestrict = a})--qTitle :: Lens' Query (Maybe Text)-qTitle = lens _qTitle (\ s a -> s{_qTitle = a})--qLinkSite :: Lens' Query (Maybe Text)-qLinkSite- = lens _qLinkSite (\ s a -> s{_qLinkSite = a})--qLowRange :: Lens' Query (Maybe Text)-qLowRange- = lens _qLowRange (\ s a -> s{_qLowRange = a})--qImgType :: Lens' Query (Maybe Text)-qImgType = lens _qImgType (\ s a -> s{_qImgType = a})--qGl :: Lens' Query (Maybe Text)-qGl = lens _qGl (\ s a -> s{_qGl = a})--qCx :: Lens' Query (Maybe Text)-qCx = lens _qCx (\ s a -> s{_qCx = a})--qImgColorType :: Lens' Query (Maybe Text)-qImgColorType- = lens _qImgColorType- (\ s a -> s{_qImgColorType = a})--qImgSize :: Lens' Query (Maybe Text)-qImgSize = lens _qImgSize (\ s a -> s{_qImgSize = a})--qExactTerms :: Lens' Query (Maybe Text)-qExactTerms- = lens _qExactTerms (\ s a -> s{_qExactTerms = a})--qStartIndex :: Lens' Query (Maybe Int32)-qStartIndex- = lens _qStartIndex (\ s a -> s{_qStartIndex = a}) .- mapping _Coerce--qCr :: Lens' Query (Maybe Text)-qCr = lens _qCr (\ s a -> s{_qCr = a})--qSafe :: Lens' Query (Maybe Text)-qSafe = lens _qSafe (\ s a -> s{_qSafe = a})--qHq :: Lens' Query (Maybe Text)-qHq = lens _qHq (\ s a -> s{_qHq = a})--qHighRange :: Lens' Query (Maybe Text)-qHighRange- = lens _qHighRange (\ s a -> s{_qHighRange = a})--instance FromJSON Query where- parseJSON- = withObject "Query"- (\ o ->- Query' <$>- (o .:? "imgDominantColor") <*>- (o .:? "outputEncoding")- <*> (o .:? "siteSearchFilter")- <*> (o .:? "inputEncoding")- <*> (o .:? "orTerms")- <*> (o .:? "searchTerms")- <*> (o .:? "startPage")- <*> (o .:? "rights")- <*> (o .:? "count")- <*> (o .:? "excludeTerms")- <*> (o .:? "fileType")- <*> (o .:? "searchType")- <*> (o .:? "googleHost")- <*> (o .:? "disableCnTwTranslation")- <*> (o .:? "relatedSite")- <*> (o .:? "hl")- <*> (o .:? "sort")- <*> (o .:? "language")- <*> (o .:? "siteSearch")- <*> (o .:? "filter")- <*> (o .:? "totalResults")- <*> (o .:? "dateRestrict")- <*> (o .:? "title")- <*> (o .:? "linkSite")- <*> (o .:? "lowRange")- <*> (o .:? "imgType")- <*> (o .:? "gl")- <*> (o .:? "cx")- <*> (o .:? "imgColorType")- <*> (o .:? "imgSize")- <*> (o .:? "exactTerms")- <*> (o .:? "startIndex")- <*> (o .:? "cr")- <*> (o .:? "safe")- <*> (o .:? "hq")- <*> (o .:? "highRange"))--instance ToJSON Query where- toJSON Query'{..}- = object- (catMaybes- [("imgDominantColor" .=) <$> _qImgDominantColor,- ("outputEncoding" .=) <$> _qOutputEncoding,- ("siteSearchFilter" .=) <$> _qSiteSearchFilter,- ("inputEncoding" .=) <$> _qInputEncoding,- ("orTerms" .=) <$> _qOrTerms,- ("searchTerms" .=) <$> _qSearchTerms,- ("startPage" .=) <$> _qStartPage,- ("rights" .=) <$> _qRights, ("count" .=) <$> _qCount,- ("excludeTerms" .=) <$> _qExcludeTerms,- ("fileType" .=) <$> _qFileType,- ("searchType" .=) <$> _qSearchType,- ("googleHost" .=) <$> _qGoogleHost,- ("disableCnTwTranslation" .=) <$>- _qDisableCnTwTranslation,- ("relatedSite" .=) <$> _qRelatedSite,- ("hl" .=) <$> _qHl, ("sort" .=) <$> _qSort,- ("language" .=) <$> _qLanguage,- ("siteSearch" .=) <$> _qSiteSearch,- ("filter" .=) <$> _qFilter,- ("totalResults" .=) <$> _qTotalResults,- ("dateRestrict" .=) <$> _qDateRestrict,- ("title" .=) <$> _qTitle,- ("linkSite" .=) <$> _qLinkSite,- ("lowRange" .=) <$> _qLowRange,- ("imgType" .=) <$> _qImgType, ("gl" .=) <$> _qGl,- ("cx" .=) <$> _qCx,- ("imgColorType" .=) <$> _qImgColorType,- ("imgSize" .=) <$> _qImgSize,- ("exactTerms" .=) <$> _qExactTerms,- ("startIndex" .=) <$> _qStartIndex,- ("cr" .=) <$> _qCr, ("safe" .=) <$> _qSafe,- ("hq" .=) <$> _qHq,- ("highRange" .=) <$> _qHighRange])------- /See:/ 'promotionBodyLinesItem' smart constructor.-data PromotionBodyLinesItem =- PromotionBodyLinesItem'- { _pbliLink :: !(Maybe Text)- , _pbliURL :: !(Maybe Text)- , _pbliHTMLTitle :: !(Maybe Text)- , _pbliTitle :: !(Maybe Text)- }- deriving (Eq, Show, Data, Typeable, Generic)----- | Creates a value of 'PromotionBodyLinesItem' with the minimum fields required to make a request.------ Use one of the following lenses to modify other fields as desired:------ * 'pbliLink'------ * 'pbliURL'------ * 'pbliHTMLTitle'------ * 'pbliTitle'-promotionBodyLinesItem- :: PromotionBodyLinesItem-promotionBodyLinesItem =- PromotionBodyLinesItem'- { _pbliLink = Nothing- , _pbliURL = Nothing- , _pbliHTMLTitle = Nothing- , _pbliTitle = Nothing- }---pbliLink :: Lens' PromotionBodyLinesItem (Maybe Text)-pbliLink = lens _pbliLink (\ s a -> s{_pbliLink = a})--pbliURL :: Lens' PromotionBodyLinesItem (Maybe Text)-pbliURL = lens _pbliURL (\ s a -> s{_pbliURL = a})--pbliHTMLTitle :: Lens' PromotionBodyLinesItem (Maybe Text)-pbliHTMLTitle- = lens _pbliHTMLTitle- (\ s a -> s{_pbliHTMLTitle = a})--pbliTitle :: Lens' PromotionBodyLinesItem (Maybe Text)-pbliTitle- = lens _pbliTitle (\ s a -> s{_pbliTitle = a})--instance FromJSON PromotionBodyLinesItem where- parseJSON- = withObject "PromotionBodyLinesItem"- (\ o ->- PromotionBodyLinesItem' <$>- (o .:? "link") <*> (o .:? "url") <*>- (o .:? "htmlTitle")- <*> (o .:? "title"))--instance ToJSON PromotionBodyLinesItem where- toJSON PromotionBodyLinesItem'{..}- = object- (catMaybes- [("link" .=) <$> _pbliLink, ("url" .=) <$> _pbliURL,- ("htmlTitle" .=) <$> _pbliHTMLTitle,- ("title" .=) <$> _pbliTitle])------- /See:/ 'promotion' smart constructor.-data Promotion =- Promotion'- { _pImage :: !(Maybe PromotionImage)- , _pDisplayLink :: !(Maybe Text)- , _pBodyLines :: !(Maybe [PromotionBodyLinesItem])- , _pLink :: !(Maybe Text)- , _pHTMLTitle :: !(Maybe Text)- , _pTitle :: !(Maybe Text)- }- deriving (Eq, Show, Data, Typeable, Generic)----- | Creates a value of 'Promotion' with the minimum fields required to make a request.------ Use one of the following lenses to modify other fields as desired:------ * 'pImage'------ * 'pDisplayLink'------ * 'pBodyLines'------ * 'pLink'------ * 'pHTMLTitle'------ * 'pTitle'-promotion- :: Promotion-promotion =- Promotion'- { _pImage = Nothing- , _pDisplayLink = Nothing- , _pBodyLines = Nothing- , _pLink = Nothing- , _pHTMLTitle = Nothing- , _pTitle = Nothing- }---pImage :: Lens' Promotion (Maybe PromotionImage)-pImage = lens _pImage (\ s a -> s{_pImage = a})--pDisplayLink :: Lens' Promotion (Maybe Text)-pDisplayLink- = lens _pDisplayLink (\ s a -> s{_pDisplayLink = a})--pBodyLines :: Lens' Promotion [PromotionBodyLinesItem]-pBodyLines- = lens _pBodyLines (\ s a -> s{_pBodyLines = a}) .- _Default- . _Coerce--pLink :: Lens' Promotion (Maybe Text)-pLink = lens _pLink (\ s a -> s{_pLink = a})--pHTMLTitle :: Lens' Promotion (Maybe Text)-pHTMLTitle- = lens _pHTMLTitle (\ s a -> s{_pHTMLTitle = a})--pTitle :: Lens' Promotion (Maybe Text)-pTitle = lens _pTitle (\ s a -> s{_pTitle = a})--instance FromJSON Promotion where- parseJSON- = withObject "Promotion"- (\ o ->- Promotion' <$>- (o .:? "image") <*> (o .:? "displayLink") <*>- (o .:? "bodyLines" .!= mempty)- <*> (o .:? "link")- <*> (o .:? "htmlTitle")- <*> (o .:? "title"))--instance ToJSON Promotion where- toJSON Promotion'{..}- = object- (catMaybes- [("image" .=) <$> _pImage,- ("displayLink" .=) <$> _pDisplayLink,- ("bodyLines" .=) <$> _pBodyLines,- ("link" .=) <$> _pLink,- ("htmlTitle" .=) <$> _pHTMLTitle,- ("title" .=) <$> _pTitle])------- /See:/ 'search' smart constructor.-data Search =- Search'- { _sQueries :: !(Maybe SearchQueries)- , _sContext :: !(Maybe Context)- , _sKind :: !Text- , _sURL :: !(Maybe SearchURL)- , _sItems :: !(Maybe [Result])- , _sSearchInformation :: !(Maybe SearchSearchInformation)- , _sPromotions :: !(Maybe [Promotion])- , _sSpelling :: !(Maybe SearchSpelling)- }- deriving (Eq, Show, Data, Typeable, Generic)----- | Creates a value of 'Search' with the minimum fields required to make a request.------ Use one of the following lenses to modify other fields as desired:------ * 'sQueries'------ * 'sContext'------ * 'sKind'------ * 'sURL'------ * 'sItems'------ * 'sSearchInformation'------ * 'sPromotions'------ * 'sSpelling'-search- :: Search-search =- Search'- { _sQueries = Nothing- , _sContext = Nothing- , _sKind = "customsearch#search"- , _sURL = Nothing- , _sItems = Nothing- , _sSearchInformation = Nothing- , _sPromotions = Nothing- , _sSpelling = Nothing- }---sQueries :: Lens' Search (Maybe SearchQueries)-sQueries = lens _sQueries (\ s a -> s{_sQueries = a})--sContext :: Lens' Search (Maybe Context)-sContext = lens _sContext (\ s a -> s{_sContext = a})--sKind :: Lens' Search Text-sKind = lens _sKind (\ s a -> s{_sKind = a})--sURL :: Lens' Search (Maybe SearchURL)-sURL = lens _sURL (\ s a -> s{_sURL = a})--sItems :: Lens' Search [Result]-sItems- = lens _sItems (\ s a -> s{_sItems = a}) . _Default .- _Coerce--sSearchInformation :: Lens' Search (Maybe SearchSearchInformation)-sSearchInformation- = lens _sSearchInformation- (\ s a -> s{_sSearchInformation = a})--sPromotions :: Lens' Search [Promotion]-sPromotions- = lens _sPromotions (\ s a -> s{_sPromotions = a}) .- _Default- . _Coerce--sSpelling :: Lens' Search (Maybe SearchSpelling)-sSpelling- = lens _sSpelling (\ s a -> s{_sSpelling = a})--instance FromJSON Search where- parseJSON- = withObject "Search"- (\ o ->- Search' <$>- (o .:? "queries") <*> (o .:? "context") <*>- (o .:? "kind" .!= "customsearch#search")- <*> (o .:? "url")- <*> (o .:? "items" .!= mempty)- <*> (o .:? "searchInformation")- <*> (o .:? "promotions" .!= mempty)- <*> (o .:? "spelling"))--instance ToJSON Search where- toJSON Search'{..}- = object- (catMaybes- [("queries" .=) <$> _sQueries,- ("context" .=) <$> _sContext,- Just ("kind" .= _sKind), ("url" .=) <$> _sURL,- ("items" .=) <$> _sItems,- ("searchInformation" .=) <$> _sSearchInformation,- ("promotions" .=) <$> _sPromotions,- ("spelling" .=) <$> _sSpelling])------- /See:/ 'contextFacetsItemItem' smart constructor.-data ContextFacetsItemItem =- ContextFacetsItemItem'- { _cfiiAnchor :: !(Maybe Text)- , _cfiiLabelWithOp :: !(Maybe Text)- , _cfiiLabel :: !(Maybe Text)- }- deriving (Eq, Show, Data, Typeable, Generic)----- | Creates a value of 'ContextFacetsItemItem' with the minimum fields required to make a request.------ Use one of the following lenses to modify other fields as desired:------ * 'cfiiAnchor'------ * 'cfiiLabelWithOp'------ * 'cfiiLabel'-contextFacetsItemItem- :: ContextFacetsItemItem-contextFacetsItemItem =- ContextFacetsItemItem'- {_cfiiAnchor = Nothing, _cfiiLabelWithOp = Nothing, _cfiiLabel = Nothing}---cfiiAnchor :: Lens' ContextFacetsItemItem (Maybe Text)-cfiiAnchor- = lens _cfiiAnchor (\ s a -> s{_cfiiAnchor = a})--cfiiLabelWithOp :: Lens' ContextFacetsItemItem (Maybe Text)-cfiiLabelWithOp- = lens _cfiiLabelWithOp- (\ s a -> s{_cfiiLabelWithOp = a})--cfiiLabel :: Lens' ContextFacetsItemItem (Maybe Text)-cfiiLabel- = lens _cfiiLabel (\ s a -> s{_cfiiLabel = a})--instance FromJSON ContextFacetsItemItem where- parseJSON- = withObject "ContextFacetsItemItem"- (\ o ->- ContextFacetsItemItem' <$>- (o .:? "anchor") <*> (o .:? "label_with_op") <*>- (o .:? "label"))--instance ToJSON ContextFacetsItemItem where- toJSON ContextFacetsItemItem'{..}- = object- (catMaybes- [("anchor" .=) <$> _cfiiAnchor,- ("label_with_op" .=) <$> _cfiiLabelWithOp,- ("label" .=) <$> _cfiiLabel])
− gen/Network/Google/CustomSearch/Types/Sum.hs
@@ -1,1076 +0,0 @@-{-# LANGUAGE DeriveDataTypeable #-}-{-# LANGUAGE DeriveGeneric #-}-{-# LANGUAGE LambdaCase #-}-{-# LANGUAGE NoImplicitPrelude #-}-{-# LANGUAGE OverloadedStrings #-}--{-# OPTIONS_GHC -fno-warn-unused-imports #-}---- |--- Module : Network.Google.CustomSearch.Types.Sum--- Copyright : (c) 2015-2016 Brendan Hay--- License : Mozilla Public License, v. 2.0.--- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>--- Stability : auto-generated--- Portability : non-portable (GHC extensions)----module Network.Google.CustomSearch.Types.Sum where--import Network.Google.Prelude hiding (Bytes)---- | Returns images of a type, which can be one of: clipart, face, lineart,--- news, and photo.-data CSEListImgType- = CliPart- -- ^ @clipart@- -- clipart- | Face- -- ^ @face@- -- face- | Lineart- -- ^ @lineart@- -- lineart- | News- -- ^ @news@- -- news- | Photo- -- ^ @photo@- -- photo- deriving (Eq, Ord, Enum, Read, Show, Data, Typeable, Generic)--instance Hashable CSEListImgType--instance FromHttpApiData CSEListImgType where- parseQueryParam = \case- "clipart" -> Right CliPart- "face" -> Right Face- "lineart" -> Right Lineart- "news" -> Right News- "photo" -> Right Photo- x -> Left ("Unable to parse CSEListImgType from: " <> x)--instance ToHttpApiData CSEListImgType where- toQueryParam = \case- CliPart -> "clipart"- Face -> "face"- Lineart -> "lineart"- News -> "news"- Photo -> "photo"--instance FromJSON CSEListImgType where- parseJSON = parseJSONText "CSEListImgType"--instance ToJSON CSEListImgType where- toJSON = toJSONText---- | Controls whether to include or exclude results from the site named in--- the as_sitesearch parameter-data CSEListSiteSearchFilter- = E- -- ^ @e@- -- exclude- | I- -- ^ @i@- -- include- deriving (Eq, Ord, Enum, Read, Show, Data, Typeable, Generic)--instance Hashable CSEListSiteSearchFilter--instance FromHttpApiData CSEListSiteSearchFilter where- parseQueryParam = \case- "e" -> Right E- "i" -> Right I- x -> Left ("Unable to parse CSEListSiteSearchFilter from: " <> x)--instance ToHttpApiData CSEListSiteSearchFilter where- toQueryParam = \case- E -> "e"- I -> "i"--instance FromJSON CSEListSiteSearchFilter where- parseJSON = parseJSONText "CSEListSiteSearchFilter"--instance ToJSON CSEListSiteSearchFilter where- toJSON = toJSONText---- | Controls turning on or off the duplicate content filter.-data CSESiterestrictListFilter- = CSESLF0- -- ^ @0@- -- Turns off duplicate content filter.- | CSESLF1- -- ^ @1@- -- Turns on duplicate content filter.- deriving (Eq, Ord, Enum, Read, Show, Data, Typeable, Generic)--instance Hashable CSESiterestrictListFilter--instance FromHttpApiData CSESiterestrictListFilter where- parseQueryParam = \case- "0" -> Right CSESLF0- "1" -> Right CSESLF1- x -> Left ("Unable to parse CSESiterestrictListFilter from: " <> x)--instance ToHttpApiData CSESiterestrictListFilter where- toQueryParam = \case- CSESLF0 -> "0"- CSESLF1 -> "1"--instance FromJSON CSESiterestrictListFilter where- parseJSON = parseJSONText "CSESiterestrictListFilter"--instance ToJSON CSESiterestrictListFilter where- toJSON = toJSONText---- | Returns images of a type, which can be one of: clipart, face, lineart,--- news, and photo.-data CSESiterestrictListImgType- = CSESLITCliPart- -- ^ @clipart@- -- clipart- | CSESLITFace- -- ^ @face@- -- face- | CSESLITLineart- -- ^ @lineart@- -- lineart- | CSESLITNews- -- ^ @news@- -- news- | CSESLITPhoto- -- ^ @photo@- -- photo- deriving (Eq, Ord, Enum, Read, Show, Data, Typeable, Generic)--instance Hashable CSESiterestrictListImgType--instance FromHttpApiData CSESiterestrictListImgType where- parseQueryParam = \case- "clipart" -> Right CSESLITCliPart- "face" -> Right CSESLITFace- "lineart" -> Right CSESLITLineart- "news" -> Right CSESLITNews- "photo" -> Right CSESLITPhoto- x -> Left ("Unable to parse CSESiterestrictListImgType from: " <> x)--instance ToHttpApiData CSESiterestrictListImgType where- toQueryParam = \case- CSESLITCliPart -> "clipart"- CSESLITFace -> "face"- CSESLITLineart -> "lineart"- CSESLITNews -> "news"- CSESLITPhoto -> "photo"--instance FromJSON CSESiterestrictListImgType where- parseJSON = parseJSONText "CSESiterestrictListImgType"--instance ToJSON CSESiterestrictListImgType where- toJSON = toJSONText---- | Returns images of a specific dominant color: red, orange, yellow, green,--- teal, blue, purple, pink, white, gray, black and brown.-data CSEListImgDominantColor- = Black- -- ^ @black@- -- black- | Blue- -- ^ @blue@- -- blue- | Brown- -- ^ @brown@- -- brown- | Gray- -- ^ @gray@- -- gray- | Green- -- ^ @green@- -- green- | Orange- -- ^ @orange@- -- orange- | Pink- -- ^ @pink@- -- pink- | Purple- -- ^ @purple@- -- purple- | Red- -- ^ @red@- -- red- | Teal- -- ^ @teal@- -- teal- | White- -- ^ @white@- -- white- | Yellow- -- ^ @yellow@- -- yellow- deriving (Eq, Ord, Enum, Read, Show, Data, Typeable, Generic)--instance Hashable CSEListImgDominantColor--instance FromHttpApiData CSEListImgDominantColor where- parseQueryParam = \case- "black" -> Right Black- "blue" -> Right Blue- "brown" -> Right Brown- "gray" -> Right Gray- "green" -> Right Green- "orange" -> Right Orange- "pink" -> Right Pink- "purple" -> Right Purple- "red" -> Right Red- "teal" -> Right Teal- "white" -> Right White- "yellow" -> Right Yellow- x -> Left ("Unable to parse CSEListImgDominantColor from: " <> x)--instance ToHttpApiData CSEListImgDominantColor where- toQueryParam = \case- Black -> "black"- Blue -> "blue"- Brown -> "brown"- Gray -> "gray"- Green -> "green"- Orange -> "orange"- Pink -> "pink"- Purple -> "purple"- Red -> "red"- Teal -> "teal"- White -> "white"- Yellow -> "yellow"--instance FromJSON CSEListImgDominantColor where- parseJSON = parseJSONText "CSEListImgDominantColor"--instance ToJSON CSEListImgDominantColor where- toJSON = toJSONText---- | Search safety level-data CSEListSafe- = Active- -- ^ @active@- -- Enables safe search filtering.- | High- -- ^ @high@- -- (Deprecated) Same as active.- | Medium- -- ^ @medium@- -- (Deprecated) Same as active.- | Off- -- ^ @off@- -- Disables safe search filtering.- deriving (Eq, Ord, Enum, Read, Show, Data, Typeable, Generic)--instance Hashable CSEListSafe--instance FromHttpApiData CSEListSafe where- parseQueryParam = \case- "active" -> Right Active- "high" -> Right High- "medium" -> Right Medium- "off" -> Right Off- x -> Left ("Unable to parse CSEListSafe from: " <> x)--instance ToHttpApiData CSEListSafe where- toQueryParam = \case- Active -> "active"- High -> "high"- Medium -> "medium"- Off -> "off"--instance FromJSON CSEListSafe where- parseJSON = parseJSONText "CSEListSafe"--instance ToJSON CSEListSafe where- toJSON = toJSONText---- | Returns images of a specified size, where size can be one of: icon,--- small, medium, large, xlarge, xxlarge, and huge.-data CSESiterestrictListImgSize- = CSESLISHuge- -- ^ @huge@- -- huge- | CSESLISIcon- -- ^ @icon@- -- icon- | CSESLISLarge- -- ^ @large@- -- large- | CSESLISMedium- -- ^ @medium@- -- medium- | CSESLISSmall- -- ^ @small@- -- small- | CSESLISXlarge- -- ^ @xlarge@- -- xlarge- | CSESLISXxlarge- -- ^ @xxlarge@- -- xxlarge- deriving (Eq, Ord, Enum, Read, Show, Data, Typeable, Generic)--instance Hashable CSESiterestrictListImgSize--instance FromHttpApiData CSESiterestrictListImgSize where- parseQueryParam = \case- "huge" -> Right CSESLISHuge- "icon" -> Right CSESLISIcon- "large" -> Right CSESLISLarge- "medium" -> Right CSESLISMedium- "small" -> Right CSESLISSmall- "xlarge" -> Right CSESLISXlarge- "xxlarge" -> Right CSESLISXxlarge- x -> Left ("Unable to parse CSESiterestrictListImgSize from: " <> x)--instance ToHttpApiData CSESiterestrictListImgSize where- toQueryParam = \case- CSESLISHuge -> "huge"- CSESLISIcon -> "icon"- CSESLISLarge -> "large"- CSESLISMedium -> "medium"- CSESLISSmall -> "small"- CSESLISXlarge -> "xlarge"- CSESLISXxlarge -> "xxlarge"--instance FromJSON CSESiterestrictListImgSize where- parseJSON = parseJSONText "CSESiterestrictListImgSize"--instance ToJSON CSESiterestrictListImgSize where- toJSON = toJSONText---- | Returns black and white, grayscale, or color images: mono, gray, and--- color.-data CSESiterestrictListImgColorType- = CSESLICTColor- -- ^ @color@- -- color- | CSESLICTGray- -- ^ @gray@- -- gray- | CSESLICTMono- -- ^ @mono@- -- mono- deriving (Eq, Ord, Enum, Read, Show, Data, Typeable, Generic)--instance Hashable CSESiterestrictListImgColorType--instance FromHttpApiData CSESiterestrictListImgColorType where- parseQueryParam = \case- "color" -> Right CSESLICTColor- "gray" -> Right CSESLICTGray- "mono" -> Right CSESLICTMono- x -> Left ("Unable to parse CSESiterestrictListImgColorType from: " <> x)--instance ToHttpApiData CSESiterestrictListImgColorType where- toQueryParam = \case- CSESLICTColor -> "color"- CSESLICTGray -> "gray"- CSESLICTMono -> "mono"--instance FromJSON CSESiterestrictListImgColorType where- parseJSON = parseJSONText "CSESiterestrictListImgColorType"--instance ToJSON CSESiterestrictListImgColorType where- toJSON = toJSONText---- | Returns black and white, grayscale, or color images: mono, gray, and--- color.-data CSEListImgColorType- = CSELICTColor- -- ^ @color@- -- color- | CSELICTGray- -- ^ @gray@- -- gray- | CSELICTMono- -- ^ @mono@- -- mono- deriving (Eq, Ord, Enum, Read, Show, Data, Typeable, Generic)--instance Hashable CSEListImgColorType--instance FromHttpApiData CSEListImgColorType where- parseQueryParam = \case- "color" -> Right CSELICTColor- "gray" -> Right CSELICTGray- "mono" -> Right CSELICTMono- x -> Left ("Unable to parse CSEListImgColorType from: " <> x)--instance ToHttpApiData CSEListImgColorType where- toQueryParam = \case- CSELICTColor -> "color"- CSELICTGray -> "gray"- CSELICTMono -> "mono"--instance FromJSON CSEListImgColorType where- parseJSON = parseJSONText "CSEListImgColorType"--instance ToJSON CSEListImgColorType where- toJSON = toJSONText---- | Search safety level-data CSESiterestrictListSafe- = CSESLSHigh- -- ^ @high@- -- Enables highest level of safe search filtering.- | CSESLSMedium- -- ^ @medium@- -- Enables moderate safe search filtering.- | CSESLSOff- -- ^ @off@- -- Disables safe search filtering.- deriving (Eq, Ord, Enum, Read, Show, Data, Typeable, Generic)--instance Hashable CSESiterestrictListSafe--instance FromHttpApiData CSESiterestrictListSafe where- parseQueryParam = \case- "high" -> Right CSESLSHigh- "medium" -> Right CSESLSMedium- "off" -> Right CSESLSOff- x -> Left ("Unable to parse CSESiterestrictListSafe from: " <> x)--instance ToHttpApiData CSESiterestrictListSafe where- toQueryParam = \case- CSESLSHigh -> "high"- CSESLSMedium -> "medium"- CSESLSOff -> "off"--instance FromJSON CSESiterestrictListSafe where- parseJSON = parseJSONText "CSESiterestrictListSafe"--instance ToJSON CSESiterestrictListSafe where- toJSON = toJSONText---- | Returns images of a specific dominant color: red, orange, yellow, green,--- teal, blue, purple, pink, white, gray, black and brown.-data CSESiterestrictListImgDominantColor- = CSESLIDCBlack- -- ^ @black@- -- black- | CSESLIDCBlue- -- ^ @blue@- -- blue- | CSESLIDCBrown- -- ^ @brown@- -- brown- | CSESLIDCGray- -- ^ @gray@- -- gray- | CSESLIDCGreen- -- ^ @green@- -- green- | CSESLIDCOrange- -- ^ @orange@- -- orange- | CSESLIDCPink- -- ^ @pink@- -- pink- | CSESLIDCPurple- -- ^ @purple@- -- purple- | CSESLIDCRed- -- ^ @red@- -- red- | CSESLIDCTeal- -- ^ @teal@- -- teal- | CSESLIDCWhite- -- ^ @white@- -- white- | CSESLIDCYellow- -- ^ @yellow@- -- yellow- deriving (Eq, Ord, Enum, Read, Show, Data, Typeable, Generic)--instance Hashable CSESiterestrictListImgDominantColor--instance FromHttpApiData CSESiterestrictListImgDominantColor where- parseQueryParam = \case- "black" -> Right CSESLIDCBlack- "blue" -> Right CSESLIDCBlue- "brown" -> Right CSESLIDCBrown- "gray" -> Right CSESLIDCGray- "green" -> Right CSESLIDCGreen- "orange" -> Right CSESLIDCOrange- "pink" -> Right CSESLIDCPink- "purple" -> Right CSESLIDCPurple- "red" -> Right CSESLIDCRed- "teal" -> Right CSESLIDCTeal- "white" -> Right CSESLIDCWhite- "yellow" -> Right CSESLIDCYellow- x -> Left ("Unable to parse CSESiterestrictListImgDominantColor from: " <> x)--instance ToHttpApiData CSESiterestrictListImgDominantColor where- toQueryParam = \case- CSESLIDCBlack -> "black"- CSESLIDCBlue -> "blue"- CSESLIDCBrown -> "brown"- CSESLIDCGray -> "gray"- CSESLIDCGreen -> "green"- CSESLIDCOrange -> "orange"- CSESLIDCPink -> "pink"- CSESLIDCPurple -> "purple"- CSESLIDCRed -> "red"- CSESLIDCTeal -> "teal"- CSESLIDCWhite -> "white"- CSESLIDCYellow -> "yellow"--instance FromJSON CSESiterestrictListImgDominantColor where- parseJSON = parseJSONText "CSESiterestrictListImgDominantColor"--instance ToJSON CSESiterestrictListImgDominantColor where- toJSON = toJSONText---- | Controls turning on or off the duplicate content filter.-data CSEListFilter- = CSELF0- -- ^ @0@- -- Turns off duplicate content filter.- | CSELF1- -- ^ @1@- -- Turns on duplicate content filter.- deriving (Eq, Ord, Enum, Read, Show, Data, Typeable, Generic)--instance Hashable CSEListFilter--instance FromHttpApiData CSEListFilter where- parseQueryParam = \case- "0" -> Right CSELF0- "1" -> Right CSELF1- x -> Left ("Unable to parse CSEListFilter from: " <> x)--instance ToHttpApiData CSEListFilter where- toQueryParam = \case- CSELF0 -> "0"- CSELF1 -> "1"--instance FromJSON CSEListFilter where- parseJSON = parseJSONText "CSEListFilter"--instance ToJSON CSEListFilter where- toJSON = toJSONText---- | Controls whether to include or exclude results from the site named in--- the as_sitesearch parameter-data CSESiterestrictListSiteSearchFilter- = CSESLSSFE- -- ^ @e@- -- exclude- | CSESLSSFI- -- ^ @i@- -- include- deriving (Eq, Ord, Enum, Read, Show, Data, Typeable, Generic)--instance Hashable CSESiterestrictListSiteSearchFilter--instance FromHttpApiData CSESiterestrictListSiteSearchFilter where- parseQueryParam = \case- "e" -> Right CSESLSSFE- "i" -> Right CSESLSSFI- x -> Left ("Unable to parse CSESiterestrictListSiteSearchFilter from: " <> x)--instance ToHttpApiData CSESiterestrictListSiteSearchFilter where- toQueryParam = \case- CSESLSSFE -> "e"- CSESLSSFI -> "i"--instance FromJSON CSESiterestrictListSiteSearchFilter where- parseJSON = parseJSONText "CSESiterestrictListSiteSearchFilter"--instance ToJSON CSESiterestrictListSiteSearchFilter where- toJSON = toJSONText---- | The language restriction for the search results-data CSESiterestrictListLr- = LangAr- -- ^ @lang_ar@- -- Arabic- | LangBg- -- ^ @lang_bg@- -- Bulgarian- | LangCa- -- ^ @lang_ca@- -- Catalan- | LangCs- -- ^ @lang_cs@- -- Czech- | LangDa- -- ^ @lang_da@- -- Danish- | LangDe- -- ^ @lang_de@- -- German- | LangEl- -- ^ @lang_el@- -- Greek- | LangEn- -- ^ @lang_en@- -- English- | LangEs- -- ^ @lang_es@- -- Spanish- | LangEt- -- ^ @lang_et@- -- Estonian- | LangFi- -- ^ @lang_fi@- -- Finnish- | LangFr- -- ^ @lang_fr@- -- French- | LangHr- -- ^ @lang_hr@- -- Croatian- | LangHu- -- ^ @lang_hu@- -- Hungarian- | LangId- -- ^ @lang_id@- -- Indonesian- | LangIs- -- ^ @lang_is@- -- Icelandic- | LangIt- -- ^ @lang_it@- -- Italian- | LangIw- -- ^ @lang_iw@- -- Hebrew- | LangJa- -- ^ @lang_ja@- -- Japanese- | LangKo- -- ^ @lang_ko@- -- Korean- | LangLT- -- ^ @lang_lt@- -- Lithuanian- | LangLv- -- ^ @lang_lv@- -- Latvian- | LangNl- -- ^ @lang_nl@- -- Dutch- | LangNo- -- ^ @lang_no@- -- Norwegian- | LangPl- -- ^ @lang_pl@- -- Polish- | LangPt- -- ^ @lang_pt@- -- Portuguese- | LangRo- -- ^ @lang_ro@- -- Romanian- | LangRu- -- ^ @lang_ru@- -- Russian- | LangSk- -- ^ @lang_sk@- -- Slovak- | LangSl- -- ^ @lang_sl@- -- Slovenian- | LangSr- -- ^ @lang_sr@- -- Serbian- | LangSv- -- ^ @lang_sv@- -- Swedish- | LangTr- -- ^ @lang_tr@- -- Turkish- | LangZhCn- -- ^ @lang_zh-CN@- -- Chinese (Simplified)- | LangZhTw- -- ^ @lang_zh-TW@- -- Chinese (Traditional)- deriving (Eq, Ord, Enum, Read, Show, Data, Typeable, Generic)--instance Hashable CSESiterestrictListLr--instance FromHttpApiData CSESiterestrictListLr where- parseQueryParam = \case- "lang_ar" -> Right LangAr- "lang_bg" -> Right LangBg- "lang_ca" -> Right LangCa- "lang_cs" -> Right LangCs- "lang_da" -> Right LangDa- "lang_de" -> Right LangDe- "lang_el" -> Right LangEl- "lang_en" -> Right LangEn- "lang_es" -> Right LangEs- "lang_et" -> Right LangEt- "lang_fi" -> Right LangFi- "lang_fr" -> Right LangFr- "lang_hr" -> Right LangHr- "lang_hu" -> Right LangHu- "lang_id" -> Right LangId- "lang_is" -> Right LangIs- "lang_it" -> Right LangIt- "lang_iw" -> Right LangIw- "lang_ja" -> Right LangJa- "lang_ko" -> Right LangKo- "lang_lt" -> Right LangLT- "lang_lv" -> Right LangLv- "lang_nl" -> Right LangNl- "lang_no" -> Right LangNo- "lang_pl" -> Right LangPl- "lang_pt" -> Right LangPt- "lang_ro" -> Right LangRo- "lang_ru" -> Right LangRu- "lang_sk" -> Right LangSk- "lang_sl" -> Right LangSl- "lang_sr" -> Right LangSr- "lang_sv" -> Right LangSv- "lang_tr" -> Right LangTr- "lang_zh-CN" -> Right LangZhCn- "lang_zh-TW" -> Right LangZhTw- x -> Left ("Unable to parse CSESiterestrictListLr from: " <> x)--instance ToHttpApiData CSESiterestrictListLr where- toQueryParam = \case- LangAr -> "lang_ar"- LangBg -> "lang_bg"- LangCa -> "lang_ca"- LangCs -> "lang_cs"- LangDa -> "lang_da"- LangDe -> "lang_de"- LangEl -> "lang_el"- LangEn -> "lang_en"- LangEs -> "lang_es"- LangEt -> "lang_et"- LangFi -> "lang_fi"- LangFr -> "lang_fr"- LangHr -> "lang_hr"- LangHu -> "lang_hu"- LangId -> "lang_id"- LangIs -> "lang_is"- LangIt -> "lang_it"- LangIw -> "lang_iw"- LangJa -> "lang_ja"- LangKo -> "lang_ko"- LangLT -> "lang_lt"- LangLv -> "lang_lv"- LangNl -> "lang_nl"- LangNo -> "lang_no"- LangPl -> "lang_pl"- LangPt -> "lang_pt"- LangRo -> "lang_ro"- LangRu -> "lang_ru"- LangSk -> "lang_sk"- LangSl -> "lang_sl"- LangSr -> "lang_sr"- LangSv -> "lang_sv"- LangTr -> "lang_tr"- LangZhCn -> "lang_zh-CN"- LangZhTw -> "lang_zh-TW"--instance FromJSON CSESiterestrictListLr where- parseJSON = parseJSONText "CSESiterestrictListLr"--instance ToJSON CSESiterestrictListLr where- toJSON = toJSONText---- | Specifies the search type: image.-data CSESiterestrictListSearchType- = Image- -- ^ @image@- -- custom image search- deriving (Eq, Ord, Enum, Read, Show, Data, Typeable, Generic)--instance Hashable CSESiterestrictListSearchType--instance FromHttpApiData CSESiterestrictListSearchType where- parseQueryParam = \case- "image" -> Right Image- x -> Left ("Unable to parse CSESiterestrictListSearchType from: " <> x)--instance ToHttpApiData CSESiterestrictListSearchType where- toQueryParam = \case- Image -> "image"--instance FromJSON CSESiterestrictListSearchType where- parseJSON = parseJSONText "CSESiterestrictListSearchType"--instance ToJSON CSESiterestrictListSearchType where- toJSON = toJSONText---- | The language restriction for the search results-data CSEListLr- = CSELLLangAr- -- ^ @lang_ar@- -- Arabic- | CSELLLangBg- -- ^ @lang_bg@- -- Bulgarian- | CSELLLangCa- -- ^ @lang_ca@- -- Catalan- | CSELLLangCs- -- ^ @lang_cs@- -- Czech- | CSELLLangDa- -- ^ @lang_da@- -- Danish- | CSELLLangDe- -- ^ @lang_de@- -- German- | CSELLLangEl- -- ^ @lang_el@- -- Greek- | CSELLLangEn- -- ^ @lang_en@- -- English- | CSELLLangEs- -- ^ @lang_es@- -- Spanish- | CSELLLangEt- -- ^ @lang_et@- -- Estonian- | CSELLLangFi- -- ^ @lang_fi@- -- Finnish- | CSELLLangFr- -- ^ @lang_fr@- -- French- | CSELLLangHr- -- ^ @lang_hr@- -- Croatian- | CSELLLangHu- -- ^ @lang_hu@- -- Hungarian- | CSELLLangId- -- ^ @lang_id@- -- Indonesian- | CSELLLangIs- -- ^ @lang_is@- -- Icelandic- | CSELLLangIt- -- ^ @lang_it@- -- Italian- | CSELLLangIw- -- ^ @lang_iw@- -- Hebrew- | CSELLLangJa- -- ^ @lang_ja@- -- Japanese- | CSELLLangKo- -- ^ @lang_ko@- -- Korean- | CSELLLangLT- -- ^ @lang_lt@- -- Lithuanian- | CSELLLangLv- -- ^ @lang_lv@- -- Latvian- | CSELLLangNl- -- ^ @lang_nl@- -- Dutch- | CSELLLangNo- -- ^ @lang_no@- -- Norwegian- | CSELLLangPl- -- ^ @lang_pl@- -- Polish- | CSELLLangPt- -- ^ @lang_pt@- -- Portuguese- | CSELLLangRo- -- ^ @lang_ro@- -- Romanian- | CSELLLangRu- -- ^ @lang_ru@- -- Russian- | CSELLLangSk- -- ^ @lang_sk@- -- Slovak- | CSELLLangSl- -- ^ @lang_sl@- -- Slovenian- | CSELLLangSr- -- ^ @lang_sr@- -- Serbian- | CSELLLangSv- -- ^ @lang_sv@- -- Swedish- | CSELLLangTr- -- ^ @lang_tr@- -- Turkish- | CSELLLangZhCn- -- ^ @lang_zh-CN@- -- Chinese (Simplified)- | CSELLLangZhTw- -- ^ @lang_zh-TW@- -- Chinese (Traditional)- deriving (Eq, Ord, Enum, Read, Show, Data, Typeable, Generic)--instance Hashable CSEListLr--instance FromHttpApiData CSEListLr where- parseQueryParam = \case- "lang_ar" -> Right CSELLLangAr- "lang_bg" -> Right CSELLLangBg- "lang_ca" -> Right CSELLLangCa- "lang_cs" -> Right CSELLLangCs- "lang_da" -> Right CSELLLangDa- "lang_de" -> Right CSELLLangDe- "lang_el" -> Right CSELLLangEl- "lang_en" -> Right CSELLLangEn- "lang_es" -> Right CSELLLangEs- "lang_et" -> Right CSELLLangEt- "lang_fi" -> Right CSELLLangFi- "lang_fr" -> Right CSELLLangFr- "lang_hr" -> Right CSELLLangHr- "lang_hu" -> Right CSELLLangHu- "lang_id" -> Right CSELLLangId- "lang_is" -> Right CSELLLangIs- "lang_it" -> Right CSELLLangIt- "lang_iw" -> Right CSELLLangIw- "lang_ja" -> Right CSELLLangJa- "lang_ko" -> Right CSELLLangKo- "lang_lt" -> Right CSELLLangLT- "lang_lv" -> Right CSELLLangLv- "lang_nl" -> Right CSELLLangNl- "lang_no" -> Right CSELLLangNo- "lang_pl" -> Right CSELLLangPl- "lang_pt" -> Right CSELLLangPt- "lang_ro" -> Right CSELLLangRo- "lang_ru" -> Right CSELLLangRu- "lang_sk" -> Right CSELLLangSk- "lang_sl" -> Right CSELLLangSl- "lang_sr" -> Right CSELLLangSr- "lang_sv" -> Right CSELLLangSv- "lang_tr" -> Right CSELLLangTr- "lang_zh-CN" -> Right CSELLLangZhCn- "lang_zh-TW" -> Right CSELLLangZhTw- x -> Left ("Unable to parse CSEListLr from: " <> x)--instance ToHttpApiData CSEListLr where- toQueryParam = \case- CSELLLangAr -> "lang_ar"- CSELLLangBg -> "lang_bg"- CSELLLangCa -> "lang_ca"- CSELLLangCs -> "lang_cs"- CSELLLangDa -> "lang_da"- CSELLLangDe -> "lang_de"- CSELLLangEl -> "lang_el"- CSELLLangEn -> "lang_en"- CSELLLangEs -> "lang_es"- CSELLLangEt -> "lang_et"- CSELLLangFi -> "lang_fi"- CSELLLangFr -> "lang_fr"- CSELLLangHr -> "lang_hr"- CSELLLangHu -> "lang_hu"- CSELLLangId -> "lang_id"- CSELLLangIs -> "lang_is"- CSELLLangIt -> "lang_it"- CSELLLangIw -> "lang_iw"- CSELLLangJa -> "lang_ja"- CSELLLangKo -> "lang_ko"- CSELLLangLT -> "lang_lt"- CSELLLangLv -> "lang_lv"- CSELLLangNl -> "lang_nl"- CSELLLangNo -> "lang_no"- CSELLLangPl -> "lang_pl"- CSELLLangPt -> "lang_pt"- CSELLLangRo -> "lang_ro"- CSELLLangRu -> "lang_ru"- CSELLLangSk -> "lang_sk"- CSELLLangSl -> "lang_sl"- CSELLLangSr -> "lang_sr"- CSELLLangSv -> "lang_sv"- CSELLLangTr -> "lang_tr"- CSELLLangZhCn -> "lang_zh-CN"- CSELLLangZhTw -> "lang_zh-TW"--instance FromJSON CSEListLr where- parseJSON = parseJSONText "CSEListLr"--instance ToJSON CSEListLr where- toJSON = toJSONText---- | Specifies the search type: image.-data CSEListSearchType- = CSELSTImage- -- ^ @image@- -- custom image search- deriving (Eq, Ord, Enum, Read, Show, Data, Typeable, Generic)--instance Hashable CSEListSearchType--instance FromHttpApiData CSEListSearchType where- parseQueryParam = \case- "image" -> Right CSELSTImage- x -> Left ("Unable to parse CSEListSearchType from: " <> x)--instance ToHttpApiData CSEListSearchType where- toQueryParam = \case- CSELSTImage -> "image"--instance FromJSON CSEListSearchType where- parseJSON = parseJSONText "CSEListSearchType"--instance ToJSON CSEListSearchType where- toJSON = toJSONText---- | Returns images of a specified size, where size can be one of: icon,--- small, medium, large, xlarge, xxlarge, and huge.-data CSEListImgSize- = CSELISHuge- -- ^ @huge@- -- huge- | CSELISIcon- -- ^ @icon@- -- icon- | CSELISLarge- -- ^ @large@- -- large- | CSELISMedium- -- ^ @medium@- -- medium- | CSELISSmall- -- ^ @small@- -- small- | CSELISXlarge- -- ^ @xlarge@- -- xlarge- | CSELISXxlarge- -- ^ @xxlarge@- -- xxlarge- deriving (Eq, Ord, Enum, Read, Show, Data, Typeable, Generic)--instance Hashable CSEListImgSize--instance FromHttpApiData CSEListImgSize where- parseQueryParam = \case- "huge" -> Right CSELISHuge- "icon" -> Right CSELISIcon- "large" -> Right CSELISLarge- "medium" -> Right CSELISMedium- "small" -> Right CSELISSmall- "xlarge" -> Right CSELISXlarge- "xxlarge" -> Right CSELISXxlarge- x -> Left ("Unable to parse CSEListImgSize from: " <> x)--instance ToHttpApiData CSEListImgSize where- toQueryParam = \case- CSELISHuge -> "huge"- CSELISIcon -> "icon"- CSELISLarge -> "large"- CSELISMedium -> "medium"- CSELISSmall -> "small"- CSELISXlarge -> "xlarge"- CSELISXxlarge -> "xxlarge"--instance FromJSON CSEListImgSize where- parseJSON = parseJSONText "CSEListImgSize"--instance ToJSON CSEListImgSize where- toJSON = toJSONText
− gen/Network/Google/Resource/Search/CSE/List.hs
@@ -1,496 +0,0 @@-{-# 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.Search.CSE.List--- Copyright : (c) 2015-2016 Brendan Hay--- License : Mozilla Public License, v. 2.0.--- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>--- Stability : auto-generated--- Portability : non-portable (GHC extensions)------ Returns metadata about the search performed, metadata about the custom--- search engine used for the search, and the search results.------ /See:/ <https://developers.google.com/custom-search/v1/using_rest CustomSearch API Reference> for @search.cse.list@.-module Network.Google.Resource.Search.CSE.List- (- -- * REST Resource- CSEListResource-- -- * Creating a Request- , cSEList- , CSEList-- -- * Request Lenses- , cselImgDominantColor- , cselSiteSearchFilter- , cselC2coff- , cselOrTerms- , cselStart- , cselRights- , cselExcludeTerms- , cselNum- , cselFileType- , cselSearchType- , cselLr- , cselQ- , cselGooglehost- , cselRelatedSite- , cselHl- , cselSort- , cselSiteSearch- , cselFilter- , cselDateRestrict- , cselLinkSite- , cselLowRange- , cselImgType- , cselGl- , cselCx- , cselImgColorType- , cselImgSize- , cselExactTerms- , cselCr- , cselSafe- , cselHq- , cselHighRange- ) where--import Network.Google.CustomSearch.Types-import Network.Google.Prelude---- | A resource alias for @search.cse.list@ method which the--- 'CSEList' request conforms to.-type CSEListResource =- "customsearch" :>- "v1" :>- QueryParam "q" Text :>- QueryParam "imgDominantColor" CSEListImgDominantColor- :>- QueryParam "siteSearchFilter" CSEListSiteSearchFilter- :>- QueryParam "c2coff" Text :>- QueryParam "orTerms" Text :>- QueryParam "start" (Textual Word32) :>- QueryParam "rights" Text :>- QueryParam "excludeTerms" Text :>- QueryParam "num" (Textual Word32) :>- QueryParam "fileType" Text :>- QueryParam "searchType" CSEListSearchType :>- QueryParam "lr" CSEListLr :>- QueryParam "googlehost" Text :>- QueryParam "relatedSite" Text :>- QueryParam "hl" Text :>- QueryParam "sort" Text :>- QueryParam "siteSearch" Text :>- QueryParam "filter" CSEListFilter :>- QueryParam "dateRestrict" Text :>- QueryParam "linkSite" Text :>- QueryParam "lowRange" Text :>- QueryParam "imgType"- CSEListImgType- :>- QueryParam "gl" Text :>- QueryParam "cx" Text :>- QueryParam- "imgColorType"- CSEListImgColorType- :>- QueryParam "imgSize"- CSEListImgSize- :>- QueryParam- "exactTerms"- Text- :>- QueryParam "cr"- Text- :>- QueryParam- "safe"- CSEListSafe- :>- QueryParam- "hq"- Text- :>- QueryParam- "highRange"- Text- :>- QueryParam- "alt"- AltJSON- :>- Get- '[JSON]- Search---- | Returns metadata about the search performed, metadata about the custom--- search engine used for the search, and the search results.------ /See:/ 'cSEList' smart constructor.-data CSEList =- CSEList'- { _cselImgDominantColor :: !(Maybe CSEListImgDominantColor)- , _cselSiteSearchFilter :: !(Maybe CSEListSiteSearchFilter)- , _cselC2coff :: !(Maybe Text)- , _cselOrTerms :: !(Maybe Text)- , _cselStart :: !(Maybe (Textual Word32))- , _cselRights :: !(Maybe Text)- , _cselExcludeTerms :: !(Maybe Text)- , _cselNum :: !(Textual Word32)- , _cselFileType :: !(Maybe Text)- , _cselSearchType :: !(Maybe CSEListSearchType)- , _cselLr :: !(Maybe CSEListLr)- , _cselQ :: !Text- , _cselGooglehost :: !(Maybe Text)- , _cselRelatedSite :: !(Maybe Text)- , _cselHl :: !(Maybe Text)- , _cselSort :: !(Maybe Text)- , _cselSiteSearch :: !(Maybe Text)- , _cselFilter :: !(Maybe CSEListFilter)- , _cselDateRestrict :: !(Maybe Text)- , _cselLinkSite :: !(Maybe Text)- , _cselLowRange :: !(Maybe Text)- , _cselImgType :: !(Maybe CSEListImgType)- , _cselGl :: !(Maybe Text)- , _cselCx :: !(Maybe Text)- , _cselImgColorType :: !(Maybe CSEListImgColorType)- , _cselImgSize :: !(Maybe CSEListImgSize)- , _cselExactTerms :: !(Maybe Text)- , _cselCr :: !(Maybe Text)- , _cselSafe :: !CSEListSafe- , _cselHq :: !(Maybe Text)- , _cselHighRange :: !(Maybe Text)- }- deriving (Eq, Show, Data, Typeable, Generic)----- | Creates a value of 'CSEList' with the minimum fields required to make a request.------ Use one of the following lenses to modify other fields as desired:------ * 'cselImgDominantColor'------ * 'cselSiteSearchFilter'------ * 'cselC2coff'------ * 'cselOrTerms'------ * 'cselStart'------ * 'cselRights'------ * 'cselExcludeTerms'------ * 'cselNum'------ * 'cselFileType'------ * 'cselSearchType'------ * 'cselLr'------ * 'cselQ'------ * 'cselGooglehost'------ * 'cselRelatedSite'------ * 'cselHl'------ * 'cselSort'------ * 'cselSiteSearch'------ * 'cselFilter'------ * 'cselDateRestrict'------ * 'cselLinkSite'------ * 'cselLowRange'------ * 'cselImgType'------ * 'cselGl'------ * 'cselCx'------ * 'cselImgColorType'------ * 'cselImgSize'------ * 'cselExactTerms'------ * 'cselCr'------ * 'cselSafe'------ * 'cselHq'------ * 'cselHighRange'-cSEList- :: Text -- ^ 'cselQ'- -> CSEList-cSEList pCselQ_ =- CSEList'- { _cselImgDominantColor = Nothing- , _cselSiteSearchFilter = Nothing- , _cselC2coff = Nothing- , _cselOrTerms = Nothing- , _cselStart = Nothing- , _cselRights = Nothing- , _cselExcludeTerms = Nothing- , _cselNum = 10- , _cselFileType = Nothing- , _cselSearchType = Nothing- , _cselLr = Nothing- , _cselQ = pCselQ_- , _cselGooglehost = Nothing- , _cselRelatedSite = Nothing- , _cselHl = Nothing- , _cselSort = Nothing- , _cselSiteSearch = Nothing- , _cselFilter = Nothing- , _cselDateRestrict = Nothing- , _cselLinkSite = Nothing- , _cselLowRange = Nothing- , _cselImgType = Nothing- , _cselGl = Nothing- , _cselCx = Nothing- , _cselImgColorType = Nothing- , _cselImgSize = Nothing- , _cselExactTerms = Nothing- , _cselCr = Nothing- , _cselSafe = Off- , _cselHq = Nothing- , _cselHighRange = Nothing- }----- | Returns images of a specific dominant color: red, orange, yellow, green,--- teal, blue, purple, pink, white, gray, black and brown.-cselImgDominantColor :: Lens' CSEList (Maybe CSEListImgDominantColor)-cselImgDominantColor- = lens _cselImgDominantColor- (\ s a -> s{_cselImgDominantColor = a})---- | Controls whether to include or exclude results from the site named in--- the as_sitesearch parameter-cselSiteSearchFilter :: Lens' CSEList (Maybe CSEListSiteSearchFilter)-cselSiteSearchFilter- = lens _cselSiteSearchFilter- (\ s a -> s{_cselSiteSearchFilter = a})---- | Turns off the translation between zh-CN and zh-TW.-cselC2coff :: Lens' CSEList (Maybe Text)-cselC2coff- = lens _cselC2coff (\ s a -> s{_cselC2coff = a})---- | Provides additional search terms to check for in a document, where each--- document in the search results must contain at least one of the--- additional search terms-cselOrTerms :: Lens' CSEList (Maybe Text)-cselOrTerms- = lens _cselOrTerms (\ s a -> s{_cselOrTerms = a})---- | The index of the first result to return-cselStart :: Lens' CSEList (Maybe Word32)-cselStart- = lens _cselStart (\ s a -> s{_cselStart = a}) .- mapping _Coerce---- | Filters based on licensing. Supported values include: cc_publicdomain,--- cc_attribute, cc_sharealike, cc_noncommercial, cc_nonderived and--- combinations of these.-cselRights :: Lens' CSEList (Maybe Text)-cselRights- = lens _cselRights (\ s a -> s{_cselRights = a})---- | Identifies a word or phrase that should not appear in any documents in--- the search results-cselExcludeTerms :: Lens' CSEList (Maybe Text)-cselExcludeTerms- = lens _cselExcludeTerms- (\ s a -> s{_cselExcludeTerms = a})---- | Number of search results to return-cselNum :: Lens' CSEList Word32-cselNum- = lens _cselNum (\ s a -> s{_cselNum = a}) . _Coerce---- | Returns images of a specified type. Some of the allowed values are: bmp,--- gif, png, jpg, svg, pdf, ...-cselFileType :: Lens' CSEList (Maybe Text)-cselFileType- = lens _cselFileType (\ s a -> s{_cselFileType = a})---- | Specifies the search type: image.-cselSearchType :: Lens' CSEList (Maybe CSEListSearchType)-cselSearchType- = lens _cselSearchType- (\ s a -> s{_cselSearchType = a})---- | The language restriction for the search results-cselLr :: Lens' CSEList (Maybe CSEListLr)-cselLr = lens _cselLr (\ s a -> s{_cselLr = a})---- | Query-cselQ :: Lens' CSEList Text-cselQ = lens _cselQ (\ s a -> s{_cselQ = a})---- | The local Google domain to use to perform the search.-cselGooglehost :: Lens' CSEList (Maybe Text)-cselGooglehost- = lens _cselGooglehost- (\ s a -> s{_cselGooglehost = a})---- | Specifies that all search results should be pages that are related to--- the specified URL-cselRelatedSite :: Lens' CSEList (Maybe Text)-cselRelatedSite- = lens _cselRelatedSite- (\ s a -> s{_cselRelatedSite = a})---- | Sets the user interface language.-cselHl :: Lens' CSEList (Maybe Text)-cselHl = lens _cselHl (\ s a -> s{_cselHl = a})---- | The sort expression to apply to the results-cselSort :: Lens' CSEList (Maybe Text)-cselSort = lens _cselSort (\ s a -> s{_cselSort = a})---- | Specifies all search results should be pages from a given site-cselSiteSearch :: Lens' CSEList (Maybe Text)-cselSiteSearch- = lens _cselSiteSearch- (\ s a -> s{_cselSiteSearch = a})---- | Controls turning on or off the duplicate content filter.-cselFilter :: Lens' CSEList (Maybe CSEListFilter)-cselFilter- = lens _cselFilter (\ s a -> s{_cselFilter = a})---- | Specifies all search results are from a time period-cselDateRestrict :: Lens' CSEList (Maybe Text)-cselDateRestrict- = lens _cselDateRestrict- (\ s a -> s{_cselDateRestrict = a})---- | Specifies that all search results should contain a link to a particular--- URL-cselLinkSite :: Lens' CSEList (Maybe Text)-cselLinkSite- = lens _cselLinkSite (\ s a -> s{_cselLinkSite = a})---- | Creates a range in form as_nlo value..as_nhi value and attempts to--- append it to query-cselLowRange :: Lens' CSEList (Maybe Text)-cselLowRange- = lens _cselLowRange (\ s a -> s{_cselLowRange = a})---- | Returns images of a type, which can be one of: clipart, face, lineart,--- news, and photo.-cselImgType :: Lens' CSEList (Maybe CSEListImgType)-cselImgType- = lens _cselImgType (\ s a -> s{_cselImgType = a})---- | Geolocation of end user.-cselGl :: Lens' CSEList (Maybe Text)-cselGl = lens _cselGl (\ s a -> s{_cselGl = a})---- | The custom search engine ID to scope this search query-cselCx :: Lens' CSEList (Maybe Text)-cselCx = lens _cselCx (\ s a -> s{_cselCx = a})---- | Returns black and white, grayscale, or color images: mono, gray, and--- color.-cselImgColorType :: Lens' CSEList (Maybe CSEListImgColorType)-cselImgColorType- = lens _cselImgColorType- (\ s a -> s{_cselImgColorType = a})---- | Returns images of a specified size, where size can be one of: icon,--- small, medium, large, xlarge, xxlarge, and huge.-cselImgSize :: Lens' CSEList (Maybe CSEListImgSize)-cselImgSize- = lens _cselImgSize (\ s a -> s{_cselImgSize = a})---- | Identifies a phrase that all documents in the search results must--- contain-cselExactTerms :: Lens' CSEList (Maybe Text)-cselExactTerms- = lens _cselExactTerms- (\ s a -> s{_cselExactTerms = a})---- | Country restrict(s).-cselCr :: Lens' CSEList (Maybe Text)-cselCr = lens _cselCr (\ s a -> s{_cselCr = a})---- | Search safety level-cselSafe :: Lens' CSEList CSEListSafe-cselSafe = lens _cselSafe (\ s a -> s{_cselSafe = a})---- | Appends the extra query terms to the query.-cselHq :: Lens' CSEList (Maybe Text)-cselHq = lens _cselHq (\ s a -> s{_cselHq = a})---- | Creates a range in form as_nlo value..as_nhi value and attempts to--- append it to query-cselHighRange :: Lens' CSEList (Maybe Text)-cselHighRange- = lens _cselHighRange- (\ s a -> s{_cselHighRange = a})--instance GoogleRequest CSEList where- type Rs CSEList = Search- type Scopes CSEList = '[]- requestClient CSEList'{..}- = go (Just _cselQ) _cselImgDominantColor- _cselSiteSearchFilter- _cselC2coff- _cselOrTerms- _cselStart- _cselRights- _cselExcludeTerms- (Just _cselNum)- _cselFileType- _cselSearchType- _cselLr- _cselGooglehost- _cselRelatedSite- _cselHl- _cselSort- _cselSiteSearch- _cselFilter- _cselDateRestrict- _cselLinkSite- _cselLowRange- _cselImgType- _cselGl- _cselCx- _cselImgColorType- _cselImgSize- _cselExactTerms- _cselCr- (Just _cselSafe)- _cselHq- _cselHighRange- (Just AltJSON)- customSearchService- where go- = buildClient (Proxy :: Proxy CSEListResource) mempty
− gen/Network/Google/Resource/Search/CSE/Siterestrict/List.hs
@@ -1,514 +0,0 @@-{-# 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.Search.CSE.Siterestrict.List--- Copyright : (c) 2015-2016 Brendan Hay--- License : Mozilla Public License, v. 2.0.--- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>--- Stability : auto-generated--- Portability : non-portable (GHC extensions)------ Returns metadata about the search performed, metadata about the custom--- search engine used for the search, and the search results. Uses a small--- set of url patterns.------ /See:/ <https://developers.google.com/custom-search/v1/using_rest CustomSearch API Reference> for @search.cse.siterestrict.list@.-module Network.Google.Resource.Search.CSE.Siterestrict.List- (- -- * REST Resource- CSESiterestrictListResource-- -- * Creating a Request- , cSESiterestrictList- , CSESiterestrictList-- -- * Request Lenses- , cseslImgDominantColor- , cseslSiteSearchFilter- , cseslC2coff- , cseslOrTerms- , cseslStart- , cseslRights- , cseslExcludeTerms- , cseslNum- , cseslFileType- , cseslSearchType- , cseslLr- , cseslQ- , cseslGooglehost- , cseslRelatedSite- , cseslHl- , cseslSort- , cseslSiteSearch- , cseslFilter- , cseslDateRestrict- , cseslLinkSite- , cseslLowRange- , cseslImgType- , cseslGl- , cseslCx- , cseslImgColorType- , cseslImgSize- , cseslExactTerms- , cseslCr- , cseslSafe- , cseslHq- , cseslHighRange- ) where--import Network.Google.CustomSearch.Types-import Network.Google.Prelude---- | A resource alias for @search.cse.siterestrict.list@ method which the--- 'CSESiterestrictList' request conforms to.-type CSESiterestrictListResource =- "customsearch" :>- "v1" :>- "siterestrict" :>- QueryParam "q" Text :>- QueryParam "imgDominantColor"- CSESiterestrictListImgDominantColor- :>- QueryParam "siteSearchFilter"- CSESiterestrictListSiteSearchFilter- :>- QueryParam "c2coff" Text :>- QueryParam "orTerms" Text :>- QueryParam "start" (Textual Word32) :>- QueryParam "rights" Text :>- QueryParam "excludeTerms" Text :>- QueryParam "num" (Textual Word32) :>- QueryParam "fileType" Text :>- QueryParam "searchType"- CSESiterestrictListSearchType- :>- QueryParam "lr" CSESiterestrictListLr :>- QueryParam "googlehost" Text :>- QueryParam "relatedSite" Text :>- QueryParam "hl" Text :>- QueryParam "sort" Text :>- QueryParam "siteSearch" Text :>- QueryParam "filter"- CSESiterestrictListFilter- :>- QueryParam "dateRestrict" Text :>- QueryParam "linkSite" Text :>- QueryParam "lowRange" Text :>- QueryParam "imgType"- CSESiterestrictListImgType- :>- QueryParam "gl" Text :>- QueryParam "cx" Text :>- QueryParam- "imgColorType"- CSESiterestrictListImgColorType- :>- QueryParam- "imgSize"- CSESiterestrictListImgSize- :>- QueryParam- "exactTerms"- Text- :>- QueryParam "cr"- Text- :>- QueryParam- "safe"- CSESiterestrictListSafe- :>- QueryParam- "hq"- Text- :>- QueryParam- "highRange"- Text- :>- QueryParam- "alt"- AltJSON- :>- Get- '[JSON]- Search---- | Returns metadata about the search performed, metadata about the custom--- search engine used for the search, and the search results. Uses a small--- set of url patterns.------ /See:/ 'cSESiterestrictList' smart constructor.-data CSESiterestrictList =- CSESiterestrictList'- { _cseslImgDominantColor :: !(Maybe CSESiterestrictListImgDominantColor)- , _cseslSiteSearchFilter :: !(Maybe CSESiterestrictListSiteSearchFilter)- , _cseslC2coff :: !(Maybe Text)- , _cseslOrTerms :: !(Maybe Text)- , _cseslStart :: !(Maybe (Textual Word32))- , _cseslRights :: !(Maybe Text)- , _cseslExcludeTerms :: !(Maybe Text)- , _cseslNum :: !(Textual Word32)- , _cseslFileType :: !(Maybe Text)- , _cseslSearchType :: !(Maybe CSESiterestrictListSearchType)- , _cseslLr :: !(Maybe CSESiterestrictListLr)- , _cseslQ :: !Text- , _cseslGooglehost :: !(Maybe Text)- , _cseslRelatedSite :: !(Maybe Text)- , _cseslHl :: !(Maybe Text)- , _cseslSort :: !(Maybe Text)- , _cseslSiteSearch :: !(Maybe Text)- , _cseslFilter :: !(Maybe CSESiterestrictListFilter)- , _cseslDateRestrict :: !(Maybe Text)- , _cseslLinkSite :: !(Maybe Text)- , _cseslLowRange :: !(Maybe Text)- , _cseslImgType :: !(Maybe CSESiterestrictListImgType)- , _cseslGl :: !(Maybe Text)- , _cseslCx :: !(Maybe Text)- , _cseslImgColorType :: !(Maybe CSESiterestrictListImgColorType)- , _cseslImgSize :: !(Maybe CSESiterestrictListImgSize)- , _cseslExactTerms :: !(Maybe Text)- , _cseslCr :: !(Maybe Text)- , _cseslSafe :: !CSESiterestrictListSafe- , _cseslHq :: !(Maybe Text)- , _cseslHighRange :: !(Maybe Text)- }- deriving (Eq, Show, Data, Typeable, Generic)----- | Creates a value of 'CSESiterestrictList' with the minimum fields required to make a request.------ Use one of the following lenses to modify other fields as desired:------ * 'cseslImgDominantColor'------ * 'cseslSiteSearchFilter'------ * 'cseslC2coff'------ * 'cseslOrTerms'------ * 'cseslStart'------ * 'cseslRights'------ * 'cseslExcludeTerms'------ * 'cseslNum'------ * 'cseslFileType'------ * 'cseslSearchType'------ * 'cseslLr'------ * 'cseslQ'------ * 'cseslGooglehost'------ * 'cseslRelatedSite'------ * 'cseslHl'------ * 'cseslSort'------ * 'cseslSiteSearch'------ * 'cseslFilter'------ * 'cseslDateRestrict'------ * 'cseslLinkSite'------ * 'cseslLowRange'------ * 'cseslImgType'------ * 'cseslGl'------ * 'cseslCx'------ * 'cseslImgColorType'------ * 'cseslImgSize'------ * 'cseslExactTerms'------ * 'cseslCr'------ * 'cseslSafe'------ * 'cseslHq'------ * 'cseslHighRange'-cSESiterestrictList- :: Text -- ^ 'cseslQ'- -> CSESiterestrictList-cSESiterestrictList pCseslQ_ =- CSESiterestrictList'- { _cseslImgDominantColor = Nothing- , _cseslSiteSearchFilter = Nothing- , _cseslC2coff = Nothing- , _cseslOrTerms = Nothing- , _cseslStart = Nothing- , _cseslRights = Nothing- , _cseslExcludeTerms = Nothing- , _cseslNum = 10- , _cseslFileType = Nothing- , _cseslSearchType = Nothing- , _cseslLr = Nothing- , _cseslQ = pCseslQ_- , _cseslGooglehost = Nothing- , _cseslRelatedSite = Nothing- , _cseslHl = Nothing- , _cseslSort = Nothing- , _cseslSiteSearch = Nothing- , _cseslFilter = Nothing- , _cseslDateRestrict = Nothing- , _cseslLinkSite = Nothing- , _cseslLowRange = Nothing- , _cseslImgType = Nothing- , _cseslGl = Nothing- , _cseslCx = Nothing- , _cseslImgColorType = Nothing- , _cseslImgSize = Nothing- , _cseslExactTerms = Nothing- , _cseslCr = Nothing- , _cseslSafe = CSESLSOff- , _cseslHq = Nothing- , _cseslHighRange = Nothing- }----- | Returns images of a specific dominant color: red, orange, yellow, green,--- teal, blue, purple, pink, white, gray, black and brown.-cseslImgDominantColor :: Lens' CSESiterestrictList (Maybe CSESiterestrictListImgDominantColor)-cseslImgDominantColor- = lens _cseslImgDominantColor- (\ s a -> s{_cseslImgDominantColor = a})---- | Controls whether to include or exclude results from the site named in--- the as_sitesearch parameter-cseslSiteSearchFilter :: Lens' CSESiterestrictList (Maybe CSESiterestrictListSiteSearchFilter)-cseslSiteSearchFilter- = lens _cseslSiteSearchFilter- (\ s a -> s{_cseslSiteSearchFilter = a})---- | Turns off the translation between zh-CN and zh-TW.-cseslC2coff :: Lens' CSESiterestrictList (Maybe Text)-cseslC2coff- = lens _cseslC2coff (\ s a -> s{_cseslC2coff = a})---- | Provides additional search terms to check for in a document, where each--- document in the search results must contain at least one of the--- additional search terms-cseslOrTerms :: Lens' CSESiterestrictList (Maybe Text)-cseslOrTerms- = lens _cseslOrTerms (\ s a -> s{_cseslOrTerms = a})---- | The index of the first result to return-cseslStart :: Lens' CSESiterestrictList (Maybe Word32)-cseslStart- = lens _cseslStart (\ s a -> s{_cseslStart = a}) .- mapping _Coerce---- | Filters based on licensing. Supported values include: cc_publicdomain,--- cc_attribute, cc_sharealike, cc_noncommercial, cc_nonderived and--- combinations of these.-cseslRights :: Lens' CSESiterestrictList (Maybe Text)-cseslRights- = lens _cseslRights (\ s a -> s{_cseslRights = a})---- | Identifies a word or phrase that should not appear in any documents in--- the search results-cseslExcludeTerms :: Lens' CSESiterestrictList (Maybe Text)-cseslExcludeTerms- = lens _cseslExcludeTerms- (\ s a -> s{_cseslExcludeTerms = a})---- | Number of search results to return-cseslNum :: Lens' CSESiterestrictList Word32-cseslNum- = lens _cseslNum (\ s a -> s{_cseslNum = a}) .- _Coerce---- | Returns images of a specified type. Some of the allowed values are: bmp,--- gif, png, jpg, svg, pdf, ...-cseslFileType :: Lens' CSESiterestrictList (Maybe Text)-cseslFileType- = lens _cseslFileType- (\ s a -> s{_cseslFileType = a})---- | Specifies the search type: image.-cseslSearchType :: Lens' CSESiterestrictList (Maybe CSESiterestrictListSearchType)-cseslSearchType- = lens _cseslSearchType- (\ s a -> s{_cseslSearchType = a})---- | The language restriction for the search results-cseslLr :: Lens' CSESiterestrictList (Maybe CSESiterestrictListLr)-cseslLr = lens _cseslLr (\ s a -> s{_cseslLr = a})---- | Query-cseslQ :: Lens' CSESiterestrictList Text-cseslQ = lens _cseslQ (\ s a -> s{_cseslQ = a})---- | The local Google domain to use to perform the search.-cseslGooglehost :: Lens' CSESiterestrictList (Maybe Text)-cseslGooglehost- = lens _cseslGooglehost- (\ s a -> s{_cseslGooglehost = a})---- | Specifies that all search results should be pages that are related to--- the specified URL-cseslRelatedSite :: Lens' CSESiterestrictList (Maybe Text)-cseslRelatedSite- = lens _cseslRelatedSite- (\ s a -> s{_cseslRelatedSite = a})---- | Sets the user interface language.-cseslHl :: Lens' CSESiterestrictList (Maybe Text)-cseslHl = lens _cseslHl (\ s a -> s{_cseslHl = a})---- | The sort expression to apply to the results-cseslSort :: Lens' CSESiterestrictList (Maybe Text)-cseslSort- = lens _cseslSort (\ s a -> s{_cseslSort = a})---- | Specifies all search results should be pages from a given site-cseslSiteSearch :: Lens' CSESiterestrictList (Maybe Text)-cseslSiteSearch- = lens _cseslSiteSearch- (\ s a -> s{_cseslSiteSearch = a})---- | Controls turning on or off the duplicate content filter.-cseslFilter :: Lens' CSESiterestrictList (Maybe CSESiterestrictListFilter)-cseslFilter- = lens _cseslFilter (\ s a -> s{_cseslFilter = a})---- | Specifies all search results are from a time period-cseslDateRestrict :: Lens' CSESiterestrictList (Maybe Text)-cseslDateRestrict- = lens _cseslDateRestrict- (\ s a -> s{_cseslDateRestrict = a})---- | Specifies that all search results should contain a link to a particular--- URL-cseslLinkSite :: Lens' CSESiterestrictList (Maybe Text)-cseslLinkSite- = lens _cseslLinkSite- (\ s a -> s{_cseslLinkSite = a})---- | Creates a range in form as_nlo value..as_nhi value and attempts to--- append it to query-cseslLowRange :: Lens' CSESiterestrictList (Maybe Text)-cseslLowRange- = lens _cseslLowRange- (\ s a -> s{_cseslLowRange = a})---- | Returns images of a type, which can be one of: clipart, face, lineart,--- news, and photo.-cseslImgType :: Lens' CSESiterestrictList (Maybe CSESiterestrictListImgType)-cseslImgType- = lens _cseslImgType (\ s a -> s{_cseslImgType = a})---- | Geolocation of end user.-cseslGl :: Lens' CSESiterestrictList (Maybe Text)-cseslGl = lens _cseslGl (\ s a -> s{_cseslGl = a})---- | The custom search engine ID to scope this search query-cseslCx :: Lens' CSESiterestrictList (Maybe Text)-cseslCx = lens _cseslCx (\ s a -> s{_cseslCx = a})---- | Returns black and white, grayscale, or color images: mono, gray, and--- color.-cseslImgColorType :: Lens' CSESiterestrictList (Maybe CSESiterestrictListImgColorType)-cseslImgColorType- = lens _cseslImgColorType- (\ s a -> s{_cseslImgColorType = a})---- | Returns images of a specified size, where size can be one of: icon,--- small, medium, large, xlarge, xxlarge, and huge.-cseslImgSize :: Lens' CSESiterestrictList (Maybe CSESiterestrictListImgSize)-cseslImgSize- = lens _cseslImgSize (\ s a -> s{_cseslImgSize = a})---- | Identifies a phrase that all documents in the search results must--- contain-cseslExactTerms :: Lens' CSESiterestrictList (Maybe Text)-cseslExactTerms- = lens _cseslExactTerms- (\ s a -> s{_cseslExactTerms = a})---- | Country restrict(s).-cseslCr :: Lens' CSESiterestrictList (Maybe Text)-cseslCr = lens _cseslCr (\ s a -> s{_cseslCr = a})---- | Search safety level-cseslSafe :: Lens' CSESiterestrictList CSESiterestrictListSafe-cseslSafe- = lens _cseslSafe (\ s a -> s{_cseslSafe = a})---- | Appends the extra query terms to the query.-cseslHq :: Lens' CSESiterestrictList (Maybe Text)-cseslHq = lens _cseslHq (\ s a -> s{_cseslHq = a})---- | Creates a range in form as_nlo value..as_nhi value and attempts to--- append it to query-cseslHighRange :: Lens' CSESiterestrictList (Maybe Text)-cseslHighRange- = lens _cseslHighRange- (\ s a -> s{_cseslHighRange = a})--instance GoogleRequest CSESiterestrictList where- type Rs CSESiterestrictList = Search- type Scopes CSESiterestrictList = '[]- requestClient CSESiterestrictList'{..}- = go (Just _cseslQ) _cseslImgDominantColor- _cseslSiteSearchFilter- _cseslC2coff- _cseslOrTerms- _cseslStart- _cseslRights- _cseslExcludeTerms- (Just _cseslNum)- _cseslFileType- _cseslSearchType- _cseslLr- _cseslGooglehost- _cseslRelatedSite- _cseslHl- _cseslSort- _cseslSiteSearch- _cseslFilter- _cseslDateRestrict- _cseslLinkSite- _cseslLowRange- _cseslImgType- _cseslGl- _cseslCx- _cseslImgColorType- _cseslImgSize- _cseslExactTerms- _cseslCr- (Just _cseslSafe)- _cseslHq- _cseslHighRange- (Just AltJSON)- customSearchService- where go- = buildClient- (Proxy :: Proxy CSESiterestrictListResource)- mempty
gogol-customsearch.cabal view
@@ -1,47 +1,62 @@-name: gogol-customsearch-version: 0.5.0-synopsis: Google CustomSearch SDK.-homepage: https://github.com/brendanhay/gogol-bug-reports: https://github.com/brendanhay/gogol/issues-license: OtherLicense-license-file: LICENSE-author: Brendan Hay-maintainer: Brendan Hay <brendan.g.hay@gmail.com>-copyright: Copyright (c) 2015-2016 Brendan Hay-category: Network, Google, Cloud-build-type: Simple-cabal-version: >= 1.10-extra-source-files: README.md src/.gitkeep+cabal-version: 2.2+name: gogol-customsearch+version: 1.0.0+synopsis: Google Custom Search SDK.+homepage: https://github.com/brendanhay/gogol+bug-reports: https://github.com/brendanhay/gogol/issues+license: MPL-2.0+license-file: LICENSE+author: Brendan Hay+maintainer:+ Brendan Hay <brendan.g.hay+gogol@gmail.com>, Toni Cebrián <toni@tonicebrian.com> +copyright: Copyright (c) 2015-2025 Brendan Hay+category: Google+build-type: Simple+extra-source-files:+ README.md+ src/.gitkeep+ description:- Searches over a website or collection of websites- .- /Warning:/ This is an experimental prototype/preview release which is still- under exploratory development and not intended for public use, caveat emptor!- .- This library is compatible with version @v1@- of the API.+ Searches over a website or collection of websites+ .+ /Warning:/ This is an experimental prototype/preview release which is still+ under exploratory development and not intended for public use, caveat emptor!+ .+ This library is compatible with version @v1@+ of the API. source-repository head- type: git- location: git://github.com/brendanhay/gogol.git+ type: git+ location: git://github.com/brendanhay/gogol.git+ subdir: gogol-customsearch +flag field-selectors+ description:+ If record field selectors should be enabled. Disabling this requires GHC >=9.2 and the NoFieldSelectors extension.++ default: False+ manual: True+ library- default-language: Haskell2010- hs-source-dirs: src gen+ default-language: GHC2021+ hs-source-dirs: src gen+ ghc-options:+ -Wall -fwarn-incomplete-uni-patterns+ -fwarn-incomplete-record-updates -funbox-strict-fields+ -fwarn-unused-packages - ghc-options: -Wall+ if (!flag(field-selectors) && impl(ghc >=9.2))+ default-extensions: NoFieldSelectors - exposed-modules:- Network.Google.CustomSearch- , Network.Google.CustomSearch.Types- , Network.Google.Resource.Search.CSE.List- , Network.Google.Resource.Search.CSE.Siterestrict.List+ exposed-modules:+ Gogol.CustomSearch+ Gogol.CustomSearch.Search.Cse.List+ Gogol.CustomSearch.Search.Cse.Siterestrict.List+ Gogol.CustomSearch.Types - other-modules:- Network.Google.CustomSearch.Types.Product- , Network.Google.CustomSearch.Types.Sum+ other-modules:+ Gogol.CustomSearch.Internal.Product+ Gogol.CustomSearch.Internal.Sum - build-depends:- gogol-core == 0.5.0.*- , base >= 4.7 && < 5+ build-depends: gogol-core ^>=1.0.0