diff --git a/LICENSE b/LICENSE
new file mode 100644
--- /dev/null
+++ b/LICENSE
@@ -0,0 +1,367 @@
+Mozilla Public License Version 2.0
+==================================
+
+1. Definitions
+--------------
+
+1.1. "Contributor"
+    means each individual or legal entity that creates, contributes to
+    the creation of, or owns Covered Software.
+
+1.2. "Contributor Version"
+    means the combination of the Contributions of others (if any) used
+    by a Contributor and that particular Contributor's Contribution.
+
+1.3. "Contribution"
+    means Covered Software of a particular Contributor.
+
+1.4. "Covered Software"
+    means Source Code Form to which the initial Contributor has attached
+    the notice in Exhibit A, the Executable Form of such Source Code
+    Form, and Modifications of such Source Code Form, in each case
+    including portions thereof.
+
+1.5. "Incompatible With Secondary Licenses"
+    means
+
+    (a) that the initial Contributor has attached the notice described
+        in Exhibit B to the Covered Software; or
+
+    (b) that the Covered Software was made available under the terms of
+        version 1.1 or earlier of the License, but not also under the
+        terms of a Secondary License.
+
+1.6. "Executable Form"
+    means any form of the work other than Source Code Form.
+
+1.7. "Larger Work"
+    means a work that combines Covered Software with other material, in
+    a separate file or files, that is not Covered Software.
+
+1.8. "License"
+    means this document.
+
+1.9. "Licensable"
+    means having the right to grant, to the maximum extent possible,
+    whether at the time of the initial grant or subsequently, any and
+    all of the rights conveyed by this License.
+
+1.10. "Modifications"
+    means any of the following:
+
+    (a) any file in Source Code Form that results from an addition to,
+        deletion from, or modification of the contents of Covered
+        Software; or
+
+    (b) any new file in Source Code Form that contains any Covered
+        Software.
+
+1.11. "Patent Claims" of a Contributor
+    means any patent claim(s), including without limitation, method,
+    process, and apparatus claims, in any patent Licensable by such
+    Contributor that would be infringed, but for the grant of the
+    License, by the making, using, selling, offering for sale, having
+    made, import, or transfer of either its Contributions or its
+    Contributor Version.
+
+1.12. "Secondary License"
+    means either the GNU General Public License, Version 2.0, the GNU
+    Lesser General Public License, Version 2.1, the GNU Affero General
+    Public License, Version 3.0, or any later versions of those
+    licenses.
+
+1.13. "Source Code Form"
+    means the form of the work preferred for making modifications.
+
+1.14. "You" (or "Your")
+    means an individual or a legal entity exercising rights under this
+    License. For legal entities, "You" includes any entity that
+    controls, is controlled by, or is under common control with You. For
+    purposes of this definition, "control" means (a) the power, direct
+    or indirect, to cause the direction or management of such entity,
+    whether by contract or otherwise, or (b) ownership of more than
+    fifty percent (50%) of the outstanding shares or beneficial
+    ownership of such entity.
+
+2. License Grants and Conditions
+--------------------------------
+
+2.1. Grants
+
+Each Contributor hereby grants You a world-wide, royalty-free,
+non-exclusive license:
+
+(a) under intellectual property rights (other than patent or trademark)
+    Licensable by such Contributor to use, reproduce, make available,
+    modify, display, perform, distribute, and otherwise exploit its
+    Contributions, either on an unmodified basis, with Modifications, or
+    as part of a Larger Work; and
+
+(b) under Patent Claims of such Contributor to make, use, sell, offer
+    for sale, have made, import, and otherwise transfer either its
+    Contributions or its Contributor Version.
+
+2.2. Effective Date
+
+The licenses granted in Section 2.1 with respect to any Contribution
+become effective for each Contribution on the date the Contributor first
+distributes such Contribution.
+
+2.3. Limitations on Grant Scope
+
+The licenses granted in this Section 2 are the only rights granted under
+this License. No additional rights or licenses will be implied from the
+distribution or licensing of Covered Software under this License.
+Notwithstanding Section 2.1(b) above, no patent license is granted by a
+Contributor:
+
+(a) for any code that a Contributor has removed from Covered Software;
+    or
+
+(b) for infringements caused by: (i) Your and any other third party's
+    modifications of Covered Software, or (ii) the combination of its
+    Contributions with other software (except as part of its Contributor
+    Version); or
+
+(c) under Patent Claims infringed by Covered Software in the absence of
+    its Contributions.
+
+This License does not grant any rights in the trademarks, service marks,
+or logos of any Contributor (except as may be necessary to comply with
+the notice requirements in Section 3.4).
+
+2.4. Subsequent Licenses
+
+No Contributor makes additional grants as a result of Your choice to
+distribute the Covered Software under a subsequent version of this
+License (see Section 10.2) or under the terms of a Secondary License (if
+permitted under the terms of Section 3.3).
+
+2.5. Representation
+
+Each Contributor represents that the Contributor believes its
+Contributions are its original creation(s) or it has sufficient rights
+to grant the rights to its Contributions conveyed by this License.
+
+2.6. Fair Use
+
+This License is not intended to limit any rights You have under
+applicable copyright doctrines of fair use, fair dealing, or other
+equivalents.
+
+2.7. Conditions
+
+Sections 3.1, 3.2, 3.3, and 3.4 are conditions of the licenses granted
+in Section 2.1.
+
+3. Responsibilities
+-------------------
+
+3.1. Distribution of Source Form
+
+All distribution of Covered Software in Source Code Form, including any
+Modifications that You create or to which You contribute, must be under
+the terms of this License. You must inform recipients that the Source
+Code Form of the Covered Software is governed by the terms of this
+License, and how they can obtain a copy of this License. You may not
+attempt to alter or restrict the recipients' rights in the Source Code
+Form.
+
+3.2. Distribution of Executable Form
+
+If You distribute Covered Software in Executable Form then:
+
+(a) such Covered Software must also be made available in Source Code
+    Form, as described in Section 3.1, and You must inform recipients of
+    the Executable Form how they can obtain a copy of such Source Code
+    Form by reasonable means in a timely manner, at a charge no more
+    than the cost of distribution to the recipient; and
+
+(b) You may distribute such Executable Form under the terms of this
+    License, or sublicense it under different terms, provided that the
+    license for the Executable Form does not attempt to limit or alter
+    the recipients' rights in the Source Code Form under this License.
+
+3.3. Distribution of a Larger Work
+
+You may create and distribute a Larger Work under terms of Your choice,
+provided that You also comply with the requirements of this License for
+the Covered Software. If the Larger Work is a combination of Covered
+Software with a work governed by one or more Secondary Licenses, and the
+Covered Software is not Incompatible With Secondary Licenses, this
+License permits You to additionally distribute such Covered Software
+under the terms of such Secondary License(s), so that the recipient of
+the Larger Work may, at their option, further distribute the Covered
+Software under the terms of either this License or such Secondary
+License(s).
+
+3.4. Notices
+
+You may not remove or alter the substance of any license notices
+(including copyright notices, patent notices, disclaimers of warranty,
+or limitations of liability) contained within the Source Code Form of
+the Covered Software, except that You may alter any license notices to
+the extent required to remedy known factual inaccuracies.
+
+3.5. Application of Additional Terms
+
+You may choose to offer, and to charge a fee for, warranty, support,
+indemnity or liability obligations to one or more recipients of Covered
+Software. However, You may do so only on Your own behalf, and not on
+behalf of any Contributor. You must make it absolutely clear that any
+such warranty, support, indemnity, or liability obligation is offered by
+You alone, and You hereby agree to indemnify every Contributor for any
+liability incurred by such Contributor as a result of warranty, support,
+indemnity or liability terms You offer. You may include additional
+disclaimers of warranty and limitations of liability specific to any
+jurisdiction.
+
+4. Inability to Comply Due to Statute or Regulation
+---------------------------------------------------
+
+If it is impossible for You to comply with any of the terms of this
+License with respect to some or all of the Covered Software due to
+statute, judicial order, or regulation then You must: (a) comply with
+the terms of this License to the maximum extent possible; and (b)
+describe the limitations and the code they affect. Such description must
+be placed in a text file included with all distributions of the Covered
+Software under this License. Except to the extent prohibited by statute
+or regulation, such description must be sufficiently detailed for a
+recipient of ordinary skill to be able to understand it.
+
+5. Termination
+--------------
+
+5.1. The rights granted under this License will terminate automatically
+if You fail to comply with any of its terms. However, if You become
+compliant, then the rights granted under this License from a particular
+Contributor are reinstated (a) provisionally, unless and until such
+Contributor explicitly and finally terminates Your grants, and (b) on an
+ongoing basis, if such Contributor fails to notify You of the
+non-compliance by some reasonable means prior to 60 days after You have
+come back into compliance. Moreover, Your grants from a particular
+Contributor are reinstated on an ongoing basis if such Contributor
+notifies You of the non-compliance by some reasonable means, this is the
+first time You have received notice of non-compliance with this License
+from such Contributor, and You become compliant prior to 30 days after
+Your receipt of the notice.
+
+5.2. If You initiate litigation against any entity by asserting a patent
+infringement claim (excluding declaratory judgment actions,
+counter-claims, and cross-claims) alleging that a Contributor Version
+directly or indirectly infringes any patent, then the rights granted to
+You by any and all Contributors for the Covered Software under Section
+2.1 of this License shall terminate.
+
+5.3. In the event of termination under Sections 5.1 or 5.2 above, all
+end user license agreements (excluding distributors and resellers) which
+have been validly granted by You or Your distributors under this License
+prior to termination shall survive termination.
+
+************************************************************************
+*                                                                      *
+*  6. Disclaimer of Warranty                                           *
+*  -------------------------                                           *
+*                                                                      *
+*  Covered Software is provided under this License on an "as is"       *
+*  basis, without warranty of any kind, either expressed, implied, or  *
+*  statutory, including, without limitation, warranties that the       *
+*  Covered Software is free of defects, merchantable, fit for a        *
+*  particular purpose or non-infringing. The entire risk as to the     *
+*  quality and performance of the Covered Software is with You.        *
+*  Should any Covered Software prove defective in any respect, You     *
+*  (not any Contributor) assume the cost of any necessary servicing,   *
+*  repair, or correction. This disclaimer of warranty constitutes an   *
+*  essential part of this License. No use of any Covered Software is   *
+*  authorized under this License except under this disclaimer.         *
+*                                                                      *
+************************************************************************
+
+************************************************************************
+*                                                                      *
+*  7. Limitation of Liability                                          *
+*  --------------------------                                          *
+*                                                                      *
+*  Under no circumstances and under no legal theory, whether tort      *
+*  (including negligence), contract, or otherwise, shall any           *
+*  Contributor, or anyone who distributes Covered Software as          *
+*  permitted above, be liable to You for any direct, indirect,         *
+*  special, incidental, or consequential damages of any character      *
+*  including, without limitation, damages for lost profits, loss of    *
+*  goodwill, work stoppage, computer failure or malfunction, or any    *
+*  and all other commercial damages or losses, even if such party      *
+*  shall have been informed of the possibility of such damages. This   *
+*  limitation of liability shall not apply to liability for death or   *
+*  personal injury resulting from such party's negligence to the       *
+*  extent applicable law prohibits such limitation. Some               *
+*  jurisdictions do not allow the exclusion or limitation of           *
+*  incidental or consequential damages, so this exclusion and          *
+*  limitation may not apply to You.                                    *
+*                                                                      *
+************************************************************************
+
+8. Litigation
+-------------
+
+Any litigation relating to this License may be brought only in the
+courts of a jurisdiction where the defendant maintains its principal
+place of business and such litigation shall be governed by laws of that
+jurisdiction, without reference to its conflict-of-law provisions.
+Nothing in this Section shall prevent a party's ability to bring
+cross-claims or counter-claims.
+
+9. Miscellaneous
+----------------
+
+This License represents the complete agreement concerning the subject
+matter hereof. If any provision of this License is held to be
+unenforceable, such provision shall be reformed only to the extent
+necessary to make it enforceable. Any law or regulation which provides
+that the language of a contract shall be construed against the drafter
+shall not be used to construe this License against a Contributor.
+
+10. Versions of the License
+---------------------------
+
+10.1. New Versions
+
+Mozilla Foundation is the license steward. Except as provided in Section
+10.3, no one other than the license steward has the right to modify or
+publish new versions of this License. Each version will be given a
+distinguishing version number.
+
+10.2. Effect of New Versions
+
+You may distribute the Covered Software under the terms of the version
+of the License under which You originally received the Covered Software,
+or under the terms of any subsequent version published by the license
+steward.
+
+10.3. Modified Versions
+
+If you create software not governed by this License, and you want to
+create a new license for such software, you may create and use a
+modified version of this License if you rename the license and remove
+any references to the name of the license steward (except to note that
+such modified license differs from this License).
+
+10.4. Distributing Source Code Form that is Incompatible With Secondary
+Licenses
+
+If You choose to distribute Source Code Form that is Incompatible With
+Secondary Licenses under the terms of this version of the License, the
+notice described in Exhibit B of this License must be attached.
+
+Exhibit A - Source Code Form License Notice
+-------------------------------------------
+
+  This Source Code Form is subject to the terms of the Mozilla Public
+  License, v. 2.0. If a copy of the MPL was not distributed with this
+  file, You can obtain one at http://mozilla.org/MPL/2.0/.
+
+If it is not possible or desirable to put the notice in a particular
+file, then You may include the notice in a location (such as a LICENSE
+file in a relevant directory) where a recipient would be likely to look
+for such a notice.
+
+You may add additional accurate notices of copyright ownership.
diff --git a/README.md b/README.md
new file mode 100644
--- /dev/null
+++ b/README.md
@@ -0,0 +1,28 @@
+# gogol-analyticsreporting
+
+* [Version](#version)
+* [Description](#description)
+* [Contribute](#contribute)
+* [Licence](#licence)
+
+
+## Version
+
+`0.3.0`
+
+
+## Description
+
+A client library for the Google Analytics Reporting.
+
+
+## Contribute
+
+For any problems, comments, or feedback please create an issue [here on GitHub](https://github.com/brendanhay/gogol/issues).
+
+> _Note:_ this library is an auto-generated Haskell package. Please see `gogol-gen` for more information.
+
+
+## Licence
+
+`gogol-analyticsreporting` is released under the [Mozilla Public License Version 2.0](http://www.mozilla.org/MPL/).
diff --git a/Setup.hs b/Setup.hs
new file mode 100644
--- /dev/null
+++ b/Setup.hs
@@ -0,0 +1,2 @@
+import           Distribution.Simple
+main = defaultMain
diff --git a/gen/Network/Google/AnalyticsReporting.hs b/gen/Network/Google/AnalyticsReporting.hs
new file mode 100644
--- /dev/null
+++ b/gen/Network/Google/AnalyticsReporting.hs
@@ -0,0 +1,351 @@
+{-# LANGUAGE DataKinds         #-}
+{-# LANGUAGE NoImplicitPrelude #-}
+{-# LANGUAGE TypeOperators     #-}
+
+{-# OPTIONS_GHC -fno-warn-unused-imports    #-}
+{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
+
+-- |
+-- Module      : Network.Google.AnalyticsReporting
+-- 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)
+--
+-- Accesses Analytics report data.
+--
+-- /See:/ <https://developers.google.com/analytics/devguides/reporting/core/v4/ Analytics Reporting API Reference>
+module Network.Google.AnalyticsReporting
+    (
+    -- * Service Configuration
+      analyticsReportingService
+
+    -- * OAuth Scopes
+    , analyticsScope
+    , analyticsReadOnlyScope
+
+    -- * API Declaration
+    , AnalyticsReportingAPI
+
+    -- * Resources
+
+    -- ** analyticsreporting.reports.batchGet
+    , module Network.Google.Resource.AnalyticsReporting.Reports.BatchGet
+
+    -- * Types
+
+    -- ** MetricFilter
+    , MetricFilter
+    , metricFilter
+    , mfNot
+    , mfOperator
+    , mfMetricName
+    , mfComparisonValue
+
+    -- ** MetricFilterOperator
+    , MetricFilterOperator (..)
+
+    -- ** ReportRow
+    , ReportRow
+    , reportRow
+    , rrMetrics
+    , rrDimensions
+
+    -- ** PivotHeaderEntry
+    , PivotHeaderEntry
+    , pivotHeaderEntry
+    , pheDimensionValues
+    , pheDimensionNames
+    , pheMetric
+
+    -- ** PivotValueRegion
+    , PivotValueRegion
+    , pivotValueRegion
+    , pvrValues
+
+    -- ** ReportRequest
+    , ReportRequest
+    , reportRequest
+    , rMetrics
+    , rPivots
+    , rCohortGroup
+    , rSamplingLevel
+    , rIncludeEmptyRows
+    , rDateRanges
+    , rViewId
+    , rHideTotals
+    , rHideValueRanges
+    , rMetricFilterClauses
+    , rSegments
+    , rPageToken
+    , rDimensions
+    , rDimensionFilterClauses
+    , rPageSize
+    , rOrderBys
+    , rFiltersExpression
+
+    -- ** MetricHeaderEntry
+    , MetricHeaderEntry
+    , metricHeaderEntry
+    , mheName
+    , mheType
+
+    -- ** CohortGroup
+    , CohortGroup
+    , cohortGroup
+    , cgCohorts
+    , cgLifetimeValue
+
+    -- ** SimpleSegment
+    , SimpleSegment
+    , simpleSegment
+    , ssOrFiltersForSegment
+
+    -- ** DimensionFilterClause
+    , DimensionFilterClause
+    , dimensionFilterClause
+    , dfcOperator
+    , dfcFilters
+
+    -- ** DimensionFilterClauseOperator
+    , DimensionFilterClauseOperator (..)
+
+    -- ** CohortType
+    , CohortType (..)
+
+    -- ** OrderBy
+    , OrderBy
+    , orderBy
+    , obOrderType
+    , obSortOrder
+    , obFieldName
+
+    -- ** Dimension
+    , Dimension
+    , dimension
+    , dName
+    , dHistogramBuckets
+
+    -- ** DateRangeValues
+    , DateRangeValues
+    , dateRangeValues
+    , drvPivotValueRegions
+    , drvValues
+
+    -- ** PivotHeader
+    , PivotHeader
+    , pivotHeader
+    , phTotalPivotGroupsCount
+    , phPivotHeaderEntries
+
+    -- ** MetricHeader
+    , MetricHeader
+    , metricHeader
+    , mhPivotHeaders
+    , mhMetricHeaderEntries
+
+    -- ** SegmentFilter
+    , SegmentFilter
+    , segmentFilter
+    , sfNot
+    , sfSimpleSegment
+    , sfSequenceSegment
+
+    -- ** OrderByOrderType
+    , OrderByOrderType (..)
+
+    -- ** DateRange
+    , DateRange
+    , dateRange
+    , drEndDate
+    , drStartDate
+
+    -- ** Report
+    , Report
+    , report
+    , rNextPageToken
+    , rData
+    , rColumnHeader
+
+    -- ** ReportData
+    , ReportData
+    , reportData
+    , rdMinimums
+    , rdRows
+    , rdTotals
+    , rdSamplesReadCounts
+    , rdMaximums
+    , rdDataLastRefreshed
+    , rdRowCount
+    , rdSamplingSpaceSizes
+    , rdIsDataGolden
+
+    -- ** SegmentFilterClause
+    , SegmentFilterClause
+    , segmentFilterClause
+    , sfcMetricFilter
+    , sfcNot
+    , sfcDimensionFilter
+
+    -- ** SegmentSequenceStep
+    , SegmentSequenceStep
+    , segmentSequenceStep
+    , sssMatchType
+    , sssOrFiltersForSegment
+
+    -- ** OrFiltersForSegment
+    , OrFiltersForSegment
+    , orFiltersForSegment
+    , offsSegmentFilterClauses
+
+    -- ** SegmentDefinition
+    , SegmentDefinition
+    , segmentDefinition
+    , sdSegmentFilters
+
+    -- ** OrderBySortOrder
+    , OrderBySortOrder (..)
+
+    -- ** Pivot
+    , Pivot
+    , pivot
+    , pStartGroup
+    , pMetrics
+    , pMaxGroupCount
+    , pDimensions
+    , pDimensionFilterClauses
+
+    -- ** SequenceSegment
+    , SequenceSegment
+    , sequenceSegment
+    , ssFirstStepShouldMatchFirstHit
+    , ssSegmentSequenceSteps
+
+    -- ** Metric
+    , Metric
+    , metric
+    , mFormattingType
+    , mAlias
+    , mExpression
+
+    -- ** SegmentMetricFilterOperator
+    , SegmentMetricFilterOperator (..)
+
+    -- ** MetricHeaderEntryType
+    , MetricHeaderEntryType (..)
+
+    -- ** SegmentMetricFilter
+    , SegmentMetricFilter
+    , segmentMetricFilter
+    , smfOperator
+    , smfMetricName
+    , smfMaxComparisonValue
+    , smfScope
+    , smfComparisonValue
+
+    -- ** ReportRequestSamplingLevel
+    , ReportRequestSamplingLevel (..)
+
+    -- ** Xgafv
+    , Xgafv (..)
+
+    -- ** GetReportsRequest
+    , GetReportsRequest
+    , getReportsRequest
+    , grrUseResourceQuotas
+    , grrReportRequests
+
+    -- ** SegmentSequenceStepMatchType
+    , SegmentSequenceStepMatchType (..)
+
+    -- ** Cohort
+    , Cohort
+    , cohort
+    , cDateRange
+    , cName
+    , cType
+
+    -- ** SegmentMetricFilterScope
+    , SegmentMetricFilterScope (..)
+
+    -- ** DimensionFilter
+    , DimensionFilter
+    , dimensionFilter
+    , dfNot
+    , dfOperator
+    , dfExpressions
+    , dfDimensionName
+    , dfCaseSensitive
+
+    -- ** GetReportsResponse
+    , GetReportsResponse
+    , getReportsResponse
+    , grrReports
+    , grrResourceQuotasRemaining
+    , grrQueryCost
+
+    -- ** DimensionFilterOperator
+    , DimensionFilterOperator (..)
+
+    -- ** MetricFormattingType
+    , MetricFormattingType (..)
+
+    -- ** Segment
+    , Segment
+    , segment
+    , sDynamicSegment
+    , sSegmentId
+
+    -- ** SegmentDimensionFilterOperator
+    , SegmentDimensionFilterOperator (..)
+
+    -- ** ResourceQuotasRemaining
+    , ResourceQuotasRemaining
+    , resourceQuotasRemaining
+    , rqrHourlyQuotaTokensRemaining
+    , rqrDailyQuotaTokensRemaining
+
+    -- ** SegmentDimensionFilter
+    , SegmentDimensionFilter
+    , segmentDimensionFilter
+    , sdfOperator
+    , sdfMinComparisonValue
+    , sdfMaxComparisonValue
+    , sdfExpressions
+    , sdfDimensionName
+    , sdfCaseSensitive
+
+    -- ** DynamicSegment
+    , DynamicSegment
+    , dynamicSegment
+    , dsUserSegment
+    , dsName
+    , dsSessionSegment
+
+    -- ** MetricFilterClause
+    , MetricFilterClause
+    , metricFilterClause
+    , mfcOperator
+    , mfcFilters
+
+    -- ** MetricFilterClauseOperator
+    , MetricFilterClauseOperator (..)
+
+    -- ** ColumnHeader
+    , ColumnHeader
+    , columnHeader
+    , chMetricHeader
+    , chDimensions
+    ) where
+
+import           Network.Google.AnalyticsReporting.Types
+import           Network.Google.Prelude
+import           Network.Google.Resource.AnalyticsReporting.Reports.BatchGet
+
+{- $resources
+TODO
+-}
+
+-- | Represents the entirety of the methods and resources available for the Analytics Reporting API service.
+type AnalyticsReportingAPI = ReportsBatchGetResource
diff --git a/gen/Network/Google/AnalyticsReporting/Types.hs b/gen/Network/Google/AnalyticsReporting/Types.hs
new file mode 100644
--- /dev/null
+++ b/gen/Network/Google/AnalyticsReporting/Types.hs
@@ -0,0 +1,346 @@
+{-# LANGUAGE DataKinds          #-}
+{-# LANGUAGE DeriveDataTypeable #-}
+{-# LANGUAGE DeriveGeneric      #-}
+{-# LANGUAGE NoImplicitPrelude  #-}
+{-# LANGUAGE OverloadedStrings  #-}
+
+{-# OPTIONS_GHC -fno-warn-unused-imports #-}
+
+-- |
+-- Module      : Network.Google.AnalyticsReporting.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.AnalyticsReporting.Types
+    (
+    -- * Service Configuration
+      analyticsReportingService
+
+    -- * OAuth Scopes
+    , analyticsScope
+    , analyticsReadOnlyScope
+
+    -- * MetricFilter
+    , MetricFilter
+    , metricFilter
+    , mfNot
+    , mfOperator
+    , mfMetricName
+    , mfComparisonValue
+
+    -- * MetricFilterOperator
+    , MetricFilterOperator (..)
+
+    -- * ReportRow
+    , ReportRow
+    , reportRow
+    , rrMetrics
+    , rrDimensions
+
+    -- * PivotHeaderEntry
+    , PivotHeaderEntry
+    , pivotHeaderEntry
+    , pheDimensionValues
+    , pheDimensionNames
+    , pheMetric
+
+    -- * PivotValueRegion
+    , PivotValueRegion
+    , pivotValueRegion
+    , pvrValues
+
+    -- * ReportRequest
+    , ReportRequest
+    , reportRequest
+    , rMetrics
+    , rPivots
+    , rCohortGroup
+    , rSamplingLevel
+    , rIncludeEmptyRows
+    , rDateRanges
+    , rViewId
+    , rHideTotals
+    , rHideValueRanges
+    , rMetricFilterClauses
+    , rSegments
+    , rPageToken
+    , rDimensions
+    , rDimensionFilterClauses
+    , rPageSize
+    , rOrderBys
+    , rFiltersExpression
+
+    -- * MetricHeaderEntry
+    , MetricHeaderEntry
+    , metricHeaderEntry
+    , mheName
+    , mheType
+
+    -- * CohortGroup
+    , CohortGroup
+    , cohortGroup
+    , cgCohorts
+    , cgLifetimeValue
+
+    -- * SimpleSegment
+    , SimpleSegment
+    , simpleSegment
+    , ssOrFiltersForSegment
+
+    -- * DimensionFilterClause
+    , DimensionFilterClause
+    , dimensionFilterClause
+    , dfcOperator
+    , dfcFilters
+
+    -- * DimensionFilterClauseOperator
+    , DimensionFilterClauseOperator (..)
+
+    -- * CohortType
+    , CohortType (..)
+
+    -- * OrderBy
+    , OrderBy
+    , orderBy
+    , obOrderType
+    , obSortOrder
+    , obFieldName
+
+    -- * Dimension
+    , Dimension
+    , dimension
+    , dName
+    , dHistogramBuckets
+
+    -- * DateRangeValues
+    , DateRangeValues
+    , dateRangeValues
+    , drvPivotValueRegions
+    , drvValues
+
+    -- * PivotHeader
+    , PivotHeader
+    , pivotHeader
+    , phTotalPivotGroupsCount
+    , phPivotHeaderEntries
+
+    -- * MetricHeader
+    , MetricHeader
+    , metricHeader
+    , mhPivotHeaders
+    , mhMetricHeaderEntries
+
+    -- * SegmentFilter
+    , SegmentFilter
+    , segmentFilter
+    , sfNot
+    , sfSimpleSegment
+    , sfSequenceSegment
+
+    -- * OrderByOrderType
+    , OrderByOrderType (..)
+
+    -- * DateRange
+    , DateRange
+    , dateRange
+    , drEndDate
+    , drStartDate
+
+    -- * Report
+    , Report
+    , report
+    , rNextPageToken
+    , rData
+    , rColumnHeader
+
+    -- * ReportData
+    , ReportData
+    , reportData
+    , rdMinimums
+    , rdRows
+    , rdTotals
+    , rdSamplesReadCounts
+    , rdMaximums
+    , rdDataLastRefreshed
+    , rdRowCount
+    , rdSamplingSpaceSizes
+    , rdIsDataGolden
+
+    -- * SegmentFilterClause
+    , SegmentFilterClause
+    , segmentFilterClause
+    , sfcMetricFilter
+    , sfcNot
+    , sfcDimensionFilter
+
+    -- * SegmentSequenceStep
+    , SegmentSequenceStep
+    , segmentSequenceStep
+    , sssMatchType
+    , sssOrFiltersForSegment
+
+    -- * OrFiltersForSegment
+    , OrFiltersForSegment
+    , orFiltersForSegment
+    , offsSegmentFilterClauses
+
+    -- * SegmentDefinition
+    , SegmentDefinition
+    , segmentDefinition
+    , sdSegmentFilters
+
+    -- * OrderBySortOrder
+    , OrderBySortOrder (..)
+
+    -- * Pivot
+    , Pivot
+    , pivot
+    , pStartGroup
+    , pMetrics
+    , pMaxGroupCount
+    , pDimensions
+    , pDimensionFilterClauses
+
+    -- * SequenceSegment
+    , SequenceSegment
+    , sequenceSegment
+    , ssFirstStepShouldMatchFirstHit
+    , ssSegmentSequenceSteps
+
+    -- * Metric
+    , Metric
+    , metric
+    , mFormattingType
+    , mAlias
+    , mExpression
+
+    -- * SegmentMetricFilterOperator
+    , SegmentMetricFilterOperator (..)
+
+    -- * MetricHeaderEntryType
+    , MetricHeaderEntryType (..)
+
+    -- * SegmentMetricFilter
+    , SegmentMetricFilter
+    , segmentMetricFilter
+    , smfOperator
+    , smfMetricName
+    , smfMaxComparisonValue
+    , smfScope
+    , smfComparisonValue
+
+    -- * ReportRequestSamplingLevel
+    , ReportRequestSamplingLevel (..)
+
+    -- * Xgafv
+    , Xgafv (..)
+
+    -- * GetReportsRequest
+    , GetReportsRequest
+    , getReportsRequest
+    , grrUseResourceQuotas
+    , grrReportRequests
+
+    -- * SegmentSequenceStepMatchType
+    , SegmentSequenceStepMatchType (..)
+
+    -- * Cohort
+    , Cohort
+    , cohort
+    , cDateRange
+    , cName
+    , cType
+
+    -- * SegmentMetricFilterScope
+    , SegmentMetricFilterScope (..)
+
+    -- * DimensionFilter
+    , DimensionFilter
+    , dimensionFilter
+    , dfNot
+    , dfOperator
+    , dfExpressions
+    , dfDimensionName
+    , dfCaseSensitive
+
+    -- * GetReportsResponse
+    , GetReportsResponse
+    , getReportsResponse
+    , grrReports
+    , grrResourceQuotasRemaining
+    , grrQueryCost
+
+    -- * DimensionFilterOperator
+    , DimensionFilterOperator (..)
+
+    -- * MetricFormattingType
+    , MetricFormattingType (..)
+
+    -- * Segment
+    , Segment
+    , segment
+    , sDynamicSegment
+    , sSegmentId
+
+    -- * SegmentDimensionFilterOperator
+    , SegmentDimensionFilterOperator (..)
+
+    -- * ResourceQuotasRemaining
+    , ResourceQuotasRemaining
+    , resourceQuotasRemaining
+    , rqrHourlyQuotaTokensRemaining
+    , rqrDailyQuotaTokensRemaining
+
+    -- * SegmentDimensionFilter
+    , SegmentDimensionFilter
+    , segmentDimensionFilter
+    , sdfOperator
+    , sdfMinComparisonValue
+    , sdfMaxComparisonValue
+    , sdfExpressions
+    , sdfDimensionName
+    , sdfCaseSensitive
+
+    -- * DynamicSegment
+    , DynamicSegment
+    , dynamicSegment
+    , dsUserSegment
+    , dsName
+    , dsSessionSegment
+
+    -- * MetricFilterClause
+    , MetricFilterClause
+    , metricFilterClause
+    , mfcOperator
+    , mfcFilters
+
+    -- * MetricFilterClauseOperator
+    , MetricFilterClauseOperator (..)
+
+    -- * ColumnHeader
+    , ColumnHeader
+    , columnHeader
+    , chMetricHeader
+    , chDimensions
+    ) where
+
+import           Network.Google.AnalyticsReporting.Types.Product
+import           Network.Google.AnalyticsReporting.Types.Sum
+import           Network.Google.Prelude
+
+-- | Default request referring to version 'v4' of the Analytics Reporting API. This contains the host and root path used as a starting point for constructing service requests.
+analyticsReportingService :: ServiceConfig
+analyticsReportingService
+  = defaultService (ServiceId "analyticsreporting:v4")
+      "analyticsreporting.googleapis.com"
+
+-- | View and manage your Google Analytics data
+analyticsScope :: Proxy '["https://www.googleapis.com/auth/analytics"]
+analyticsScope = Proxy;
+
+-- | View your Google Analytics data
+analyticsReadOnlyScope :: Proxy '["https://www.googleapis.com/auth/analytics.readonly"]
+analyticsReadOnlyScope = Proxy;
diff --git a/gen/Network/Google/AnalyticsReporting/Types/Product.hs b/gen/Network/Google/AnalyticsReporting/Types/Product.hs
new file mode 100644
--- /dev/null
+++ b/gen/Network/Google/AnalyticsReporting/Types/Product.hs
@@ -0,0 +1,2582 @@
+{-# 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.AnalyticsReporting.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.AnalyticsReporting.Types.Product where
+
+import           Network.Google.AnalyticsReporting.Types.Sum
+import           Network.Google.Prelude
+
+-- | MetricFilter specifies the filter on a metric.
+--
+-- /See:/ 'metricFilter' smart constructor.
+data MetricFilter = MetricFilter'
+    { _mfNot             :: !(Maybe Bool)
+    , _mfOperator        :: !(Maybe MetricFilterOperator)
+    , _mfMetricName      :: !(Maybe Text)
+    , _mfComparisonValue :: !(Maybe Text)
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'MetricFilter' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'mfNot'
+--
+-- * 'mfOperator'
+--
+-- * 'mfMetricName'
+--
+-- * 'mfComparisonValue'
+metricFilter
+    :: MetricFilter
+metricFilter =
+    MetricFilter'
+    { _mfNot = Nothing
+    , _mfOperator = Nothing
+    , _mfMetricName = Nothing
+    , _mfComparisonValue = Nothing
+    }
+
+-- | Logical \`NOT\` operator. If this boolean is set to true, then the
+-- matching metric values will be excluded in the report. The default is
+-- false.
+mfNot :: Lens' MetricFilter (Maybe Bool)
+mfNot = lens _mfNot (\ s a -> s{_mfNot = a})
+
+-- | Is the metric \`EQUAL\`, \`LESS_THAN\` or \`GREATER_THAN\` the
+-- comparisonValue, the default is \`EQUAL\`. If the operator is
+-- \`IS_MISSING\`, checks if the metric is missing and would ignore the
+-- comparisonValue.
+mfOperator :: Lens' MetricFilter (Maybe MetricFilterOperator)
+mfOperator
+  = lens _mfOperator (\ s a -> s{_mfOperator = a})
+
+-- | The metric that will be filtered on. A metricFilter must contain a
+-- metric name. A metric name can be an alias earlier defined as a metric
+-- or it can also be a metric expression.
+mfMetricName :: Lens' MetricFilter (Maybe Text)
+mfMetricName
+  = lens _mfMetricName (\ s a -> s{_mfMetricName = a})
+
+-- | The value to compare against.
+mfComparisonValue :: Lens' MetricFilter (Maybe Text)
+mfComparisonValue
+  = lens _mfComparisonValue
+      (\ s a -> s{_mfComparisonValue = a})
+
+instance FromJSON MetricFilter where
+        parseJSON
+          = withObject "MetricFilter"
+              (\ o ->
+                 MetricFilter' <$>
+                   (o .:? "not") <*> (o .:? "operator") <*>
+                     (o .:? "metricName")
+                     <*> (o .:? "comparisonValue"))
+
+instance ToJSON MetricFilter where
+        toJSON MetricFilter'{..}
+          = object
+              (catMaybes
+                 [("not" .=) <$> _mfNot,
+                  ("operator" .=) <$> _mfOperator,
+                  ("metricName" .=) <$> _mfMetricName,
+                  ("comparisonValue" .=) <$> _mfComparisonValue])
+
+-- | A row in the report.
+--
+-- /See:/ 'reportRow' smart constructor.
+data ReportRow = ReportRow'
+    { _rrMetrics    :: !(Maybe [DateRangeValues])
+    , _rrDimensions :: !(Maybe [Text])
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'ReportRow' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'rrMetrics'
+--
+-- * 'rrDimensions'
+reportRow
+    :: ReportRow
+reportRow =
+    ReportRow'
+    { _rrMetrics = Nothing
+    , _rrDimensions = Nothing
+    }
+
+-- | List of metrics for each requested DateRange.
+rrMetrics :: Lens' ReportRow [DateRangeValues]
+rrMetrics
+  = lens _rrMetrics (\ s a -> s{_rrMetrics = a}) .
+      _Default
+      . _Coerce
+
+-- | List of requested dimensions.
+rrDimensions :: Lens' ReportRow [Text]
+rrDimensions
+  = lens _rrDimensions (\ s a -> s{_rrDimensions = a})
+      . _Default
+      . _Coerce
+
+instance FromJSON ReportRow where
+        parseJSON
+          = withObject "ReportRow"
+              (\ o ->
+                 ReportRow' <$>
+                   (o .:? "metrics" .!= mempty) <*>
+                     (o .:? "dimensions" .!= mempty))
+
+instance ToJSON ReportRow where
+        toJSON ReportRow'{..}
+          = object
+              (catMaybes
+                 [("metrics" .=) <$> _rrMetrics,
+                  ("dimensions" .=) <$> _rrDimensions])
+
+-- | The headers for the each of the metric column corresponding to the
+-- metrics requested in the pivots section of the response.
+--
+-- /See:/ 'pivotHeaderEntry' smart constructor.
+data PivotHeaderEntry = PivotHeaderEntry'
+    { _pheDimensionValues :: !(Maybe [Text])
+    , _pheDimensionNames  :: !(Maybe [Text])
+    , _pheMetric          :: !(Maybe MetricHeaderEntry)
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'PivotHeaderEntry' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'pheDimensionValues'
+--
+-- * 'pheDimensionNames'
+--
+-- * 'pheMetric'
+pivotHeaderEntry
+    :: PivotHeaderEntry
+pivotHeaderEntry =
+    PivotHeaderEntry'
+    { _pheDimensionValues = Nothing
+    , _pheDimensionNames = Nothing
+    , _pheMetric = Nothing
+    }
+
+-- | The values for the dimensions in the pivot.
+pheDimensionValues :: Lens' PivotHeaderEntry [Text]
+pheDimensionValues
+  = lens _pheDimensionValues
+      (\ s a -> s{_pheDimensionValues = a})
+      . _Default
+      . _Coerce
+
+-- | The name of the dimensions in the pivot response.
+pheDimensionNames :: Lens' PivotHeaderEntry [Text]
+pheDimensionNames
+  = lens _pheDimensionNames
+      (\ s a -> s{_pheDimensionNames = a})
+      . _Default
+      . _Coerce
+
+-- | The metric header for the metric in the pivot.
+pheMetric :: Lens' PivotHeaderEntry (Maybe MetricHeaderEntry)
+pheMetric
+  = lens _pheMetric (\ s a -> s{_pheMetric = a})
+
+instance FromJSON PivotHeaderEntry where
+        parseJSON
+          = withObject "PivotHeaderEntry"
+              (\ o ->
+                 PivotHeaderEntry' <$>
+                   (o .:? "dimensionValues" .!= mempty) <*>
+                     (o .:? "dimensionNames" .!= mempty)
+                     <*> (o .:? "metric"))
+
+instance ToJSON PivotHeaderEntry where
+        toJSON PivotHeaderEntry'{..}
+          = object
+              (catMaybes
+                 [("dimensionValues" .=) <$> _pheDimensionValues,
+                  ("dimensionNames" .=) <$> _pheDimensionNames,
+                  ("metric" .=) <$> _pheMetric])
+
+-- | The metric values in the pivot region.
+--
+-- /See:/ 'pivotValueRegion' smart constructor.
+newtype PivotValueRegion = PivotValueRegion'
+    { _pvrValues :: Maybe [Text]
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'PivotValueRegion' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'pvrValues'
+pivotValueRegion
+    :: PivotValueRegion
+pivotValueRegion =
+    PivotValueRegion'
+    { _pvrValues = Nothing
+    }
+
+-- | The values of the metrics in each of the pivot regions.
+pvrValues :: Lens' PivotValueRegion [Text]
+pvrValues
+  = lens _pvrValues (\ s a -> s{_pvrValues = a}) .
+      _Default
+      . _Coerce
+
+instance FromJSON PivotValueRegion where
+        parseJSON
+          = withObject "PivotValueRegion"
+              (\ o ->
+                 PivotValueRegion' <$> (o .:? "values" .!= mempty))
+
+instance ToJSON PivotValueRegion where
+        toJSON PivotValueRegion'{..}
+          = object (catMaybes [("values" .=) <$> _pvrValues])
+
+-- | The main request class which specifies the Reporting API request.
+--
+-- /See:/ 'reportRequest' smart constructor.
+data ReportRequest = ReportRequest'
+    { _rMetrics                :: !(Maybe [Metric])
+    , _rPivots                 :: !(Maybe [Pivot])
+    , _rCohortGroup            :: !(Maybe CohortGroup)
+    , _rSamplingLevel          :: !(Maybe ReportRequestSamplingLevel)
+    , _rIncludeEmptyRows       :: !(Maybe Bool)
+    , _rDateRanges             :: !(Maybe [DateRange])
+    , _rViewId                 :: !(Maybe Text)
+    , _rHideTotals             :: !(Maybe Bool)
+    , _rHideValueRanges        :: !(Maybe Bool)
+    , _rMetricFilterClauses    :: !(Maybe [MetricFilterClause])
+    , _rSegments               :: !(Maybe [Segment])
+    , _rPageToken              :: !(Maybe Text)
+    , _rDimensions             :: !(Maybe [Dimension])
+    , _rDimensionFilterClauses :: !(Maybe [DimensionFilterClause])
+    , _rPageSize               :: !(Maybe (Textual Int32))
+    , _rOrderBys               :: !(Maybe [OrderBy])
+    , _rFiltersExpression      :: !(Maybe Text)
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'ReportRequest' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'rMetrics'
+--
+-- * 'rPivots'
+--
+-- * 'rCohortGroup'
+--
+-- * 'rSamplingLevel'
+--
+-- * 'rIncludeEmptyRows'
+--
+-- * 'rDateRanges'
+--
+-- * 'rViewId'
+--
+-- * 'rHideTotals'
+--
+-- * 'rHideValueRanges'
+--
+-- * 'rMetricFilterClauses'
+--
+-- * 'rSegments'
+--
+-- * 'rPageToken'
+--
+-- * 'rDimensions'
+--
+-- * 'rDimensionFilterClauses'
+--
+-- * 'rPageSize'
+--
+-- * 'rOrderBys'
+--
+-- * 'rFiltersExpression'
+reportRequest
+    :: ReportRequest
+reportRequest =
+    ReportRequest'
+    { _rMetrics = Nothing
+    , _rPivots = Nothing
+    , _rCohortGroup = Nothing
+    , _rSamplingLevel = Nothing
+    , _rIncludeEmptyRows = Nothing
+    , _rDateRanges = Nothing
+    , _rViewId = Nothing
+    , _rHideTotals = Nothing
+    , _rHideValueRanges = Nothing
+    , _rMetricFilterClauses = Nothing
+    , _rSegments = Nothing
+    , _rPageToken = Nothing
+    , _rDimensions = Nothing
+    , _rDimensionFilterClauses = Nothing
+    , _rPageSize = Nothing
+    , _rOrderBys = Nothing
+    , _rFiltersExpression = Nothing
+    }
+
+-- | The metrics requested. Requests must specify at least one metric.
+-- Requests can have a total of 10 metrics.
+rMetrics :: Lens' ReportRequest [Metric]
+rMetrics
+  = lens _rMetrics (\ s a -> s{_rMetrics = a}) .
+      _Default
+      . _Coerce
+
+-- | The pivot definitions. Requests can have a maximum of 2 pivots.
+rPivots :: Lens' ReportRequest [Pivot]
+rPivots
+  = lens _rPivots (\ s a -> s{_rPivots = a}) . _Default
+      . _Coerce
+
+-- | Cohort group associated with this request. If there is a cohort group in
+-- the request the \`ga:cohort\` dimension must be present. Every
+-- [ReportRequest](#ReportRequest) within a \`batchGet\` method must
+-- contain the same \`cohortGroup\` definition.
+rCohortGroup :: Lens' ReportRequest (Maybe CohortGroup)
+rCohortGroup
+  = lens _rCohortGroup (\ s a -> s{_rCohortGroup = a})
+
+-- | The desired report
+-- [sample](https:\/\/support.google.com\/analytics\/answer\/2637192) size.
+-- If the the \`samplingLevel\` field is unspecified the \`DEFAULT\`
+-- sampling level is used. Every [ReportRequest](#ReportRequest) within a
+-- \`batchGet\` method must contain the same \`samplingLevel\` definition.
+-- See [developer
+-- guide](\/analytics\/devguides\/reporting\/core\/v4\/basics#sampling) for
+-- details.
+rSamplingLevel :: Lens' ReportRequest (Maybe ReportRequestSamplingLevel)
+rSamplingLevel
+  = lens _rSamplingLevel
+      (\ s a -> s{_rSamplingLevel = a})
+
+-- | If set to false, the response does not include rows if all the retrieved
+-- metrics are equal to zero. The default is false which will exclude these
+-- rows.
+rIncludeEmptyRows :: Lens' ReportRequest (Maybe Bool)
+rIncludeEmptyRows
+  = lens _rIncludeEmptyRows
+      (\ s a -> s{_rIncludeEmptyRows = a})
+
+-- | Date ranges in the request. The request can have a maximum of 2 date
+-- ranges. The response will contain a set of metric values for each
+-- combination of the dimensions for each date range in the request. So, if
+-- there are two date ranges, there will be two set of metric values, one
+-- for the original date range and one for the second date range. The
+-- \`reportRequest.dateRanges\` field should not be specified for cohorts
+-- or Lifetime value requests. If a date range is not provided, the default
+-- date range is (startDate: current date - 7 days, endDate: current date -
+-- 1 day). Every [ReportRequest](#ReportRequest) within a \`batchGet\`
+-- method must contain the same \`dateRanges\` definition.
+rDateRanges :: Lens' ReportRequest [DateRange]
+rDateRanges
+  = lens _rDateRanges (\ s a -> s{_rDateRanges = a}) .
+      _Default
+      . _Coerce
+
+-- | The Analytics [view
+-- ID](https:\/\/support.google.com\/analytics\/answer\/1009618) from which
+-- to retrieve data. Every [ReportRequest](#ReportRequest) within a
+-- \`batchGet\` method must contain the same \`viewId\`.
+rViewId :: Lens' ReportRequest (Maybe Text)
+rViewId = lens _rViewId (\ s a -> s{_rViewId = a})
+
+-- | If set to true, hides the total of all metrics for all the matching
+-- rows, for every date range. The default false and will return the
+-- totals.
+rHideTotals :: Lens' ReportRequest (Maybe Bool)
+rHideTotals
+  = lens _rHideTotals (\ s a -> s{_rHideTotals = a})
+
+-- | If set to true, hides the minimum and maximum across all matching rows.
+-- The default is false and the value ranges are returned.
+rHideValueRanges :: Lens' ReportRequest (Maybe Bool)
+rHideValueRanges
+  = lens _rHideValueRanges
+      (\ s a -> s{_rHideValueRanges = a})
+
+-- | The metric filter clauses. They are logically combined with the \`AND\`
+-- operator. Metric filters look at only the first date range and not the
+-- comparing date range. Note that filtering on metrics occurs after the
+-- metrics are aggregated.
+rMetricFilterClauses :: Lens' ReportRequest [MetricFilterClause]
+rMetricFilterClauses
+  = lens _rMetricFilterClauses
+      (\ s a -> s{_rMetricFilterClauses = a})
+      . _Default
+      . _Coerce
+
+-- | Segment the data returned for the request. A segment definition helps
+-- look at a subset of the segment request. A request can contain up to
+-- four segments. Every [ReportRequest](#ReportRequest) within a
+-- \`batchGet\` method must contain the same \`segments\` definition.
+-- Requests with segments must have the \`ga:segment\` dimension.
+rSegments :: Lens' ReportRequest [Segment]
+rSegments
+  = lens _rSegments (\ s a -> s{_rSegments = a}) .
+      _Default
+      . _Coerce
+
+-- | A continuation token to get the next page of the results. Adding this to
+-- the request will return the rows after the pageToken. The pageToken
+-- should be the value returned in the nextPageToken parameter in the
+-- response to the GetReports request.
+rPageToken :: Lens' ReportRequest (Maybe Text)
+rPageToken
+  = lens _rPageToken (\ s a -> s{_rPageToken = a})
+
+-- | The dimensions requested. Requests can have a total of 7 dimensions.
+rDimensions :: Lens' ReportRequest [Dimension]
+rDimensions
+  = lens _rDimensions (\ s a -> s{_rDimensions = a}) .
+      _Default
+      . _Coerce
+
+-- | The dimension filter clauses for filtering Dimension Values. They are
+-- logically combined with the \`AND\` operator. Note that filtering occurs
+-- before any dimensions are aggregated, so that the returned metrics
+-- represent the total for only the relevant dimensions.
+rDimensionFilterClauses :: Lens' ReportRequest [DimensionFilterClause]
+rDimensionFilterClauses
+  = lens _rDimensionFilterClauses
+      (\ s a -> s{_rDimensionFilterClauses = a})
+      . _Default
+      . _Coerce
+
+-- | Page size is for paging and specifies the maximum number of returned
+-- rows. Page size should be >= 0. A query returns the default of 1,000
+-- rows. The Analytics Core Reporting API returns a maximum of 100,000 rows
+-- per request, no matter how many you ask for. It can also return fewer
+-- rows than requested, if there aren\'t as many dimension segments as you
+-- expect. For instance, there are fewer than 300 possible values for
+-- \`ga:country\`, so when segmenting only by country, you can\'t get more
+-- than 300 rows, even if you set \`pageSize\` to a higher value.
+rPageSize :: Lens' ReportRequest (Maybe Int32)
+rPageSize
+  = lens _rPageSize (\ s a -> s{_rPageSize = a}) .
+      mapping _Coerce
+
+-- | Sort order on output rows. To compare two rows, the elements of the
+-- following are applied in order until a difference is found. All date
+-- ranges in the output get the same row order.
+rOrderBys :: Lens' ReportRequest [OrderBy]
+rOrderBys
+  = lens _rOrderBys (\ s a -> s{_rOrderBys = a}) .
+      _Default
+      . _Coerce
+
+-- | Dimension or metric filters that restrict the data returned for your
+-- request. To use the \`filtersExpression\`, supply a dimension or metric
+-- on which to filter, followed by the filter expression. For example, the
+-- following expression selects \`ga:browser\` dimension which starts with
+-- Firefox; \`ga:browser=~^Firefox\`. For more information on dimensions
+-- and metric filters, see [Filters
+-- reference](https:\/\/developers.google.com\/analytics\/devguides\/reporting\/core\/v3\/reference#filters).
+rFiltersExpression :: Lens' ReportRequest (Maybe Text)
+rFiltersExpression
+  = lens _rFiltersExpression
+      (\ s a -> s{_rFiltersExpression = a})
+
+instance FromJSON ReportRequest where
+        parseJSON
+          = withObject "ReportRequest"
+              (\ o ->
+                 ReportRequest' <$>
+                   (o .:? "metrics" .!= mempty) <*>
+                     (o .:? "pivots" .!= mempty)
+                     <*> (o .:? "cohortGroup")
+                     <*> (o .:? "samplingLevel")
+                     <*> (o .:? "includeEmptyRows")
+                     <*> (o .:? "dateRanges" .!= mempty)
+                     <*> (o .:? "viewId")
+                     <*> (o .:? "hideTotals")
+                     <*> (o .:? "hideValueRanges")
+                     <*> (o .:? "metricFilterClauses" .!= mempty)
+                     <*> (o .:? "segments" .!= mempty)
+                     <*> (o .:? "pageToken")
+                     <*> (o .:? "dimensions" .!= mempty)
+                     <*> (o .:? "dimensionFilterClauses" .!= mempty)
+                     <*> (o .:? "pageSize")
+                     <*> (o .:? "orderBys" .!= mempty)
+                     <*> (o .:? "filtersExpression"))
+
+instance ToJSON ReportRequest where
+        toJSON ReportRequest'{..}
+          = object
+              (catMaybes
+                 [("metrics" .=) <$> _rMetrics,
+                  ("pivots" .=) <$> _rPivots,
+                  ("cohortGroup" .=) <$> _rCohortGroup,
+                  ("samplingLevel" .=) <$> _rSamplingLevel,
+                  ("includeEmptyRows" .=) <$> _rIncludeEmptyRows,
+                  ("dateRanges" .=) <$> _rDateRanges,
+                  ("viewId" .=) <$> _rViewId,
+                  ("hideTotals" .=) <$> _rHideTotals,
+                  ("hideValueRanges" .=) <$> _rHideValueRanges,
+                  ("metricFilterClauses" .=) <$> _rMetricFilterClauses,
+                  ("segments" .=) <$> _rSegments,
+                  ("pageToken" .=) <$> _rPageToken,
+                  ("dimensions" .=) <$> _rDimensions,
+                  ("dimensionFilterClauses" .=) <$>
+                    _rDimensionFilterClauses,
+                  ("pageSize" .=) <$> _rPageSize,
+                  ("orderBys" .=) <$> _rOrderBys,
+                  ("filtersExpression" .=) <$> _rFiltersExpression])
+
+-- | Header for the metrics.
+--
+-- /See:/ 'metricHeaderEntry' smart constructor.
+data MetricHeaderEntry = MetricHeaderEntry'
+    { _mheName :: !(Maybe Text)
+    , _mheType :: !(Maybe MetricHeaderEntryType)
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'MetricHeaderEntry' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'mheName'
+--
+-- * 'mheType'
+metricHeaderEntry
+    :: MetricHeaderEntry
+metricHeaderEntry =
+    MetricHeaderEntry'
+    { _mheName = Nothing
+    , _mheType = Nothing
+    }
+
+-- | The name of the header.
+mheName :: Lens' MetricHeaderEntry (Maybe Text)
+mheName = lens _mheName (\ s a -> s{_mheName = a})
+
+-- | The type of the metric, for example \`INTEGER\`.
+mheType :: Lens' MetricHeaderEntry (Maybe MetricHeaderEntryType)
+mheType = lens _mheType (\ s a -> s{_mheType = a})
+
+instance FromJSON MetricHeaderEntry where
+        parseJSON
+          = withObject "MetricHeaderEntry"
+              (\ o ->
+                 MetricHeaderEntry' <$>
+                   (o .:? "name") <*> (o .:? "type"))
+
+instance ToJSON MetricHeaderEntry where
+        toJSON MetricHeaderEntry'{..}
+          = object
+              (catMaybes
+                 [("name" .=) <$> _mheName, ("type" .=) <$> _mheType])
+
+-- | Defines a cohort group. For example: \"cohortGroup\": { \"cohorts\": [{
+-- \"name\": \"cohort 1\", \"type\": \"FIRST_VISIT_DATE\", \"dateRange\": {
+-- \"startDate\": \"2015-08-01\", \"endDate\": \"2015-08-01\" } },{
+-- \"name\": \"cohort 2\" \"type\": \"FIRST_VISIT_DATE\" \"dateRange\": {
+-- \"startDate\": \"2015-07-01\", \"endDate\": \"2015-07-01\" } }] }
+--
+-- /See:/ 'cohortGroup' smart constructor.
+data CohortGroup = CohortGroup'
+    { _cgCohorts       :: !(Maybe [Cohort])
+    , _cgLifetimeValue :: !(Maybe Bool)
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'CohortGroup' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'cgCohorts'
+--
+-- * 'cgLifetimeValue'
+cohortGroup
+    :: CohortGroup
+cohortGroup =
+    CohortGroup'
+    { _cgCohorts = Nothing
+    , _cgLifetimeValue = Nothing
+    }
+
+-- | The definition for the cohort.
+cgCohorts :: Lens' CohortGroup [Cohort]
+cgCohorts
+  = lens _cgCohorts (\ s a -> s{_cgCohorts = a}) .
+      _Default
+      . _Coerce
+
+-- | Enable Life Time Value (LTV). LTV measures lifetime value for users
+-- acquired through different channels. Please see: [Cohort
+-- Analysis](https:\/\/support.google.com\/analytics\/answer\/6074676) and
+-- [Lifetime
+-- Value](https:\/\/support.google.com\/analytics\/answer\/6182550) If the
+-- value of lifetimeValue is false: - The metric values are similar to the
+-- values in the web interface cohort report. - The cohort definition date
+-- ranges must be aligned to the calendar week and month. i.e. while
+-- requesting \`ga:cohortNthWeek\` the \`startDate\` in the cohort
+-- definition should be a Sunday and the \`endDate\` should be the
+-- following Saturday, and for \`ga:cohortNthMonth\`, the \`startDate\`
+-- should be the 1st of the month and \`endDate\` should be the last day of
+-- the month. When the lifetimeValue is true: - The metric values will
+-- correspond to the values in the web interface LifeTime value report. -
+-- The Lifetime Value report shows you how user value (Revenue) and
+-- engagement (Appviews, Goal Completions, Sessions, and Session Duration)
+-- grow during the 90 days after a user is acquired. - The metrics are
+-- calculated as a cumulative average per user per the time increment. -
+-- The cohort definition date ranges need not be aligned to the calendar
+-- week and month boundaries. - The \`viewId\` must be an [app view
+-- ID](https:\/\/support.google.com\/analytics\/answer\/2649553#WebVersusAppViews)
+cgLifetimeValue :: Lens' CohortGroup (Maybe Bool)
+cgLifetimeValue
+  = lens _cgLifetimeValue
+      (\ s a -> s{_cgLifetimeValue = a})
+
+instance FromJSON CohortGroup where
+        parseJSON
+          = withObject "CohortGroup"
+              (\ o ->
+                 CohortGroup' <$>
+                   (o .:? "cohorts" .!= mempty) <*>
+                     (o .:? "lifetimeValue"))
+
+instance ToJSON CohortGroup where
+        toJSON CohortGroup'{..}
+          = object
+              (catMaybes
+                 [("cohorts" .=) <$> _cgCohorts,
+                  ("lifetimeValue" .=) <$> _cgLifetimeValue])
+
+-- | A Simple segment conditions consist of one or more dimension\/metric
+-- conditions that can be combined.
+--
+-- /See:/ 'simpleSegment' smart constructor.
+newtype SimpleSegment = SimpleSegment'
+    { _ssOrFiltersForSegment :: Maybe [OrFiltersForSegment]
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'SimpleSegment' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'ssOrFiltersForSegment'
+simpleSegment
+    :: SimpleSegment
+simpleSegment =
+    SimpleSegment'
+    { _ssOrFiltersForSegment = Nothing
+    }
+
+-- | A list of segment filters groups which are combined with logical \`AND\`
+-- operator.
+ssOrFiltersForSegment :: Lens' SimpleSegment [OrFiltersForSegment]
+ssOrFiltersForSegment
+  = lens _ssOrFiltersForSegment
+      (\ s a -> s{_ssOrFiltersForSegment = a})
+      . _Default
+      . _Coerce
+
+instance FromJSON SimpleSegment where
+        parseJSON
+          = withObject "SimpleSegment"
+              (\ o ->
+                 SimpleSegment' <$>
+                   (o .:? "orFiltersForSegment" .!= mempty))
+
+instance ToJSON SimpleSegment where
+        toJSON SimpleSegment'{..}
+          = object
+              (catMaybes
+                 [("orFiltersForSegment" .=) <$>
+                    _ssOrFiltersForSegment])
+
+-- | A group of dimension filters. Set the operator value to specify how the
+-- filters are logically combined.
+--
+-- /See:/ 'dimensionFilterClause' smart constructor.
+data DimensionFilterClause = DimensionFilterClause'
+    { _dfcOperator :: !(Maybe DimensionFilterClauseOperator)
+    , _dfcFilters  :: !(Maybe [DimensionFilter])
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'DimensionFilterClause' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'dfcOperator'
+--
+-- * 'dfcFilters'
+dimensionFilterClause
+    :: DimensionFilterClause
+dimensionFilterClause =
+    DimensionFilterClause'
+    { _dfcOperator = Nothing
+    , _dfcFilters = Nothing
+    }
+
+-- | The operator for combining multiple dimension filters. If unspecified,
+-- it is treated as an \`OR\`.
+dfcOperator :: Lens' DimensionFilterClause (Maybe DimensionFilterClauseOperator)
+dfcOperator
+  = lens _dfcOperator (\ s a -> s{_dfcOperator = a})
+
+-- | The repeated set of filters. They are logically combined based on the
+-- operator specified.
+dfcFilters :: Lens' DimensionFilterClause [DimensionFilter]
+dfcFilters
+  = lens _dfcFilters (\ s a -> s{_dfcFilters = a}) .
+      _Default
+      . _Coerce
+
+instance FromJSON DimensionFilterClause where
+        parseJSON
+          = withObject "DimensionFilterClause"
+              (\ o ->
+                 DimensionFilterClause' <$>
+                   (o .:? "operator") <*> (o .:? "filters" .!= mempty))
+
+instance ToJSON DimensionFilterClause where
+        toJSON DimensionFilterClause'{..}
+          = object
+              (catMaybes
+                 [("operator" .=) <$> _dfcOperator,
+                  ("filters" .=) <$> _dfcFilters])
+
+-- | Specifies the sorting options.
+--
+-- /See:/ 'orderBy' smart constructor.
+data OrderBy = OrderBy'
+    { _obOrderType :: !(Maybe OrderByOrderType)
+    , _obSortOrder :: !(Maybe OrderBySortOrder)
+    , _obFieldName :: !(Maybe Text)
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'OrderBy' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'obOrderType'
+--
+-- * 'obSortOrder'
+--
+-- * 'obFieldName'
+orderBy
+    :: OrderBy
+orderBy =
+    OrderBy'
+    { _obOrderType = Nothing
+    , _obSortOrder = Nothing
+    , _obFieldName = Nothing
+    }
+
+-- | The order type. The default orderType is \`VALUE\`.
+obOrderType :: Lens' OrderBy (Maybe OrderByOrderType)
+obOrderType
+  = lens _obOrderType (\ s a -> s{_obOrderType = a})
+
+-- | The sorting order for the field.
+obSortOrder :: Lens' OrderBy (Maybe OrderBySortOrder)
+obSortOrder
+  = lens _obSortOrder (\ s a -> s{_obSortOrder = a})
+
+-- | The field which to sort by. The default sort order is ascending.
+-- Example: \`ga:browser\`. Note, that you can only specify one field for
+-- sort here. For example, \`ga:browser, ga:city\` is not valid.
+obFieldName :: Lens' OrderBy (Maybe Text)
+obFieldName
+  = lens _obFieldName (\ s a -> s{_obFieldName = a})
+
+instance FromJSON OrderBy where
+        parseJSON
+          = withObject "OrderBy"
+              (\ o ->
+                 OrderBy' <$>
+                   (o .:? "orderType") <*> (o .:? "sortOrder") <*>
+                     (o .:? "fieldName"))
+
+instance ToJSON OrderBy where
+        toJSON OrderBy'{..}
+          = object
+              (catMaybes
+                 [("orderType" .=) <$> _obOrderType,
+                  ("sortOrder" .=) <$> _obSortOrder,
+                  ("fieldName" .=) <$> _obFieldName])
+
+-- | [Dimensions](https:\/\/support.google.com\/analytics\/answer\/1033861)
+-- are attributes of your data. For example, the dimension \`ga:city\`
+-- indicates the city, for example, \"Paris\" or \"New York\", from which a
+-- session originates.
+--
+-- /See:/ 'dimension' smart constructor.
+data Dimension = Dimension'
+    { _dName             :: !(Maybe Text)
+    , _dHistogramBuckets :: !(Maybe [Textual Int64])
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'Dimension' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'dName'
+--
+-- * 'dHistogramBuckets'
+dimension
+    :: Dimension
+dimension =
+    Dimension'
+    { _dName = Nothing
+    , _dHistogramBuckets = Nothing
+    }
+
+-- | Name of the dimension to fetch, for example \`ga:browser\`.
+dName :: Lens' Dimension (Maybe Text)
+dName = lens _dName (\ s a -> s{_dName = a})
+
+-- | If non-empty, we place dimension values into buckets after string to
+-- int64. Dimension values that are not the string representation of an
+-- integral value will be converted to zero. The bucket values have to be
+-- in increasing order. Each bucket is closed on the lower end, and open on
+-- the upper end. The \"first\" bucket includes all values less than the
+-- first boundary, the \"last\" bucket includes all values up to infinity.
+-- Dimension values that fall in a bucket get transformed to a new
+-- dimension value. For example, if one gives a list of \"0, 1, 3, 4, 7\",
+-- then we return the following buckets: - bucket #1: values \< 0,
+-- dimension value \"\<0\" - bucket #2: values in [0,1), dimension value
+-- \"0\" - bucket #3: values in [1,3), dimension value \"1-2\" - bucket #4:
+-- values in [3,4), dimension value \"3\" - bucket #5: values in [4,7),
+-- dimension value \"4-6\" - bucket #6: values >= 7, dimension value \"7+\"
+-- NOTE: If you are applying histogram mutation on any dimension, and using
+-- that dimension in sort, you will want to use the sort type
+-- \`HISTOGRAM_BUCKET\` for that purpose. Without that the dimension values
+-- will be sorted according to dictionary (lexicographic) order. For
+-- example the ascending dictionary order is: \"\<50\", \"1001+\",
+-- \"121-1000\", \"50-120\" And the ascending \`HISTOGRAM_BUCKET\` order
+-- is: \"\<50\", \"50-120\", \"121-1000\", \"1001+\" The client has to
+-- explicitly request \`\"orderType\": \"HISTOGRAM_BUCKET\"\` for a
+-- histogram-mutated dimension.
+dHistogramBuckets :: Lens' Dimension [Int64]
+dHistogramBuckets
+  = lens _dHistogramBuckets
+      (\ s a -> s{_dHistogramBuckets = a})
+      . _Default
+      . _Coerce
+
+instance FromJSON Dimension where
+        parseJSON
+          = withObject "Dimension"
+              (\ o ->
+                 Dimension' <$>
+                   (o .:? "name") <*>
+                     (o .:? "histogramBuckets" .!= mempty))
+
+instance ToJSON Dimension where
+        toJSON Dimension'{..}
+          = object
+              (catMaybes
+                 [("name" .=) <$> _dName,
+                  ("histogramBuckets" .=) <$> _dHistogramBuckets])
+
+-- | Used to return a list of metrics for a single DateRange \/ dimension
+-- combination
+--
+-- /See:/ 'dateRangeValues' smart constructor.
+data DateRangeValues = DateRangeValues'
+    { _drvPivotValueRegions :: !(Maybe [PivotValueRegion])
+    , _drvValues            :: !(Maybe [Text])
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'DateRangeValues' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'drvPivotValueRegions'
+--
+-- * 'drvValues'
+dateRangeValues
+    :: DateRangeValues
+dateRangeValues =
+    DateRangeValues'
+    { _drvPivotValueRegions = Nothing
+    , _drvValues = Nothing
+    }
+
+-- | The values of each pivot region.
+drvPivotValueRegions :: Lens' DateRangeValues [PivotValueRegion]
+drvPivotValueRegions
+  = lens _drvPivotValueRegions
+      (\ s a -> s{_drvPivotValueRegions = a})
+      . _Default
+      . _Coerce
+
+-- | Each value corresponds to each Metric in the request.
+drvValues :: Lens' DateRangeValues [Text]
+drvValues
+  = lens _drvValues (\ s a -> s{_drvValues = a}) .
+      _Default
+      . _Coerce
+
+instance FromJSON DateRangeValues where
+        parseJSON
+          = withObject "DateRangeValues"
+              (\ o ->
+                 DateRangeValues' <$>
+                   (o .:? "pivotValueRegions" .!= mempty) <*>
+                     (o .:? "values" .!= mempty))
+
+instance ToJSON DateRangeValues where
+        toJSON DateRangeValues'{..}
+          = object
+              (catMaybes
+                 [("pivotValueRegions" .=) <$> _drvPivotValueRegions,
+                  ("values" .=) <$> _drvValues])
+
+-- | The headers for each of the pivot sections defined in the request.
+--
+-- /See:/ 'pivotHeader' smart constructor.
+data PivotHeader = PivotHeader'
+    { _phTotalPivotGroupsCount :: !(Maybe (Textual Int32))
+    , _phPivotHeaderEntries    :: !(Maybe [PivotHeaderEntry])
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'PivotHeader' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'phTotalPivotGroupsCount'
+--
+-- * 'phPivotHeaderEntries'
+pivotHeader
+    :: PivotHeader
+pivotHeader =
+    PivotHeader'
+    { _phTotalPivotGroupsCount = Nothing
+    , _phPivotHeaderEntries = Nothing
+    }
+
+-- | The total number of groups for this pivot.
+phTotalPivotGroupsCount :: Lens' PivotHeader (Maybe Int32)
+phTotalPivotGroupsCount
+  = lens _phTotalPivotGroupsCount
+      (\ s a -> s{_phTotalPivotGroupsCount = a})
+      . mapping _Coerce
+
+-- | A single pivot section header.
+phPivotHeaderEntries :: Lens' PivotHeader [PivotHeaderEntry]
+phPivotHeaderEntries
+  = lens _phPivotHeaderEntries
+      (\ s a -> s{_phPivotHeaderEntries = a})
+      . _Default
+      . _Coerce
+
+instance FromJSON PivotHeader where
+        parseJSON
+          = withObject "PivotHeader"
+              (\ o ->
+                 PivotHeader' <$>
+                   (o .:? "totalPivotGroupsCount") <*>
+                     (o .:? "pivotHeaderEntries" .!= mempty))
+
+instance ToJSON PivotHeader where
+        toJSON PivotHeader'{..}
+          = object
+              (catMaybes
+                 [("totalPivotGroupsCount" .=) <$>
+                    _phTotalPivotGroupsCount,
+                  ("pivotHeaderEntries" .=) <$> _phPivotHeaderEntries])
+
+-- | The headers for the metrics.
+--
+-- /See:/ 'metricHeader' smart constructor.
+data MetricHeader = MetricHeader'
+    { _mhPivotHeaders        :: !(Maybe [PivotHeader])
+    , _mhMetricHeaderEntries :: !(Maybe [MetricHeaderEntry])
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'MetricHeader' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'mhPivotHeaders'
+--
+-- * 'mhMetricHeaderEntries'
+metricHeader
+    :: MetricHeader
+metricHeader =
+    MetricHeader'
+    { _mhPivotHeaders = Nothing
+    , _mhMetricHeaderEntries = Nothing
+    }
+
+-- | Headers for the pivots in the response.
+mhPivotHeaders :: Lens' MetricHeader [PivotHeader]
+mhPivotHeaders
+  = lens _mhPivotHeaders
+      (\ s a -> s{_mhPivotHeaders = a})
+      . _Default
+      . _Coerce
+
+-- | Headers for the metrics in the response.
+mhMetricHeaderEntries :: Lens' MetricHeader [MetricHeaderEntry]
+mhMetricHeaderEntries
+  = lens _mhMetricHeaderEntries
+      (\ s a -> s{_mhMetricHeaderEntries = a})
+      . _Default
+      . _Coerce
+
+instance FromJSON MetricHeader where
+        parseJSON
+          = withObject "MetricHeader"
+              (\ o ->
+                 MetricHeader' <$>
+                   (o .:? "pivotHeaders" .!= mempty) <*>
+                     (o .:? "metricHeaderEntries" .!= mempty))
+
+instance ToJSON MetricHeader where
+        toJSON MetricHeader'{..}
+          = object
+              (catMaybes
+                 [("pivotHeaders" .=) <$> _mhPivotHeaders,
+                  ("metricHeaderEntries" .=) <$>
+                    _mhMetricHeaderEntries])
+
+-- | SegmentFilter defines the segment to be either a simple or a sequence
+-- segment. A simple segment condition contains dimension and metric
+-- conditions to select the sessions or users. A sequence segment condition
+-- can be used to select users or sessions based on sequential conditions.
+--
+-- /See:/ 'segmentFilter' smart constructor.
+data SegmentFilter = SegmentFilter'
+    { _sfNot             :: !(Maybe Bool)
+    , _sfSimpleSegment   :: !(Maybe SimpleSegment)
+    , _sfSequenceSegment :: !(Maybe SequenceSegment)
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'SegmentFilter' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'sfNot'
+--
+-- * 'sfSimpleSegment'
+--
+-- * 'sfSequenceSegment'
+segmentFilter
+    :: SegmentFilter
+segmentFilter =
+    SegmentFilter'
+    { _sfNot = Nothing
+    , _sfSimpleSegment = Nothing
+    , _sfSequenceSegment = Nothing
+    }
+
+-- | If true, match the complement of simple or sequence segment. For
+-- example, to match all visits not from \"New York\", we can define the
+-- segment as follows: \"sessionSegment\": { \"segmentFilters\": [{
+-- \"simpleSegment\" :{ \"orFiltersForSegment\": [{
+-- \"segmentFilterClauses\":[{ \"dimensionFilter\": { \"dimensionName\":
+-- \"ga:city\", \"expressions\": [\"New York\"] } }] }] }, \"not\":
+-- \"True\" }] },
+sfNot :: Lens' SegmentFilter (Maybe Bool)
+sfNot = lens _sfNot (\ s a -> s{_sfNot = a})
+
+-- | A Simple segment conditions consist of one or more dimension\/metric
+-- conditions that can be combined
+sfSimpleSegment :: Lens' SegmentFilter (Maybe SimpleSegment)
+sfSimpleSegment
+  = lens _sfSimpleSegment
+      (\ s a -> s{_sfSimpleSegment = a})
+
+-- | Sequence conditions consist of one or more steps, where each step is
+-- defined by one or more dimension\/metric conditions. Multiple steps can
+-- be combined with special sequence operators.
+sfSequenceSegment :: Lens' SegmentFilter (Maybe SequenceSegment)
+sfSequenceSegment
+  = lens _sfSequenceSegment
+      (\ s a -> s{_sfSequenceSegment = a})
+
+instance FromJSON SegmentFilter where
+        parseJSON
+          = withObject "SegmentFilter"
+              (\ o ->
+                 SegmentFilter' <$>
+                   (o .:? "not") <*> (o .:? "simpleSegment") <*>
+                     (o .:? "sequenceSegment"))
+
+instance ToJSON SegmentFilter where
+        toJSON SegmentFilter'{..}
+          = object
+              (catMaybes
+                 [("not" .=) <$> _sfNot,
+                  ("simpleSegment" .=) <$> _sfSimpleSegment,
+                  ("sequenceSegment" .=) <$> _sfSequenceSegment])
+
+-- | A contiguous set of days: startDate, startDate + 1 day, ..., endDate.
+-- The start and end dates are specified in
+-- [ISO8601](https:\/\/en.wikipedia.org\/wiki\/ISO_8601) date format
+-- \`YYYY-MM-DD\`.
+--
+-- /See:/ 'dateRange' smart constructor.
+data DateRange = DateRange'
+    { _drEndDate   :: !(Maybe Text)
+    , _drStartDate :: !(Maybe Text)
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'DateRange' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'drEndDate'
+--
+-- * 'drStartDate'
+dateRange
+    :: DateRange
+dateRange =
+    DateRange'
+    { _drEndDate = Nothing
+    , _drStartDate = Nothing
+    }
+
+-- | The end date for the query in the format \`YYYY-MM-DD\`.
+drEndDate :: Lens' DateRange (Maybe Text)
+drEndDate
+  = lens _drEndDate (\ s a -> s{_drEndDate = a})
+
+-- | The start date for the query in the format \`YYYY-MM-DD\`.
+drStartDate :: Lens' DateRange (Maybe Text)
+drStartDate
+  = lens _drStartDate (\ s a -> s{_drStartDate = a})
+
+instance FromJSON DateRange where
+        parseJSON
+          = withObject "DateRange"
+              (\ o ->
+                 DateRange' <$>
+                   (o .:? "endDate") <*> (o .:? "startDate"))
+
+instance ToJSON DateRange where
+        toJSON DateRange'{..}
+          = object
+              (catMaybes
+                 [("endDate" .=) <$> _drEndDate,
+                  ("startDate" .=) <$> _drStartDate])
+
+-- | The data response corresponding to the request.
+--
+-- /See:/ 'report' smart constructor.
+data Report = Report'
+    { _rNextPageToken :: !(Maybe Text)
+    , _rData          :: !(Maybe ReportData)
+    , _rColumnHeader  :: !(Maybe ColumnHeader)
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'Report' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'rNextPageToken'
+--
+-- * 'rData'
+--
+-- * 'rColumnHeader'
+report
+    :: Report
+report =
+    Report'
+    { _rNextPageToken = Nothing
+    , _rData = Nothing
+    , _rColumnHeader = Nothing
+    }
+
+-- | Page token to retrieve the next page of results in the list.
+rNextPageToken :: Lens' Report (Maybe Text)
+rNextPageToken
+  = lens _rNextPageToken
+      (\ s a -> s{_rNextPageToken = a})
+
+-- | Response data.
+rData :: Lens' Report (Maybe ReportData)
+rData = lens _rData (\ s a -> s{_rData = a})
+
+-- | The column headers.
+rColumnHeader :: Lens' Report (Maybe ColumnHeader)
+rColumnHeader
+  = lens _rColumnHeader
+      (\ s a -> s{_rColumnHeader = a})
+
+instance FromJSON Report where
+        parseJSON
+          = withObject "Report"
+              (\ o ->
+                 Report' <$>
+                   (o .:? "nextPageToken") <*> (o .:? "data") <*>
+                     (o .:? "columnHeader"))
+
+instance ToJSON Report where
+        toJSON Report'{..}
+          = object
+              (catMaybes
+                 [("nextPageToken" .=) <$> _rNextPageToken,
+                  ("data" .=) <$> _rData,
+                  ("columnHeader" .=) <$> _rColumnHeader])
+
+-- | The data part of the report.
+--
+-- /See:/ 'reportData' smart constructor.
+data ReportData = ReportData'
+    { _rdMinimums           :: !(Maybe [DateRangeValues])
+    , _rdRows               :: !(Maybe [ReportRow])
+    , _rdTotals             :: !(Maybe [DateRangeValues])
+    , _rdSamplesReadCounts  :: !(Maybe [Textual Int64])
+    , _rdMaximums           :: !(Maybe [DateRangeValues])
+    , _rdDataLastRefreshed  :: !(Maybe DateTime')
+    , _rdRowCount           :: !(Maybe (Textual Int32))
+    , _rdSamplingSpaceSizes :: !(Maybe [Textual Int64])
+    , _rdIsDataGolden       :: !(Maybe Bool)
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'ReportData' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'rdMinimums'
+--
+-- * 'rdRows'
+--
+-- * 'rdTotals'
+--
+-- * 'rdSamplesReadCounts'
+--
+-- * 'rdMaximums'
+--
+-- * 'rdDataLastRefreshed'
+--
+-- * 'rdRowCount'
+--
+-- * 'rdSamplingSpaceSizes'
+--
+-- * 'rdIsDataGolden'
+reportData
+    :: ReportData
+reportData =
+    ReportData'
+    { _rdMinimums = Nothing
+    , _rdRows = Nothing
+    , _rdTotals = Nothing
+    , _rdSamplesReadCounts = Nothing
+    , _rdMaximums = Nothing
+    , _rdDataLastRefreshed = Nothing
+    , _rdRowCount = Nothing
+    , _rdSamplingSpaceSizes = Nothing
+    , _rdIsDataGolden = Nothing
+    }
+
+-- | Minimum and maximum values seen over all matching rows. These are both
+-- empty when \`hideValueRanges\` in the request is false, or when rowCount
+-- is zero.
+rdMinimums :: Lens' ReportData [DateRangeValues]
+rdMinimums
+  = lens _rdMinimums (\ s a -> s{_rdMinimums = a}) .
+      _Default
+      . _Coerce
+
+-- | There\'s one ReportRow for every unique combination of dimensions.
+rdRows :: Lens' ReportData [ReportRow]
+rdRows
+  = lens _rdRows (\ s a -> s{_rdRows = a}) . _Default .
+      _Coerce
+
+-- | For each requested date range, for the set of all rows that match the
+-- query, every requested value format gets a total. The total for a value
+-- format is computed by first totaling the metrics mentioned in the value
+-- format and then evaluating the value format as a scalar expression.
+-- E.g., The \"totals\" for \`3 \/ (ga:sessions + 2)\` we compute \`3 \/
+-- ((sum of all relevant ga:sessions) + 2)\`. Totals are computed before
+-- pagination.
+rdTotals :: Lens' ReportData [DateRangeValues]
+rdTotals
+  = lens _rdTotals (\ s a -> s{_rdTotals = a}) .
+      _Default
+      . _Coerce
+
+-- | If the results are
+-- [sampled](https:\/\/support.google.com\/analytics\/answer\/2637192),
+-- this returns the total number of samples read, one entry per date range.
+-- If the results are not sampled this field will not be defined. See
+-- [developer
+-- guide](\/analytics\/devguides\/reporting\/core\/v4\/basics#sampling) for
+-- details.
+rdSamplesReadCounts :: Lens' ReportData [Int64]
+rdSamplesReadCounts
+  = lens _rdSamplesReadCounts
+      (\ s a -> s{_rdSamplesReadCounts = a})
+      . _Default
+      . _Coerce
+
+-- | Minimum and maximum values seen over all matching rows. These are both
+-- empty when \`hideValueRanges\` in the request is false, or when rowCount
+-- is zero.
+rdMaximums :: Lens' ReportData [DateRangeValues]
+rdMaximums
+  = lens _rdMaximums (\ s a -> s{_rdMaximums = a}) .
+      _Default
+      . _Coerce
+
+-- | The last time the data in the report was refreshed. All the hits
+-- received before this timestamp are included in the calculation of the
+-- report.
+rdDataLastRefreshed :: Lens' ReportData (Maybe UTCTime)
+rdDataLastRefreshed
+  = lens _rdDataLastRefreshed
+      (\ s a -> s{_rdDataLastRefreshed = a})
+      . mapping _DateTime
+
+-- | Total number of matching rows for this query.
+rdRowCount :: Lens' ReportData (Maybe Int32)
+rdRowCount
+  = lens _rdRowCount (\ s a -> s{_rdRowCount = a}) .
+      mapping _Coerce
+
+-- | If the results are
+-- [sampled](https:\/\/support.google.com\/analytics\/answer\/2637192),
+-- this returns the total number of samples present, one entry per date
+-- range. If the results are not sampled this field will not be defined.
+-- See [developer
+-- guide](\/analytics\/devguides\/reporting\/core\/v4\/basics#sampling) for
+-- details.
+rdSamplingSpaceSizes :: Lens' ReportData [Int64]
+rdSamplingSpaceSizes
+  = lens _rdSamplingSpaceSizes
+      (\ s a -> s{_rdSamplingSpaceSizes = a})
+      . _Default
+      . _Coerce
+
+-- | Indicates if response to this request is golden or not. Data is golden
+-- when the exact same request will not produce any new results if asked at
+-- a later point in time.
+rdIsDataGolden :: Lens' ReportData (Maybe Bool)
+rdIsDataGolden
+  = lens _rdIsDataGolden
+      (\ s a -> s{_rdIsDataGolden = a})
+
+instance FromJSON ReportData where
+        parseJSON
+          = withObject "ReportData"
+              (\ o ->
+                 ReportData' <$>
+                   (o .:? "minimums" .!= mempty) <*>
+                     (o .:? "rows" .!= mempty)
+                     <*> (o .:? "totals" .!= mempty)
+                     <*> (o .:? "samplesReadCounts" .!= mempty)
+                     <*> (o .:? "maximums" .!= mempty)
+                     <*> (o .:? "dataLastRefreshed")
+                     <*> (o .:? "rowCount")
+                     <*> (o .:? "samplingSpaceSizes" .!= mempty)
+                     <*> (o .:? "isDataGolden"))
+
+instance ToJSON ReportData where
+        toJSON ReportData'{..}
+          = object
+              (catMaybes
+                 [("minimums" .=) <$> _rdMinimums,
+                  ("rows" .=) <$> _rdRows, ("totals" .=) <$> _rdTotals,
+                  ("samplesReadCounts" .=) <$> _rdSamplesReadCounts,
+                  ("maximums" .=) <$> _rdMaximums,
+                  ("dataLastRefreshed" .=) <$> _rdDataLastRefreshed,
+                  ("rowCount" .=) <$> _rdRowCount,
+                  ("samplingSpaceSizes" .=) <$> _rdSamplingSpaceSizes,
+                  ("isDataGolden" .=) <$> _rdIsDataGolden])
+
+-- | Filter Clause to be used in a segment definition, can be wither a metric
+-- or a dimension filter.
+--
+-- /See:/ 'segmentFilterClause' smart constructor.
+data SegmentFilterClause = SegmentFilterClause'
+    { _sfcMetricFilter    :: !(Maybe SegmentMetricFilter)
+    , _sfcNot             :: !(Maybe Bool)
+    , _sfcDimensionFilter :: !(Maybe SegmentDimensionFilter)
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'SegmentFilterClause' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'sfcMetricFilter'
+--
+-- * 'sfcNot'
+--
+-- * 'sfcDimensionFilter'
+segmentFilterClause
+    :: SegmentFilterClause
+segmentFilterClause =
+    SegmentFilterClause'
+    { _sfcMetricFilter = Nothing
+    , _sfcNot = Nothing
+    , _sfcDimensionFilter = Nothing
+    }
+
+-- | Metric Filter for the segment definition.
+sfcMetricFilter :: Lens' SegmentFilterClause (Maybe SegmentMetricFilter)
+sfcMetricFilter
+  = lens _sfcMetricFilter
+      (\ s a -> s{_sfcMetricFilter = a})
+
+-- | Matches the complement (\`!\`) of the filter.
+sfcNot :: Lens' SegmentFilterClause (Maybe Bool)
+sfcNot = lens _sfcNot (\ s a -> s{_sfcNot = a})
+
+-- | Dimension Filter for the segment definition.
+sfcDimensionFilter :: Lens' SegmentFilterClause (Maybe SegmentDimensionFilter)
+sfcDimensionFilter
+  = lens _sfcDimensionFilter
+      (\ s a -> s{_sfcDimensionFilter = a})
+
+instance FromJSON SegmentFilterClause where
+        parseJSON
+          = withObject "SegmentFilterClause"
+              (\ o ->
+                 SegmentFilterClause' <$>
+                   (o .:? "metricFilter") <*> (o .:? "not") <*>
+                     (o .:? "dimensionFilter"))
+
+instance ToJSON SegmentFilterClause where
+        toJSON SegmentFilterClause'{..}
+          = object
+              (catMaybes
+                 [("metricFilter" .=) <$> _sfcMetricFilter,
+                  ("not" .=) <$> _sfcNot,
+                  ("dimensionFilter" .=) <$> _sfcDimensionFilter])
+
+-- | A segment sequence definition.
+--
+-- /See:/ 'segmentSequenceStep' smart constructor.
+data SegmentSequenceStep = SegmentSequenceStep'
+    { _sssMatchType           :: !(Maybe SegmentSequenceStepMatchType)
+    , _sssOrFiltersForSegment :: !(Maybe [OrFiltersForSegment])
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'SegmentSequenceStep' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'sssMatchType'
+--
+-- * 'sssOrFiltersForSegment'
+segmentSequenceStep
+    :: SegmentSequenceStep
+segmentSequenceStep =
+    SegmentSequenceStep'
+    { _sssMatchType = Nothing
+    , _sssOrFiltersForSegment = Nothing
+    }
+
+-- | Specifies if the step immediately precedes or can be any time before the
+-- next step.
+sssMatchType :: Lens' SegmentSequenceStep (Maybe SegmentSequenceStepMatchType)
+sssMatchType
+  = lens _sssMatchType (\ s a -> s{_sssMatchType = a})
+
+-- | A sequence is specified with a list of Or grouped filters which are
+-- combined with \`AND\` operator.
+sssOrFiltersForSegment :: Lens' SegmentSequenceStep [OrFiltersForSegment]
+sssOrFiltersForSegment
+  = lens _sssOrFiltersForSegment
+      (\ s a -> s{_sssOrFiltersForSegment = a})
+      . _Default
+      . _Coerce
+
+instance FromJSON SegmentSequenceStep where
+        parseJSON
+          = withObject "SegmentSequenceStep"
+              (\ o ->
+                 SegmentSequenceStep' <$>
+                   (o .:? "matchType") <*>
+                     (o .:? "orFiltersForSegment" .!= mempty))
+
+instance ToJSON SegmentSequenceStep where
+        toJSON SegmentSequenceStep'{..}
+          = object
+              (catMaybes
+                 [("matchType" .=) <$> _sssMatchType,
+                  ("orFiltersForSegment" .=) <$>
+                    _sssOrFiltersForSegment])
+
+-- | A list of segment filters in the \`OR\` group are combined with the
+-- logical OR operator.
+--
+-- /See:/ 'orFiltersForSegment' smart constructor.
+newtype OrFiltersForSegment = OrFiltersForSegment'
+    { _offsSegmentFilterClauses :: Maybe [SegmentFilterClause]
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'OrFiltersForSegment' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'offsSegmentFilterClauses'
+orFiltersForSegment
+    :: OrFiltersForSegment
+orFiltersForSegment =
+    OrFiltersForSegment'
+    { _offsSegmentFilterClauses = Nothing
+    }
+
+-- | List of segment filters to be combined with a \`OR\` operator.
+offsSegmentFilterClauses :: Lens' OrFiltersForSegment [SegmentFilterClause]
+offsSegmentFilterClauses
+  = lens _offsSegmentFilterClauses
+      (\ s a -> s{_offsSegmentFilterClauses = a})
+      . _Default
+      . _Coerce
+
+instance FromJSON OrFiltersForSegment where
+        parseJSON
+          = withObject "OrFiltersForSegment"
+              (\ o ->
+                 OrFiltersForSegment' <$>
+                   (o .:? "segmentFilterClauses" .!= mempty))
+
+instance ToJSON OrFiltersForSegment where
+        toJSON OrFiltersForSegment'{..}
+          = object
+              (catMaybes
+                 [("segmentFilterClauses" .=) <$>
+                    _offsSegmentFilterClauses])
+
+-- | SegmentDefinition defines the segment to be a set of SegmentFilters
+-- which are combined together with a logical \`AND\` operation.
+--
+-- /See:/ 'segmentDefinition' smart constructor.
+newtype SegmentDefinition = SegmentDefinition'
+    { _sdSegmentFilters :: Maybe [SegmentFilter]
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'SegmentDefinition' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'sdSegmentFilters'
+segmentDefinition
+    :: SegmentDefinition
+segmentDefinition =
+    SegmentDefinition'
+    { _sdSegmentFilters = Nothing
+    }
+
+-- | A segment is defined by a set of segment filters which are combined
+-- together with a logical \`AND\` operation.
+sdSegmentFilters :: Lens' SegmentDefinition [SegmentFilter]
+sdSegmentFilters
+  = lens _sdSegmentFilters
+      (\ s a -> s{_sdSegmentFilters = a})
+      . _Default
+      . _Coerce
+
+instance FromJSON SegmentDefinition where
+        parseJSON
+          = withObject "SegmentDefinition"
+              (\ o ->
+                 SegmentDefinition' <$>
+                   (o .:? "segmentFilters" .!= mempty))
+
+instance ToJSON SegmentDefinition where
+        toJSON SegmentDefinition'{..}
+          = object
+              (catMaybes
+                 [("segmentFilters" .=) <$> _sdSegmentFilters])
+
+-- | The Pivot describes the pivot section in the request. The Pivot helps
+-- rearrange the information in the table for certain reports by pivoting
+-- your data on a second dimension.
+--
+-- /See:/ 'pivot' smart constructor.
+data Pivot = Pivot'
+    { _pStartGroup             :: !(Maybe (Textual Int32))
+    , _pMetrics                :: !(Maybe [Metric])
+    , _pMaxGroupCount          :: !(Maybe (Textual Int32))
+    , _pDimensions             :: !(Maybe [Dimension])
+    , _pDimensionFilterClauses :: !(Maybe [DimensionFilterClause])
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'Pivot' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'pStartGroup'
+--
+-- * 'pMetrics'
+--
+-- * 'pMaxGroupCount'
+--
+-- * 'pDimensions'
+--
+-- * 'pDimensionFilterClauses'
+pivot
+    :: Pivot
+pivot =
+    Pivot'
+    { _pStartGroup = Nothing
+    , _pMetrics = Nothing
+    , _pMaxGroupCount = Nothing
+    , _pDimensions = Nothing
+    , _pDimensionFilterClauses = Nothing
+    }
+
+-- | If k metrics were requested, then the response will contain some
+-- data-dependent multiple of k columns in the report. E.g., if you pivoted
+-- on the dimension \`ga:browser\` then you\'d get k columns for
+-- \"Firefox\", k columns for \"IE\", k columns for \"Chrome\", etc. The
+-- ordering of the groups of columns is determined by descending order of
+-- \"total\" for the first of the k values. Ties are broken by
+-- lexicographic ordering of the first pivot dimension, then lexicographic
+-- ordering of the second pivot dimension, and so on. E.g., if the totals
+-- for the first value for Firefox, IE, and Chrome were 8, 2, 8,
+-- respectively, the order of columns would be Chrome, Firefox, IE. The
+-- following let you choose which of the groups of k columns are included
+-- in the response.
+pStartGroup :: Lens' Pivot (Maybe Int32)
+pStartGroup
+  = lens _pStartGroup (\ s a -> s{_pStartGroup = a}) .
+      mapping _Coerce
+
+-- | The pivot metrics. Pivot metrics are part of the restriction on total
+-- number of metrics allowed in the request.
+pMetrics :: Lens' Pivot [Metric]
+pMetrics
+  = lens _pMetrics (\ s a -> s{_pMetrics = a}) .
+      _Default
+      . _Coerce
+
+-- | Specifies the maximum number of groups to return. The default value is
+-- 10, also the maximum value is 1,000.
+pMaxGroupCount :: Lens' Pivot (Maybe Int32)
+pMaxGroupCount
+  = lens _pMaxGroupCount
+      (\ s a -> s{_pMaxGroupCount = a})
+      . mapping _Coerce
+
+-- | A list of dimensions to show as pivot columns. A Pivot can have a
+-- maximum of 4 dimensions. Pivot dimensions are part of the restriction on
+-- the total number of dimensions allowed in the request.
+pDimensions :: Lens' Pivot [Dimension]
+pDimensions
+  = lens _pDimensions (\ s a -> s{_pDimensions = a}) .
+      _Default
+      . _Coerce
+
+-- | DimensionFilterClauses are logically combined with an \`AND\` operator:
+-- only data that is included by all these DimensionFilterClauses
+-- contributes to the values in this pivot region. Dimension filters can be
+-- used to restrict the columns shown in the pivot region. For example if
+-- you have \`ga:browser\` as the requested dimension in the pivot region,
+-- and you specify key filters to restrict \`ga:browser\` to only \"IE\" or
+-- \"Firefox\", then only those two browsers would show up as columns.
+pDimensionFilterClauses :: Lens' Pivot [DimensionFilterClause]
+pDimensionFilterClauses
+  = lens _pDimensionFilterClauses
+      (\ s a -> s{_pDimensionFilterClauses = a})
+      . _Default
+      . _Coerce
+
+instance FromJSON Pivot where
+        parseJSON
+          = withObject "Pivot"
+              (\ o ->
+                 Pivot' <$>
+                   (o .:? "startGroup") <*> (o .:? "metrics" .!= mempty)
+                     <*> (o .:? "maxGroupCount")
+                     <*> (o .:? "dimensions" .!= mempty)
+                     <*> (o .:? "dimensionFilterClauses" .!= mempty))
+
+instance ToJSON Pivot where
+        toJSON Pivot'{..}
+          = object
+              (catMaybes
+                 [("startGroup" .=) <$> _pStartGroup,
+                  ("metrics" .=) <$> _pMetrics,
+                  ("maxGroupCount" .=) <$> _pMaxGroupCount,
+                  ("dimensions" .=) <$> _pDimensions,
+                  ("dimensionFilterClauses" .=) <$>
+                    _pDimensionFilterClauses])
+
+-- | Sequence conditions consist of one or more steps, where each step is
+-- defined by one or more dimension\/metric conditions. Multiple steps can
+-- be combined with special sequence operators.
+--
+-- /See:/ 'sequenceSegment' smart constructor.
+data SequenceSegment = SequenceSegment'
+    { _ssFirstStepShouldMatchFirstHit :: !(Maybe Bool)
+    , _ssSegmentSequenceSteps         :: !(Maybe [SegmentSequenceStep])
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'SequenceSegment' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'ssFirstStepShouldMatchFirstHit'
+--
+-- * 'ssSegmentSequenceSteps'
+sequenceSegment
+    :: SequenceSegment
+sequenceSegment =
+    SequenceSegment'
+    { _ssFirstStepShouldMatchFirstHit = Nothing
+    , _ssSegmentSequenceSteps = Nothing
+    }
+
+-- | If set, first step condition must match the first hit of the visitor (in
+-- the date range).
+ssFirstStepShouldMatchFirstHit :: Lens' SequenceSegment (Maybe Bool)
+ssFirstStepShouldMatchFirstHit
+  = lens _ssFirstStepShouldMatchFirstHit
+      (\ s a -> s{_ssFirstStepShouldMatchFirstHit = a})
+
+-- | The list of steps in the sequence.
+ssSegmentSequenceSteps :: Lens' SequenceSegment [SegmentSequenceStep]
+ssSegmentSequenceSteps
+  = lens _ssSegmentSequenceSteps
+      (\ s a -> s{_ssSegmentSequenceSteps = a})
+      . _Default
+      . _Coerce
+
+instance FromJSON SequenceSegment where
+        parseJSON
+          = withObject "SequenceSegment"
+              (\ o ->
+                 SequenceSegment' <$>
+                   (o .:? "firstStepShouldMatchFirstHit") <*>
+                     (o .:? "segmentSequenceSteps" .!= mempty))
+
+instance ToJSON SequenceSegment where
+        toJSON SequenceSegment'{..}
+          = object
+              (catMaybes
+                 [("firstStepShouldMatchFirstHit" .=) <$>
+                    _ssFirstStepShouldMatchFirstHit,
+                  ("segmentSequenceSteps" .=) <$>
+                    _ssSegmentSequenceSteps])
+
+-- | [Metrics](https:\/\/support.google.com\/analytics\/answer\/1033861) are
+-- the quantitative measurements. For example, the metric \`ga:users\`
+-- indicates the total number of users for the requested time period.
+--
+-- /See:/ 'metric' smart constructor.
+data Metric = Metric'
+    { _mFormattingType :: !(Maybe MetricFormattingType)
+    , _mAlias          :: !(Maybe Text)
+    , _mExpression     :: !(Maybe Text)
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'Metric' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'mFormattingType'
+--
+-- * 'mAlias'
+--
+-- * 'mExpression'
+metric
+    :: Metric
+metric =
+    Metric'
+    { _mFormattingType = Nothing
+    , _mAlias = Nothing
+    , _mExpression = Nothing
+    }
+
+-- | Specifies how the metric expression should be formatted, for example
+-- \`INTEGER\`.
+mFormattingType :: Lens' Metric (Maybe MetricFormattingType)
+mFormattingType
+  = lens _mFormattingType
+      (\ s a -> s{_mFormattingType = a})
+
+-- | An alias for the metric expression is an alternate name for the
+-- expression. The alias can be used for filtering and sorting. This field
+-- is optional and is useful if the expression is not a single metric but a
+-- complex expression which cannot be used in filtering and sorting. The
+-- alias is also used in the response column header.
+mAlias :: Lens' Metric (Maybe Text)
+mAlias = lens _mAlias (\ s a -> s{_mAlias = a})
+
+-- | A metric expression in the request. An expression is constructed from
+-- one or more metrics and numbers. Accepted operators include: Plus (+),
+-- Minus (-), Negation (Unary -), Divided by (\/), Multiplied by (*),
+-- Parenthesis, Positive cardinal numbers (0-9), can include decimals and
+-- is limited to 1024 characters. Example \`ga:totalRefunds\/ga:users\`, in
+-- most cases the metric expression is just a single metric name like
+-- \`ga:users\`. Adding mixed \`MetricType\` (E.g., \`CURRENCY\` +
+-- \`PERCENTAGE\`) metrics will result in unexpected results.
+mExpression :: Lens' Metric (Maybe Text)
+mExpression
+  = lens _mExpression (\ s a -> s{_mExpression = a})
+
+instance FromJSON Metric where
+        parseJSON
+          = withObject "Metric"
+              (\ o ->
+                 Metric' <$>
+                   (o .:? "formattingType") <*> (o .:? "alias") <*>
+                     (o .:? "expression"))
+
+instance ToJSON Metric where
+        toJSON Metric'{..}
+          = object
+              (catMaybes
+                 [("formattingType" .=) <$> _mFormattingType,
+                  ("alias" .=) <$> _mAlias,
+                  ("expression" .=) <$> _mExpression])
+
+-- | Metric filter to be used in a segment filter clause.
+--
+-- /See:/ 'segmentMetricFilter' smart constructor.
+data SegmentMetricFilter = SegmentMetricFilter'
+    { _smfOperator           :: !(Maybe SegmentMetricFilterOperator)
+    , _smfMetricName         :: !(Maybe Text)
+    , _smfMaxComparisonValue :: !(Maybe Text)
+    , _smfScope              :: !(Maybe SegmentMetricFilterScope)
+    , _smfComparisonValue    :: !(Maybe Text)
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'SegmentMetricFilter' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'smfOperator'
+--
+-- * 'smfMetricName'
+--
+-- * 'smfMaxComparisonValue'
+--
+-- * 'smfScope'
+--
+-- * 'smfComparisonValue'
+segmentMetricFilter
+    :: SegmentMetricFilter
+segmentMetricFilter =
+    SegmentMetricFilter'
+    { _smfOperator = Nothing
+    , _smfMetricName = Nothing
+    , _smfMaxComparisonValue = Nothing
+    , _smfScope = Nothing
+    , _smfComparisonValue = Nothing
+    }
+
+-- | Specifies is the operation to perform to compare the metric. The default
+-- is \`EQUAL\`.
+smfOperator :: Lens' SegmentMetricFilter (Maybe SegmentMetricFilterOperator)
+smfOperator
+  = lens _smfOperator (\ s a -> s{_smfOperator = a})
+
+-- | The metric that will be filtered on. A \`metricFilter\` must contain a
+-- metric name.
+smfMetricName :: Lens' SegmentMetricFilter (Maybe Text)
+smfMetricName
+  = lens _smfMetricName
+      (\ s a -> s{_smfMetricName = a})
+
+-- | Max comparison value is only used for \`BETWEEN\` operator.
+smfMaxComparisonValue :: Lens' SegmentMetricFilter (Maybe Text)
+smfMaxComparisonValue
+  = lens _smfMaxComparisonValue
+      (\ s a -> s{_smfMaxComparisonValue = a})
+
+-- | Scope for a metric defines the level at which that metric is defined.
+-- The specified metric scope must be equal to or greater than its primary
+-- scope as defined in the data model. The primary scope is defined by if
+-- the segment is selecting users or sessions.
+smfScope :: Lens' SegmentMetricFilter (Maybe SegmentMetricFilterScope)
+smfScope = lens _smfScope (\ s a -> s{_smfScope = a})
+
+-- | The value to compare against. If the operator is \`BETWEEN\`, this value
+-- is treated as minimum comparison value.
+smfComparisonValue :: Lens' SegmentMetricFilter (Maybe Text)
+smfComparisonValue
+  = lens _smfComparisonValue
+      (\ s a -> s{_smfComparisonValue = a})
+
+instance FromJSON SegmentMetricFilter where
+        parseJSON
+          = withObject "SegmentMetricFilter"
+              (\ o ->
+                 SegmentMetricFilter' <$>
+                   (o .:? "operator") <*> (o .:? "metricName") <*>
+                     (o .:? "maxComparisonValue")
+                     <*> (o .:? "scope")
+                     <*> (o .:? "comparisonValue"))
+
+instance ToJSON SegmentMetricFilter where
+        toJSON SegmentMetricFilter'{..}
+          = object
+              (catMaybes
+                 [("operator" .=) <$> _smfOperator,
+                  ("metricName" .=) <$> _smfMetricName,
+                  ("maxComparisonValue" .=) <$> _smfMaxComparisonValue,
+                  ("scope" .=) <$> _smfScope,
+                  ("comparisonValue" .=) <$> _smfComparisonValue])
+
+-- | The batch request containing multiple report request.
+--
+-- /See:/ 'getReportsRequest' smart constructor.
+data GetReportsRequest = GetReportsRequest'
+    { _grrUseResourceQuotas :: !(Maybe Bool)
+    , _grrReportRequests    :: !(Maybe [ReportRequest])
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'GetReportsRequest' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'grrUseResourceQuotas'
+--
+-- * 'grrReportRequests'
+getReportsRequest
+    :: GetReportsRequest
+getReportsRequest =
+    GetReportsRequest'
+    { _grrUseResourceQuotas = Nothing
+    , _grrReportRequests = Nothing
+    }
+
+-- | Enables [resource based
+-- quotas](\/analytics\/devguides\/reporting\/core\/v4\/limits-quotas#analytics_reporting_api_v4),
+-- (defaults to \`False\`). If this field is set to \`True\` the per view
+-- (profile) quotas are governed by the computational cost of the request.
+-- Note that using cost based quotas will higher enable sampling rates. (10
+-- Million for \`SMALL\`, 100M for \`LARGE\`. See the [limits and quotas
+-- documentation](\/analytics\/devguides\/reporting\/core\/v4\/limits-quotas#analytics_reporting_api_v4)
+-- for details.
+grrUseResourceQuotas :: Lens' GetReportsRequest (Maybe Bool)
+grrUseResourceQuotas
+  = lens _grrUseResourceQuotas
+      (\ s a -> s{_grrUseResourceQuotas = a})
+
+-- | Requests, each request will have a separate response. There can be a
+-- maximum of 5 requests. All requests should have the same \`dateRanges\`,
+-- \`viewId\`, \`segments\`, \`samplingLevel\`, and \`cohortGroup\`.
+grrReportRequests :: Lens' GetReportsRequest [ReportRequest]
+grrReportRequests
+  = lens _grrReportRequests
+      (\ s a -> s{_grrReportRequests = a})
+      . _Default
+      . _Coerce
+
+instance FromJSON GetReportsRequest where
+        parseJSON
+          = withObject "GetReportsRequest"
+              (\ o ->
+                 GetReportsRequest' <$>
+                   (o .:? "useResourceQuotas") <*>
+                     (o .:? "reportRequests" .!= mempty))
+
+instance ToJSON GetReportsRequest where
+        toJSON GetReportsRequest'{..}
+          = object
+              (catMaybes
+                 [("useResourceQuotas" .=) <$> _grrUseResourceQuotas,
+                  ("reportRequests" .=) <$> _grrReportRequests])
+
+-- | Defines a cohort. A cohort is a group of users who share a common
+-- characteristic. For example, all users with the same acquisition date
+-- belong to the same cohort.
+--
+-- /See:/ 'cohort' smart constructor.
+data Cohort = Cohort'
+    { _cDateRange :: !(Maybe DateRange)
+    , _cName      :: !(Maybe Text)
+    , _cType      :: !(Maybe CohortType)
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'Cohort' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'cDateRange'
+--
+-- * 'cName'
+--
+-- * 'cType'
+cohort
+    :: Cohort
+cohort =
+    Cohort'
+    { _cDateRange = Nothing
+    , _cName = Nothing
+    , _cType = Nothing
+    }
+
+-- | This is used for \`FIRST_VISIT_DATE\` cohort, the cohort selects users
+-- whose first visit date is between start date and end date defined in the
+-- DateRange. The date ranges should be aligned for cohort requests. If the
+-- request contains \`ga:cohortNthDay\` it should be exactly one day long,
+-- if \`ga:cohortNthWeek\` it should be aligned to the week boundary
+-- (starting at Sunday and ending Saturday), and for \`ga:cohortNthMonth\`
+-- the date range should be aligned to the month (starting at the first and
+-- ending on the last day of the month). For LTV requests there are no such
+-- restrictions. You do not need to supply a date range for the
+-- \`reportsRequest.dateRanges\` field.
+cDateRange :: Lens' Cohort (Maybe DateRange)
+cDateRange
+  = lens _cDateRange (\ s a -> s{_cDateRange = a})
+
+-- | A unique name for the cohort. If not defined name will be auto-generated
+-- with values cohort_[1234...].
+cName :: Lens' Cohort (Maybe Text)
+cName = lens _cName (\ s a -> s{_cName = a})
+
+-- | Type of the cohort. The only supported type as of now is
+-- \`FIRST_VISIT_DATE\`. If this field is unspecified the cohort is treated
+-- as \`FIRST_VISIT_DATE\` type cohort.
+cType :: Lens' Cohort (Maybe CohortType)
+cType = lens _cType (\ s a -> s{_cType = a})
+
+instance FromJSON Cohort where
+        parseJSON
+          = withObject "Cohort"
+              (\ o ->
+                 Cohort' <$>
+                   (o .:? "dateRange") <*> (o .:? "name") <*>
+                     (o .:? "type"))
+
+instance ToJSON Cohort where
+        toJSON Cohort'{..}
+          = object
+              (catMaybes
+                 [("dateRange" .=) <$> _cDateRange,
+                  ("name" .=) <$> _cName, ("type" .=) <$> _cType])
+
+-- | Dimension filter specifies the filtering options on a dimension.
+--
+-- /See:/ 'dimensionFilter' smart constructor.
+data DimensionFilter = DimensionFilter'
+    { _dfNot           :: !(Maybe Bool)
+    , _dfOperator      :: !(Maybe DimensionFilterOperator)
+    , _dfExpressions   :: !(Maybe [Text])
+    , _dfDimensionName :: !(Maybe Text)
+    , _dfCaseSensitive :: !(Maybe Bool)
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'DimensionFilter' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'dfNot'
+--
+-- * 'dfOperator'
+--
+-- * 'dfExpressions'
+--
+-- * 'dfDimensionName'
+--
+-- * 'dfCaseSensitive'
+dimensionFilter
+    :: DimensionFilter
+dimensionFilter =
+    DimensionFilter'
+    { _dfNot = Nothing
+    , _dfOperator = Nothing
+    , _dfExpressions = Nothing
+    , _dfDimensionName = Nothing
+    , _dfCaseSensitive = Nothing
+    }
+
+-- | Logical \`NOT\` operator. If this boolean is set to true, then the
+-- matching dimension values will be excluded in the report. The default is
+-- false.
+dfNot :: Lens' DimensionFilter (Maybe Bool)
+dfNot = lens _dfNot (\ s a -> s{_dfNot = a})
+
+-- | How to match the dimension to the expression. The default is REGEXP.
+dfOperator :: Lens' DimensionFilter (Maybe DimensionFilterOperator)
+dfOperator
+  = lens _dfOperator (\ s a -> s{_dfOperator = a})
+
+-- | Strings or regular expression to match against. Only the first value of
+-- the list is used for comparison unless the operator is \`IN_LIST\`. If
+-- \`IN_LIST\` operator, then the entire list is used to filter the
+-- dimensions as explained in the description of the \`IN_LIST\` operator.
+dfExpressions :: Lens' DimensionFilter [Text]
+dfExpressions
+  = lens _dfExpressions
+      (\ s a -> s{_dfExpressions = a})
+      . _Default
+      . _Coerce
+
+-- | The dimension to filter on. A DimensionFilter must contain a dimension.
+dfDimensionName :: Lens' DimensionFilter (Maybe Text)
+dfDimensionName
+  = lens _dfDimensionName
+      (\ s a -> s{_dfDimensionName = a})
+
+-- | Should the match be case sensitive? Default is false.
+dfCaseSensitive :: Lens' DimensionFilter (Maybe Bool)
+dfCaseSensitive
+  = lens _dfCaseSensitive
+      (\ s a -> s{_dfCaseSensitive = a})
+
+instance FromJSON DimensionFilter where
+        parseJSON
+          = withObject "DimensionFilter"
+              (\ o ->
+                 DimensionFilter' <$>
+                   (o .:? "not") <*> (o .:? "operator") <*>
+                     (o .:? "expressions" .!= mempty)
+                     <*> (o .:? "dimensionName")
+                     <*> (o .:? "caseSensitive"))
+
+instance ToJSON DimensionFilter where
+        toJSON DimensionFilter'{..}
+          = object
+              (catMaybes
+                 [("not" .=) <$> _dfNot,
+                  ("operator" .=) <$> _dfOperator,
+                  ("expressions" .=) <$> _dfExpressions,
+                  ("dimensionName" .=) <$> _dfDimensionName,
+                  ("caseSensitive" .=) <$> _dfCaseSensitive])
+
+-- | The main response class which holds the reports from the Reporting API
+-- \`batchGet\` call.
+--
+-- /See:/ 'getReportsResponse' smart constructor.
+data GetReportsResponse = GetReportsResponse'
+    { _grrReports                 :: !(Maybe [Report])
+    , _grrResourceQuotasRemaining :: !(Maybe ResourceQuotasRemaining)
+    , _grrQueryCost               :: !(Maybe (Textual Int32))
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'GetReportsResponse' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'grrReports'
+--
+-- * 'grrResourceQuotasRemaining'
+--
+-- * 'grrQueryCost'
+getReportsResponse
+    :: GetReportsResponse
+getReportsResponse =
+    GetReportsResponse'
+    { _grrReports = Nothing
+    , _grrResourceQuotasRemaining = Nothing
+    , _grrQueryCost = Nothing
+    }
+
+-- | Responses corresponding to each of the request.
+grrReports :: Lens' GetReportsResponse [Report]
+grrReports
+  = lens _grrReports (\ s a -> s{_grrReports = a}) .
+      _Default
+      . _Coerce
+
+-- | The amount of resource quota remaining for the property.
+grrResourceQuotasRemaining :: Lens' GetReportsResponse (Maybe ResourceQuotasRemaining)
+grrResourceQuotasRemaining
+  = lens _grrResourceQuotasRemaining
+      (\ s a -> s{_grrResourceQuotasRemaining = a})
+
+-- | The amount of resource quota tokens deducted to execute the query.
+-- Includes all responses.
+grrQueryCost :: Lens' GetReportsResponse (Maybe Int32)
+grrQueryCost
+  = lens _grrQueryCost (\ s a -> s{_grrQueryCost = a})
+      . mapping _Coerce
+
+instance FromJSON GetReportsResponse where
+        parseJSON
+          = withObject "GetReportsResponse"
+              (\ o ->
+                 GetReportsResponse' <$>
+                   (o .:? "reports" .!= mempty) <*>
+                     (o .:? "resourceQuotasRemaining")
+                     <*> (o .:? "queryCost"))
+
+instance ToJSON GetReportsResponse where
+        toJSON GetReportsResponse'{..}
+          = object
+              (catMaybes
+                 [("reports" .=) <$> _grrReports,
+                  ("resourceQuotasRemaining" .=) <$>
+                    _grrResourceQuotasRemaining,
+                  ("queryCost" .=) <$> _grrQueryCost])
+
+-- | The segment definition, if the report needs to be segmented. A Segment
+-- is a subset of the Analytics data. For example, of the entire set of
+-- users, one Segment might be users from a particular country or city.
+--
+-- /See:/ 'segment' smart constructor.
+data Segment = Segment'
+    { _sDynamicSegment :: !(Maybe DynamicSegment)
+    , _sSegmentId      :: !(Maybe Text)
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'Segment' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'sDynamicSegment'
+--
+-- * 'sSegmentId'
+segment
+    :: Segment
+segment =
+    Segment'
+    { _sDynamicSegment = Nothing
+    , _sSegmentId = Nothing
+    }
+
+-- | A dynamic segment definition in the request.
+sDynamicSegment :: Lens' Segment (Maybe DynamicSegment)
+sDynamicSegment
+  = lens _sDynamicSegment
+      (\ s a -> s{_sDynamicSegment = a})
+
+-- | The segment ID of a built-in or custom segment, for example
+-- \`gaid::-3\`.
+sSegmentId :: Lens' Segment (Maybe Text)
+sSegmentId
+  = lens _sSegmentId (\ s a -> s{_sSegmentId = a})
+
+instance FromJSON Segment where
+        parseJSON
+          = withObject "Segment"
+              (\ o ->
+                 Segment' <$>
+                   (o .:? "dynamicSegment") <*> (o .:? "segmentId"))
+
+instance ToJSON Segment where
+        toJSON Segment'{..}
+          = object
+              (catMaybes
+                 [("dynamicSegment" .=) <$> _sDynamicSegment,
+                  ("segmentId" .=) <$> _sSegmentId])
+
+-- | The resource quota tokens remaining for the property after the request
+-- is completed.
+--
+-- /See:/ 'resourceQuotasRemaining' smart constructor.
+data ResourceQuotasRemaining = ResourceQuotasRemaining'
+    { _rqrHourlyQuotaTokensRemaining :: !(Maybe (Textual Int32))
+    , _rqrDailyQuotaTokensRemaining  :: !(Maybe (Textual Int32))
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'ResourceQuotasRemaining' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'rqrHourlyQuotaTokensRemaining'
+--
+-- * 'rqrDailyQuotaTokensRemaining'
+resourceQuotasRemaining
+    :: ResourceQuotasRemaining
+resourceQuotasRemaining =
+    ResourceQuotasRemaining'
+    { _rqrHourlyQuotaTokensRemaining = Nothing
+    , _rqrDailyQuotaTokensRemaining = Nothing
+    }
+
+-- | Hourly resource quota tokens remaining.
+rqrHourlyQuotaTokensRemaining :: Lens' ResourceQuotasRemaining (Maybe Int32)
+rqrHourlyQuotaTokensRemaining
+  = lens _rqrHourlyQuotaTokensRemaining
+      (\ s a -> s{_rqrHourlyQuotaTokensRemaining = a})
+      . mapping _Coerce
+
+-- | Daily resource quota remaining remaining.
+rqrDailyQuotaTokensRemaining :: Lens' ResourceQuotasRemaining (Maybe Int32)
+rqrDailyQuotaTokensRemaining
+  = lens _rqrDailyQuotaTokensRemaining
+      (\ s a -> s{_rqrDailyQuotaTokensRemaining = a})
+      . mapping _Coerce
+
+instance FromJSON ResourceQuotasRemaining where
+        parseJSON
+          = withObject "ResourceQuotasRemaining"
+              (\ o ->
+                 ResourceQuotasRemaining' <$>
+                   (o .:? "hourlyQuotaTokensRemaining") <*>
+                     (o .:? "dailyQuotaTokensRemaining"))
+
+instance ToJSON ResourceQuotasRemaining where
+        toJSON ResourceQuotasRemaining'{..}
+          = object
+              (catMaybes
+                 [("hourlyQuotaTokensRemaining" .=) <$>
+                    _rqrHourlyQuotaTokensRemaining,
+                  ("dailyQuotaTokensRemaining" .=) <$>
+                    _rqrDailyQuotaTokensRemaining])
+
+-- | Dimension filter specifies the filtering options on a dimension.
+--
+-- /See:/ 'segmentDimensionFilter' smart constructor.
+data SegmentDimensionFilter = SegmentDimensionFilter'
+    { _sdfOperator           :: !(Maybe SegmentDimensionFilterOperator)
+    , _sdfMinComparisonValue :: !(Maybe Text)
+    , _sdfMaxComparisonValue :: !(Maybe Text)
+    , _sdfExpressions        :: !(Maybe [Text])
+    , _sdfDimensionName      :: !(Maybe Text)
+    , _sdfCaseSensitive      :: !(Maybe Bool)
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'SegmentDimensionFilter' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'sdfOperator'
+--
+-- * 'sdfMinComparisonValue'
+--
+-- * 'sdfMaxComparisonValue'
+--
+-- * 'sdfExpressions'
+--
+-- * 'sdfDimensionName'
+--
+-- * 'sdfCaseSensitive'
+segmentDimensionFilter
+    :: SegmentDimensionFilter
+segmentDimensionFilter =
+    SegmentDimensionFilter'
+    { _sdfOperator = Nothing
+    , _sdfMinComparisonValue = Nothing
+    , _sdfMaxComparisonValue = Nothing
+    , _sdfExpressions = Nothing
+    , _sdfDimensionName = Nothing
+    , _sdfCaseSensitive = Nothing
+    }
+
+-- | The operator to use to match the dimension with the expressions.
+sdfOperator :: Lens' SegmentDimensionFilter (Maybe SegmentDimensionFilterOperator)
+sdfOperator
+  = lens _sdfOperator (\ s a -> s{_sdfOperator = a})
+
+-- | Minimum comparison values for \`BETWEEN\` match type.
+sdfMinComparisonValue :: Lens' SegmentDimensionFilter (Maybe Text)
+sdfMinComparisonValue
+  = lens _sdfMinComparisonValue
+      (\ s a -> s{_sdfMinComparisonValue = a})
+
+-- | Maximum comparison values for \`BETWEEN\` match type.
+sdfMaxComparisonValue :: Lens' SegmentDimensionFilter (Maybe Text)
+sdfMaxComparisonValue
+  = lens _sdfMaxComparisonValue
+      (\ s a -> s{_sdfMaxComparisonValue = a})
+
+-- | The list of expressions, only the first element is used for all
+-- operators
+sdfExpressions :: Lens' SegmentDimensionFilter [Text]
+sdfExpressions
+  = lens _sdfExpressions
+      (\ s a -> s{_sdfExpressions = a})
+      . _Default
+      . _Coerce
+
+-- | Name of the dimension for which the filter is being applied.
+sdfDimensionName :: Lens' SegmentDimensionFilter (Maybe Text)
+sdfDimensionName
+  = lens _sdfDimensionName
+      (\ s a -> s{_sdfDimensionName = a})
+
+-- | Should the match be case sensitive, ignored for \`IN_LIST\` operator.
+sdfCaseSensitive :: Lens' SegmentDimensionFilter (Maybe Bool)
+sdfCaseSensitive
+  = lens _sdfCaseSensitive
+      (\ s a -> s{_sdfCaseSensitive = a})
+
+instance FromJSON SegmentDimensionFilter where
+        parseJSON
+          = withObject "SegmentDimensionFilter"
+              (\ o ->
+                 SegmentDimensionFilter' <$>
+                   (o .:? "operator") <*> (o .:? "minComparisonValue")
+                     <*> (o .:? "maxComparisonValue")
+                     <*> (o .:? "expressions" .!= mempty)
+                     <*> (o .:? "dimensionName")
+                     <*> (o .:? "caseSensitive"))
+
+instance ToJSON SegmentDimensionFilter where
+        toJSON SegmentDimensionFilter'{..}
+          = object
+              (catMaybes
+                 [("operator" .=) <$> _sdfOperator,
+                  ("minComparisonValue" .=) <$> _sdfMinComparisonValue,
+                  ("maxComparisonValue" .=) <$> _sdfMaxComparisonValue,
+                  ("expressions" .=) <$> _sdfExpressions,
+                  ("dimensionName" .=) <$> _sdfDimensionName,
+                  ("caseSensitive" .=) <$> _sdfCaseSensitive])
+
+-- | Dynamic segment definition for defining the segment within the request.
+-- A segment can select users, sessions or both.
+--
+-- /See:/ 'dynamicSegment' smart constructor.
+data DynamicSegment = DynamicSegment'
+    { _dsUserSegment    :: !(Maybe SegmentDefinition)
+    , _dsName           :: !(Maybe Text)
+    , _dsSessionSegment :: !(Maybe SegmentDefinition)
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'DynamicSegment' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'dsUserSegment'
+--
+-- * 'dsName'
+--
+-- * 'dsSessionSegment'
+dynamicSegment
+    :: DynamicSegment
+dynamicSegment =
+    DynamicSegment'
+    { _dsUserSegment = Nothing
+    , _dsName = Nothing
+    , _dsSessionSegment = Nothing
+    }
+
+-- | User Segment to select users to include in the segment.
+dsUserSegment :: Lens' DynamicSegment (Maybe SegmentDefinition)
+dsUserSegment
+  = lens _dsUserSegment
+      (\ s a -> s{_dsUserSegment = a})
+
+-- | The name of the dynamic segment.
+dsName :: Lens' DynamicSegment (Maybe Text)
+dsName = lens _dsName (\ s a -> s{_dsName = a})
+
+-- | Session Segment to select sessions to include in the segment.
+dsSessionSegment :: Lens' DynamicSegment (Maybe SegmentDefinition)
+dsSessionSegment
+  = lens _dsSessionSegment
+      (\ s a -> s{_dsSessionSegment = a})
+
+instance FromJSON DynamicSegment where
+        parseJSON
+          = withObject "DynamicSegment"
+              (\ o ->
+                 DynamicSegment' <$>
+                   (o .:? "userSegment") <*> (o .:? "name") <*>
+                     (o .:? "sessionSegment"))
+
+instance ToJSON DynamicSegment where
+        toJSON DynamicSegment'{..}
+          = object
+              (catMaybes
+                 [("userSegment" .=) <$> _dsUserSegment,
+                  ("name" .=) <$> _dsName,
+                  ("sessionSegment" .=) <$> _dsSessionSegment])
+
+-- | Represents a group of metric filters. Set the operator value to specify
+-- how the filters are logically combined.
+--
+-- /See:/ 'metricFilterClause' smart constructor.
+data MetricFilterClause = MetricFilterClause'
+    { _mfcOperator :: !(Maybe MetricFilterClauseOperator)
+    , _mfcFilters  :: !(Maybe [MetricFilter])
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'MetricFilterClause' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'mfcOperator'
+--
+-- * 'mfcFilters'
+metricFilterClause
+    :: MetricFilterClause
+metricFilterClause =
+    MetricFilterClause'
+    { _mfcOperator = Nothing
+    , _mfcFilters = Nothing
+    }
+
+-- | The operator for combining multiple metric filters. If unspecified, it
+-- is treated as an \`OR\`.
+mfcOperator :: Lens' MetricFilterClause (Maybe MetricFilterClauseOperator)
+mfcOperator
+  = lens _mfcOperator (\ s a -> s{_mfcOperator = a})
+
+-- | The repeated set of filters. They are logically combined based on the
+-- operator specified.
+mfcFilters :: Lens' MetricFilterClause [MetricFilter]
+mfcFilters
+  = lens _mfcFilters (\ s a -> s{_mfcFilters = a}) .
+      _Default
+      . _Coerce
+
+instance FromJSON MetricFilterClause where
+        parseJSON
+          = withObject "MetricFilterClause"
+              (\ o ->
+                 MetricFilterClause' <$>
+                   (o .:? "operator") <*> (o .:? "filters" .!= mempty))
+
+instance ToJSON MetricFilterClause where
+        toJSON MetricFilterClause'{..}
+          = object
+              (catMaybes
+                 [("operator" .=) <$> _mfcOperator,
+                  ("filters" .=) <$> _mfcFilters])
+
+-- | Column headers.
+--
+-- /See:/ 'columnHeader' smart constructor.
+data ColumnHeader = ColumnHeader'
+    { _chMetricHeader :: !(Maybe MetricHeader)
+    , _chDimensions   :: !(Maybe [Text])
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'ColumnHeader' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'chMetricHeader'
+--
+-- * 'chDimensions'
+columnHeader
+    :: ColumnHeader
+columnHeader =
+    ColumnHeader'
+    { _chMetricHeader = Nothing
+    , _chDimensions = Nothing
+    }
+
+-- | Metric headers for the metrics in the response.
+chMetricHeader :: Lens' ColumnHeader (Maybe MetricHeader)
+chMetricHeader
+  = lens _chMetricHeader
+      (\ s a -> s{_chMetricHeader = a})
+
+-- | The dimension names in the response.
+chDimensions :: Lens' ColumnHeader [Text]
+chDimensions
+  = lens _chDimensions (\ s a -> s{_chDimensions = a})
+      . _Default
+      . _Coerce
+
+instance FromJSON ColumnHeader where
+        parseJSON
+          = withObject "ColumnHeader"
+              (\ o ->
+                 ColumnHeader' <$>
+                   (o .:? "metricHeader") <*>
+                     (o .:? "dimensions" .!= mempty))
+
+instance ToJSON ColumnHeader where
+        toJSON ColumnHeader'{..}
+          = object
+              (catMaybes
+                 [("metricHeader" .=) <$> _chMetricHeader,
+                  ("dimensions" .=) <$> _chDimensions])
diff --git a/gen/Network/Google/AnalyticsReporting/Types/Sum.hs b/gen/Network/Google/AnalyticsReporting/Types/Sum.hs
new file mode 100644
--- /dev/null
+++ b/gen/Network/Google/AnalyticsReporting/Types/Sum.hs
@@ -0,0 +1,731 @@
+{-# LANGUAGE DeriveDataTypeable #-}
+{-# LANGUAGE DeriveGeneric      #-}
+{-# LANGUAGE LambdaCase         #-}
+{-# LANGUAGE NoImplicitPrelude  #-}
+{-# LANGUAGE OverloadedStrings  #-}
+
+{-# OPTIONS_GHC -fno-warn-unused-imports #-}
+
+-- |
+-- Module      : Network.Google.AnalyticsReporting.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.AnalyticsReporting.Types.Sum where
+
+import           Network.Google.Prelude hiding (Bytes)
+
+-- | Is the metric \`EQUAL\`, \`LESS_THAN\` or \`GREATER_THAN\` the
+-- comparisonValue, the default is \`EQUAL\`. If the operator is
+-- \`IS_MISSING\`, checks if the metric is missing and would ignore the
+-- comparisonValue.
+data MetricFilterOperator
+    = OperatorUnspecified
+      -- ^ @OPERATOR_UNSPECIFIED@
+      -- If the operator is not specified, it is treated as \`EQUAL\`.
+    | Equal
+      -- ^ @EQUAL@
+      -- Should the value of the metric be exactly equal to the comparison value.
+    | LessThan
+      -- ^ @LESS_THAN@
+      -- Should the value of the metric be less than to the comparison value.
+    | GreaterThan
+      -- ^ @GREATER_THAN@
+      -- Should the value of the metric be greater than to the comparison value.
+    | IsMissing
+      -- ^ @IS_MISSING@
+      -- Validates if the metric is missing. Doesn\'t take comparisonValue into
+      -- account.
+      deriving (Eq, Ord, Enum, Read, Show, Data, Typeable, Generic)
+
+instance Hashable MetricFilterOperator
+
+instance FromHttpApiData MetricFilterOperator where
+    parseQueryParam = \case
+        "OPERATOR_UNSPECIFIED" -> Right OperatorUnspecified
+        "EQUAL" -> Right Equal
+        "LESS_THAN" -> Right LessThan
+        "GREATER_THAN" -> Right GreaterThan
+        "IS_MISSING" -> Right IsMissing
+        x -> Left ("Unable to parse MetricFilterOperator from: " <> x)
+
+instance ToHttpApiData MetricFilterOperator where
+    toQueryParam = \case
+        OperatorUnspecified -> "OPERATOR_UNSPECIFIED"
+        Equal -> "EQUAL"
+        LessThan -> "LESS_THAN"
+        GreaterThan -> "GREATER_THAN"
+        IsMissing -> "IS_MISSING"
+
+instance FromJSON MetricFilterOperator where
+    parseJSON = parseJSONText "MetricFilterOperator"
+
+instance ToJSON MetricFilterOperator where
+    toJSON = toJSONText
+
+-- | The operator for combining multiple dimension filters. If unspecified,
+-- it is treated as an \`OR\`.
+data DimensionFilterClauseOperator
+    = DFCOOperatorUnspecified
+      -- ^ @OPERATOR_UNSPECIFIED@
+      -- Unspecified operator. It is treated as an \`OR\`.
+    | DFCOOR
+      -- ^ @OR@
+      -- The logical \`OR\` operator.
+    | DFCOAnd
+      -- ^ @AND@
+      -- The logical \`AND\` operator.
+      deriving (Eq, Ord, Enum, Read, Show, Data, Typeable, Generic)
+
+instance Hashable DimensionFilterClauseOperator
+
+instance FromHttpApiData DimensionFilterClauseOperator where
+    parseQueryParam = \case
+        "OPERATOR_UNSPECIFIED" -> Right DFCOOperatorUnspecified
+        "OR" -> Right DFCOOR
+        "AND" -> Right DFCOAnd
+        x -> Left ("Unable to parse DimensionFilterClauseOperator from: " <> x)
+
+instance ToHttpApiData DimensionFilterClauseOperator where
+    toQueryParam = \case
+        DFCOOperatorUnspecified -> "OPERATOR_UNSPECIFIED"
+        DFCOOR -> "OR"
+        DFCOAnd -> "AND"
+
+instance FromJSON DimensionFilterClauseOperator where
+    parseJSON = parseJSONText "DimensionFilterClauseOperator"
+
+instance ToJSON DimensionFilterClauseOperator where
+    toJSON = toJSONText
+
+-- | Type of the cohort. The only supported type as of now is
+-- \`FIRST_VISIT_DATE\`. If this field is unspecified the cohort is treated
+-- as \`FIRST_VISIT_DATE\` type cohort.
+data CohortType
+    = UnspecifiedCohortType
+      -- ^ @UNSPECIFIED_COHORT_TYPE@
+      -- If unspecified it\'s treated as \`FIRST_VISIT_DATE\`.
+    | FirstVisitDate
+      -- ^ @FIRST_VISIT_DATE@
+      -- Cohorts that are selected based on first visit date.
+      deriving (Eq, Ord, Enum, Read, Show, Data, Typeable, Generic)
+
+instance Hashable CohortType
+
+instance FromHttpApiData CohortType where
+    parseQueryParam = \case
+        "UNSPECIFIED_COHORT_TYPE" -> Right UnspecifiedCohortType
+        "FIRST_VISIT_DATE" -> Right FirstVisitDate
+        x -> Left ("Unable to parse CohortType from: " <> x)
+
+instance ToHttpApiData CohortType where
+    toQueryParam = \case
+        UnspecifiedCohortType -> "UNSPECIFIED_COHORT_TYPE"
+        FirstVisitDate -> "FIRST_VISIT_DATE"
+
+instance FromJSON CohortType where
+    parseJSON = parseJSONText "CohortType"
+
+instance ToJSON CohortType where
+    toJSON = toJSONText
+
+-- | The order type. The default orderType is \`VALUE\`.
+data OrderByOrderType
+    = OrderTypeUnspecified
+      -- ^ @ORDER_TYPE_UNSPECIFIED@
+      -- Unspecified order type will be treated as sort based on value.
+    | Value
+      -- ^ @VALUE@
+      -- The sort order is based on the value of the chosen column; looks only at
+      -- the first date range.
+    | Delta
+      -- ^ @DELTA@
+      -- The sort order is based on the difference of the values of the chosen
+      -- column between the first two date ranges. Usable only if there are
+      -- exactly two date ranges.
+    | Smart
+      -- ^ @SMART@
+      -- The sort order is based on weighted value of the chosen column. If
+      -- column has n\/d format, then weighted value of this ratio will be \`(n +
+      -- totals.n)\/(d + totals.d)\` Usable only for metrics that represent
+      -- ratios.
+    | HistogramBucket
+      -- ^ @HISTOGRAM_BUCKET@
+      -- Histogram order type is applicable only to dimension columns with
+      -- non-empty histogram-buckets.
+    | DimensionAsInteger
+      -- ^ @DIMENSION_AS_INTEGER@
+      -- If the dimensions are fixed length numbers, ordinary sort would just
+      -- work fine. \`DIMENSION_AS_INTEGER\` can be used if the dimensions are
+      -- variable length numbers.
+      deriving (Eq, Ord, Enum, Read, Show, Data, Typeable, Generic)
+
+instance Hashable OrderByOrderType
+
+instance FromHttpApiData OrderByOrderType where
+    parseQueryParam = \case
+        "ORDER_TYPE_UNSPECIFIED" -> Right OrderTypeUnspecified
+        "VALUE" -> Right Value
+        "DELTA" -> Right Delta
+        "SMART" -> Right Smart
+        "HISTOGRAM_BUCKET" -> Right HistogramBucket
+        "DIMENSION_AS_INTEGER" -> Right DimensionAsInteger
+        x -> Left ("Unable to parse OrderByOrderType from: " <> x)
+
+instance ToHttpApiData OrderByOrderType where
+    toQueryParam = \case
+        OrderTypeUnspecified -> "ORDER_TYPE_UNSPECIFIED"
+        Value -> "VALUE"
+        Delta -> "DELTA"
+        Smart -> "SMART"
+        HistogramBucket -> "HISTOGRAM_BUCKET"
+        DimensionAsInteger -> "DIMENSION_AS_INTEGER"
+
+instance FromJSON OrderByOrderType where
+    parseJSON = parseJSONText "OrderByOrderType"
+
+instance ToJSON OrderByOrderType where
+    toJSON = toJSONText
+
+-- | The sorting order for the field.
+data OrderBySortOrder
+    = SortOrderUnspecified
+      -- ^ @SORT_ORDER_UNSPECIFIED@
+      -- If the sort order is unspecified, the default is ascending.
+    | Ascending
+      -- ^ @ASCENDING@
+      -- Ascending sort. The field will be sorted in an ascending manner.
+    | Descending
+      -- ^ @DESCENDING@
+      -- Descending sort. The field will be sorted in a descending manner.
+      deriving (Eq, Ord, Enum, Read, Show, Data, Typeable, Generic)
+
+instance Hashable OrderBySortOrder
+
+instance FromHttpApiData OrderBySortOrder where
+    parseQueryParam = \case
+        "SORT_ORDER_UNSPECIFIED" -> Right SortOrderUnspecified
+        "ASCENDING" -> Right Ascending
+        "DESCENDING" -> Right Descending
+        x -> Left ("Unable to parse OrderBySortOrder from: " <> x)
+
+instance ToHttpApiData OrderBySortOrder where
+    toQueryParam = \case
+        SortOrderUnspecified -> "SORT_ORDER_UNSPECIFIED"
+        Ascending -> "ASCENDING"
+        Descending -> "DESCENDING"
+
+instance FromJSON OrderBySortOrder where
+    parseJSON = parseJSONText "OrderBySortOrder"
+
+instance ToJSON OrderBySortOrder where
+    toJSON = toJSONText
+
+-- | Specifies is the operation to perform to compare the metric. The default
+-- is \`EQUAL\`.
+data SegmentMetricFilterOperator
+    = SMFOUnspecifiedOperator
+      -- ^ @UNSPECIFIED_OPERATOR@
+      -- Unspecified operator is treated as \`LESS_THAN\` operator.
+    | SMFOLessThan
+      -- ^ @LESS_THAN@
+      -- Checks if the metric value is less than comparison value.
+    | SMFOGreaterThan
+      -- ^ @GREATER_THAN@
+      -- Checks if the metric value is greater than comparison value.
+    | SMFOEqual
+      -- ^ @EQUAL@
+      -- Equals operator.
+    | SMFOBetween
+      -- ^ @BETWEEN@
+      -- For between operator, both the minimum and maximum are exclusive. We
+      -- will use \`LT\` and \`GT\` for comparison.
+      deriving (Eq, Ord, Enum, Read, Show, Data, Typeable, Generic)
+
+instance Hashable SegmentMetricFilterOperator
+
+instance FromHttpApiData SegmentMetricFilterOperator where
+    parseQueryParam = \case
+        "UNSPECIFIED_OPERATOR" -> Right SMFOUnspecifiedOperator
+        "LESS_THAN" -> Right SMFOLessThan
+        "GREATER_THAN" -> Right SMFOGreaterThan
+        "EQUAL" -> Right SMFOEqual
+        "BETWEEN" -> Right SMFOBetween
+        x -> Left ("Unable to parse SegmentMetricFilterOperator from: " <> x)
+
+instance ToHttpApiData SegmentMetricFilterOperator where
+    toQueryParam = \case
+        SMFOUnspecifiedOperator -> "UNSPECIFIED_OPERATOR"
+        SMFOLessThan -> "LESS_THAN"
+        SMFOGreaterThan -> "GREATER_THAN"
+        SMFOEqual -> "EQUAL"
+        SMFOBetween -> "BETWEEN"
+
+instance FromJSON SegmentMetricFilterOperator where
+    parseJSON = parseJSONText "SegmentMetricFilterOperator"
+
+instance ToJSON SegmentMetricFilterOperator where
+    toJSON = toJSONText
+
+-- | The type of the metric, for example \`INTEGER\`.
+data MetricHeaderEntryType
+    = MetricTypeUnspecified
+      -- ^ @METRIC_TYPE_UNSPECIFIED@
+      -- Metric type is unspecified.
+    | Integer
+      -- ^ @INTEGER@
+      -- Integer metric.
+    | Float
+      -- ^ @FLOAT@
+      -- Float metric.
+    | Currency
+      -- ^ @CURRENCY@
+      -- Currency metric.
+    | Percent
+      -- ^ @PERCENT@
+      -- Percentage metric.
+    | Time
+      -- ^ @TIME@
+      -- Time metric in \`HH:MM:SS\` format.
+      deriving (Eq, Ord, Enum, Read, Show, Data, Typeable, Generic)
+
+instance Hashable MetricHeaderEntryType
+
+instance FromHttpApiData MetricHeaderEntryType where
+    parseQueryParam = \case
+        "METRIC_TYPE_UNSPECIFIED" -> Right MetricTypeUnspecified
+        "INTEGER" -> Right Integer
+        "FLOAT" -> Right Float
+        "CURRENCY" -> Right Currency
+        "PERCENT" -> Right Percent
+        "TIME" -> Right Time
+        x -> Left ("Unable to parse MetricHeaderEntryType from: " <> x)
+
+instance ToHttpApiData MetricHeaderEntryType where
+    toQueryParam = \case
+        MetricTypeUnspecified -> "METRIC_TYPE_UNSPECIFIED"
+        Integer -> "INTEGER"
+        Float -> "FLOAT"
+        Currency -> "CURRENCY"
+        Percent -> "PERCENT"
+        Time -> "TIME"
+
+instance FromJSON MetricHeaderEntryType where
+    parseJSON = parseJSONText "MetricHeaderEntryType"
+
+instance ToJSON MetricHeaderEntryType where
+    toJSON = toJSONText
+
+-- | The desired report
+-- [sample](https:\/\/support.google.com\/analytics\/answer\/2637192) size.
+-- If the the \`samplingLevel\` field is unspecified the \`DEFAULT\`
+-- sampling level is used. Every [ReportRequest](#ReportRequest) within a
+-- \`batchGet\` method must contain the same \`samplingLevel\` definition.
+-- See [developer
+-- guide](\/analytics\/devguides\/reporting\/core\/v4\/basics#sampling) for
+-- details.
+data ReportRequestSamplingLevel
+    = SamplingUnspecified
+      -- ^ @SAMPLING_UNSPECIFIED@
+      -- If the \`samplingLevel\` field is unspecified the \`DEFAULT\` sampling
+      -- level is used.
+    | Default
+      -- ^ @DEFAULT@
+      -- Returns response with a sample size that balances speed and accuracy.
+    | Small
+      -- ^ @SMALL@
+      -- It returns a fast response with a smaller sampling size.
+    | Large
+      -- ^ @LARGE@
+      -- Returns a more accurate response using a large sampling size. But this
+      -- may result in response being slower.
+      deriving (Eq, Ord, Enum, Read, Show, Data, Typeable, Generic)
+
+instance Hashable ReportRequestSamplingLevel
+
+instance FromHttpApiData ReportRequestSamplingLevel where
+    parseQueryParam = \case
+        "SAMPLING_UNSPECIFIED" -> Right SamplingUnspecified
+        "DEFAULT" -> Right Default
+        "SMALL" -> Right Small
+        "LARGE" -> Right Large
+        x -> Left ("Unable to parse ReportRequestSamplingLevel from: " <> x)
+
+instance ToHttpApiData ReportRequestSamplingLevel where
+    toQueryParam = \case
+        SamplingUnspecified -> "SAMPLING_UNSPECIFIED"
+        Default -> "DEFAULT"
+        Small -> "SMALL"
+        Large -> "LARGE"
+
+instance FromJSON ReportRequestSamplingLevel where
+    parseJSON = parseJSONText "ReportRequestSamplingLevel"
+
+instance ToJSON ReportRequestSamplingLevel where
+    toJSON = toJSONText
+
+-- | V1 error format.
+data Xgafv
+    = X1
+      -- ^ @1@
+      -- v1 error format
+    | X2
+      -- ^ @2@
+      -- v2 error format
+      deriving (Eq, Ord, Enum, Read, Show, Data, Typeable, Generic)
+
+instance Hashable Xgafv
+
+instance FromHttpApiData Xgafv where
+    parseQueryParam = \case
+        "1" -> Right X1
+        "2" -> Right X2
+        x -> Left ("Unable to parse Xgafv from: " <> x)
+
+instance ToHttpApiData Xgafv where
+    toQueryParam = \case
+        X1 -> "1"
+        X2 -> "2"
+
+instance FromJSON Xgafv where
+    parseJSON = parseJSONText "Xgafv"
+
+instance ToJSON Xgafv where
+    toJSON = toJSONText
+
+-- | Specifies if the step immediately precedes or can be any time before the
+-- next step.
+data SegmentSequenceStepMatchType
+    = UnspecifiedMatchType
+      -- ^ @UNSPECIFIED_MATCH_TYPE@
+      -- Unspecified match type is treated as precedes.
+    | Precedes
+      -- ^ @PRECEDES@
+      -- Operator indicates that the previous step precedes the next step.
+    | ImmediatelyPrecedes
+      -- ^ @IMMEDIATELY_PRECEDES@
+      -- Operator indicates that the previous step immediately precedes the next
+      -- step.
+      deriving (Eq, Ord, Enum, Read, Show, Data, Typeable, Generic)
+
+instance Hashable SegmentSequenceStepMatchType
+
+instance FromHttpApiData SegmentSequenceStepMatchType where
+    parseQueryParam = \case
+        "UNSPECIFIED_MATCH_TYPE" -> Right UnspecifiedMatchType
+        "PRECEDES" -> Right Precedes
+        "IMMEDIATELY_PRECEDES" -> Right ImmediatelyPrecedes
+        x -> Left ("Unable to parse SegmentSequenceStepMatchType from: " <> x)
+
+instance ToHttpApiData SegmentSequenceStepMatchType where
+    toQueryParam = \case
+        UnspecifiedMatchType -> "UNSPECIFIED_MATCH_TYPE"
+        Precedes -> "PRECEDES"
+        ImmediatelyPrecedes -> "IMMEDIATELY_PRECEDES"
+
+instance FromJSON SegmentSequenceStepMatchType where
+    parseJSON = parseJSONText "SegmentSequenceStepMatchType"
+
+instance ToJSON SegmentSequenceStepMatchType where
+    toJSON = toJSONText
+
+-- | Scope for a metric defines the level at which that metric is defined.
+-- The specified metric scope must be equal to or greater than its primary
+-- scope as defined in the data model. The primary scope is defined by if
+-- the segment is selecting users or sessions.
+data SegmentMetricFilterScope
+    = UnspecifiedScope
+      -- ^ @UNSPECIFIED_SCOPE@
+      -- If the scope is unspecified, it defaults to the condition scope,
+      -- \`USER\` or \`SESSION\` depending on if the segment is trying to choose
+      -- users or sessions.
+    | Product
+      -- ^ @PRODUCT@
+      -- Product scope.
+    | Hit
+      -- ^ @HIT@
+      -- Hit scope.
+    | Session
+      -- ^ @SESSION@
+      -- Session scope.
+    | User
+      -- ^ @USER@
+      -- User scope.
+      deriving (Eq, Ord, Enum, Read, Show, Data, Typeable, Generic)
+
+instance Hashable SegmentMetricFilterScope
+
+instance FromHttpApiData SegmentMetricFilterScope where
+    parseQueryParam = \case
+        "UNSPECIFIED_SCOPE" -> Right UnspecifiedScope
+        "PRODUCT" -> Right Product
+        "HIT" -> Right Hit
+        "SESSION" -> Right Session
+        "USER" -> Right User
+        x -> Left ("Unable to parse SegmentMetricFilterScope from: " <> x)
+
+instance ToHttpApiData SegmentMetricFilterScope where
+    toQueryParam = \case
+        UnspecifiedScope -> "UNSPECIFIED_SCOPE"
+        Product -> "PRODUCT"
+        Hit -> "HIT"
+        Session -> "SESSION"
+        User -> "USER"
+
+instance FromJSON SegmentMetricFilterScope where
+    parseJSON = parseJSONText "SegmentMetricFilterScope"
+
+instance ToJSON SegmentMetricFilterScope where
+    toJSON = toJSONText
+
+-- | How to match the dimension to the expression. The default is REGEXP.
+data DimensionFilterOperator
+    = DFOOperatorUnspecified
+      -- ^ @OPERATOR_UNSPECIFIED@
+      -- If the match type is unspecified, it is treated as a \`REGEXP\`.
+    | DFORegexp
+      -- ^ @REGEXP@
+      -- The match expression is treated as a regular expression. All match types
+      -- are not treated as regular expressions.
+    | DFOBeginsWith
+      -- ^ @BEGINS_WITH@
+      -- Matches the value which begin with the match expression provided.
+    | DFOEndsWith
+      -- ^ @ENDS_WITH@
+      -- Matches the values which end with the match expression provided.
+    | DFOPartial
+      -- ^ @PARTIAL@
+      -- Substring match.
+    | DFOExact
+      -- ^ @EXACT@
+      -- The value should match the match expression entirely.
+    | DFONumericEqual
+      -- ^ @NUMERIC_EQUAL@
+      -- Integer comparison filters. case sensitivity is ignored for these and
+      -- the expression is assumed to be a string representing an integer.
+      -- Failure conditions: - If expression is not a valid int64, the client
+      -- should expect an error. - Input dimensions that are not valid int64
+      -- values will never match the filter.
+    | DFONumericGreaterThan
+      -- ^ @NUMERIC_GREATER_THAN@
+      -- Checks if the dimension is numerically greater than the match
+      -- expression. Read the description for \`NUMERIC_EQUALS\` for
+      -- restrictions.
+    | DFONumericLessThan
+      -- ^ @NUMERIC_LESS_THAN@
+      -- Checks if the dimension is numerically less than the match expression.
+      -- Read the description for \`NUMERIC_EQUALS\` for restrictions.
+    | DFOInList
+      -- ^ @IN_LIST@
+      -- This option is used to specify a dimension filter whose expression can
+      -- take any value from a selected list of values. This helps avoiding
+      -- evaluating multiple exact match dimension filters which are OR\'ed for
+      -- every single response row. For example: expressions: [\"A\", \"B\",
+      -- \"C\"] Any response row whose dimension has it is value as A, B or C,
+      -- matches this DimensionFilter.
+      deriving (Eq, Ord, Enum, Read, Show, Data, Typeable, Generic)
+
+instance Hashable DimensionFilterOperator
+
+instance FromHttpApiData DimensionFilterOperator where
+    parseQueryParam = \case
+        "OPERATOR_UNSPECIFIED" -> Right DFOOperatorUnspecified
+        "REGEXP" -> Right DFORegexp
+        "BEGINS_WITH" -> Right DFOBeginsWith
+        "ENDS_WITH" -> Right DFOEndsWith
+        "PARTIAL" -> Right DFOPartial
+        "EXACT" -> Right DFOExact
+        "NUMERIC_EQUAL" -> Right DFONumericEqual
+        "NUMERIC_GREATER_THAN" -> Right DFONumericGreaterThan
+        "NUMERIC_LESS_THAN" -> Right DFONumericLessThan
+        "IN_LIST" -> Right DFOInList
+        x -> Left ("Unable to parse DimensionFilterOperator from: " <> x)
+
+instance ToHttpApiData DimensionFilterOperator where
+    toQueryParam = \case
+        DFOOperatorUnspecified -> "OPERATOR_UNSPECIFIED"
+        DFORegexp -> "REGEXP"
+        DFOBeginsWith -> "BEGINS_WITH"
+        DFOEndsWith -> "ENDS_WITH"
+        DFOPartial -> "PARTIAL"
+        DFOExact -> "EXACT"
+        DFONumericEqual -> "NUMERIC_EQUAL"
+        DFONumericGreaterThan -> "NUMERIC_GREATER_THAN"
+        DFONumericLessThan -> "NUMERIC_LESS_THAN"
+        DFOInList -> "IN_LIST"
+
+instance FromJSON DimensionFilterOperator where
+    parseJSON = parseJSONText "DimensionFilterOperator"
+
+instance ToJSON DimensionFilterOperator where
+    toJSON = toJSONText
+
+-- | Specifies how the metric expression should be formatted, for example
+-- \`INTEGER\`.
+data MetricFormattingType
+    = MFTMetricTypeUnspecified
+      -- ^ @METRIC_TYPE_UNSPECIFIED@
+      -- Metric type is unspecified.
+    | MFTInteger
+      -- ^ @INTEGER@
+      -- Integer metric.
+    | MFTFloat
+      -- ^ @FLOAT@
+      -- Float metric.
+    | MFTCurrency
+      -- ^ @CURRENCY@
+      -- Currency metric.
+    | MFTPercent
+      -- ^ @PERCENT@
+      -- Percentage metric.
+    | MFTTime
+      -- ^ @TIME@
+      -- Time metric in \`HH:MM:SS\` format.
+      deriving (Eq, Ord, Enum, Read, Show, Data, Typeable, Generic)
+
+instance Hashable MetricFormattingType
+
+instance FromHttpApiData MetricFormattingType where
+    parseQueryParam = \case
+        "METRIC_TYPE_UNSPECIFIED" -> Right MFTMetricTypeUnspecified
+        "INTEGER" -> Right MFTInteger
+        "FLOAT" -> Right MFTFloat
+        "CURRENCY" -> Right MFTCurrency
+        "PERCENT" -> Right MFTPercent
+        "TIME" -> Right MFTTime
+        x -> Left ("Unable to parse MetricFormattingType from: " <> x)
+
+instance ToHttpApiData MetricFormattingType where
+    toQueryParam = \case
+        MFTMetricTypeUnspecified -> "METRIC_TYPE_UNSPECIFIED"
+        MFTInteger -> "INTEGER"
+        MFTFloat -> "FLOAT"
+        MFTCurrency -> "CURRENCY"
+        MFTPercent -> "PERCENT"
+        MFTTime -> "TIME"
+
+instance FromJSON MetricFormattingType where
+    parseJSON = parseJSONText "MetricFormattingType"
+
+instance ToJSON MetricFormattingType where
+    toJSON = toJSONText
+
+-- | The operator to use to match the dimension with the expressions.
+data SegmentDimensionFilterOperator
+    = SDFOOperatorUnspecified
+      -- ^ @OPERATOR_UNSPECIFIED@
+      -- If the match type is unspecified, it is treated as a REGEXP.
+    | SDFORegexp
+      -- ^ @REGEXP@
+      -- The match expression is treated as a regular expression. All other match
+      -- types are not treated as regular expressions.
+    | SDFOBeginsWith
+      -- ^ @BEGINS_WITH@
+      -- Matches the values which begin with the match expression provided.
+    | SDFOEndsWith
+      -- ^ @ENDS_WITH@
+      -- Matches the values which end with the match expression provided.
+    | SDFOPartial
+      -- ^ @PARTIAL@
+      -- Substring match.
+    | SDFOExact
+      -- ^ @EXACT@
+      -- The value should match the match expression entirely.
+    | SDFOInList
+      -- ^ @IN_LIST@
+      -- This option is used to specify a dimension filter whose expression can
+      -- take any value from a selected list of values. This helps avoiding
+      -- evaluating multiple exact match dimension filters which are OR\'ed for
+      -- every single response row. For example: expressions: [\"A\", \"B\",
+      -- \"C\"] Any response row whose dimension has it is value as A, B or C,
+      -- matches this DimensionFilter.
+    | SDFONumericLessThan
+      -- ^ @NUMERIC_LESS_THAN@
+      -- Integer comparison filters. case sensitivity is ignored for these and
+      -- the expression is assumed to be a string representing an integer.
+      -- Failure conditions: - if expression is not a valid int64, the client
+      -- should expect an error. - input dimensions that are not valid int64
+      -- values will never match the filter. Checks if the dimension is
+      -- numerically less than the match expression.
+    | SDFONumericGreaterThan
+      -- ^ @NUMERIC_GREATER_THAN@
+      -- Checks if the dimension is numerically greater than the match
+      -- expression.
+    | SDFONumericBetween
+      -- ^ @NUMERIC_BETWEEN@
+      -- Checks if the dimension is numerically between the minimum and maximum
+      -- of the match expression, boundaries excluded.
+      deriving (Eq, Ord, Enum, Read, Show, Data, Typeable, Generic)
+
+instance Hashable SegmentDimensionFilterOperator
+
+instance FromHttpApiData SegmentDimensionFilterOperator where
+    parseQueryParam = \case
+        "OPERATOR_UNSPECIFIED" -> Right SDFOOperatorUnspecified
+        "REGEXP" -> Right SDFORegexp
+        "BEGINS_WITH" -> Right SDFOBeginsWith
+        "ENDS_WITH" -> Right SDFOEndsWith
+        "PARTIAL" -> Right SDFOPartial
+        "EXACT" -> Right SDFOExact
+        "IN_LIST" -> Right SDFOInList
+        "NUMERIC_LESS_THAN" -> Right SDFONumericLessThan
+        "NUMERIC_GREATER_THAN" -> Right SDFONumericGreaterThan
+        "NUMERIC_BETWEEN" -> Right SDFONumericBetween
+        x -> Left ("Unable to parse SegmentDimensionFilterOperator from: " <> x)
+
+instance ToHttpApiData SegmentDimensionFilterOperator where
+    toQueryParam = \case
+        SDFOOperatorUnspecified -> "OPERATOR_UNSPECIFIED"
+        SDFORegexp -> "REGEXP"
+        SDFOBeginsWith -> "BEGINS_WITH"
+        SDFOEndsWith -> "ENDS_WITH"
+        SDFOPartial -> "PARTIAL"
+        SDFOExact -> "EXACT"
+        SDFOInList -> "IN_LIST"
+        SDFONumericLessThan -> "NUMERIC_LESS_THAN"
+        SDFONumericGreaterThan -> "NUMERIC_GREATER_THAN"
+        SDFONumericBetween -> "NUMERIC_BETWEEN"
+
+instance FromJSON SegmentDimensionFilterOperator where
+    parseJSON = parseJSONText "SegmentDimensionFilterOperator"
+
+instance ToJSON SegmentDimensionFilterOperator where
+    toJSON = toJSONText
+
+-- | The operator for combining multiple metric filters. If unspecified, it
+-- is treated as an \`OR\`.
+data MetricFilterClauseOperator
+    = MFCOOperatorUnspecified
+      -- ^ @OPERATOR_UNSPECIFIED@
+      -- Unspecified operator. It is treated as an \`OR\`.
+    | MFCOOR
+      -- ^ @OR@
+      -- The logical \`OR\` operator.
+    | MFCOAnd
+      -- ^ @AND@
+      -- The logical \`AND\` operator.
+      deriving (Eq, Ord, Enum, Read, Show, Data, Typeable, Generic)
+
+instance Hashable MetricFilterClauseOperator
+
+instance FromHttpApiData MetricFilterClauseOperator where
+    parseQueryParam = \case
+        "OPERATOR_UNSPECIFIED" -> Right MFCOOperatorUnspecified
+        "OR" -> Right MFCOOR
+        "AND" -> Right MFCOAnd
+        x -> Left ("Unable to parse MetricFilterClauseOperator from: " <> x)
+
+instance ToHttpApiData MetricFilterClauseOperator where
+    toQueryParam = \case
+        MFCOOperatorUnspecified -> "OPERATOR_UNSPECIFIED"
+        MFCOOR -> "OR"
+        MFCOAnd -> "AND"
+
+instance FromJSON MetricFilterClauseOperator where
+    parseJSON = parseJSONText "MetricFilterClauseOperator"
+
+instance ToJSON MetricFilterClauseOperator where
+    toJSON = toJSONText
diff --git a/gen/Network/Google/Resource/AnalyticsReporting/Reports/BatchGet.hs b/gen/Network/Google/Resource/AnalyticsReporting/Reports/BatchGet.hs
new file mode 100644
--- /dev/null
+++ b/gen/Network/Google/Resource/AnalyticsReporting/Reports/BatchGet.hs
@@ -0,0 +1,148 @@
+{-# 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.AnalyticsReporting.Reports.BatchGet
+-- 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 the Analytics data.
+--
+-- /See:/ <https://developers.google.com/analytics/devguides/reporting/core/v4/ Analytics Reporting API Reference> for @analyticsreporting.reports.batchGet@.
+module Network.Google.Resource.AnalyticsReporting.Reports.BatchGet
+    (
+    -- * REST Resource
+      ReportsBatchGetResource
+
+    -- * Creating a Request
+    , reportsBatchGet
+    , ReportsBatchGet
+
+    -- * Request Lenses
+    , rbgXgafv
+    , rbgUploadProtocol
+    , rbgAccessToken
+    , rbgUploadType
+    , rbgPayload
+    , rbgCallback
+    ) where
+
+import           Network.Google.AnalyticsReporting.Types
+import           Network.Google.Prelude
+
+-- | A resource alias for @analyticsreporting.reports.batchGet@ method which the
+-- 'ReportsBatchGet' request conforms to.
+type ReportsBatchGetResource =
+     "v4" :>
+       "reports:batchGet" :>
+         QueryParam "$.xgafv" Xgafv :>
+           QueryParam "upload_protocol" Text :>
+             QueryParam "access_token" Text :>
+               QueryParam "uploadType" Text :>
+                 QueryParam "callback" Text :>
+                   QueryParam "alt" AltJSON :>
+                     ReqBody '[JSON] GetReportsRequest :>
+                       Post '[JSON] GetReportsResponse
+
+-- | Returns the Analytics data.
+--
+-- /See:/ 'reportsBatchGet' smart constructor.
+data ReportsBatchGet = ReportsBatchGet'
+    { _rbgXgafv          :: !(Maybe Xgafv)
+    , _rbgUploadProtocol :: !(Maybe Text)
+    , _rbgAccessToken    :: !(Maybe Text)
+    , _rbgUploadType     :: !(Maybe Text)
+    , _rbgPayload        :: !GetReportsRequest
+    , _rbgCallback       :: !(Maybe Text)
+    } deriving (Eq,Show,Data,Typeable,Generic)
+
+-- | Creates a value of 'ReportsBatchGet' with the minimum fields required to make a request.
+--
+-- Use one of the following lenses to modify other fields as desired:
+--
+-- * 'rbgXgafv'
+--
+-- * 'rbgUploadProtocol'
+--
+-- * 'rbgAccessToken'
+--
+-- * 'rbgUploadType'
+--
+-- * 'rbgPayload'
+--
+-- * 'rbgCallback'
+reportsBatchGet
+    :: GetReportsRequest -- ^ 'rbgPayload'
+    -> ReportsBatchGet
+reportsBatchGet pRbgPayload_ =
+    ReportsBatchGet'
+    { _rbgXgafv = Nothing
+    , _rbgUploadProtocol = Nothing
+    , _rbgAccessToken = Nothing
+    , _rbgUploadType = Nothing
+    , _rbgPayload = pRbgPayload_
+    , _rbgCallback = Nothing
+    }
+
+-- | V1 error format.
+rbgXgafv :: Lens' ReportsBatchGet (Maybe Xgafv)
+rbgXgafv = lens _rbgXgafv (\ s a -> s{_rbgXgafv = a})
+
+-- | Upload protocol for media (e.g. \"raw\", \"multipart\").
+rbgUploadProtocol :: Lens' ReportsBatchGet (Maybe Text)
+rbgUploadProtocol
+  = lens _rbgUploadProtocol
+      (\ s a -> s{_rbgUploadProtocol = a})
+
+-- | OAuth access token.
+rbgAccessToken :: Lens' ReportsBatchGet (Maybe Text)
+rbgAccessToken
+  = lens _rbgAccessToken
+      (\ s a -> s{_rbgAccessToken = a})
+
+-- | Legacy upload protocol for media (e.g. \"media\", \"multipart\").
+rbgUploadType :: Lens' ReportsBatchGet (Maybe Text)
+rbgUploadType
+  = lens _rbgUploadType
+      (\ s a -> s{_rbgUploadType = a})
+
+-- | Multipart request metadata.
+rbgPayload :: Lens' ReportsBatchGet GetReportsRequest
+rbgPayload
+  = lens _rbgPayload (\ s a -> s{_rbgPayload = a})
+
+-- | JSONP
+rbgCallback :: Lens' ReportsBatchGet (Maybe Text)
+rbgCallback
+  = lens _rbgCallback (\ s a -> s{_rbgCallback = a})
+
+instance GoogleRequest ReportsBatchGet where
+        type Rs ReportsBatchGet = GetReportsResponse
+        type Scopes ReportsBatchGet =
+             '["https://www.googleapis.com/auth/analytics",
+               "https://www.googleapis.com/auth/analytics.readonly"]
+        requestClient ReportsBatchGet'{..}
+          = go _rbgXgafv _rbgUploadProtocol _rbgAccessToken
+              _rbgUploadType
+              _rbgCallback
+              (Just AltJSON)
+              _rbgPayload
+              analyticsReportingService
+          where go
+                  = buildClient
+                      (Proxy :: Proxy ReportsBatchGetResource)
+                      mempty
diff --git a/gogol-analyticsreporting.cabal b/gogol-analyticsreporting.cabal
new file mode 100644
--- /dev/null
+++ b/gogol-analyticsreporting.cabal
@@ -0,0 +1,46 @@
+name:                  gogol-analyticsreporting
+version:               0.4.0
+synopsis:              Google Analytics Reporting 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
+
+description:
+    Accesses Analytics report data.
+    .
+    /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 @v4@
+    of the API.
+
+source-repository head
+    type:     git
+    location: git://github.com/brendanhay/gogol.git
+
+library
+    default-language:  Haskell2010
+    hs-source-dirs:    src gen
+
+    ghc-options:       -Wall
+
+    exposed-modules:
+          Network.Google.AnalyticsReporting
+        , Network.Google.AnalyticsReporting.Types
+        , Network.Google.Resource.AnalyticsReporting.Reports.BatchGet
+
+    other-modules:
+          Network.Google.AnalyticsReporting.Types.Product
+        , Network.Google.AnalyticsReporting.Types.Sum
+
+    build-depends:
+          gogol-core == 0.4.0.*
+        , base       >= 4.7 && < 5
diff --git a/src/.gitkeep b/src/.gitkeep
new file mode 100644
--- /dev/null
+++ b/src/.gitkeep
