on develop help sign in
Regenerating gogol-books from latest service definition
c52b3e0Brendan Hay
gen/model/books/v1/books-api.json+50−4
@@ -1,13 +1,13 @@
1{
1{
2 "kind": "discovery#restDescription",
2 "kind": "discovery#restDescription",
3− "etag": "\"jQLIOHBVnDZie4rQHGH1WJF-INE/EKgCMl0lR3W1RkwoySiKYH3FM7c\"",
3+ "etag": "\"C5oy1hgQsABtYOYIOXWcR3BgYqU/qBcgfnv8LaBwEppyThW1YG_JvBU\"",
4 "discoveryVersion": "v1",
4 "discoveryVersion": "v1",
5 "id": "books:v1",
5 "id": "books:v1",
6 "name": "books",
6 "name": "books",
7 "version": "v1",
7 "version": "v1",
8− "revision": "20160411",
8+ "revision": "20161005",
9 "title": "Books API",
9 "title": "Books API",
10− "description": "Lets you search for books and manage your Google Books library.",
10+ "description": "Searches for books and manages your Google Books library.",
11 "ownerDomain": "google.com",
11 "ownerDomain": "google.com",
12 "ownerName": "Google",
12 "ownerName": "Google",
13 "icons": {
13 "icons": {
@@ -1374,6 +1374,7 @@
1374 },
1374 },
1375 "series": {
1375 "series": {
1376 "type": "array",
1376 "type": "array",
1377+ "description": "Series info list. The client always expects this element in the JSON output, hence declared here as OutputAlways.",
1377 "items": {
1378 "items": {
1378 "type": "object",
1379 "type": "object",
1379 "properties": {
1380 "properties": {
@@ -1448,6 +1449,14 @@
1448 "type": "string"
1449 "type": "string"
1449 }
1450 }
1450 }
1451 }
1452+ },
1453+ "moreFromSeries": {
1454+ "type": "object",
1455+ "properties": {
1456+ "opted_state": {
1457+ "type": "string"
1458+ }
1459+ }
1451 }
1460 }
1452 }
1461 }
1453 }
1462 }
@@ -1635,6 +1644,10 @@
1635 "description": "The finsky offer type (e.g., PURCHASE=0 RENTAL=3)",
1644 "description": "The finsky offer type (e.g., PURCHASE=0 RENTAL=3)",
1636 "format": "int32"
1645 "format": "int32"
1637 },
1646 },
1647+ "giftable": {
1648+ "type": "boolean",
1649+ "description": "Indicates whether the offer is giftable."
1650+ },
1638 "listPrice": {
1651 "listPrice": {
1639 "type": "object",
1652 "type": "object",
1640 "description": "Offer list (=undiscounted) price in Micros.",
1653 "description": "Offer list (=undiscounted) price in Micros.",
@@ -1972,6 +1985,24 @@
1972 "description": "Total number of pages as per publisher metadata.",
1985 "description": "Total number of pages as per publisher metadata.",
1973 "format": "int32"
1986 "format": "int32"
1974 },
1987 },
1988+ "panelizationSummary": {
1989+ "type": "object",
1990+ "description": "A top-level summary of the panelization info in this volume.",
1991+ "properties": {
1992+ "containsEpubBubbles": {
1993+ "type": "boolean"
1994+ },
1995+ "containsImageBubbles": {
1996+ "type": "boolean"
1997+ },
1998+ "epubBubbleVersion": {
1999+ "type": "string"
2000+ },
2001+ "imageBubbleVersion": {
2002+ "type": "string"
2003+ }
2004+ }
2005+ },
1975 "previewLink": {
2006 "previewLink": {
1976 "type": "string",
2007 "type": "string",
1977 "description": "URL to preview this volume on the Google Books site."
2008 "description": "URL to preview this volume on the Google Books site."
@@ -4154,6 +4185,19 @@
4154 ],
4185 ],
4155 "location": "query"
4186 "location": "query"
4156 },
4187 },
4188+ "maxAllowedMaturityRating": {
4189+ "type": "string",
4190+ "description": "The maximum allowed maturity rating of returned recommendations. Books with a higher maturity rating are filtered out.",
4191+ "enum": [
4192+ "mature",
4193+ "not-mature"
4194+ ],
4195+ "enumDescriptions": [
4196+ "Show books which are rated mature or lower.",
4197+ "Show books which are rated not mature."
4198+ ],
4199+ "location": "query"
4200+ },
4157 "maxResults": {
4201 "maxResults": {
4158 "type": "integer",
4202 "type": "integer",
4159 "description": "Maximum number of results to return.",
4203 "description": "Maximum number of results to return.",
@@ -4319,8 +4363,9 @@
4319 "parameters": {
4363 "parameters": {
4320 "acquireMethod": {
4364 "acquireMethod": {
4321 "type": "string",
4365 "type": "string",
4322− "description": "How the book was aquired",
4366+ "description": "How the book was acquired",
4323 "enum": [
4367 "enum": [
4368+ "FAMILY_SHARED",
4324 "PREORDERED",
4369 "PREORDERED",
4325 "PREVIOUSLY_RENTED",
4370 "PREVIOUSLY_RENTED",
4326 "PUBLIC_DOMAIN",
4371 "PUBLIC_DOMAIN",
@@ -4330,6 +4375,7 @@
4330 "UPLOADED"
4375 "UPLOADED"
4331 ],
4376 ],
4332 "enumDescriptions": [
4377 "enumDescriptions": [
4378+ "Books acquired via Family Sharing",
4333 "Preordered books (not yet available)",
4379 "Preordered books (not yet available)",
4334 "User-rented books past their expiration time",
4380 "User-rented books past their expiration time",
4335 "Public domain books",
4381 "Public domain books",
gogol-books/gen/Network/Google/Books.hs+20−1
@@ -13,7 +13,7 @@
13-- Stability : auto-generated
13-- Stability : auto-generated
14-- Portability : non-portable (GHC extensions)
14-- Portability : non-portable (GHC extensions)
15--
15--
16−-- Lets you search for books and manage your Google Books library.
16+-- Searches for books and manages your Google Books library.
17--
17--
18-- /See:/ <https://developers.google.com/books/docs/v1/getting_started Books API Reference>
18-- /See:/ <https://developers.google.com/books/docs/v1/getting_started Books API Reference>
19module Network.Google.Books
19module Network.Google.Books
@@ -374,6 +374,14 @@ module Network.Google.Books
374 , vaiViewOrderURL
374 , vaiViewOrderURL
375 , vaiPublicDomain
375 , vaiPublicDomain
376
376
377+ -- ** VolumeVolumeInfoPanelizationSummary
378+ , VolumeVolumeInfoPanelizationSummary
379+ , volumeVolumeInfoPanelizationSummary
380+ , vvipsEpubBubbleVersion
381+ , vvipsContainsImageBubbles
382+ , vvipsContainsEpubBubbles
383+ , vvipsImageBubbleVersion
384+
377 -- ** MyLibraryBookshelvesRemoveVolumeReason
385 -- ** MyLibraryBookshelvesRemoveVolumeReason
378 , MyLibraryBookshelvesRemoveVolumeReason (..)
386 , MyLibraryBookshelvesRemoveVolumeReason (..)
379
387
@@ -668,6 +676,7 @@ module Network.Google.Books
668 , UserSettingsNotification
676 , UserSettingsNotification
669 , userSettingsNotification
677 , userSettingsNotification
670 , usnMoreFromAuthors
678 , usnMoreFromAuthors
679+ , usnMoreFromSeries
671
680
672 -- ** DictlayerDataDictWordsItemSensesItemSynonymsItem
681 -- ** DictlayerDataDictWordsItemSensesItemSynonymsItem
673 , DictlayerDataDictWordsItemSensesItemSynonymsItem
682 , DictlayerDataDictWordsItemSensesItemSynonymsItem
@@ -892,6 +901,7 @@ module Network.Google.Books
892 , vsioiRentalDuration
901 , vsioiRentalDuration
893 , vsioiListPrice
902 , vsioiListPrice
894 , vsioiRetailPrice
903 , vsioiRetailPrice
904+ , vsioiGiftable
895
905
896 -- ** DictlayerDataDict
906 -- ** DictlayerDataDict
897 , DictlayerDataDict
907 , DictlayerDataDict
@@ -1002,6 +1012,7 @@ module Network.Google.Books
1002 , VolumeVolumeInfo
1012 , VolumeVolumeInfo
1003 , volumeVolumeInfo
1013 , volumeVolumeInfo
1004 , vviImageLinks
1014 , vviImageLinks
1015+ , vviPanelizationSummary
1005 , vviAverageRating
1016 , vviAverageRating
1006 , vviRatingsCount
1017 , vviRatingsCount
1007 , vviCanonicalVolumeLink
1018 , vviCanonicalVolumeLink
@@ -1056,6 +1067,11 @@ module Network.Google.Books
1056 , vuifsIsSharingAllowed
1067 , vuifsIsSharingAllowed
1057 , vuifsIsSharingDisabledByFop
1068 , vuifsIsSharingDisabledByFop
1058
1069
1070+ -- ** UserSettingsNotificationMoreFromSeries
1071+ , UserSettingsNotificationMoreFromSeries
1072+ , userSettingsNotificationMoreFromSeries
1073+ , usnmfsOptedState
1074+
1059 -- ** VolumeVolumeInfoIndustryIdentifiersItem
1075 -- ** VolumeVolumeInfoIndustryIdentifiersItem
1060 , VolumeVolumeInfoIndustryIdentifiersItem
1076 , VolumeVolumeInfoIndustryIdentifiersItem
1061 , volumeVolumeInfoIndustryIdentifiersItem
1077 , volumeVolumeInfoIndustryIdentifiersItem
@@ -1070,6 +1086,9 @@ module Network.Google.Books
1070 , barEndPosition
1086 , barEndPosition
1071 , barStartPosition
1087 , barStartPosition
1072
1088
1089+ -- ** VolumesListMaxAllowedMaturityRating
1090+ , VolumesListMaxAllowedMaturityRating (..)
1091+
1073 -- ** Layersummaries
1092 -- ** Layersummaries
1074 , Layersummaries
1093 , Layersummaries
1075 , layersummaries
1094 , layersummaries
gogol-books/gen/Network/Google/Books/Types.hs+19
@@ -221,6 +221,14 @@ module Network.Google.Books.Types
221 , vaiViewOrderURL
221 , vaiViewOrderURL
222 , vaiPublicDomain
222 , vaiPublicDomain
223
223
224+ -- * VolumeVolumeInfoPanelizationSummary
225+ , VolumeVolumeInfoPanelizationSummary
226+ , volumeVolumeInfoPanelizationSummary
227+ , vvipsEpubBubbleVersion
228+ , vvipsContainsImageBubbles
229+ , vvipsContainsEpubBubbles
230+ , vvipsImageBubbleVersion
231+
224 -- * MyLibraryBookshelvesRemoveVolumeReason
232 -- * MyLibraryBookshelvesRemoveVolumeReason
225 , MyLibraryBookshelvesRemoveVolumeReason (..)
233 , MyLibraryBookshelvesRemoveVolumeReason (..)
226
234
@@ -515,6 +523,7 @@ module Network.Google.Books.Types
515 , UserSettingsNotification
523 , UserSettingsNotification
516 , userSettingsNotification
524 , userSettingsNotification
517 , usnMoreFromAuthors
525 , usnMoreFromAuthors
526+ , usnMoreFromSeries
518
527
519 -- * DictlayerDataDictWordsItemSensesItemSynonymsItem
528 -- * DictlayerDataDictWordsItemSensesItemSynonymsItem
520 , DictlayerDataDictWordsItemSensesItemSynonymsItem
529 , DictlayerDataDictWordsItemSensesItemSynonymsItem
@@ -739,6 +748,7 @@ module Network.Google.Books.Types
739 , vsioiRentalDuration
748 , vsioiRentalDuration
740 , vsioiListPrice
749 , vsioiListPrice
741 , vsioiRetailPrice
750 , vsioiRetailPrice
751+ , vsioiGiftable
742
752
743 -- * DictlayerDataDict
753 -- * DictlayerDataDict
744 , DictlayerDataDict
754 , DictlayerDataDict
@@ -849,6 +859,7 @@ module Network.Google.Books.Types
849 , VolumeVolumeInfo
859 , VolumeVolumeInfo
850 , volumeVolumeInfo
860 , volumeVolumeInfo
851 , vviImageLinks
861 , vviImageLinks
862+ , vviPanelizationSummary
852 , vviAverageRating
863 , vviAverageRating
853 , vviRatingsCount
864 , vviRatingsCount
854 , vviCanonicalVolumeLink
865 , vviCanonicalVolumeLink
@@ -903,6 +914,11 @@ module Network.Google.Books.Types
903 , vuifsIsSharingAllowed
914 , vuifsIsSharingAllowed
904 , vuifsIsSharingDisabledByFop
915 , vuifsIsSharingDisabledByFop
905
916
917+ -- * UserSettingsNotificationMoreFromSeries
918+ , UserSettingsNotificationMoreFromSeries
919+ , userSettingsNotificationMoreFromSeries
920+ , usnmfsOptedState
921+
906 -- * VolumeVolumeInfoIndustryIdentifiersItem
922 -- * VolumeVolumeInfoIndustryIdentifiersItem
907 , VolumeVolumeInfoIndustryIdentifiersItem
923 , VolumeVolumeInfoIndustryIdentifiersItem
908 , volumeVolumeInfoIndustryIdentifiersItem
924 , volumeVolumeInfoIndustryIdentifiersItem
@@ -917,6 +933,9 @@ module Network.Google.Books.Types
917 , barEndPosition
933 , barEndPosition
918 , barStartPosition
934 , barStartPosition
919
935
936+ -- * VolumesListMaxAllowedMaturityRating
937+ , VolumesListMaxAllowedMaturityRating (..)
938+
920 -- * Layersummaries
939 -- * Layersummaries
921 , Layersummaries
940 , Layersummaries
922 , layersummaries
941 , layersummaries
gogol-books/gen/Network/Google/Books/Types/Product.hs+161−8
@@ -1850,6 +1850,82 @@ instance ToJSON VolumeAccessInfo where
1850 ("viewOrderUrl" .=) <$> _vaiViewOrderURL,
1850 ("viewOrderUrl" .=) <$> _vaiViewOrderURL,
1851 ("publicDomain" .=) <$> _vaiPublicDomain])
1851 ("publicDomain" .=) <$> _vaiPublicDomain])
1852
1852
1853+-- | A top-level summary of the panelization info in this volume.
1854+--
1855+-- /See:/ 'volumeVolumeInfoPanelizationSummary' smart constructor.
1856+data VolumeVolumeInfoPanelizationSummary = VolumeVolumeInfoPanelizationSummary'
1857+ { _vvipsEpubBubbleVersion :: !(Maybe Text)
1858+ , _vvipsContainsImageBubbles :: !(Maybe Bool)
1859+ , _vvipsContainsEpubBubbles :: !(Maybe Bool)
1860+ , _vvipsImageBubbleVersion :: !(Maybe Text)
1861+ } deriving (Eq,Show,Data,Typeable,Generic)
1862+
1863+-- | Creates a value of 'VolumeVolumeInfoPanelizationSummary' with the minimum fields required to make a request.
1864+--
1865+-- Use one of the following lenses to modify other fields as desired:
1866+--
1867+-- * 'vvipsEpubBubbleVersion'
1868+--
1869+-- * 'vvipsContainsImageBubbles'
1870+--
1871+-- * 'vvipsContainsEpubBubbles'
1872+--
1873+-- * 'vvipsImageBubbleVersion'
1874+volumeVolumeInfoPanelizationSummary
1875+ :: VolumeVolumeInfoPanelizationSummary
1876+volumeVolumeInfoPanelizationSummary =
1877+ VolumeVolumeInfoPanelizationSummary'
1878+ { _vvipsEpubBubbleVersion = Nothing
1879+ , _vvipsContainsImageBubbles = Nothing
1880+ , _vvipsContainsEpubBubbles = Nothing
1881+ , _vvipsImageBubbleVersion = Nothing
1882+ }
1883+
1884+vvipsEpubBubbleVersion :: Lens' VolumeVolumeInfoPanelizationSummary (Maybe Text)
1885+vvipsEpubBubbleVersion
1886+ = lens _vvipsEpubBubbleVersion
1887+ (\ s a -> s{_vvipsEpubBubbleVersion = a})
1888+
1889+vvipsContainsImageBubbles :: Lens' VolumeVolumeInfoPanelizationSummary (Maybe Bool)
1890+vvipsContainsImageBubbles
1891+ = lens _vvipsContainsImageBubbles
1892+ (\ s a -> s{_vvipsContainsImageBubbles = a})
1893+
1894+vvipsContainsEpubBubbles :: Lens' VolumeVolumeInfoPanelizationSummary (Maybe Bool)
1895+vvipsContainsEpubBubbles
1896+ = lens _vvipsContainsEpubBubbles
1897+ (\ s a -> s{_vvipsContainsEpubBubbles = a})
1898+
1899+vvipsImageBubbleVersion :: Lens' VolumeVolumeInfoPanelizationSummary (Maybe Text)
1900+vvipsImageBubbleVersion
1901+ = lens _vvipsImageBubbleVersion
1902+ (\ s a -> s{_vvipsImageBubbleVersion = a})
1903+
1904+instance FromJSON VolumeVolumeInfoPanelizationSummary
1905+ where
1906+ parseJSON
1907+ = withObject "VolumeVolumeInfoPanelizationSummary"
1908+ (\ o ->
1909+ VolumeVolumeInfoPanelizationSummary' <$>
1910+ (o .:? "epubBubbleVersion") <*>
1911+ (o .:? "containsImageBubbles")
1912+ <*> (o .:? "containsEpubBubbles")
1913+ <*> (o .:? "imageBubbleVersion"))
1914+
1915+instance ToJSON VolumeVolumeInfoPanelizationSummary
1916+ where
1917+ toJSON VolumeVolumeInfoPanelizationSummary'{..}
1918+ = object
1919+ (catMaybes
1920+ [("epubBubbleVersion" .=) <$>
1921+ _vvipsEpubBubbleVersion,
1922+ ("containsImageBubbles" .=) <$>
1923+ _vvipsContainsImageBubbles,
1924+ ("containsEpubBubbles" .=) <$>
1925+ _vvipsContainsEpubBubbles,
1926+ ("imageBubbleVersion" .=) <$>
1927+ _vvipsImageBubbleVersion])
1928+
1853-- | A list of image links for all the sizes that are available. (In LITE
1929-- | A list of image links for all the sizes that are available. (In LITE
1854-- projection.)
1930-- projection.)
1855--
1931--
@@ -3224,6 +3300,8 @@ series =
3224sKind :: Lens' Series Text
3300sKind :: Lens' Series Text
3225sKind = lens _sKind (\ s a -> s{_sKind = a})
3301sKind = lens _sKind (\ s a -> s{_sKind = a})
3226
3302
3303+-- | Series info list. The client always expects this element in the JSON
3304+-- output, hence declared here as OutputAlways.
3227sSeries :: Lens' Series [SeriesSeriesItem]
3305sSeries :: Lens' Series [SeriesSeriesItem]
3228sSeries
3306sSeries
3229 = lens _sSeries (\ s a -> s{_sSeries = a}) . _Default
3307 = lens _sSeries (\ s a -> s{_sSeries = a}) . _Default
@@ -4130,8 +4208,9 @@ instance ToJSON Seriesmembership where
4130
4208
4131--
4209--
4132-- /See:/ 'userSettingsNotification' smart constructor.
4210-- /See:/ 'userSettingsNotification' smart constructor.
4133−newtype UserSettingsNotification = UserSettingsNotification'
4211+data UserSettingsNotification = UserSettingsNotification'
4134− { _usnMoreFromAuthors :: Maybe UserSettingsNotificationMoreFromAuthors
4212+ { _usnMoreFromAuthors :: !(Maybe UserSettingsNotificationMoreFromAuthors)
4213+ , _usnMoreFromSeries :: !(Maybe UserSettingsNotificationMoreFromSeries)
4135 } deriving (Eq,Show,Data,Typeable,Generic)
4214 } deriving (Eq,Show,Data,Typeable,Generic)
4136
4215
4137-- | Creates a value of 'UserSettingsNotification' with the minimum fields required to make a request.
4216-- | Creates a value of 'UserSettingsNotification' with the minimum fields required to make a request.
@@ -4139,11 +4218,14 @@ newtype UserSettingsNotification = UserSettingsNotification'
4139-- Use one of the following lenses to modify other fields as desired:
4218-- Use one of the following lenses to modify other fields as desired:
4140--
4219--
4141-- * 'usnMoreFromAuthors'
4220-- * 'usnMoreFromAuthors'
4221+--
4222+-- * 'usnMoreFromSeries'
4142userSettingsNotification
4223userSettingsNotification
4143 :: UserSettingsNotification
4224 :: UserSettingsNotification
4144userSettingsNotification =
4225userSettingsNotification =
4145 UserSettingsNotification'
4226 UserSettingsNotification'
4146 { _usnMoreFromAuthors = Nothing
4227 { _usnMoreFromAuthors = Nothing
4228+ , _usnMoreFromSeries = Nothing
4147 }
4229 }
4148
4230
4149usnMoreFromAuthors :: Lens' UserSettingsNotification (Maybe UserSettingsNotificationMoreFromAuthors)
4231usnMoreFromAuthors :: Lens' UserSettingsNotification (Maybe UserSettingsNotificationMoreFromAuthors)
@@ -4151,18 +4233,25 @@ usnMoreFromAuthors
4151 = lens _usnMoreFromAuthors
4233 = lens _usnMoreFromAuthors
4152 (\ s a -> s{_usnMoreFromAuthors = a})
4234 (\ s a -> s{_usnMoreFromAuthors = a})
4153
4235
4236+usnMoreFromSeries :: Lens' UserSettingsNotification (Maybe UserSettingsNotificationMoreFromSeries)
4237+usnMoreFromSeries
4238+ = lens _usnMoreFromSeries
4239+ (\ s a -> s{_usnMoreFromSeries = a})
4240+
4154instance FromJSON UserSettingsNotification where
4241instance FromJSON UserSettingsNotification where
4155 parseJSON
4242 parseJSON
4156 = withObject "UserSettingsNotification"
4243 = withObject "UserSettingsNotification"
4157 (\ o ->
4244 (\ o ->
4158 UserSettingsNotification' <$>
4245 UserSettingsNotification' <$>
4159− (o .:? "moreFromAuthors"))
4246+ (o .:? "moreFromAuthors") <*>
4247+ (o .:? "moreFromSeries"))
4160
4248
4161instance ToJSON UserSettingsNotification where
4249instance ToJSON UserSettingsNotification where
4162 toJSON UserSettingsNotification'{..}
4250 toJSON UserSettingsNotification'{..}
4163 = object
4251 = object
4164 (catMaybes
4252 (catMaybes
4165− [("moreFromAuthors" .=) <$> _usnMoreFromAuthors])
4253+ [("moreFromAuthors" .=) <$> _usnMoreFromAuthors,
4254+ ("moreFromSeries" .=) <$> _usnMoreFromSeries])
4166
4255
4167--
4256--
4168-- /See:/ 'dictlayerDataDictWordsItemSensesItemSynonymsItem' smart constructor.
4257-- /See:/ 'dictlayerDataDictWordsItemSensesItemSynonymsItem' smart constructor.
@@ -5959,6 +6048,7 @@ data VolumeSaleInfoOffersItem = VolumeSaleInfoOffersItem'
5959 , _vsioiRentalDuration :: !(Maybe VolumeSaleInfoOffersItemRentalDuration)
6048 , _vsioiRentalDuration :: !(Maybe VolumeSaleInfoOffersItemRentalDuration)
5960 , _vsioiListPrice :: !(Maybe VolumeSaleInfoOffersItemListPrice)
6049 , _vsioiListPrice :: !(Maybe VolumeSaleInfoOffersItemListPrice)
5961 , _vsioiRetailPrice :: !(Maybe VolumeSaleInfoOffersItemRetailPrice)
6050 , _vsioiRetailPrice :: !(Maybe VolumeSaleInfoOffersItemRetailPrice)
6051+ , _vsioiGiftable :: !(Maybe Bool)
5962 } deriving (Eq,Show,Data,Typeable,Generic)
6052 } deriving (Eq,Show,Data,Typeable,Generic)
5963
6053
5964-- | Creates a value of 'VolumeSaleInfoOffersItem' with the minimum fields required to make a request.
6054-- | Creates a value of 'VolumeSaleInfoOffersItem' with the minimum fields required to make a request.
@@ -5972,6 +6062,8 @@ data VolumeSaleInfoOffersItem = VolumeSaleInfoOffersItem'
5972-- * 'vsioiListPrice'
6062-- * 'vsioiListPrice'
5973--
6063--
5974-- * 'vsioiRetailPrice'
6064-- * 'vsioiRetailPrice'
6065+--
6066+-- * 'vsioiGiftable'
5975volumeSaleInfoOffersItem
6067volumeSaleInfoOffersItem
5976 :: VolumeSaleInfoOffersItem
6068 :: VolumeSaleInfoOffersItem
5977volumeSaleInfoOffersItem =
6069volumeSaleInfoOffersItem =
@@ -5980,6 +6072,7 @@ volumeSaleInfoOffersItem =
5980 , _vsioiRentalDuration = Nothing
6072 , _vsioiRentalDuration = Nothing
5981 , _vsioiListPrice = Nothing
6073 , _vsioiListPrice = Nothing
5982 , _vsioiRetailPrice = Nothing
6074 , _vsioiRetailPrice = Nothing
6075+ , _vsioiGiftable = Nothing
5983 }
6076 }
5984
6077
5985-- | The finsky offer type (e.g., PURCHASE=0 RENTAL=3)
6078-- | The finsky offer type (e.g., PURCHASE=0 RENTAL=3)
@@ -6007,6 +6100,12 @@ vsioiRetailPrice
6007 = lens _vsioiRetailPrice
6100 = lens _vsioiRetailPrice
6008 (\ s a -> s{_vsioiRetailPrice = a})
6101 (\ s a -> s{_vsioiRetailPrice = a})
6009
6102
6103+-- | Indicates whether the offer is giftable.
6104+vsioiGiftable :: Lens' VolumeSaleInfoOffersItem (Maybe Bool)
6105+vsioiGiftable
6106+ = lens _vsioiGiftable
6107+ (\ s a -> s{_vsioiGiftable = a})
6108+
6010instance FromJSON VolumeSaleInfoOffersItem where
6109instance FromJSON VolumeSaleInfoOffersItem where
6011 parseJSON
6110 parseJSON
6012 = withObject "VolumeSaleInfoOffersItem"
6111 = withObject "VolumeSaleInfoOffersItem"
@@ -6015,7 +6114,8 @@ instance FromJSON VolumeSaleInfoOffersItem where
6015 (o .:? "finskyOfferType") <*>
6114 (o .:? "finskyOfferType") <*>
6016 (o .:? "rentalDuration")
6115 (o .:? "rentalDuration")
6017 <*> (o .:? "listPrice")
6116 <*> (o .:? "listPrice")
6018− <*> (o .:? "retailPrice"))
6117+ <*> (o .:? "retailPrice")
6118+ <*> (o .:? "giftable"))
6019
6119
6020instance ToJSON VolumeSaleInfoOffersItem where
6120instance ToJSON VolumeSaleInfoOffersItem where
6021 toJSON VolumeSaleInfoOffersItem'{..}
6121 toJSON VolumeSaleInfoOffersItem'{..}
@@ -6024,7 +6124,8 @@ instance ToJSON VolumeSaleInfoOffersItem where
6024 [("finskyOfferType" .=) <$> _vsioiFinskyOfferType,
6124 [("finskyOfferType" .=) <$> _vsioiFinskyOfferType,
6025 ("rentalDuration" .=) <$> _vsioiRentalDuration,
6125 ("rentalDuration" .=) <$> _vsioiRentalDuration,
6026 ("listPrice" .=) <$> _vsioiListPrice,
6126 ("listPrice" .=) <$> _vsioiListPrice,
6027− ("retailPrice" .=) <$> _vsioiRetailPrice])
6127+ ("retailPrice" .=) <$> _vsioiRetailPrice,
6128+ ("giftable" .=) <$> _vsioiGiftable])
6028
6129
6029--
6130--
6030-- /See:/ 'dictlayerDataDict' smart constructor.
6131-- /See:/ 'dictlayerDataDict' smart constructor.
@@ -6870,6 +6971,7 @@ instance ToJSON GeolayerDataGeoViewportHi where
6870-- /See:/ 'volumeVolumeInfo' smart constructor.
6971-- /See:/ 'volumeVolumeInfo' smart constructor.
6871data VolumeVolumeInfo = VolumeVolumeInfo'
6972data VolumeVolumeInfo = VolumeVolumeInfo'
6872 { _vviImageLinks :: !(Maybe VolumeVolumeInfoImageLinks)
6973 { _vviImageLinks :: !(Maybe VolumeVolumeInfoImageLinks)
6974+ , _vviPanelizationSummary :: !(Maybe VolumeVolumeInfoPanelizationSummary)
6873 , _vviAverageRating :: !(Maybe (Textual Double))
6975 , _vviAverageRating :: !(Maybe (Textual Double))
6874 , _vviRatingsCount :: !(Maybe (Textual Int32))
6976 , _vviRatingsCount :: !(Maybe (Textual Int32))
6875 , _vviCanonicalVolumeLink :: !(Maybe Text)
6977 , _vviCanonicalVolumeLink :: !(Maybe Text)
@@ -6903,6 +7005,8 @@ data VolumeVolumeInfo = VolumeVolumeInfo'
6903--
7005--
6904-- * 'vviImageLinks'
7006-- * 'vviImageLinks'
6905--
7007--
7008+-- * 'vviPanelizationSummary'
7009+--
6906-- * 'vviAverageRating'
7010-- * 'vviAverageRating'
6907--
7011--
6908-- * 'vviRatingsCount'
7012-- * 'vviRatingsCount'
@@ -6957,6 +7061,7 @@ volumeVolumeInfo
6957volumeVolumeInfo =
7061volumeVolumeInfo =
6958 VolumeVolumeInfo'
7062 VolumeVolumeInfo'
6959 { _vviImageLinks = Nothing
7063 { _vviImageLinks = Nothing
7064+ , _vviPanelizationSummary = Nothing
6960 , _vviAverageRating = Nothing
7065 , _vviAverageRating = Nothing
6961 , _vviRatingsCount = Nothing
7066 , _vviRatingsCount = Nothing
6962 , _vviCanonicalVolumeLink = Nothing
7067 , _vviCanonicalVolumeLink = Nothing
@@ -6991,6 +7096,12 @@ vviImageLinks
6991 = lens _vviImageLinks
7096 = lens _vviImageLinks
6992 (\ s a -> s{_vviImageLinks = a})
7097 (\ s a -> s{_vviImageLinks = a})
6993
7098
7099+-- | A top-level summary of the panelization info in this volume.
7100+vviPanelizationSummary :: Lens' VolumeVolumeInfo (Maybe VolumeVolumeInfoPanelizationSummary)
7101+vviPanelizationSummary
7102+ = lens _vviPanelizationSummary
7103+ (\ s a -> s{_vviPanelizationSummary = a})
7104+
6994-- | The mean review rating for this volume. (min = 1.0, max = 5.0)
7105-- | The mean review rating for this volume. (min = 1.0, max = 5.0)
6995vviAverageRating :: Lens' VolumeVolumeInfo (Maybe Double)
7106vviAverageRating :: Lens' VolumeVolumeInfo (Maybe Double)
6996vviAverageRating
7107vviAverageRating
@@ -7154,8 +7265,10 @@ instance FromJSON VolumeVolumeInfo where
7154 = withObject "VolumeVolumeInfo"
7265 = withObject "VolumeVolumeInfo"
7155 (\ o ->
7266 (\ o ->
7156 VolumeVolumeInfo' <$>
7267 VolumeVolumeInfo' <$>
7268+ (o .:? "imageLinks") <*>
7269+ (o .:? "panelizationSummary")
7157− (o .:? "imageLinks") <*> (o .:? "averageRating") <*>
7270+ <*> (o .:? "averageRating")
7158− (o .:? "ratingsCount")
7271+ <*> (o .:? "ratingsCount")
7159 <*> (o .:? "canonicalVolumeLink")
7272 <*> (o .:? "canonicalVolumeLink")
7160 <*> (o .:? "readingModes")
7273 <*> (o .:? "readingModes")
7161 <*> (o .:? "industryIdentifiers" .!= mempty)
7274 <*> (o .:? "industryIdentifiers" .!= mempty)
@@ -7185,6 +7298,8 @@ instance ToJSON VolumeVolumeInfo where
7185 = object
7298 = object
7186 (catMaybes
7299 (catMaybes
7187 [("imageLinks" .=) <$> _vviImageLinks,
7300 [("imageLinks" .=) <$> _vviImageLinks,
7301+ ("panelizationSummary" .=) <$>
7302+ _vviPanelizationSummary,
7188 ("averageRating" .=) <$> _vviAverageRating,
7303 ("averageRating" .=) <$> _vviAverageRating,
7189 ("ratingsCount" .=) <$> _vviRatingsCount,
7304 ("ratingsCount" .=) <$> _vviRatingsCount,
7190 ("canonicalVolumeLink" .=) <$>
7305 ("canonicalVolumeLink" .=) <$>
@@ -7455,6 +7570,44 @@ instance ToJSON VolumeUserInfoFamilySharing where
7455 ("isSharingDisabledByFop" .=) <$>
7570 ("isSharingDisabledByFop" .=) <$>
7456 _vuifsIsSharingDisabledByFop])
7571 _vuifsIsSharingDisabledByFop])
7457
7572
7573+--
7574+-- /See:/ 'userSettingsNotificationMoreFromSeries' smart constructor.
7575+newtype UserSettingsNotificationMoreFromSeries = UserSettingsNotificationMoreFromSeries'
7576+ { _usnmfsOptedState :: Maybe Text
7577+ } deriving (Eq,Show,Data,Typeable,Generic)
7578+
7579+-- | Creates a value of 'UserSettingsNotificationMoreFromSeries' with the minimum fields required to make a request.
7580+--
7581+-- Use one of the following lenses to modify other fields as desired:
7582+--
7583+-- * 'usnmfsOptedState'
7584+userSettingsNotificationMoreFromSeries
7585+ :: UserSettingsNotificationMoreFromSeries
7586+userSettingsNotificationMoreFromSeries =
7587+ UserSettingsNotificationMoreFromSeries'
7588+ { _usnmfsOptedState = Nothing
7589+ }
7590+
7591+usnmfsOptedState :: Lens' UserSettingsNotificationMoreFromSeries (Maybe Text)
7592+usnmfsOptedState
7593+ = lens _usnmfsOptedState
7594+ (\ s a -> s{_usnmfsOptedState = a})
7595+
7596+instance FromJSON
7597+ UserSettingsNotificationMoreFromSeries where
7598+ parseJSON
7599+ = withObject "UserSettingsNotificationMoreFromSeries"
7600+ (\ o ->
7601+ UserSettingsNotificationMoreFromSeries' <$>
7602+ (o .:? "opted_state"))
7603+
7604+instance ToJSON
7605+ UserSettingsNotificationMoreFromSeries where
7606+ toJSON UserSettingsNotificationMoreFromSeries'{..}
7607+ = object
7608+ (catMaybes
7609+ [("opted_state" .=) <$> _usnmfsOptedState])
7610+
7458--
7611--
7459-- /See:/ 'volumeVolumeInfoIndustryIdentifiersItem' smart constructor.
7612-- /See:/ 'volumeVolumeInfoIndustryIdentifiersItem' smart constructor.
7460data VolumeVolumeInfoIndustryIdentifiersItem = VolumeVolumeInfoIndustryIdentifiersItem'
7613data VolumeVolumeInfoIndustryIdentifiersItem = VolumeVolumeInfoIndustryIdentifiersItem'
gogol-books/gen/Network/Google/Books/Types/Sum.hs+37−2
@@ -500,9 +500,12 @@ instance FromJSON MyLibraryBookshelvesAddVolumeReason where
500instance ToJSON MyLibraryBookshelvesAddVolumeReason where
500instance ToJSON MyLibraryBookshelvesAddVolumeReason where
501 toJSON = toJSONText
501 toJSON = toJSONText
502
502
503−-- | How the book was aquired
503+-- | How the book was acquired
504data VolumesMybooksListAcquireMethod
504data VolumesMybooksListAcquireMethod
505+ = FamilyShared
506+ -- ^ @FAMILY_SHARED@
507+ -- Books acquired via Family Sharing
505− = PreOrdered
508+ | PreOrdered
506 -- ^ @PREORDERED@
509 -- ^ @PREORDERED@
507 -- Preordered books (not yet available)
510 -- Preordered books (not yet available)
508 | PreviouslyRented
511 | PreviouslyRented
@@ -529,6 +532,7 @@ instance Hashable VolumesMybooksListAcquireMethod
529
532
530instance FromHttpApiData VolumesMybooksListAcquireMethod where
533instance FromHttpApiData VolumesMybooksListAcquireMethod where
531 parseQueryParam = \case
534 parseQueryParam = \case
535+ "FAMILY_SHARED" -> Right FamilyShared
532 "PREORDERED" -> Right PreOrdered
536 "PREORDERED" -> Right PreOrdered
533 "PREVIOUSLY_RENTED" -> Right PreviouslyRented
537 "PREVIOUSLY_RENTED" -> Right PreviouslyRented
534 "PUBLIC_DOMAIN" -> Right PublicDomain
538 "PUBLIC_DOMAIN" -> Right PublicDomain
@@ -540,6 +544,7 @@ instance FromHttpApiData VolumesMybooksListAcquireMethod where
540
544
541instance ToHttpApiData VolumesMybooksListAcquireMethod where
545instance ToHttpApiData VolumesMybooksListAcquireMethod where
542 toQueryParam = \case
546 toQueryParam = \case
547+ FamilyShared -> "FAMILY_SHARED"
543 PreOrdered -> "PREORDERED"
548 PreOrdered -> "PREORDERED"
544 PreviouslyRented -> "PREVIOUSLY_RENTED"
549 PreviouslyRented -> "PREVIOUSLY_RENTED"
545 PublicDomain -> "PUBLIC_DOMAIN"
550 PublicDomain -> "PUBLIC_DOMAIN"
@@ -736,3 +741,33 @@ instance FromJSON MyLibraryReadingPositionsSetPositionAction where
736
741
737instance ToJSON MyLibraryReadingPositionsSetPositionAction where
742instance ToJSON MyLibraryReadingPositionsSetPositionAction where
738 toJSON = toJSONText
743 toJSON = toJSONText
744+
745+-- | The maximum allowed maturity rating of returned recommendations. Books
746+-- with a higher maturity rating are filtered out.
747+data VolumesListMaxAllowedMaturityRating
748+ = VLMAMRMature
749+ -- ^ @mature@
750+ -- Show books which are rated mature or lower.
751+ | VLMAMRNotMature
752+ -- ^ @not-mature@
753+ -- Show books which are rated not mature.
754+ deriving (Eq, Ord, Enum, Read, Show, Data, Typeable, Generic)
755+
756+instance Hashable VolumesListMaxAllowedMaturityRating
757+
758+instance FromHttpApiData VolumesListMaxAllowedMaturityRating where
759+ parseQueryParam = \case
760+ "mature" -> Right VLMAMRMature
761+ "not-mature" -> Right VLMAMRNotMature
762+ x -> Left ("Unable to parse VolumesListMaxAllowedMaturityRating from: " <> x)
763+
764+instance ToHttpApiData VolumesListMaxAllowedMaturityRating where
765+ toQueryParam = \case
766+ VLMAMRMature -> "mature"
767+ VLMAMRNotMature -> "not-mature"
768+
769+instance FromJSON VolumesListMaxAllowedMaturityRating where
770+ parseJSON = parseJSONText "VolumesListMaxAllowedMaturityRating"
771+
772+instance ToJSON VolumesListMaxAllowedMaturityRating where
773+ toJSON = toJSONText
gogol-books/gen/Network/Google/Resource/Books/Volumes/List.hs+46−29
@@ -34,6 +34,7 @@ module Network.Google.Resource.Books.Volumes.List
34
34
35 -- * Request Lenses
35 -- * Request Lenses
36 , vlOrderBy
36 , vlOrderBy
37+ , vlMaxAllowedMaturityRating
37 , vlLibraryRestrict
38 , vlLibraryRestrict
38 , vlPartner
39 , vlPartner
39 , vlQ
40 , vlQ
@@ -59,40 +60,44 @@ type VolumesListResource =
59 "volumes" :>
60 "volumes" :>
60 QueryParam "q" Text :>
61 QueryParam "q" Text :>
61 QueryParam "orderBy" VolumesListOrderBy :>
62 QueryParam "orderBy" VolumesListOrderBy :>
62− QueryParam "libraryRestrict"
63+ QueryParam "maxAllowedMaturityRating"
63− VolumesListLibraryRestrict
64+ VolumesListMaxAllowedMaturityRating
64 :>
65 :>
66+ QueryParam "libraryRestrict"
67+ VolumesListLibraryRestrict
68+ :>
65− QueryParam "partner" Text :>
69+ QueryParam "partner" Text :>
66− QueryParam "download" VolumesListDownload :>
70+ QueryParam "download" VolumesListDownload :>
67− QueryParam "source" Text :>
71+ QueryParam "source" Text :>
68− QueryParam "projection" VolumesListProjection :>
72+ QueryParam "projection" VolumesListProjection :>
69− QueryParam "filter" VolumesListFilter :>
73+ QueryParam "filter" VolumesListFilter :>
70− QueryParam "langRestrict" Text :>
74+ QueryParam "langRestrict" Text :>
71− QueryParam "startIndex" (Textual Word32) :>
75+ QueryParam "startIndex" (Textual Word32) :>
72− QueryParam "maxResults" (Textual Word32) :>
76+ QueryParam "maxResults" (Textual Word32) :>
73− QueryParam "showPreorders" Bool :>
77+ QueryParam "showPreorders" Bool :>
74− QueryParam "printType" VolumesListPrintType
78+ QueryParam "printType" VolumesListPrintType
75− :>
79+ :>
76− QueryParam "alt" AltJSON :>
80+ QueryParam "alt" AltJSON :>
77− Get '[JSON] Volumes
81+ Get '[JSON] Volumes
78
82
79-- | Performs a book search.
83-- | Performs a book search.
80--
84--
81-- /See:/ 'volumesList' smart constructor.
85-- /See:/ 'volumesList' smart constructor.
82data VolumesList = VolumesList'
86data VolumesList = VolumesList'
83− { _vlOrderBy :: !(Maybe VolumesListOrderBy)
87+ { _vlOrderBy :: !(Maybe VolumesListOrderBy)
88+ , _vlMaxAllowedMaturityRating :: !(Maybe VolumesListMaxAllowedMaturityRating)
84− , _vlLibraryRestrict :: !(Maybe VolumesListLibraryRestrict)
89+ , _vlLibraryRestrict :: !(Maybe VolumesListLibraryRestrict)
85− , _vlPartner :: !(Maybe Text)
90+ , _vlPartner :: !(Maybe Text)
86− , _vlQ :: !Text
91+ , _vlQ :: !Text
87− , _vlDownload :: !(Maybe VolumesListDownload)
92+ , _vlDownload :: !(Maybe VolumesListDownload)
88− , _vlSource :: !(Maybe Text)
93+ , _vlSource :: !(Maybe Text)
89− , _vlProjection :: !(Maybe VolumesListProjection)
94+ , _vlProjection :: !(Maybe VolumesListProjection)
90− , _vlFilter :: !(Maybe VolumesListFilter)
95+ , _vlFilter :: !(Maybe VolumesListFilter)
91− , _vlLangRestrict :: !(Maybe Text)
96+ , _vlLangRestrict :: !(Maybe Text)
92− , _vlStartIndex :: !(Maybe (Textual Word32))
97+ , _vlStartIndex :: !(Maybe (Textual Word32))
93− , _vlMaxResults :: !(Maybe (Textual Word32))
98+ , _vlMaxResults :: !(Maybe (Textual Word32))
94− , _vlShowPreOrders :: !(Maybe Bool)
99+ , _vlShowPreOrders :: !(Maybe Bool)
95− , _vlPrintType :: !(Maybe VolumesListPrintType)
100+ , _vlPrintType :: !(Maybe VolumesListPrintType)
96 } deriving (Eq,Show,Data,Typeable,Generic)
101 } deriving (Eq,Show,Data,Typeable,Generic)
97
102
98-- | Creates a value of 'VolumesList' with the minimum fields required to make a request.
103-- | Creates a value of 'VolumesList' with the minimum fields required to make a request.
@@ -101,6 +106,8 @@ data VolumesList = VolumesList'
101--
106--
102-- * 'vlOrderBy'
107-- * 'vlOrderBy'
103--
108--
109+-- * 'vlMaxAllowedMaturityRating'
110+--
104-- * 'vlLibraryRestrict'
111-- * 'vlLibraryRestrict'
105--
112--
106-- * 'vlPartner'
113-- * 'vlPartner'
@@ -130,6 +137,7 @@ volumesList
130volumesList pVlQ_ =
137volumesList pVlQ_ =
131 VolumesList'
138 VolumesList'
132 { _vlOrderBy = Nothing
139 { _vlOrderBy = Nothing
140+ , _vlMaxAllowedMaturityRating = Nothing
133 , _vlLibraryRestrict = Nothing
141 , _vlLibraryRestrict = Nothing
134 , _vlPartner = Nothing
142 , _vlPartner = Nothing
135 , _vlQ = pVlQ_
143 , _vlQ = pVlQ_
@@ -149,6 +157,13 @@ vlOrderBy :: Lens' VolumesList (Maybe VolumesListOrderBy)
149vlOrderBy
157vlOrderBy
150 = lens _vlOrderBy (\ s a -> s{_vlOrderBy = a})
158 = lens _vlOrderBy (\ s a -> s{_vlOrderBy = a})
151
159
160+-- | The maximum allowed maturity rating of returned recommendations. Books
161+-- with a higher maturity rating are filtered out.
162+vlMaxAllowedMaturityRating :: Lens' VolumesList (Maybe VolumesListMaxAllowedMaturityRating)
163+vlMaxAllowedMaturityRating
164+ = lens _vlMaxAllowedMaturityRating
165+ (\ s a -> s{_vlMaxAllowedMaturityRating = a})
166+
152-- | Restrict search to this user\'s library.
167-- | Restrict search to this user\'s library.
153vlLibraryRestrict :: Lens' VolumesList (Maybe VolumesListLibraryRestrict)
168vlLibraryRestrict :: Lens' VolumesList (Maybe VolumesListLibraryRestrict)
154vlLibraryRestrict
169vlLibraryRestrict
@@ -216,7 +231,9 @@ instance GoogleRequest VolumesList where
216 type Scopes VolumesList =
231 type Scopes VolumesList =
217 '["https://www.googleapis.com/auth/books"]
232 '["https://www.googleapis.com/auth/books"]
218 requestClient VolumesList'{..}
233 requestClient VolumesList'{..}
219− = go (Just _vlQ) _vlOrderBy _vlLibraryRestrict
234+ = go (Just _vlQ) _vlOrderBy
235+ _vlMaxAllowedMaturityRating
236+ _vlLibraryRestrict
220 _vlPartner
237 _vlPartner
221 _vlDownload
238 _vlDownload
222 _vlSource
239 _vlSource
gogol-books/gen/Network/Google/Resource/Books/Volumes/Mybooks/List.hs+1−1
@@ -117,7 +117,7 @@ vmlProcessingState
117 . _Default
117 . _Default
118 . _Coerce
118 . _Coerce
119
119
120−-- | How the book was aquired
120+-- | How the book was acquired
121vmlAcquireMethod :: Lens' VolumesMybooksList [VolumesMybooksListAcquireMethod]
121vmlAcquireMethod :: Lens' VolumesMybooksList [VolumesMybooksListAcquireMethod]
122vmlAcquireMethod
122vmlAcquireMethod
123 = lens _vmlAcquireMethod
123 = lens _vmlAcquireMethod
gogol-books/gogol-books.cabal+1−1
@@ -14,7 +14,7 @@ cabal-version: >= 1.10
14extra-source-files: README.md
14extra-source-files: README.md
15
15
16description:
16description:
17− Lets you search for books and manage your Google Books library.
17+ Searches for books and manages your Google Books library.
18 .
18 .
19 /Warning:/ This is an experimental prototype/preview release which is still
19 /Warning:/ This is an experimental prototype/preview release which is still
20 under exploratory development and not intended for public use, caveat emptor!
20 under exploratory development and not intended for public use, caveat emptor!