gogol-clouderrorreporting (empty) → 0.4.0
raw patch · 15 files changed
+3082/−0 lines, 15 filesdep +basedep +gogol-coresetup-changed
Dependencies added: base, gogol-core
Files
- LICENSE +367/−0
- README.md +28/−0
- Setup.hs +2/−0
- gen/Network/Google/CloudErrorReporting.hs +186/−0
- gen/Network/Google/CloudErrorReporting/Types.hs +150/−0
- gen/Network/Google/CloudErrorReporting/Types/Product.hs +1060/−0
- gen/Network/Google/CloudErrorReporting/Types/Sum.hs +48/−0
- gen/Network/Google/Resource/CloudErrorReporting/Projects/DeleteEvents.hs +151/−0
- gen/Network/Google/Resource/CloudErrorReporting/Projects/Events/List.hs +243/−0
- gen/Network/Google/Resource/CloudErrorReporting/Projects/Events/Report.hs +175/−0
- gen/Network/Google/Resource/CloudErrorReporting/Projects/GroupStats/List.hs +310/−0
- gen/Network/Google/Resource/CloudErrorReporting/Projects/Groups/Get.hs +149/−0
- gen/Network/Google/Resource/CloudErrorReporting/Projects/Groups/Update.hs +160/−0
- gogol-clouderrorreporting.cabal +53/−0
- src/.gitkeep +0/−0
+ LICENSE view
@@ -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.
+ README.md view
@@ -0,0 +1,28 @@+# gogol-clouderrorreporting++* [Version](#version)+* [Description](#description)+* [Contribute](#contribute)+* [Licence](#licence)+++## Version++`0.3.0`+++## Description++A client library for the Google Stackdriver Error 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-clouderrorreporting` is released under the [Mozilla Public License Version 2.0](http://www.mozilla.org/MPL/).
+ Setup.hs view
@@ -0,0 +1,2 @@+import Distribution.Simple+main = defaultMain
+ gen/Network/Google/CloudErrorReporting.hs view
@@ -0,0 +1,186 @@+{-# LANGUAGE DataKinds #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# LANGUAGE TypeOperators #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}+{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}++-- |+-- Module : Network.Google.CloudErrorReporting+-- 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)+--+-- Groups and counts similar errors from cloud services and applications,+-- reports new errors, and provides access to error groups and their+-- associated errors.+--+-- /See:/ <https://cloud.google.com/error-reporting/ Stackdriver Error Reporting API Reference>+module Network.Google.CloudErrorReporting+ (+ -- * Service Configuration+ cloudErrorReportingService++ -- * OAuth Scopes+ , cloudPlatformScope++ -- * API Declaration+ , CloudErrorReportingAPI++ -- * Resources++ -- ** clouderrorreporting.projects.deleteEvents+ , module Network.Google.Resource.CloudErrorReporting.Projects.DeleteEvents++ -- ** clouderrorreporting.projects.events.list+ , module Network.Google.Resource.CloudErrorReporting.Projects.Events.List++ -- ** clouderrorreporting.projects.events.report+ , module Network.Google.Resource.CloudErrorReporting.Projects.Events.Report++ -- ** clouderrorreporting.projects.groupStats.list+ , module Network.Google.Resource.CloudErrorReporting.Projects.GroupStats.List++ -- ** clouderrorreporting.projects.groups.get+ , module Network.Google.Resource.CloudErrorReporting.Projects.Groups.Get++ -- ** clouderrorreporting.projects.groups.update+ , module Network.Google.Resource.CloudErrorReporting.Projects.Groups.Update++ -- * Types++ -- ** ErrorEvent+ , ErrorEvent+ , errorEvent+ , eeContext+ , eeEventTime+ , eeServiceContext+ , eeMessage++ -- ** ErrorContext+ , ErrorContext+ , errorContext+ , ecHTTPRequest+ , ecUser+ , ecSourceReferences+ , ecReportLocation++ -- ** ErrorGroup+ , ErrorGroup+ , errorGroup+ , egTrackingIssues+ , egName+ , egGroupId++ -- ** DeleteEventsResponse+ , DeleteEventsResponse+ , deleteEventsResponse++ -- ** ReportedErrorEvent+ , ReportedErrorEvent+ , reportedErrorEvent+ , reeContext+ , reeEventTime+ , reeServiceContext+ , reeMessage++ -- ** HTTPRequestContext+ , HTTPRequestContext+ , hTTPRequestContext+ , httprcRemoteIP+ , httprcURL+ , httprcReferrer+ , httprcMethod+ , httprcResponseStatusCode+ , httprcUserAgent++ -- ** TrackingIssue+ , TrackingIssue+ , trackingIssue+ , tiURL++ -- ** ListEventsResponse+ , ListEventsResponse+ , listEventsResponse+ , lerNextPageToken+ , lerTimeRangeBegin+ , lerErrorEvents++ -- ** ErrorGroupStats+ , ErrorGroupStats+ , errorGroupStats+ , egsAffectedServices+ , egsGroup+ , egsFirstSeenTime+ , egsAffectedUsersCount+ , egsCount+ , egsTimedCounts+ , egsNumAffectedServices+ , egsLastSeenTime+ , egsRepresentative++ -- ** ListGroupStatsResponse+ , ListGroupStatsResponse+ , listGroupStatsResponse+ , lgsrNextPageToken+ , lgsrTimeRangeBegin+ , lgsrErrorGroupStats++ -- ** ServiceContext+ , ServiceContext+ , serviceContext+ , scResourceType+ , scService+ , scVersion++ -- ** Xgafv+ , Xgafv (..)++ -- ** TimedCount+ , TimedCount+ , timedCount+ , tcStartTime+ , tcCount+ , tcEndTime++ -- ** SourceLocation+ , SourceLocation+ , sourceLocation+ , slLineNumber+ , slFilePath+ , slFunctionName++ -- ** SourceReference+ , SourceReference+ , sourceReference+ , srRepository+ , srRevisionId++ -- ** ReportErrorEventResponse+ , ReportErrorEventResponse+ , reportErrorEventResponse+ ) where++import Network.Google.CloudErrorReporting.Types+import Network.Google.Prelude+import Network.Google.Resource.CloudErrorReporting.Projects.DeleteEvents+import Network.Google.Resource.CloudErrorReporting.Projects.Events.List+import Network.Google.Resource.CloudErrorReporting.Projects.Events.Report+import Network.Google.Resource.CloudErrorReporting.Projects.Groups.Get+import Network.Google.Resource.CloudErrorReporting.Projects.Groups.Update+import Network.Google.Resource.CloudErrorReporting.Projects.GroupStats.List++{- $resources+TODO+-}++-- | Represents the entirety of the methods and resources available for the Stackdriver Error Reporting API service.+type CloudErrorReportingAPI =+ ProjectsGroupsGetResource :<|>+ ProjectsGroupsUpdateResource+ :<|> ProjectsGroupStatsListResource+ :<|> ProjectsEventsListResource+ :<|> ProjectsEventsReportResource+ :<|> ProjectsDeleteEventsResource
+ gen/Network/Google/CloudErrorReporting/Types.hs view
@@ -0,0 +1,150 @@+{-# LANGUAGE DataKinds #-}+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# LANGUAGE OverloadedStrings #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- |+-- Module : Network.Google.CloudErrorReporting.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.CloudErrorReporting.Types+ (+ -- * Service Configuration+ cloudErrorReportingService++ -- * OAuth Scopes+ , cloudPlatformScope++ -- * ErrorEvent+ , ErrorEvent+ , errorEvent+ , eeContext+ , eeEventTime+ , eeServiceContext+ , eeMessage++ -- * ErrorContext+ , ErrorContext+ , errorContext+ , ecHTTPRequest+ , ecUser+ , ecSourceReferences+ , ecReportLocation++ -- * ErrorGroup+ , ErrorGroup+ , errorGroup+ , egTrackingIssues+ , egName+ , egGroupId++ -- * DeleteEventsResponse+ , DeleteEventsResponse+ , deleteEventsResponse++ -- * ReportedErrorEvent+ , ReportedErrorEvent+ , reportedErrorEvent+ , reeContext+ , reeEventTime+ , reeServiceContext+ , reeMessage++ -- * HTTPRequestContext+ , HTTPRequestContext+ , hTTPRequestContext+ , httprcRemoteIP+ , httprcURL+ , httprcReferrer+ , httprcMethod+ , httprcResponseStatusCode+ , httprcUserAgent++ -- * TrackingIssue+ , TrackingIssue+ , trackingIssue+ , tiURL++ -- * ListEventsResponse+ , ListEventsResponse+ , listEventsResponse+ , lerNextPageToken+ , lerTimeRangeBegin+ , lerErrorEvents++ -- * ErrorGroupStats+ , ErrorGroupStats+ , errorGroupStats+ , egsAffectedServices+ , egsGroup+ , egsFirstSeenTime+ , egsAffectedUsersCount+ , egsCount+ , egsTimedCounts+ , egsNumAffectedServices+ , egsLastSeenTime+ , egsRepresentative++ -- * ListGroupStatsResponse+ , ListGroupStatsResponse+ , listGroupStatsResponse+ , lgsrNextPageToken+ , lgsrTimeRangeBegin+ , lgsrErrorGroupStats++ -- * ServiceContext+ , ServiceContext+ , serviceContext+ , scResourceType+ , scService+ , scVersion++ -- * Xgafv+ , Xgafv (..)++ -- * TimedCount+ , TimedCount+ , timedCount+ , tcStartTime+ , tcCount+ , tcEndTime++ -- * SourceLocation+ , SourceLocation+ , sourceLocation+ , slLineNumber+ , slFilePath+ , slFunctionName++ -- * SourceReference+ , SourceReference+ , sourceReference+ , srRepository+ , srRevisionId++ -- * ReportErrorEventResponse+ , ReportErrorEventResponse+ , reportErrorEventResponse+ ) where++import Network.Google.CloudErrorReporting.Types.Product+import Network.Google.CloudErrorReporting.Types.Sum+import Network.Google.Prelude++-- | Default request referring to version 'v1beta1' of the Stackdriver Error Reporting API. This contains the host and root path used as a starting point for constructing service requests.+cloudErrorReportingService :: ServiceConfig+cloudErrorReportingService+ = defaultService+ (ServiceId "clouderrorreporting:v1beta1")+ "clouderrorreporting.googleapis.com"++-- | View and manage your data across Google Cloud Platform services+cloudPlatformScope :: Proxy '["https://www.googleapis.com/auth/cloud-platform"]+cloudPlatformScope = Proxy;
+ gen/Network/Google/CloudErrorReporting/Types/Product.hs view
@@ -0,0 +1,1060 @@+{-# 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.CloudErrorReporting.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.CloudErrorReporting.Types.Product where++import Network.Google.CloudErrorReporting.Types.Sum+import Network.Google.Prelude++-- | An error event which is returned by the Error Reporting system.+--+-- /See:/ 'errorEvent' smart constructor.+data ErrorEvent = ErrorEvent'+ { _eeContext :: !(Maybe ErrorContext)+ , _eeEventTime :: !(Maybe DateTime')+ , _eeServiceContext :: !(Maybe ServiceContext)+ , _eeMessage :: !(Maybe Text)+ } deriving (Eq,Show,Data,Typeable,Generic)++-- | Creates a value of 'ErrorEvent' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'eeContext'+--+-- * 'eeEventTime'+--+-- * 'eeServiceContext'+--+-- * 'eeMessage'+errorEvent+ :: ErrorEvent+errorEvent =+ ErrorEvent'+ { _eeContext = Nothing+ , _eeEventTime = Nothing+ , _eeServiceContext = Nothing+ , _eeMessage = Nothing+ }++-- | Data about the context in which the error occurred.+eeContext :: Lens' ErrorEvent (Maybe ErrorContext)+eeContext+ = lens _eeContext (\ s a -> s{_eeContext = a})++-- | Time when the event occurred as provided in the error report. If the+-- report did not contain a timestamp, the time the error was received by+-- the Error Reporting system is used.+eeEventTime :: Lens' ErrorEvent (Maybe UTCTime)+eeEventTime+ = lens _eeEventTime (\ s a -> s{_eeEventTime = a}) .+ mapping _DateTime++-- | The \`ServiceContext\` for which this error was reported.+eeServiceContext :: Lens' ErrorEvent (Maybe ServiceContext)+eeServiceContext+ = lens _eeServiceContext+ (\ s a -> s{_eeServiceContext = a})++-- | The stack trace that was reported or logged by the service.+eeMessage :: Lens' ErrorEvent (Maybe Text)+eeMessage+ = lens _eeMessage (\ s a -> s{_eeMessage = a})++instance FromJSON ErrorEvent where+ parseJSON+ = withObject "ErrorEvent"+ (\ o ->+ ErrorEvent' <$>+ (o .:? "context") <*> (o .:? "eventTime") <*>+ (o .:? "serviceContext")+ <*> (o .:? "message"))++instance ToJSON ErrorEvent where+ toJSON ErrorEvent'{..}+ = object+ (catMaybes+ [("context" .=) <$> _eeContext,+ ("eventTime" .=) <$> _eeEventTime,+ ("serviceContext" .=) <$> _eeServiceContext,+ ("message" .=) <$> _eeMessage])++-- | A description of the context in which an error occurred. This data+-- should be provided by the application when reporting an error, unless+-- the error report has been generated automatically from Google App Engine+-- logs.+--+-- /See:/ 'errorContext' smart constructor.+data ErrorContext = ErrorContext'+ { _ecHTTPRequest :: !(Maybe HTTPRequestContext)+ , _ecUser :: !(Maybe Text)+ , _ecSourceReferences :: !(Maybe [SourceReference])+ , _ecReportLocation :: !(Maybe SourceLocation)+ } deriving (Eq,Show,Data,Typeable,Generic)++-- | Creates a value of 'ErrorContext' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'ecHTTPRequest'+--+-- * 'ecUser'+--+-- * 'ecSourceReferences'+--+-- * 'ecReportLocation'+errorContext+ :: ErrorContext+errorContext =+ ErrorContext'+ { _ecHTTPRequest = Nothing+ , _ecUser = Nothing+ , _ecSourceReferences = Nothing+ , _ecReportLocation = Nothing+ }++-- | The HTTP request which was processed when the error was triggered.+ecHTTPRequest :: Lens' ErrorContext (Maybe HTTPRequestContext)+ecHTTPRequest+ = lens _ecHTTPRequest+ (\ s a -> s{_ecHTTPRequest = a})++-- | The user who caused or was affected by the crash. This can be a user ID,+-- an email address, or an arbitrary token that uniquely identifies the+-- user. When sending an error report, leave this field empty if the user+-- was not logged in. In this case the Error Reporting system will use+-- other data, such as remote IP address, to distinguish affected users.+-- See \`affected_users_count\` in \`ErrorGroupStats\`.+ecUser :: Lens' ErrorContext (Maybe Text)+ecUser = lens _ecUser (\ s a -> s{_ecUser = a})++-- | Source code that was used to build the executable which has caused the+-- given error message.+ecSourceReferences :: Lens' ErrorContext [SourceReference]+ecSourceReferences+ = lens _ecSourceReferences+ (\ s a -> s{_ecSourceReferences = a})+ . _Default+ . _Coerce++-- | The location in the source code where the decision was made to report+-- the error, usually the place where it was logged. For a logged exception+-- this would be the source line where the exception is logged, usually+-- close to the place where it was caught.+ecReportLocation :: Lens' ErrorContext (Maybe SourceLocation)+ecReportLocation+ = lens _ecReportLocation+ (\ s a -> s{_ecReportLocation = a})++instance FromJSON ErrorContext where+ parseJSON+ = withObject "ErrorContext"+ (\ o ->+ ErrorContext' <$>+ (o .:? "httpRequest") <*> (o .:? "user") <*>+ (o .:? "sourceReferences" .!= mempty)+ <*> (o .:? "reportLocation"))++instance ToJSON ErrorContext where+ toJSON ErrorContext'{..}+ = object+ (catMaybes+ [("httpRequest" .=) <$> _ecHTTPRequest,+ ("user" .=) <$> _ecUser,+ ("sourceReferences" .=) <$> _ecSourceReferences,+ ("reportLocation" .=) <$> _ecReportLocation])++-- | Description of a group of similar error events.+--+-- /See:/ 'errorGroup' smart constructor.+data ErrorGroup = ErrorGroup'+ { _egTrackingIssues :: !(Maybe [TrackingIssue])+ , _egName :: !(Maybe Text)+ , _egGroupId :: !(Maybe Text)+ } deriving (Eq,Show,Data,Typeable,Generic)++-- | Creates a value of 'ErrorGroup' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'egTrackingIssues'+--+-- * 'egName'+--+-- * 'egGroupId'+errorGroup+ :: ErrorGroup+errorGroup =+ ErrorGroup'+ { _egTrackingIssues = Nothing+ , _egName = Nothing+ , _egGroupId = Nothing+ }++-- | Associated tracking issues.+egTrackingIssues :: Lens' ErrorGroup [TrackingIssue]+egTrackingIssues+ = lens _egTrackingIssues+ (\ s a -> s{_egTrackingIssues = a})+ . _Default+ . _Coerce++-- | The group resource name. Example:+-- 'projects\/my-project-123\/groups\/my-groupid'+egName :: Lens' ErrorGroup (Maybe Text)+egName = lens _egName (\ s a -> s{_egName = a})++-- | Group IDs are unique for a given project. If the same kind of error+-- occurs in different service contexts, it will receive the same group ID.+egGroupId :: Lens' ErrorGroup (Maybe Text)+egGroupId+ = lens _egGroupId (\ s a -> s{_egGroupId = a})++instance FromJSON ErrorGroup where+ parseJSON+ = withObject "ErrorGroup"+ (\ o ->+ ErrorGroup' <$>+ (o .:? "trackingIssues" .!= mempty) <*>+ (o .:? "name")+ <*> (o .:? "groupId"))++instance ToJSON ErrorGroup where+ toJSON ErrorGroup'{..}+ = object+ (catMaybes+ [("trackingIssues" .=) <$> _egTrackingIssues,+ ("name" .=) <$> _egName,+ ("groupId" .=) <$> _egGroupId])++-- | Response message for deleting error events.+--+-- /See:/ 'deleteEventsResponse' smart constructor.+data DeleteEventsResponse =+ DeleteEventsResponse'+ deriving (Eq,Show,Data,Typeable,Generic)++-- | Creates a value of 'DeleteEventsResponse' with the minimum fields required to make a request.+--+deleteEventsResponse+ :: DeleteEventsResponse+deleteEventsResponse = DeleteEventsResponse'++instance FromJSON DeleteEventsResponse where+ parseJSON+ = withObject "DeleteEventsResponse"+ (\ o -> pure DeleteEventsResponse')++instance ToJSON DeleteEventsResponse where+ toJSON = const emptyObject++-- | An error event which is reported to the Error Reporting system.+--+-- /See:/ 'reportedErrorEvent' smart constructor.+data ReportedErrorEvent = ReportedErrorEvent'+ { _reeContext :: !(Maybe ErrorContext)+ , _reeEventTime :: !(Maybe DateTime')+ , _reeServiceContext :: !(Maybe ServiceContext)+ , _reeMessage :: !(Maybe Text)+ } deriving (Eq,Show,Data,Typeable,Generic)++-- | Creates a value of 'ReportedErrorEvent' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'reeContext'+--+-- * 'reeEventTime'+--+-- * 'reeServiceContext'+--+-- * 'reeMessage'+reportedErrorEvent+ :: ReportedErrorEvent+reportedErrorEvent =+ ReportedErrorEvent'+ { _reeContext = Nothing+ , _reeEventTime = Nothing+ , _reeServiceContext = Nothing+ , _reeMessage = Nothing+ }++-- | [Optional] A description of the context in which the error occurred.+reeContext :: Lens' ReportedErrorEvent (Maybe ErrorContext)+reeContext+ = lens _reeContext (\ s a -> s{_reeContext = a})++-- | [Optional] Time when the event occurred. If not provided, the time when+-- the event was received by the Error Reporting system will be used.+reeEventTime :: Lens' ReportedErrorEvent (Maybe UTCTime)+reeEventTime+ = lens _reeEventTime (\ s a -> s{_reeEventTime = a})+ . mapping _DateTime++-- | [Required] The service context in which this error has occurred.+reeServiceContext :: Lens' ReportedErrorEvent (Maybe ServiceContext)+reeServiceContext+ = lens _reeServiceContext+ (\ s a -> s{_reeServiceContext = a})++-- | [Required] The error message. If no \`context.reportLocation\` is+-- provided, the message must contain a header (typically consisting of the+-- exception type name and an error message) and an exception stack trace+-- in one of the supported programming languages and formats. Supported+-- languages are Java, Python, JavaScript, Ruby, C#, PHP, and Go. Supported+-- stack trace formats are: * **Java**: Must be the return value of+-- [\`Throwable.printStackTrace()\`](https:\/\/docs.oracle.com\/javase\/7\/docs\/api\/java\/lang\/Throwable.html#printStackTrace%28%29).+-- * **Python**: Must be the return value of+-- [\`traceback.format_exc()\`](https:\/\/docs.python.org\/2\/library\/traceback.html#traceback.format_exc).+-- * **JavaScript**: Must be the value of+-- [\`error.stack\`](https:\/\/github.com\/v8\/v8\/wiki\/Stack-Trace-API)+-- as returned by V8. * **Ruby**: Must contain frames returned by+-- [\`Exception.backtrace\`](https:\/\/ruby-doc.org\/core-2.2.0\/Exception.html#method-i-backtrace).+-- * **C#**: Must be the return value of+-- [\`Exception.ToString()\`](https:\/\/msdn.microsoft.com\/en-us\/library\/system.exception.tostring.aspx).+-- * **PHP**: Must start with \`PHP (Notice|Parse error|Fatal+-- error|Warning)\` and contain the result of+-- [\`(string)$exception\`](http:\/\/php.net\/manual\/en\/exception.tostring.php).+-- * **Go**: Must be the return value of+-- [\`runtime.Stack()\`](https:\/\/golang.org\/pkg\/runtime\/debug\/#Stack).+reeMessage :: Lens' ReportedErrorEvent (Maybe Text)+reeMessage+ = lens _reeMessage (\ s a -> s{_reeMessage = a})++instance FromJSON ReportedErrorEvent where+ parseJSON+ = withObject "ReportedErrorEvent"+ (\ o ->+ ReportedErrorEvent' <$>+ (o .:? "context") <*> (o .:? "eventTime") <*>+ (o .:? "serviceContext")+ <*> (o .:? "message"))++instance ToJSON ReportedErrorEvent where+ toJSON ReportedErrorEvent'{..}+ = object+ (catMaybes+ [("context" .=) <$> _reeContext,+ ("eventTime" .=) <$> _reeEventTime,+ ("serviceContext" .=) <$> _reeServiceContext,+ ("message" .=) <$> _reeMessage])++-- | HTTP request data that is related to a reported error. This data should+-- be provided by the application when reporting an error, unless the error+-- report has been generated automatically from Google App Engine logs.+--+-- /See:/ 'hTTPRequestContext' smart constructor.+data HTTPRequestContext = HTTPRequestContext'+ { _httprcRemoteIP :: !(Maybe Text)+ , _httprcURL :: !(Maybe Text)+ , _httprcReferrer :: !(Maybe Text)+ , _httprcMethod :: !(Maybe Text)+ , _httprcResponseStatusCode :: !(Maybe (Textual Int32))+ , _httprcUserAgent :: !(Maybe Text)+ } deriving (Eq,Show,Data,Typeable,Generic)++-- | Creates a value of 'HTTPRequestContext' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'httprcRemoteIP'+--+-- * 'httprcURL'+--+-- * 'httprcReferrer'+--+-- * 'httprcMethod'+--+-- * 'httprcResponseStatusCode'+--+-- * 'httprcUserAgent'+hTTPRequestContext+ :: HTTPRequestContext+hTTPRequestContext =+ HTTPRequestContext'+ { _httprcRemoteIP = Nothing+ , _httprcURL = Nothing+ , _httprcReferrer = Nothing+ , _httprcMethod = Nothing+ , _httprcResponseStatusCode = Nothing+ , _httprcUserAgent = Nothing+ }++-- | The IP address from which the request originated. This can be IPv4,+-- IPv6, or a token which is derived from the IP address, depending on the+-- data that has been provided in the error report.+httprcRemoteIP :: Lens' HTTPRequestContext (Maybe Text)+httprcRemoteIP+ = lens _httprcRemoteIP+ (\ s a -> s{_httprcRemoteIP = a})++-- | The URL of the request.+httprcURL :: Lens' HTTPRequestContext (Maybe Text)+httprcURL+ = lens _httprcURL (\ s a -> s{_httprcURL = a})++-- | The referrer information that is provided with the request.+httprcReferrer :: Lens' HTTPRequestContext (Maybe Text)+httprcReferrer+ = lens _httprcReferrer+ (\ s a -> s{_httprcReferrer = a})++-- | The type of HTTP request, such as \`GET\`, \`POST\`, etc.+httprcMethod :: Lens' HTTPRequestContext (Maybe Text)+httprcMethod+ = lens _httprcMethod (\ s a -> s{_httprcMethod = a})++-- | The HTTP response status code for the request.+httprcResponseStatusCode :: Lens' HTTPRequestContext (Maybe Int32)+httprcResponseStatusCode+ = lens _httprcResponseStatusCode+ (\ s a -> s{_httprcResponseStatusCode = a})+ . mapping _Coerce++-- | The user agent information that is provided with the request.+httprcUserAgent :: Lens' HTTPRequestContext (Maybe Text)+httprcUserAgent+ = lens _httprcUserAgent+ (\ s a -> s{_httprcUserAgent = a})++instance FromJSON HTTPRequestContext where+ parseJSON+ = withObject "HTTPRequestContext"+ (\ o ->+ HTTPRequestContext' <$>+ (o .:? "remoteIp") <*> (o .:? "url") <*>+ (o .:? "referrer")+ <*> (o .:? "method")+ <*> (o .:? "responseStatusCode")+ <*> (o .:? "userAgent"))++instance ToJSON HTTPRequestContext where+ toJSON HTTPRequestContext'{..}+ = object+ (catMaybes+ [("remoteIp" .=) <$> _httprcRemoteIP,+ ("url" .=) <$> _httprcURL,+ ("referrer" .=) <$> _httprcReferrer,+ ("method" .=) <$> _httprcMethod,+ ("responseStatusCode" .=) <$>+ _httprcResponseStatusCode,+ ("userAgent" .=) <$> _httprcUserAgent])++-- | Information related to tracking the progress on resolving the error.+--+-- /See:/ 'trackingIssue' smart constructor.+newtype TrackingIssue = TrackingIssue'+ { _tiURL :: Maybe Text+ } deriving (Eq,Show,Data,Typeable,Generic)++-- | Creates a value of 'TrackingIssue' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'tiURL'+trackingIssue+ :: TrackingIssue+trackingIssue =+ TrackingIssue'+ { _tiURL = Nothing+ }++-- | A URL pointing to a related entry in an issue tracking system. Example:+-- https:\/\/github.com\/user\/project\/issues\/4+tiURL :: Lens' TrackingIssue (Maybe Text)+tiURL = lens _tiURL (\ s a -> s{_tiURL = a})++instance FromJSON TrackingIssue where+ parseJSON+ = withObject "TrackingIssue"+ (\ o -> TrackingIssue' <$> (o .:? "url"))++instance ToJSON TrackingIssue where+ toJSON TrackingIssue'{..}+ = object (catMaybes [("url" .=) <$> _tiURL])++-- | Contains a set of requested error events.+--+-- /See:/ 'listEventsResponse' smart constructor.+data ListEventsResponse = ListEventsResponse'+ { _lerNextPageToken :: !(Maybe Text)+ , _lerTimeRangeBegin :: !(Maybe DateTime')+ , _lerErrorEvents :: !(Maybe [ErrorEvent])+ } deriving (Eq,Show,Data,Typeable,Generic)++-- | Creates a value of 'ListEventsResponse' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'lerNextPageToken'+--+-- * 'lerTimeRangeBegin'+--+-- * 'lerErrorEvents'+listEventsResponse+ :: ListEventsResponse+listEventsResponse =+ ListEventsResponse'+ { _lerNextPageToken = Nothing+ , _lerTimeRangeBegin = Nothing+ , _lerErrorEvents = Nothing+ }++-- | If non-empty, more results are available. Pass this token, along with+-- the same query parameters as the first request, to view the next page of+-- results.+lerNextPageToken :: Lens' ListEventsResponse (Maybe Text)+lerNextPageToken+ = lens _lerNextPageToken+ (\ s a -> s{_lerNextPageToken = a})++-- | The timestamp specifies the start time to which the request was+-- restricted.+lerTimeRangeBegin :: Lens' ListEventsResponse (Maybe UTCTime)+lerTimeRangeBegin+ = lens _lerTimeRangeBegin+ (\ s a -> s{_lerTimeRangeBegin = a})+ . mapping _DateTime++-- | The error events which match the given request.+lerErrorEvents :: Lens' ListEventsResponse [ErrorEvent]+lerErrorEvents+ = lens _lerErrorEvents+ (\ s a -> s{_lerErrorEvents = a})+ . _Default+ . _Coerce++instance FromJSON ListEventsResponse where+ parseJSON+ = withObject "ListEventsResponse"+ (\ o ->+ ListEventsResponse' <$>+ (o .:? "nextPageToken") <*> (o .:? "timeRangeBegin")+ <*> (o .:? "errorEvents" .!= mempty))++instance ToJSON ListEventsResponse where+ toJSON ListEventsResponse'{..}+ = object+ (catMaybes+ [("nextPageToken" .=) <$> _lerNextPageToken,+ ("timeRangeBegin" .=) <$> _lerTimeRangeBegin,+ ("errorEvents" .=) <$> _lerErrorEvents])++-- | Data extracted for a specific group based on certain filter criteria,+-- such as a given time period and\/or service filter.+--+-- /See:/ 'errorGroupStats' smart constructor.+data ErrorGroupStats = ErrorGroupStats'+ { _egsAffectedServices :: !(Maybe [ServiceContext])+ , _egsGroup :: !(Maybe ErrorGroup)+ , _egsFirstSeenTime :: !(Maybe DateTime')+ , _egsAffectedUsersCount :: !(Maybe (Textual Int64))+ , _egsCount :: !(Maybe (Textual Int64))+ , _egsTimedCounts :: !(Maybe [TimedCount])+ , _egsNumAffectedServices :: !(Maybe (Textual Int32))+ , _egsLastSeenTime :: !(Maybe DateTime')+ , _egsRepresentative :: !(Maybe ErrorEvent)+ } deriving (Eq,Show,Data,Typeable,Generic)++-- | Creates a value of 'ErrorGroupStats' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'egsAffectedServices'+--+-- * 'egsGroup'+--+-- * 'egsFirstSeenTime'+--+-- * 'egsAffectedUsersCount'+--+-- * 'egsCount'+--+-- * 'egsTimedCounts'+--+-- * 'egsNumAffectedServices'+--+-- * 'egsLastSeenTime'+--+-- * 'egsRepresentative'+errorGroupStats+ :: ErrorGroupStats+errorGroupStats =+ ErrorGroupStats'+ { _egsAffectedServices = Nothing+ , _egsGroup = Nothing+ , _egsFirstSeenTime = Nothing+ , _egsAffectedUsersCount = Nothing+ , _egsCount = Nothing+ , _egsTimedCounts = Nothing+ , _egsNumAffectedServices = Nothing+ , _egsLastSeenTime = Nothing+ , _egsRepresentative = Nothing+ }++-- | Service contexts with a non-zero error count for the given filter+-- criteria. This list can be truncated if multiple services are affected.+-- Refer to \`num_affected_services\` for the total count.+egsAffectedServices :: Lens' ErrorGroupStats [ServiceContext]+egsAffectedServices+ = lens _egsAffectedServices+ (\ s a -> s{_egsAffectedServices = a})+ . _Default+ . _Coerce++-- | Group data that is independent of the filter criteria.+egsGroup :: Lens' ErrorGroupStats (Maybe ErrorGroup)+egsGroup = lens _egsGroup (\ s a -> s{_egsGroup = a})++-- | Approximate first occurrence that was ever seen for this group and which+-- matches the given filter criteria, ignoring the time_range that was+-- specified in the request.+egsFirstSeenTime :: Lens' ErrorGroupStats (Maybe UTCTime)+egsFirstSeenTime+ = lens _egsFirstSeenTime+ (\ s a -> s{_egsFirstSeenTime = a})+ . mapping _DateTime++-- | Approximate number of affected users in the given group that match the+-- filter criteria. Users are distinguished by data in the \`ErrorContext\`+-- of the individual error events, such as their login name or their remote+-- IP address in case of HTTP requests. The number of affected users can be+-- zero even if the number of errors is non-zero if no data was provided+-- from which the affected user could be deduced. Users are counted based+-- on data in the request context that was provided in the error report. If+-- more users are implicitly affected, such as due to a crash of the whole+-- service, this is not reflected here.+egsAffectedUsersCount :: Lens' ErrorGroupStats (Maybe Int64)+egsAffectedUsersCount+ = lens _egsAffectedUsersCount+ (\ s a -> s{_egsAffectedUsersCount = a})+ . mapping _Coerce++-- | Approximate total number of events in the given group that match the+-- filter criteria.+egsCount :: Lens' ErrorGroupStats (Maybe Int64)+egsCount+ = lens _egsCount (\ s a -> s{_egsCount = a}) .+ mapping _Coerce++-- | Approximate number of occurrences over time. Timed counts returned by+-- ListGroups are guaranteed to be: - Inside the requested time interval -+-- Non-overlapping, and - Ordered by ascending time.+egsTimedCounts :: Lens' ErrorGroupStats [TimedCount]+egsTimedCounts+ = lens _egsTimedCounts+ (\ s a -> s{_egsTimedCounts = a})+ . _Default+ . _Coerce++-- | The total number of services with a non-zero error count for the given+-- filter criteria.+egsNumAffectedServices :: Lens' ErrorGroupStats (Maybe Int32)+egsNumAffectedServices+ = lens _egsNumAffectedServices+ (\ s a -> s{_egsNumAffectedServices = a})+ . mapping _Coerce++-- | Approximate last occurrence that was ever seen for this group and which+-- matches the given filter criteria, ignoring the time_range that was+-- specified in the request.+egsLastSeenTime :: Lens' ErrorGroupStats (Maybe UTCTime)+egsLastSeenTime+ = lens _egsLastSeenTime+ (\ s a -> s{_egsLastSeenTime = a})+ . mapping _DateTime++-- | An arbitrary event that is chosen as representative for the whole group.+-- The representative event is intended to be used as a quick preview for+-- the whole group. Events in the group are usually sufficiently similar to+-- each other such that showing an arbitrary representative provides+-- insight into the characteristics of the group as a whole.+egsRepresentative :: Lens' ErrorGroupStats (Maybe ErrorEvent)+egsRepresentative+ = lens _egsRepresentative+ (\ s a -> s{_egsRepresentative = a})++instance FromJSON ErrorGroupStats where+ parseJSON+ = withObject "ErrorGroupStats"+ (\ o ->+ ErrorGroupStats' <$>+ (o .:? "affectedServices" .!= mempty) <*>+ (o .:? "group")+ <*> (o .:? "firstSeenTime")+ <*> (o .:? "affectedUsersCount")+ <*> (o .:? "count")+ <*> (o .:? "timedCounts" .!= mempty)+ <*> (o .:? "numAffectedServices")+ <*> (o .:? "lastSeenTime")+ <*> (o .:? "representative"))++instance ToJSON ErrorGroupStats where+ toJSON ErrorGroupStats'{..}+ = object+ (catMaybes+ [("affectedServices" .=) <$> _egsAffectedServices,+ ("group" .=) <$> _egsGroup,+ ("firstSeenTime" .=) <$> _egsFirstSeenTime,+ ("affectedUsersCount" .=) <$> _egsAffectedUsersCount,+ ("count" .=) <$> _egsCount,+ ("timedCounts" .=) <$> _egsTimedCounts,+ ("numAffectedServices" .=) <$>+ _egsNumAffectedServices,+ ("lastSeenTime" .=) <$> _egsLastSeenTime,+ ("representative" .=) <$> _egsRepresentative])++-- | Contains a set of requested error group stats.+--+-- /See:/ 'listGroupStatsResponse' smart constructor.+data ListGroupStatsResponse = ListGroupStatsResponse'+ { _lgsrNextPageToken :: !(Maybe Text)+ , _lgsrTimeRangeBegin :: !(Maybe DateTime')+ , _lgsrErrorGroupStats :: !(Maybe [ErrorGroupStats])+ } deriving (Eq,Show,Data,Typeable,Generic)++-- | Creates a value of 'ListGroupStatsResponse' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'lgsrNextPageToken'+--+-- * 'lgsrTimeRangeBegin'+--+-- * 'lgsrErrorGroupStats'+listGroupStatsResponse+ :: ListGroupStatsResponse+listGroupStatsResponse =+ ListGroupStatsResponse'+ { _lgsrNextPageToken = Nothing+ , _lgsrTimeRangeBegin = Nothing+ , _lgsrErrorGroupStats = Nothing+ }++-- | If non-empty, more results are available. Pass this token, along with+-- the same query parameters as the first request, to view the next page of+-- results.+lgsrNextPageToken :: Lens' ListGroupStatsResponse (Maybe Text)+lgsrNextPageToken+ = lens _lgsrNextPageToken+ (\ s a -> s{_lgsrNextPageToken = a})++-- | The timestamp specifies the start time to which the request was+-- restricted. The start time is set based on the requested time range. It+-- may be adjusted to a later time if a project has exceeded the storage+-- quota and older data has been deleted.+lgsrTimeRangeBegin :: Lens' ListGroupStatsResponse (Maybe UTCTime)+lgsrTimeRangeBegin+ = lens _lgsrTimeRangeBegin+ (\ s a -> s{_lgsrTimeRangeBegin = a})+ . mapping _DateTime++-- | The error group stats which match the given request.+lgsrErrorGroupStats :: Lens' ListGroupStatsResponse [ErrorGroupStats]+lgsrErrorGroupStats+ = lens _lgsrErrorGroupStats+ (\ s a -> s{_lgsrErrorGroupStats = a})+ . _Default+ . _Coerce++instance FromJSON ListGroupStatsResponse where+ parseJSON+ = withObject "ListGroupStatsResponse"+ (\ o ->+ ListGroupStatsResponse' <$>+ (o .:? "nextPageToken") <*> (o .:? "timeRangeBegin")+ <*> (o .:? "errorGroupStats" .!= mempty))++instance ToJSON ListGroupStatsResponse where+ toJSON ListGroupStatsResponse'{..}+ = object+ (catMaybes+ [("nextPageToken" .=) <$> _lgsrNextPageToken,+ ("timeRangeBegin" .=) <$> _lgsrTimeRangeBegin,+ ("errorGroupStats" .=) <$> _lgsrErrorGroupStats])++-- | Describes a running service that sends errors. Its version changes over+-- time and multiple versions can run in parallel.+--+-- /See:/ 'serviceContext' smart constructor.+data ServiceContext = ServiceContext'+ { _scResourceType :: !(Maybe Text)+ , _scService :: !(Maybe Text)+ , _scVersion :: !(Maybe Text)+ } deriving (Eq,Show,Data,Typeable,Generic)++-- | Creates a value of 'ServiceContext' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'scResourceType'+--+-- * 'scService'+--+-- * 'scVersion'+serviceContext+ :: ServiceContext+serviceContext =+ ServiceContext'+ { _scResourceType = Nothing+ , _scService = Nothing+ , _scVersion = Nothing+ }++-- | Type of the MonitoredResource. List of possible values:+-- https:\/\/cloud.google.com\/monitoring\/api\/resources Value is set+-- automatically for incoming errors and must not be set when reporting+-- errors.+scResourceType :: Lens' ServiceContext (Maybe Text)+scResourceType+ = lens _scResourceType+ (\ s a -> s{_scResourceType = a})++-- | An identifier of the service, such as the name of the executable, job,+-- or Google App Engine service name. This field is expected to have a low+-- number of values that are relatively stable over time, as opposed to+-- \`version\`, which can be changed whenever new code is deployed.+-- Contains the service name for error reports extracted from Google App+-- Engine logs or \`default\` if the App Engine default service is used.+scService :: Lens' ServiceContext (Maybe Text)+scService+ = lens _scService (\ s a -> s{_scService = a})++-- | Represents the source code version that the developer provided, which+-- could represent a version label or a Git SHA-1 hash, for example. For+-- App Engine standard environment, the version is set to the version of+-- the app.+scVersion :: Lens' ServiceContext (Maybe Text)+scVersion+ = lens _scVersion (\ s a -> s{_scVersion = a})++instance FromJSON ServiceContext where+ parseJSON+ = withObject "ServiceContext"+ (\ o ->+ ServiceContext' <$>+ (o .:? "resourceType") <*> (o .:? "service") <*>+ (o .:? "version"))++instance ToJSON ServiceContext where+ toJSON ServiceContext'{..}+ = object+ (catMaybes+ [("resourceType" .=) <$> _scResourceType,+ ("service" .=) <$> _scService,+ ("version" .=) <$> _scVersion])++-- | The number of errors in a given time period. All numbers are approximate+-- since the error events are sampled before counting them.+--+-- /See:/ 'timedCount' smart constructor.+data TimedCount = TimedCount'+ { _tcStartTime :: !(Maybe DateTime')+ , _tcCount :: !(Maybe (Textual Int64))+ , _tcEndTime :: !(Maybe DateTime')+ } deriving (Eq,Show,Data,Typeable,Generic)++-- | Creates a value of 'TimedCount' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'tcStartTime'+--+-- * 'tcCount'+--+-- * 'tcEndTime'+timedCount+ :: TimedCount+timedCount =+ TimedCount'+ { _tcStartTime = Nothing+ , _tcCount = Nothing+ , _tcEndTime = Nothing+ }++-- | Start of the time period to which \`count\` refers (included).+tcStartTime :: Lens' TimedCount (Maybe UTCTime)+tcStartTime+ = lens _tcStartTime (\ s a -> s{_tcStartTime = a}) .+ mapping _DateTime++-- | Approximate number of occurrences in the given time period.+tcCount :: Lens' TimedCount (Maybe Int64)+tcCount+ = lens _tcCount (\ s a -> s{_tcCount = a}) .+ mapping _Coerce++-- | End of the time period to which \`count\` refers (excluded).+tcEndTime :: Lens' TimedCount (Maybe UTCTime)+tcEndTime+ = lens _tcEndTime (\ s a -> s{_tcEndTime = a}) .+ mapping _DateTime++instance FromJSON TimedCount where+ parseJSON+ = withObject "TimedCount"+ (\ o ->+ TimedCount' <$>+ (o .:? "startTime") <*> (o .:? "count") <*>+ (o .:? "endTime"))++instance ToJSON TimedCount where+ toJSON TimedCount'{..}+ = object+ (catMaybes+ [("startTime" .=) <$> _tcStartTime,+ ("count" .=) <$> _tcCount,+ ("endTime" .=) <$> _tcEndTime])++-- | Indicates a location in the source code of the service for which errors+-- are reported. \`functionName\` must be provided by the application when+-- reporting an error, unless the error report contains a \`message\` with+-- a supported exception stack trace. All fields are optional for the later+-- case.+--+-- /See:/ 'sourceLocation' smart constructor.+data SourceLocation = SourceLocation'+ { _slLineNumber :: !(Maybe (Textual Int32))+ , _slFilePath :: !(Maybe Text)+ , _slFunctionName :: !(Maybe Text)+ } deriving (Eq,Show,Data,Typeable,Generic)++-- | Creates a value of 'SourceLocation' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'slLineNumber'+--+-- * 'slFilePath'+--+-- * 'slFunctionName'+sourceLocation+ :: SourceLocation+sourceLocation =+ SourceLocation'+ { _slLineNumber = Nothing+ , _slFilePath = Nothing+ , _slFunctionName = Nothing+ }++-- | 1-based. 0 indicates that the line number is unknown.+slLineNumber :: Lens' SourceLocation (Maybe Int32)+slLineNumber+ = lens _slLineNumber (\ s a -> s{_slLineNumber = a})+ . mapping _Coerce++-- | The source code filename, which can include a truncated relative path,+-- or a full path from a production machine.+slFilePath :: Lens' SourceLocation (Maybe Text)+slFilePath+ = lens _slFilePath (\ s a -> s{_slFilePath = a})++-- | Human-readable name of a function or method. The value can include+-- optional context like the class or package name. For example,+-- \`my.package.MyClass.method\` in case of Java.+slFunctionName :: Lens' SourceLocation (Maybe Text)+slFunctionName+ = lens _slFunctionName+ (\ s a -> s{_slFunctionName = a})++instance FromJSON SourceLocation where+ parseJSON+ = withObject "SourceLocation"+ (\ o ->+ SourceLocation' <$>+ (o .:? "lineNumber") <*> (o .:? "filePath") <*>+ (o .:? "functionName"))++instance ToJSON SourceLocation where+ toJSON SourceLocation'{..}+ = object+ (catMaybes+ [("lineNumber" .=) <$> _slLineNumber,+ ("filePath" .=) <$> _slFilePath,+ ("functionName" .=) <$> _slFunctionName])++-- | A reference to a particular snapshot of the source tree used to build+-- and deploy an application.+--+-- /See:/ 'sourceReference' smart constructor.+data SourceReference = SourceReference'+ { _srRepository :: !(Maybe Text)+ , _srRevisionId :: !(Maybe Text)+ } deriving (Eq,Show,Data,Typeable,Generic)++-- | Creates a value of 'SourceReference' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'srRepository'+--+-- * 'srRevisionId'+sourceReference+ :: SourceReference+sourceReference =+ SourceReference'+ { _srRepository = Nothing+ , _srRevisionId = Nothing+ }++-- | Optional. A URI string identifying the repository. Example:+-- \"https:\/\/github.com\/GoogleCloudPlatform\/kubernetes.git\"+srRepository :: Lens' SourceReference (Maybe Text)+srRepository+ = lens _srRepository (\ s a -> s{_srRepository = a})++-- | The canonical and persistent identifier of the deployed revision.+-- Example (git): \"0035781c50ec7aa23385dc841529ce8a4b70db1b\"+srRevisionId :: Lens' SourceReference (Maybe Text)+srRevisionId+ = lens _srRevisionId (\ s a -> s{_srRevisionId = a})++instance FromJSON SourceReference where+ parseJSON+ = withObject "SourceReference"+ (\ o ->+ SourceReference' <$>+ (o .:? "repository") <*> (o .:? "revisionId"))++instance ToJSON SourceReference where+ toJSON SourceReference'{..}+ = object+ (catMaybes+ [("repository" .=) <$> _srRepository,+ ("revisionId" .=) <$> _srRevisionId])++-- | Response for reporting an individual error event. Data may be added to+-- this message in the future.+--+-- /See:/ 'reportErrorEventResponse' smart constructor.+data ReportErrorEventResponse =+ ReportErrorEventResponse'+ deriving (Eq,Show,Data,Typeable,Generic)++-- | Creates a value of 'ReportErrorEventResponse' with the minimum fields required to make a request.+--+reportErrorEventResponse+ :: ReportErrorEventResponse+reportErrorEventResponse = ReportErrorEventResponse'++instance FromJSON ReportErrorEventResponse where+ parseJSON+ = withObject "ReportErrorEventResponse"+ (\ o -> pure ReportErrorEventResponse')++instance ToJSON ReportErrorEventResponse where+ toJSON = const emptyObject
+ gen/Network/Google/CloudErrorReporting/Types/Sum.hs view
@@ -0,0 +1,48 @@+{-# LANGUAGE DeriveDataTypeable #-}+{-# LANGUAGE DeriveGeneric #-}+{-# LANGUAGE LambdaCase #-}+{-# LANGUAGE NoImplicitPrelude #-}+{-# LANGUAGE OverloadedStrings #-}++{-# OPTIONS_GHC -fno-warn-unused-imports #-}++-- |+-- Module : Network.Google.CloudErrorReporting.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.CloudErrorReporting.Types.Sum where++import Network.Google.Prelude hiding (Bytes)++-- | 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
+ gen/Network/Google/Resource/CloudErrorReporting/Projects/DeleteEvents.hs view
@@ -0,0 +1,151 @@+{-# 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.CloudErrorReporting.Projects.DeleteEvents+-- 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)+--+-- Deletes all error events of a given project.+--+-- /See:/ <https://cloud.google.com/error-reporting/ Stackdriver Error Reporting API Reference> for @clouderrorreporting.projects.deleteEvents@.+module Network.Google.Resource.CloudErrorReporting.Projects.DeleteEvents+ (+ -- * REST Resource+ ProjectsDeleteEventsResource++ -- * Creating a Request+ , projectsDeleteEvents+ , ProjectsDeleteEvents++ -- * Request Lenses+ , pdeXgafv+ , pdeUploadProtocol+ , pdeAccessToken+ , pdeUploadType+ , pdeProjectName+ , pdeCallback+ ) where++import Network.Google.CloudErrorReporting.Types+import Network.Google.Prelude++-- | A resource alias for @clouderrorreporting.projects.deleteEvents@ method which the+-- 'ProjectsDeleteEvents' request conforms to.+type ProjectsDeleteEventsResource =+ "v1beta1" :>+ Capture "projectName" Text :>+ "events" :>+ QueryParam "$.xgafv" Xgafv :>+ QueryParam "upload_protocol" Text :>+ QueryParam "access_token" Text :>+ QueryParam "uploadType" Text :>+ QueryParam "callback" Text :>+ QueryParam "alt" AltJSON :>+ Delete '[JSON] DeleteEventsResponse++-- | Deletes all error events of a given project.+--+-- /See:/ 'projectsDeleteEvents' smart constructor.+data ProjectsDeleteEvents = ProjectsDeleteEvents'+ { _pdeXgafv :: !(Maybe Xgafv)+ , _pdeUploadProtocol :: !(Maybe Text)+ , _pdeAccessToken :: !(Maybe Text)+ , _pdeUploadType :: !(Maybe Text)+ , _pdeProjectName :: !Text+ , _pdeCallback :: !(Maybe Text)+ } deriving (Eq,Show,Data,Typeable,Generic)++-- | Creates a value of 'ProjectsDeleteEvents' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'pdeXgafv'+--+-- * 'pdeUploadProtocol'+--+-- * 'pdeAccessToken'+--+-- * 'pdeUploadType'+--+-- * 'pdeProjectName'+--+-- * 'pdeCallback'+projectsDeleteEvents+ :: Text -- ^ 'pdeProjectName'+ -> ProjectsDeleteEvents+projectsDeleteEvents pPdeProjectName_ =+ ProjectsDeleteEvents'+ { _pdeXgafv = Nothing+ , _pdeUploadProtocol = Nothing+ , _pdeAccessToken = Nothing+ , _pdeUploadType = Nothing+ , _pdeProjectName = pPdeProjectName_+ , _pdeCallback = Nothing+ }++-- | V1 error format.+pdeXgafv :: Lens' ProjectsDeleteEvents (Maybe Xgafv)+pdeXgafv = lens _pdeXgafv (\ s a -> s{_pdeXgafv = a})++-- | Upload protocol for media (e.g. \"raw\", \"multipart\").+pdeUploadProtocol :: Lens' ProjectsDeleteEvents (Maybe Text)+pdeUploadProtocol+ = lens _pdeUploadProtocol+ (\ s a -> s{_pdeUploadProtocol = a})++-- | OAuth access token.+pdeAccessToken :: Lens' ProjectsDeleteEvents (Maybe Text)+pdeAccessToken+ = lens _pdeAccessToken+ (\ s a -> s{_pdeAccessToken = a})++-- | Legacy upload protocol for media (e.g. \"media\", \"multipart\").+pdeUploadType :: Lens' ProjectsDeleteEvents (Maybe Text)+pdeUploadType+ = lens _pdeUploadType+ (\ s a -> s{_pdeUploadType = a})++-- | [Required] The resource name of the Google Cloud Platform project.+-- Written as \`projects\/\` plus the [Google Cloud Platform project+-- ID](https:\/\/support.google.com\/cloud\/answer\/6158840). Example:+-- \`projects\/my-project-123\`.+pdeProjectName :: Lens' ProjectsDeleteEvents Text+pdeProjectName+ = lens _pdeProjectName+ (\ s a -> s{_pdeProjectName = a})++-- | JSONP+pdeCallback :: Lens' ProjectsDeleteEvents (Maybe Text)+pdeCallback+ = lens _pdeCallback (\ s a -> s{_pdeCallback = a})++instance GoogleRequest ProjectsDeleteEvents where+ type Rs ProjectsDeleteEvents = DeleteEventsResponse+ type Scopes ProjectsDeleteEvents =+ '["https://www.googleapis.com/auth/cloud-platform"]+ requestClient ProjectsDeleteEvents'{..}+ = go _pdeProjectName _pdeXgafv _pdeUploadProtocol+ _pdeAccessToken+ _pdeUploadType+ _pdeCallback+ (Just AltJSON)+ cloudErrorReportingService+ where go+ = buildClient+ (Proxy :: Proxy ProjectsDeleteEventsResource)+ mempty
+ gen/Network/Google/Resource/CloudErrorReporting/Projects/Events/List.hs view
@@ -0,0 +1,243 @@+{-# 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.CloudErrorReporting.Projects.Events.List+-- Copyright : (c) 2015-2016 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Lists the specified events.+--+-- /See:/ <https://cloud.google.com/error-reporting/ Stackdriver Error Reporting API Reference> for @clouderrorreporting.projects.events.list@.+module Network.Google.Resource.CloudErrorReporting.Projects.Events.List+ (+ -- * REST Resource+ ProjectsEventsListResource++ -- * Creating a Request+ , projectsEventsList+ , ProjectsEventsList++ -- * Request Lenses+ , pelXgafv+ , pelUploadProtocol+ , pelAccessToken+ , pelUploadType+ , pelProjectName+ , pelGroupId+ , pelPageToken+ , pelPageSize+ , pelServiceFilterService+ , pelServiceFilterResourceType+ , pelCallback+ , pelServiceFilterVersion+ , pelTimeRangePeriod+ ) where++import Network.Google.CloudErrorReporting.Types+import Network.Google.Prelude++-- | A resource alias for @clouderrorreporting.projects.events.list@ method which the+-- 'ProjectsEventsList' request conforms to.+type ProjectsEventsListResource =+ "v1beta1" :>+ Capture "projectName" Text :>+ "events" :>+ QueryParam "$.xgafv" Xgafv :>+ QueryParam "upload_protocol" Text :>+ QueryParam "access_token" Text :>+ QueryParam "uploadType" Text :>+ QueryParam "groupId" Text :>+ QueryParam "pageToken" Text :>+ QueryParam "pageSize" (Textual Int32) :>+ QueryParam "serviceFilter.service" Text :>+ QueryParam "serviceFilter.resourceType" Text :>+ QueryParam "callback" Text :>+ QueryParam "serviceFilter.version" Text :>+ QueryParam "timeRange.period" Text :>+ QueryParam "alt" AltJSON :>+ Get '[JSON] ListEventsResponse++-- | Lists the specified events.+--+-- /See:/ 'projectsEventsList' smart constructor.+data ProjectsEventsList = ProjectsEventsList'+ { _pelXgafv :: !(Maybe Xgafv)+ , _pelUploadProtocol :: !(Maybe Text)+ , _pelAccessToken :: !(Maybe Text)+ , _pelUploadType :: !(Maybe Text)+ , _pelProjectName :: !Text+ , _pelGroupId :: !(Maybe Text)+ , _pelPageToken :: !(Maybe Text)+ , _pelPageSize :: !(Maybe (Textual Int32))+ , _pelServiceFilterService :: !(Maybe Text)+ , _pelServiceFilterResourceType :: !(Maybe Text)+ , _pelCallback :: !(Maybe Text)+ , _pelServiceFilterVersion :: !(Maybe Text)+ , _pelTimeRangePeriod :: !(Maybe Text)+ } deriving (Eq,Show,Data,Typeable,Generic)++-- | Creates a value of 'ProjectsEventsList' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'pelXgafv'+--+-- * 'pelUploadProtocol'+--+-- * 'pelAccessToken'+--+-- * 'pelUploadType'+--+-- * 'pelProjectName'+--+-- * 'pelGroupId'+--+-- * 'pelPageToken'+--+-- * 'pelPageSize'+--+-- * 'pelServiceFilterService'+--+-- * 'pelServiceFilterResourceType'+--+-- * 'pelCallback'+--+-- * 'pelServiceFilterVersion'+--+-- * 'pelTimeRangePeriod'+projectsEventsList+ :: Text -- ^ 'pelProjectName'+ -> ProjectsEventsList+projectsEventsList pPelProjectName_ =+ ProjectsEventsList'+ { _pelXgafv = Nothing+ , _pelUploadProtocol = Nothing+ , _pelAccessToken = Nothing+ , _pelUploadType = Nothing+ , _pelProjectName = pPelProjectName_+ , _pelGroupId = Nothing+ , _pelPageToken = Nothing+ , _pelPageSize = Nothing+ , _pelServiceFilterService = Nothing+ , _pelServiceFilterResourceType = Nothing+ , _pelCallback = Nothing+ , _pelServiceFilterVersion = Nothing+ , _pelTimeRangePeriod = Nothing+ }++-- | V1 error format.+pelXgafv :: Lens' ProjectsEventsList (Maybe Xgafv)+pelXgafv = lens _pelXgafv (\ s a -> s{_pelXgafv = a})++-- | Upload protocol for media (e.g. \"raw\", \"multipart\").+pelUploadProtocol :: Lens' ProjectsEventsList (Maybe Text)+pelUploadProtocol+ = lens _pelUploadProtocol+ (\ s a -> s{_pelUploadProtocol = a})++-- | OAuth access token.+pelAccessToken :: Lens' ProjectsEventsList (Maybe Text)+pelAccessToken+ = lens _pelAccessToken+ (\ s a -> s{_pelAccessToken = a})++-- | Legacy upload protocol for media (e.g. \"media\", \"multipart\").+pelUploadType :: Lens' ProjectsEventsList (Maybe Text)+pelUploadType+ = lens _pelUploadType+ (\ s a -> s{_pelUploadType = a})++-- | [Required] The resource name of the Google Cloud Platform project.+-- Written as \`projects\/\` plus the [Google Cloud Platform project+-- ID](https:\/\/support.google.com\/cloud\/answer\/6158840). Example:+-- \`projects\/my-project-123\`.+pelProjectName :: Lens' ProjectsEventsList Text+pelProjectName+ = lens _pelProjectName+ (\ s a -> s{_pelProjectName = a})++-- | [Required] The group for which events shall be returned.+pelGroupId :: Lens' ProjectsEventsList (Maybe Text)+pelGroupId+ = lens _pelGroupId (\ s a -> s{_pelGroupId = a})++-- | [Optional] A \`next_page_token\` provided by a previous response.+pelPageToken :: Lens' ProjectsEventsList (Maybe Text)+pelPageToken+ = lens _pelPageToken (\ s a -> s{_pelPageToken = a})++-- | [Optional] The maximum number of results to return per response.+pelPageSize :: Lens' ProjectsEventsList (Maybe Int32)+pelPageSize+ = lens _pelPageSize (\ s a -> s{_pelPageSize = a}) .+ mapping _Coerce++-- | [Optional] The exact value to match against+-- [\`ServiceContext.service\`](\/error-reporting\/reference\/rest\/v1beta1\/ServiceContext#FIELDS.service).+pelServiceFilterService :: Lens' ProjectsEventsList (Maybe Text)+pelServiceFilterService+ = lens _pelServiceFilterService+ (\ s a -> s{_pelServiceFilterService = a})++-- | [Optional] The exact value to match against+-- [\`ServiceContext.resource_type\`](\/error-reporting\/reference\/rest\/v1beta1\/ServiceContext#FIELDS.resource_type).+pelServiceFilterResourceType :: Lens' ProjectsEventsList (Maybe Text)+pelServiceFilterResourceType+ = lens _pelServiceFilterResourceType+ (\ s a -> s{_pelServiceFilterResourceType = a})++-- | JSONP+pelCallback :: Lens' ProjectsEventsList (Maybe Text)+pelCallback+ = lens _pelCallback (\ s a -> s{_pelCallback = a})++-- | [Optional] The exact value to match against+-- [\`ServiceContext.version\`](\/error-reporting\/reference\/rest\/v1beta1\/ServiceContext#FIELDS.version).+pelServiceFilterVersion :: Lens' ProjectsEventsList (Maybe Text)+pelServiceFilterVersion+ = lens _pelServiceFilterVersion+ (\ s a -> s{_pelServiceFilterVersion = a})++-- | Restricts the query to the specified time range.+pelTimeRangePeriod :: Lens' ProjectsEventsList (Maybe Text)+pelTimeRangePeriod+ = lens _pelTimeRangePeriod+ (\ s a -> s{_pelTimeRangePeriod = a})++instance GoogleRequest ProjectsEventsList where+ type Rs ProjectsEventsList = ListEventsResponse+ type Scopes ProjectsEventsList =+ '["https://www.googleapis.com/auth/cloud-platform"]+ requestClient ProjectsEventsList'{..}+ = go _pelProjectName _pelXgafv _pelUploadProtocol+ _pelAccessToken+ _pelUploadType+ _pelGroupId+ _pelPageToken+ _pelPageSize+ _pelServiceFilterService+ _pelServiceFilterResourceType+ _pelCallback+ _pelServiceFilterVersion+ _pelTimeRangePeriod+ (Just AltJSON)+ cloudErrorReportingService+ where go+ = buildClient+ (Proxy :: Proxy ProjectsEventsListResource)+ mempty
+ gen/Network/Google/Resource/CloudErrorReporting/Projects/Events/Report.hs view
@@ -0,0 +1,175 @@+{-# 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.CloudErrorReporting.Projects.Events.Report+-- 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)+--+-- Report an individual error event. This endpoint accepts **either** an+-- OAuth token, **or** an [API+-- key](https:\/\/support.google.com\/cloud\/answer\/6158862) for+-- authentication. To use an API key, append it to the URL as the value of+-- a \`key\` parameter. For example: \`POST+-- https:\/\/clouderrorreporting.googleapis.com\/v1beta1\/projects\/example-project\/events:report?key=123ABC456\`+--+-- /See:/ <https://cloud.google.com/error-reporting/ Stackdriver Error Reporting API Reference> for @clouderrorreporting.projects.events.report@.+module Network.Google.Resource.CloudErrorReporting.Projects.Events.Report+ (+ -- * REST Resource+ ProjectsEventsReportResource++ -- * Creating a Request+ , projectsEventsReport+ , ProjectsEventsReport++ -- * Request Lenses+ , perXgafv+ , perUploadProtocol+ , perAccessToken+ , perUploadType+ , perPayload+ , perProjectName+ , perCallback+ ) where++import Network.Google.CloudErrorReporting.Types+import Network.Google.Prelude++-- | A resource alias for @clouderrorreporting.projects.events.report@ method which the+-- 'ProjectsEventsReport' request conforms to.+type ProjectsEventsReportResource =+ "v1beta1" :>+ Capture "projectName" Text :>+ "events:report" :>+ QueryParam "$.xgafv" Xgafv :>+ QueryParam "upload_protocol" Text :>+ QueryParam "access_token" Text :>+ QueryParam "uploadType" Text :>+ QueryParam "callback" Text :>+ QueryParam "alt" AltJSON :>+ ReqBody '[JSON] ReportedErrorEvent :>+ Post '[JSON] ReportErrorEventResponse++-- | Report an individual error event. This endpoint accepts **either** an+-- OAuth token, **or** an [API+-- key](https:\/\/support.google.com\/cloud\/answer\/6158862) for+-- authentication. To use an API key, append it to the URL as the value of+-- a \`key\` parameter. For example: \`POST+-- https:\/\/clouderrorreporting.googleapis.com\/v1beta1\/projects\/example-project\/events:report?key=123ABC456\`+--+-- /See:/ 'projectsEventsReport' smart constructor.+data ProjectsEventsReport = ProjectsEventsReport'+ { _perXgafv :: !(Maybe Xgafv)+ , _perUploadProtocol :: !(Maybe Text)+ , _perAccessToken :: !(Maybe Text)+ , _perUploadType :: !(Maybe Text)+ , _perPayload :: !ReportedErrorEvent+ , _perProjectName :: !Text+ , _perCallback :: !(Maybe Text)+ } deriving (Eq,Show,Data,Typeable,Generic)++-- | Creates a value of 'ProjectsEventsReport' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'perXgafv'+--+-- * 'perUploadProtocol'+--+-- * 'perAccessToken'+--+-- * 'perUploadType'+--+-- * 'perPayload'+--+-- * 'perProjectName'+--+-- * 'perCallback'+projectsEventsReport+ :: ReportedErrorEvent -- ^ 'perPayload'+ -> Text -- ^ 'perProjectName'+ -> ProjectsEventsReport+projectsEventsReport pPerPayload_ pPerProjectName_ =+ ProjectsEventsReport'+ { _perXgafv = Nothing+ , _perUploadProtocol = Nothing+ , _perAccessToken = Nothing+ , _perUploadType = Nothing+ , _perPayload = pPerPayload_+ , _perProjectName = pPerProjectName_+ , _perCallback = Nothing+ }++-- | V1 error format.+perXgafv :: Lens' ProjectsEventsReport (Maybe Xgafv)+perXgafv = lens _perXgafv (\ s a -> s{_perXgafv = a})++-- | Upload protocol for media (e.g. \"raw\", \"multipart\").+perUploadProtocol :: Lens' ProjectsEventsReport (Maybe Text)+perUploadProtocol+ = lens _perUploadProtocol+ (\ s a -> s{_perUploadProtocol = a})++-- | OAuth access token.+perAccessToken :: Lens' ProjectsEventsReport (Maybe Text)+perAccessToken+ = lens _perAccessToken+ (\ s a -> s{_perAccessToken = a})++-- | Legacy upload protocol for media (e.g. \"media\", \"multipart\").+perUploadType :: Lens' ProjectsEventsReport (Maybe Text)+perUploadType+ = lens _perUploadType+ (\ s a -> s{_perUploadType = a})++-- | Multipart request metadata.+perPayload :: Lens' ProjectsEventsReport ReportedErrorEvent+perPayload+ = lens _perPayload (\ s a -> s{_perPayload = a})++-- | [Required] The resource name of the Google Cloud Platform project.+-- Written as \`projects\/\` plus the [Google Cloud Platform project+-- ID](https:\/\/support.google.com\/cloud\/answer\/6158840). Example:+-- \`projects\/my-project-123\`.+perProjectName :: Lens' ProjectsEventsReport Text+perProjectName+ = lens _perProjectName+ (\ s a -> s{_perProjectName = a})++-- | JSONP+perCallback :: Lens' ProjectsEventsReport (Maybe Text)+perCallback+ = lens _perCallback (\ s a -> s{_perCallback = a})++instance GoogleRequest ProjectsEventsReport where+ type Rs ProjectsEventsReport =+ ReportErrorEventResponse+ type Scopes ProjectsEventsReport =+ '["https://www.googleapis.com/auth/cloud-platform"]+ requestClient ProjectsEventsReport'{..}+ = go _perProjectName _perXgafv _perUploadProtocol+ _perAccessToken+ _perUploadType+ _perCallback+ (Just AltJSON)+ _perPayload+ cloudErrorReportingService+ where go+ = buildClient+ (Proxy :: Proxy ProjectsEventsReportResource)+ mempty
+ gen/Network/Google/Resource/CloudErrorReporting/Projects/GroupStats/List.hs view
@@ -0,0 +1,310 @@+{-# 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.CloudErrorReporting.Projects.GroupStats.List+-- Copyright : (c) 2015-2016 Brendan Hay+-- License : Mozilla Public License, v. 2.0.+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>+-- Stability : auto-generated+-- Portability : non-portable (GHC extensions)+--+-- Lists the specified groups.+--+-- /See:/ <https://cloud.google.com/error-reporting/ Stackdriver Error Reporting API Reference> for @clouderrorreporting.projects.groupStats.list@.+module Network.Google.Resource.CloudErrorReporting.Projects.GroupStats.List+ (+ -- * REST Resource+ ProjectsGroupStatsListResource++ -- * Creating a Request+ , projectsGroupStatsList+ , ProjectsGroupStatsList++ -- * Request Lenses+ , pgslXgafv+ , pgslUploadProtocol+ , pgslAccessToken+ , pgslUploadType+ , pgslTimedCountDuration+ , pgslAlignment+ , pgslProjectName+ , pgslGroupId+ , pgslAlignmentTime+ , pgslPageToken+ , pgslPageSize+ , pgslServiceFilterService+ , pgslOrder+ , pgslServiceFilterResourceType+ , pgslCallback+ , pgslServiceFilterVersion+ , pgslTimeRangePeriod+ ) where++import Network.Google.CloudErrorReporting.Types+import Network.Google.Prelude++-- | A resource alias for @clouderrorreporting.projects.groupStats.list@ method which the+-- 'ProjectsGroupStatsList' request conforms to.+type ProjectsGroupStatsListResource =+ "v1beta1" :>+ Capture "projectName" Text :>+ "groupStats" :>+ QueryParam "$.xgafv" Xgafv :>+ QueryParam "upload_protocol" Text :>+ QueryParam "access_token" Text :>+ QueryParam "uploadType" Text :>+ QueryParam "timedCountDuration" GDuration :>+ QueryParam "alignment" Text :>+ QueryParams "groupId" Text :>+ QueryParam "alignmentTime" DateTime' :>+ QueryParam "pageToken" Text :>+ QueryParam "pageSize" (Textual Int32) :>+ QueryParam "serviceFilter.service" Text :>+ QueryParam "order" Text :>+ QueryParam "serviceFilter.resourceType" Text+ :>+ QueryParam "callback" Text :>+ QueryParam "serviceFilter.version" Text+ :>+ QueryParam "timeRange.period" Text :>+ QueryParam "alt" AltJSON :>+ Get '[JSON] ListGroupStatsResponse++-- | Lists the specified groups.+--+-- /See:/ 'projectsGroupStatsList' smart constructor.+data ProjectsGroupStatsList = ProjectsGroupStatsList'+ { _pgslXgafv :: !(Maybe Xgafv)+ , _pgslUploadProtocol :: !(Maybe Text)+ , _pgslAccessToken :: !(Maybe Text)+ , _pgslUploadType :: !(Maybe Text)+ , _pgslTimedCountDuration :: !(Maybe GDuration)+ , _pgslAlignment :: !(Maybe Text)+ , _pgslProjectName :: !Text+ , _pgslGroupId :: !(Maybe [Text])+ , _pgslAlignmentTime :: !(Maybe DateTime')+ , _pgslPageToken :: !(Maybe Text)+ , _pgslPageSize :: !(Maybe (Textual Int32))+ , _pgslServiceFilterService :: !(Maybe Text)+ , _pgslOrder :: !(Maybe Text)+ , _pgslServiceFilterResourceType :: !(Maybe Text)+ , _pgslCallback :: !(Maybe Text)+ , _pgslServiceFilterVersion :: !(Maybe Text)+ , _pgslTimeRangePeriod :: !(Maybe Text)+ } deriving (Eq,Show,Data,Typeable,Generic)++-- | Creates a value of 'ProjectsGroupStatsList' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'pgslXgafv'+--+-- * 'pgslUploadProtocol'+--+-- * 'pgslAccessToken'+--+-- * 'pgslUploadType'+--+-- * 'pgslTimedCountDuration'+--+-- * 'pgslAlignment'+--+-- * 'pgslProjectName'+--+-- * 'pgslGroupId'+--+-- * 'pgslAlignmentTime'+--+-- * 'pgslPageToken'+--+-- * 'pgslPageSize'+--+-- * 'pgslServiceFilterService'+--+-- * 'pgslOrder'+--+-- * 'pgslServiceFilterResourceType'+--+-- * 'pgslCallback'+--+-- * 'pgslServiceFilterVersion'+--+-- * 'pgslTimeRangePeriod'+projectsGroupStatsList+ :: Text -- ^ 'pgslProjectName'+ -> ProjectsGroupStatsList+projectsGroupStatsList pPgslProjectName_ =+ ProjectsGroupStatsList'+ { _pgslXgafv = Nothing+ , _pgslUploadProtocol = Nothing+ , _pgslAccessToken = Nothing+ , _pgslUploadType = Nothing+ , _pgslTimedCountDuration = Nothing+ , _pgslAlignment = Nothing+ , _pgslProjectName = pPgslProjectName_+ , _pgslGroupId = Nothing+ , _pgslAlignmentTime = Nothing+ , _pgslPageToken = Nothing+ , _pgslPageSize = Nothing+ , _pgslServiceFilterService = Nothing+ , _pgslOrder = Nothing+ , _pgslServiceFilterResourceType = Nothing+ , _pgslCallback = Nothing+ , _pgslServiceFilterVersion = Nothing+ , _pgslTimeRangePeriod = Nothing+ }++-- | V1 error format.+pgslXgafv :: Lens' ProjectsGroupStatsList (Maybe Xgafv)+pgslXgafv+ = lens _pgslXgafv (\ s a -> s{_pgslXgafv = a})++-- | Upload protocol for media (e.g. \"raw\", \"multipart\").+pgslUploadProtocol :: Lens' ProjectsGroupStatsList (Maybe Text)+pgslUploadProtocol+ = lens _pgslUploadProtocol+ (\ s a -> s{_pgslUploadProtocol = a})++-- | OAuth access token.+pgslAccessToken :: Lens' ProjectsGroupStatsList (Maybe Text)+pgslAccessToken+ = lens _pgslAccessToken+ (\ s a -> s{_pgslAccessToken = a})++-- | Legacy upload protocol for media (e.g. \"media\", \"multipart\").+pgslUploadType :: Lens' ProjectsGroupStatsList (Maybe Text)+pgslUploadType+ = lens _pgslUploadType+ (\ s a -> s{_pgslUploadType = a})++-- | [Optional] The preferred duration for a single returned \`TimedCount\`.+-- If not set, no timed counts are returned.+pgslTimedCountDuration :: Lens' ProjectsGroupStatsList (Maybe Scientific)+pgslTimedCountDuration+ = lens _pgslTimedCountDuration+ (\ s a -> s{_pgslTimedCountDuration = a})+ . mapping _GDuration++-- | [Optional] The alignment of the timed counts to be returned. Default is+-- \`ALIGNMENT_EQUAL_AT_END\`.+pgslAlignment :: Lens' ProjectsGroupStatsList (Maybe Text)+pgslAlignment+ = lens _pgslAlignment+ (\ s a -> s{_pgslAlignment = a})++-- | [Required] The resource name of the Google Cloud Platform project.+-- Written as 'projects\/' plus the+-- <https://support.google.com/cloud/answer/6158840 Google Cloud Platform project ID>.+-- Example: 'projects\/my-project-123'.+pgslProjectName :: Lens' ProjectsGroupStatsList Text+pgslProjectName+ = lens _pgslProjectName+ (\ s a -> s{_pgslProjectName = a})++-- | [Optional] List all 'ErrorGroupStats' with these IDs.+pgslGroupId :: Lens' ProjectsGroupStatsList [Text]+pgslGroupId+ = lens _pgslGroupId (\ s a -> s{_pgslGroupId = a}) .+ _Default+ . _Coerce++-- | [Optional] Time where the timed counts shall be aligned if rounded+-- alignment is chosen. Default is 00:00 UTC.+pgslAlignmentTime :: Lens' ProjectsGroupStatsList (Maybe UTCTime)+pgslAlignmentTime+ = lens _pgslAlignmentTime+ (\ s a -> s{_pgslAlignmentTime = a})+ . mapping _DateTime++-- | [Optional] A \`next_page_token\` provided by a previous response. To+-- view additional results, pass this token along with the identical query+-- parameters as the first request.+pgslPageToken :: Lens' ProjectsGroupStatsList (Maybe Text)+pgslPageToken+ = lens _pgslPageToken+ (\ s a -> s{_pgslPageToken = a})++-- | [Optional] The maximum number of results to return per response. Default+-- is 20.+pgslPageSize :: Lens' ProjectsGroupStatsList (Maybe Int32)+pgslPageSize+ = lens _pgslPageSize (\ s a -> s{_pgslPageSize = a})+ . mapping _Coerce++-- | [Optional] The exact value to match against+-- [\`ServiceContext.service\`](\/error-reporting\/reference\/rest\/v1beta1\/ServiceContext#FIELDS.service).+pgslServiceFilterService :: Lens' ProjectsGroupStatsList (Maybe Text)+pgslServiceFilterService+ = lens _pgslServiceFilterService+ (\ s a -> s{_pgslServiceFilterService = a})++-- | [Optional] The sort order in which the results are returned. Default is+-- \`COUNT_DESC\`.+pgslOrder :: Lens' ProjectsGroupStatsList (Maybe Text)+pgslOrder+ = lens _pgslOrder (\ s a -> s{_pgslOrder = a})++-- | [Optional] The exact value to match against+-- [\`ServiceContext.resource_type\`](\/error-reporting\/reference\/rest\/v1beta1\/ServiceContext#FIELDS.resource_type).+pgslServiceFilterResourceType :: Lens' ProjectsGroupStatsList (Maybe Text)+pgslServiceFilterResourceType+ = lens _pgslServiceFilterResourceType+ (\ s a -> s{_pgslServiceFilterResourceType = a})++-- | JSONP+pgslCallback :: Lens' ProjectsGroupStatsList (Maybe Text)+pgslCallback+ = lens _pgslCallback (\ s a -> s{_pgslCallback = a})++-- | [Optional] The exact value to match against+-- [\`ServiceContext.version\`](\/error-reporting\/reference\/rest\/v1beta1\/ServiceContext#FIELDS.version).+pgslServiceFilterVersion :: Lens' ProjectsGroupStatsList (Maybe Text)+pgslServiceFilterVersion+ = lens _pgslServiceFilterVersion+ (\ s a -> s{_pgslServiceFilterVersion = a})++-- | Restricts the query to the specified time range.+pgslTimeRangePeriod :: Lens' ProjectsGroupStatsList (Maybe Text)+pgslTimeRangePeriod+ = lens _pgslTimeRangePeriod+ (\ s a -> s{_pgslTimeRangePeriod = a})++instance GoogleRequest ProjectsGroupStatsList where+ type Rs ProjectsGroupStatsList =+ ListGroupStatsResponse+ type Scopes ProjectsGroupStatsList =+ '["https://www.googleapis.com/auth/cloud-platform"]+ requestClient ProjectsGroupStatsList'{..}+ = go _pgslProjectName _pgslXgafv _pgslUploadProtocol+ _pgslAccessToken+ _pgslUploadType+ _pgslTimedCountDuration+ _pgslAlignment+ (_pgslGroupId ^. _Default)+ _pgslAlignmentTime+ _pgslPageToken+ _pgslPageSize+ _pgslServiceFilterService+ _pgslOrder+ _pgslServiceFilterResourceType+ _pgslCallback+ _pgslServiceFilterVersion+ _pgslTimeRangePeriod+ (Just AltJSON)+ cloudErrorReportingService+ where go+ = buildClient+ (Proxy :: Proxy ProjectsGroupStatsListResource)+ mempty
+ gen/Network/Google/Resource/CloudErrorReporting/Projects/Groups/Get.hs view
@@ -0,0 +1,149 @@+{-# 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.CloudErrorReporting.Projects.Groups.Get+-- 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)+--+-- Get the specified group.+--+-- /See:/ <https://cloud.google.com/error-reporting/ Stackdriver Error Reporting API Reference> for @clouderrorreporting.projects.groups.get@.+module Network.Google.Resource.CloudErrorReporting.Projects.Groups.Get+ (+ -- * REST Resource+ ProjectsGroupsGetResource++ -- * Creating a Request+ , projectsGroupsGet+ , ProjectsGroupsGet++ -- * Request Lenses+ , pggXgafv+ , pggUploadProtocol+ , pggAccessToken+ , pggUploadType+ , pggGroupName+ , pggCallback+ ) where++import Network.Google.CloudErrorReporting.Types+import Network.Google.Prelude++-- | A resource alias for @clouderrorreporting.projects.groups.get@ method which the+-- 'ProjectsGroupsGet' request conforms to.+type ProjectsGroupsGetResource =+ "v1beta1" :>+ Capture "groupName" Text :>+ QueryParam "$.xgafv" Xgafv :>+ QueryParam "upload_protocol" Text :>+ QueryParam "access_token" Text :>+ QueryParam "uploadType" Text :>+ QueryParam "callback" Text :>+ QueryParam "alt" AltJSON :> Get '[JSON] ErrorGroup++-- | Get the specified group.+--+-- /See:/ 'projectsGroupsGet' smart constructor.+data ProjectsGroupsGet = ProjectsGroupsGet'+ { _pggXgafv :: !(Maybe Xgafv)+ , _pggUploadProtocol :: !(Maybe Text)+ , _pggAccessToken :: !(Maybe Text)+ , _pggUploadType :: !(Maybe Text)+ , _pggGroupName :: !Text+ , _pggCallback :: !(Maybe Text)+ } deriving (Eq,Show,Data,Typeable,Generic)++-- | Creates a value of 'ProjectsGroupsGet' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'pggXgafv'+--+-- * 'pggUploadProtocol'+--+-- * 'pggAccessToken'+--+-- * 'pggUploadType'+--+-- * 'pggGroupName'+--+-- * 'pggCallback'+projectsGroupsGet+ :: Text -- ^ 'pggGroupName'+ -> ProjectsGroupsGet+projectsGroupsGet pPggGroupName_ =+ ProjectsGroupsGet'+ { _pggXgafv = Nothing+ , _pggUploadProtocol = Nothing+ , _pggAccessToken = Nothing+ , _pggUploadType = Nothing+ , _pggGroupName = pPggGroupName_+ , _pggCallback = Nothing+ }++-- | V1 error format.+pggXgafv :: Lens' ProjectsGroupsGet (Maybe Xgafv)+pggXgafv = lens _pggXgafv (\ s a -> s{_pggXgafv = a})++-- | Upload protocol for media (e.g. \"raw\", \"multipart\").+pggUploadProtocol :: Lens' ProjectsGroupsGet (Maybe Text)+pggUploadProtocol+ = lens _pggUploadProtocol+ (\ s a -> s{_pggUploadProtocol = a})++-- | OAuth access token.+pggAccessToken :: Lens' ProjectsGroupsGet (Maybe Text)+pggAccessToken+ = lens _pggAccessToken+ (\ s a -> s{_pggAccessToken = a})++-- | Legacy upload protocol for media (e.g. \"media\", \"multipart\").+pggUploadType :: Lens' ProjectsGroupsGet (Maybe Text)+pggUploadType+ = lens _pggUploadType+ (\ s a -> s{_pggUploadType = a})++-- | [Required] The group resource name. Written as+-- 'projects\/projectID\/groups\/group_name'. Call+-- </error-reporting/reference/rest/v1beta1/projects.groupStats/list groupStats.list>+-- to return a list of groups belonging to this project. Example:+-- 'projects\/my-project-123\/groups\/my-group'+pggGroupName :: Lens' ProjectsGroupsGet Text+pggGroupName+ = lens _pggGroupName (\ s a -> s{_pggGroupName = a})++-- | JSONP+pggCallback :: Lens' ProjectsGroupsGet (Maybe Text)+pggCallback+ = lens _pggCallback (\ s a -> s{_pggCallback = a})++instance GoogleRequest ProjectsGroupsGet where+ type Rs ProjectsGroupsGet = ErrorGroup+ type Scopes ProjectsGroupsGet =+ '["https://www.googleapis.com/auth/cloud-platform"]+ requestClient ProjectsGroupsGet'{..}+ = go _pggGroupName _pggXgafv _pggUploadProtocol+ _pggAccessToken+ _pggUploadType+ _pggCallback+ (Just AltJSON)+ cloudErrorReportingService+ where go+ = buildClient+ (Proxy :: Proxy ProjectsGroupsGetResource)+ mempty
+ gen/Network/Google/Resource/CloudErrorReporting/Projects/Groups/Update.hs view
@@ -0,0 +1,160 @@+{-# 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.CloudErrorReporting.Projects.Groups.Update+-- 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)+--+-- Replace the data for the specified group. Fails if the group does not+-- exist.+--+-- /See:/ <https://cloud.google.com/error-reporting/ Stackdriver Error Reporting API Reference> for @clouderrorreporting.projects.groups.update@.+module Network.Google.Resource.CloudErrorReporting.Projects.Groups.Update+ (+ -- * REST Resource+ ProjectsGroupsUpdateResource++ -- * Creating a Request+ , projectsGroupsUpdate+ , ProjectsGroupsUpdate++ -- * Request Lenses+ , pguXgafv+ , pguUploadProtocol+ , pguAccessToken+ , pguUploadType+ , pguPayload+ , pguName+ , pguCallback+ ) where++import Network.Google.CloudErrorReporting.Types+import Network.Google.Prelude++-- | A resource alias for @clouderrorreporting.projects.groups.update@ method which the+-- 'ProjectsGroupsUpdate' request conforms to.+type ProjectsGroupsUpdateResource =+ "v1beta1" :>+ Capture "name" Text :>+ QueryParam "$.xgafv" Xgafv :>+ QueryParam "upload_protocol" Text :>+ QueryParam "access_token" Text :>+ QueryParam "uploadType" Text :>+ QueryParam "callback" Text :>+ QueryParam "alt" AltJSON :>+ ReqBody '[JSON] ErrorGroup :> Put '[JSON] ErrorGroup++-- | Replace the data for the specified group. Fails if the group does not+-- exist.+--+-- /See:/ 'projectsGroupsUpdate' smart constructor.+data ProjectsGroupsUpdate = ProjectsGroupsUpdate'+ { _pguXgafv :: !(Maybe Xgafv)+ , _pguUploadProtocol :: !(Maybe Text)+ , _pguAccessToken :: !(Maybe Text)+ , _pguUploadType :: !(Maybe Text)+ , _pguPayload :: !ErrorGroup+ , _pguName :: !Text+ , _pguCallback :: !(Maybe Text)+ } deriving (Eq,Show,Data,Typeable,Generic)++-- | Creates a value of 'ProjectsGroupsUpdate' with the minimum fields required to make a request.+--+-- Use one of the following lenses to modify other fields as desired:+--+-- * 'pguXgafv'+--+-- * 'pguUploadProtocol'+--+-- * 'pguAccessToken'+--+-- * 'pguUploadType'+--+-- * 'pguPayload'+--+-- * 'pguName'+--+-- * 'pguCallback'+projectsGroupsUpdate+ :: ErrorGroup -- ^ 'pguPayload'+ -> Text -- ^ 'pguName'+ -> ProjectsGroupsUpdate+projectsGroupsUpdate pPguPayload_ pPguName_ =+ ProjectsGroupsUpdate'+ { _pguXgafv = Nothing+ , _pguUploadProtocol = Nothing+ , _pguAccessToken = Nothing+ , _pguUploadType = Nothing+ , _pguPayload = pPguPayload_+ , _pguName = pPguName_+ , _pguCallback = Nothing+ }++-- | V1 error format.+pguXgafv :: Lens' ProjectsGroupsUpdate (Maybe Xgafv)+pguXgafv = lens _pguXgafv (\ s a -> s{_pguXgafv = a})++-- | Upload protocol for media (e.g. \"raw\", \"multipart\").+pguUploadProtocol :: Lens' ProjectsGroupsUpdate (Maybe Text)+pguUploadProtocol+ = lens _pguUploadProtocol+ (\ s a -> s{_pguUploadProtocol = a})++-- | OAuth access token.+pguAccessToken :: Lens' ProjectsGroupsUpdate (Maybe Text)+pguAccessToken+ = lens _pguAccessToken+ (\ s a -> s{_pguAccessToken = a})++-- | Legacy upload protocol for media (e.g. \"media\", \"multipart\").+pguUploadType :: Lens' ProjectsGroupsUpdate (Maybe Text)+pguUploadType+ = lens _pguUploadType+ (\ s a -> s{_pguUploadType = a})++-- | Multipart request metadata.+pguPayload :: Lens' ProjectsGroupsUpdate ErrorGroup+pguPayload+ = lens _pguPayload (\ s a -> s{_pguPayload = a})++-- | The group resource name. Example:+-- 'projects\/my-project-123\/groups\/my-groupid'+pguName :: Lens' ProjectsGroupsUpdate Text+pguName = lens _pguName (\ s a -> s{_pguName = a})++-- | JSONP+pguCallback :: Lens' ProjectsGroupsUpdate (Maybe Text)+pguCallback+ = lens _pguCallback (\ s a -> s{_pguCallback = a})++instance GoogleRequest ProjectsGroupsUpdate where+ type Rs ProjectsGroupsUpdate = ErrorGroup+ type Scopes ProjectsGroupsUpdate =+ '["https://www.googleapis.com/auth/cloud-platform"]+ requestClient ProjectsGroupsUpdate'{..}+ = go _pguName _pguXgafv _pguUploadProtocol+ _pguAccessToken+ _pguUploadType+ _pguCallback+ (Just AltJSON)+ _pguPayload+ cloudErrorReportingService+ where go+ = buildClient+ (Proxy :: Proxy ProjectsGroupsUpdateResource)+ mempty
+ gogol-clouderrorreporting.cabal view
@@ -0,0 +1,53 @@+name: gogol-clouderrorreporting+version: 0.4.0+synopsis: Google Stackdriver Error 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:+ Groups and counts similar errors from cloud services and applications,+ reports new errors, and provides access to error groups and their+ associated errors.+ .+ /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 @v1beta1@+ 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.CloudErrorReporting+ , Network.Google.CloudErrorReporting.Types+ , Network.Google.Resource.CloudErrorReporting.Projects.DeleteEvents+ , Network.Google.Resource.CloudErrorReporting.Projects.Events.List+ , Network.Google.Resource.CloudErrorReporting.Projects.Events.Report+ , Network.Google.Resource.CloudErrorReporting.Projects.GroupStats.List+ , Network.Google.Resource.CloudErrorReporting.Projects.Groups.Get+ , Network.Google.Resource.CloudErrorReporting.Projects.Groups.Update++ other-modules:+ Network.Google.CloudErrorReporting.Types.Product+ , Network.Google.CloudErrorReporting.Types.Sum++ build-depends:+ gogol-core == 0.4.0.*+ , base >= 4.7 && < 5
+ src/.gitkeep view