on develop help sign in
Regenerating gogol-iam
commita2c2011fd0728537a3b622d2d387604c7f844bc9 authorBrendan Hay <brendan.g.hay@gmail.com> dateFri 28 Oct 2016, 08:23 (10 years ago) parenta641647
24 files changed+4617
gogol-iam/LICENSE+367 gogol-iam/Makefile+1 gogol-iam/README.md+28 gogol-iam/Setup.hs+2 gogol-iam/gen/Network/Google/IAM.hs+238 gogol-iam/gen/Network/Google/IAM/Types.hs+160 gogol-iam/gen/Network/Google/IAM/Types/Product.hs+1107 gogol-iam/gen/Network/Google/IAM/Types/Sum.hs+19 gogol-iam/gen/Network/Google/Resource/IAM/Projects/ServiceAccounts/Create.hs+188 gogol-iam/gen/Network/Google/Resource/IAM/Projects/ServiceAccounts/Delete.hs+175 gogol-iam/gen/Network/Google/Resource/IAM/Projects/ServiceAccounts/Get.hs+175 gogol-iam/gen/Network/Google/Resource/IAM/Projects/ServiceAccounts/GetIAMPolicy.hs+178 gogol-iam/gen/Network/Google/Resource/IAM/Projects/ServiceAccounts/Keys/Create.hs+193 gogol-iam/gen/Network/Google/Resource/IAM/Projects/ServiceAccounts/Keys/Delete.hs+177 gogol-iam/gen/Network/Google/Resource/IAM/Projects/ServiceAccounts/Keys/Get.hs+193 gogol-iam/gen/Network/Google/Resource/IAM/Projects/ServiceAccounts/Keys/List.hs+198 gogol-iam/gen/Network/Google/Resource/IAM/Projects/ServiceAccounts/List.hs+203 gogol-iam/gen/Network/Google/Resource/IAM/Projects/ServiceAccounts/SetIAMPolicy.hs+193 gogol-iam/gen/Network/Google/Resource/IAM/Projects/ServiceAccounts/SignBlob.hs+192 gogol-iam/gen/Network/Google/Resource/IAM/Projects/ServiceAccounts/TestIAMPermissions.hs+198 gogol-iam/gen/Network/Google/Resource/IAM/Projects/ServiceAccounts/Update.hs+194 gogol-iam/gen/Network/Google/Resource/IAM/Roles/QueryGrantableRoles.hs+177 gogol-iam/gogol-iam.cabal+61 gogol-iam/src/.gitkeep
gogol-iam/LICENSEnew file+367
@@ -0,0 +1,367 @@
1+Mozilla Public License Version 2.0
2+==================================
3+
4+1. Definitions
5+--------------
6+
7+1.1. "Contributor"
8+ means each individual or legal entity that creates, contributes to
9+ the creation of, or owns Covered Software.
10+
11+1.2. "Contributor Version"
12+ means the combination of the Contributions of others (if any) used
13+ by a Contributor and that particular Contributor's Contribution.
14+
15+1.3. "Contribution"
16+ means Covered Software of a particular Contributor.
17+
18+1.4. "Covered Software"
19+ means Source Code Form to which the initial Contributor has attached
20+ the notice in Exhibit A, the Executable Form of such Source Code
21+ Form, and Modifications of such Source Code Form, in each case
22+ including portions thereof.
23+
24+1.5. "Incompatible With Secondary Licenses"
25+ means
26+
27+ (a) that the initial Contributor has attached the notice described
28+ in Exhibit B to the Covered Software; or
29+
30+ (b) that the Covered Software was made available under the terms of
31+ version 1.1 or earlier of the License, but not also under the
32+ terms of a Secondary License.
33+
34+1.6. "Executable Form"
35+ means any form of the work other than Source Code Form.
36+
37+1.7. "Larger Work"
38+ means a work that combines Covered Software with other material, in
39+ a separate file or files, that is not Covered Software.
40+
41+1.8. "License"
42+ means this document.
43+
44+1.9. "Licensable"
45+ means having the right to grant, to the maximum extent possible,
46+ whether at the time of the initial grant or subsequently, any and
47+ all of the rights conveyed by this License.
48+
49+1.10. "Modifications"
50+ means any of the following:
51+
52+ (a) any file in Source Code Form that results from an addition to,
53+ deletion from, or modification of the contents of Covered
54+ Software; or
55+
56+ (b) any new file in Source Code Form that contains any Covered
57+ Software.
58+
59+1.11. "Patent Claims" of a Contributor
60+ means any patent claim(s), including without limitation, method,
61+ process, and apparatus claims, in any patent Licensable by such
62+ Contributor that would be infringed, but for the grant of the
63+ License, by the making, using, selling, offering for sale, having
64+ made, import, or transfer of either its Contributions or its
65+ Contributor Version.
66+
67+1.12. "Secondary License"
68+ means either the GNU General Public License, Version 2.0, the GNU
69+ Lesser General Public License, Version 2.1, the GNU Affero General
70+ Public License, Version 3.0, or any later versions of those
71+ licenses.
72+
73+1.13. "Source Code Form"
74+ means the form of the work preferred for making modifications.
75+
76+1.14. "You" (or "Your")
77+ means an individual or a legal entity exercising rights under this
78+ License. For legal entities, "You" includes any entity that
79+ controls, is controlled by, or is under common control with You. For
80+ purposes of this definition, "control" means (a) the power, direct
81+ or indirect, to cause the direction or management of such entity,
82+ whether by contract or otherwise, or (b) ownership of more than
83+ fifty percent (50%) of the outstanding shares or beneficial
84+ ownership of such entity.
85+
86+2. License Grants and Conditions
87+--------------------------------
88+
89+2.1. Grants
90+
91+Each Contributor hereby grants You a world-wide, royalty-free,
92+non-exclusive license:
93+
94+(a) under intellectual property rights (other than patent or trademark)
95+ Licensable by such Contributor to use, reproduce, make available,
96+ modify, display, perform, distribute, and otherwise exploit its
97+ Contributions, either on an unmodified basis, with Modifications, or
98+ as part of a Larger Work; and
99+
100+(b) under Patent Claims of such Contributor to make, use, sell, offer
101+ for sale, have made, import, and otherwise transfer either its
102+ Contributions or its Contributor Version.
103+
104+2.2. Effective Date
105+
106+The licenses granted in Section 2.1 with respect to any Contribution
107+become effective for each Contribution on the date the Contributor first
108+distributes such Contribution.
109+
110+2.3. Limitations on Grant Scope
111+
112+The licenses granted in this Section 2 are the only rights granted under
113+this License. No additional rights or licenses will be implied from the
114+distribution or licensing of Covered Software under this License.
115+Notwithstanding Section 2.1(b) above, no patent license is granted by a
116+Contributor:
117+
118+(a) for any code that a Contributor has removed from Covered Software;
119+ or
120+
121+(b) for infringements caused by: (i) Your and any other third party's
122+ modifications of Covered Software, or (ii) the combination of its
123+ Contributions with other software (except as part of its Contributor
124+ Version); or
125+
126+(c) under Patent Claims infringed by Covered Software in the absence of
127+ its Contributions.
128+
129+This License does not grant any rights in the trademarks, service marks,
130+or logos of any Contributor (except as may be necessary to comply with
131+the notice requirements in Section 3.4).
132+
133+2.4. Subsequent Licenses
134+
135+No Contributor makes additional grants as a result of Your choice to
136+distribute the Covered Software under a subsequent version of this
137+License (see Section 10.2) or under the terms of a Secondary License (if
138+permitted under the terms of Section 3.3).
139+
140+2.5. Representation
141+
142+Each Contributor represents that the Contributor believes its
143+Contributions are its original creation(s) or it has sufficient rights
144+to grant the rights to its Contributions conveyed by this License.
145+
146+2.6. Fair Use
147+
148+This License is not intended to limit any rights You have under
149+applicable copyright doctrines of fair use, fair dealing, or other
150+equivalents.
151+
152+2.7. Conditions
153+
154+Sections 3.1, 3.2, 3.3, and 3.4 are conditions of the licenses granted
155+in Section 2.1.
156+
157+3. Responsibilities
158+-------------------
159+
160+3.1. Distribution of Source Form
161+
162+All distribution of Covered Software in Source Code Form, including any
163+Modifications that You create or to which You contribute, must be under
164+the terms of this License. You must inform recipients that the Source
165+Code Form of the Covered Software is governed by the terms of this
166+License, and how they can obtain a copy of this License. You may not
167+attempt to alter or restrict the recipients' rights in the Source Code
168+Form.
169+
170+3.2. Distribution of Executable Form
171+
172+If You distribute Covered Software in Executable Form then:
173+
174+(a) such Covered Software must also be made available in Source Code
175+ Form, as described in Section 3.1, and You must inform recipients of
176+ the Executable Form how they can obtain a copy of such Source Code
177+ Form by reasonable means in a timely manner, at a charge no more
178+ than the cost of distribution to the recipient; and
179+
180+(b) You may distribute such Executable Form under the terms of this
181+ License, or sublicense it under different terms, provided that the
182+ license for the Executable Form does not attempt to limit or alter
183+ the recipients' rights in the Source Code Form under this License.
184+
185+3.3. Distribution of a Larger Work
186+
187+You may create and distribute a Larger Work under terms of Your choice,
188+provided that You also comply with the requirements of this License for
189+the Covered Software. If the Larger Work is a combination of Covered
190+Software with a work governed by one or more Secondary Licenses, and the
191+Covered Software is not Incompatible With Secondary Licenses, this
192+License permits You to additionally distribute such Covered Software
193+under the terms of such Secondary License(s), so that the recipient of
194+the Larger Work may, at their option, further distribute the Covered
195+Software under the terms of either this License or such Secondary
196+License(s).
197+
198+3.4. Notices
199+
200+You may not remove or alter the substance of any license notices
201+(including copyright notices, patent notices, disclaimers of warranty,
202+or limitations of liability) contained within the Source Code Form of
203+the Covered Software, except that You may alter any license notices to
204+the extent required to remedy known factual inaccuracies.
205+
206+3.5. Application of Additional Terms
207+
208+You may choose to offer, and to charge a fee for, warranty, support,
209+indemnity or liability obligations to one or more recipients of Covered
210+Software. However, You may do so only on Your own behalf, and not on
211+behalf of any Contributor. You must make it absolutely clear that any
212+such warranty, support, indemnity, or liability obligation is offered by
213+You alone, and You hereby agree to indemnify every Contributor for any
214+liability incurred by such Contributor as a result of warranty, support,
215+indemnity or liability terms You offer. You may include additional
216+disclaimers of warranty and limitations of liability specific to any
217+jurisdiction.
218+
219+4. Inability to Comply Due to Statute or Regulation
220+---------------------------------------------------
221+
222+If it is impossible for You to comply with any of the terms of this
223+License with respect to some or all of the Covered Software due to
224+statute, judicial order, or regulation then You must: (a) comply with
225+the terms of this License to the maximum extent possible; and (b)
226+describe the limitations and the code they affect. Such description must
227+be placed in a text file included with all distributions of the Covered
228+Software under this License. Except to the extent prohibited by statute
229+or regulation, such description must be sufficiently detailed for a
230+recipient of ordinary skill to be able to understand it.
231+
232+5. Termination
233+--------------
234+
235+5.1. The rights granted under this License will terminate automatically
236+if You fail to comply with any of its terms. However, if You become
237+compliant, then the rights granted under this License from a particular
238+Contributor are reinstated (a) provisionally, unless and until such
239+Contributor explicitly and finally terminates Your grants, and (b) on an
240+ongoing basis, if such Contributor fails to notify You of the
241+non-compliance by some reasonable means prior to 60 days after You have
242+come back into compliance. Moreover, Your grants from a particular
243+Contributor are reinstated on an ongoing basis if such Contributor
244+notifies You of the non-compliance by some reasonable means, this is the
245+first time You have received notice of non-compliance with this License
246+from such Contributor, and You become compliant prior to 30 days after
247+Your receipt of the notice.
248+
249+5.2. If You initiate litigation against any entity by asserting a patent
250+infringement claim (excluding declaratory judgment actions,
251+counter-claims, and cross-claims) alleging that a Contributor Version
252+directly or indirectly infringes any patent, then the rights granted to
253+You by any and all Contributors for the Covered Software under Section
254+2.1 of this License shall terminate.
255+
256+5.3. In the event of termination under Sections 5.1 or 5.2 above, all
257+end user license agreements (excluding distributors and resellers) which
258+have been validly granted by You or Your distributors under this License
259+prior to termination shall survive termination.
260+
261+************************************************************************
262+* *
263+* 6. Disclaimer of Warranty *
264+* ------------------------- *
265+* *
266+* Covered Software is provided under this License on an "as is" *
267+* basis, without warranty of any kind, either expressed, implied, or *
268+* statutory, including, without limitation, warranties that the *
269+* Covered Software is free of defects, merchantable, fit for a *
270+* particular purpose or non-infringing. The entire risk as to the *
271+* quality and performance of the Covered Software is with You. *
272+* Should any Covered Software prove defective in any respect, You *
273+* (not any Contributor) assume the cost of any necessary servicing, *
274+* repair, or correction. This disclaimer of warranty constitutes an *
275+* essential part of this License. No use of any Covered Software is *
276+* authorized under this License except under this disclaimer. *
277+* *
278+************************************************************************
279+
280+************************************************************************
281+* *
282+* 7. Limitation of Liability *
283+* -------------------------- *
284+* *
285+* Under no circumstances and under no legal theory, whether tort *
286+* (including negligence), contract, or otherwise, shall any *
287+* Contributor, or anyone who distributes Covered Software as *
288+* permitted above, be liable to You for any direct, indirect, *
289+* special, incidental, or consequential damages of any character *
290+* including, without limitation, damages for lost profits, loss of *
291+* goodwill, work stoppage, computer failure or malfunction, or any *
292+* and all other commercial damages or losses, even if such party *
293+* shall have been informed of the possibility of such damages. This *
294+* limitation of liability shall not apply to liability for death or *
295+* personal injury resulting from such party's negligence to the *
296+* extent applicable law prohibits such limitation. Some *
297+* jurisdictions do not allow the exclusion or limitation of *
298+* incidental or consequential damages, so this exclusion and *
299+* limitation may not apply to You. *
300+* *
301+************************************************************************
302+
303+8. Litigation
304+-------------
305+
306+Any litigation relating to this License may be brought only in the
307+courts of a jurisdiction where the defendant maintains its principal
308+place of business and such litigation shall be governed by laws of that
309+jurisdiction, without reference to its conflict-of-law provisions.
310+Nothing in this Section shall prevent a party's ability to bring
311+cross-claims or counter-claims.
312+
313+9. Miscellaneous
314+----------------
315+
316+This License represents the complete agreement concerning the subject
317+matter hereof. If any provision of this License is held to be
318+unenforceable, such provision shall be reformed only to the extent
319+necessary to make it enforceable. Any law or regulation which provides
320+that the language of a contract shall be construed against the drafter
321+shall not be used to construe this License against a Contributor.
322+
323+10. Versions of the License
324+---------------------------
325+
326+10.1. New Versions
327+
328+Mozilla Foundation is the license steward. Except as provided in Section
329+10.3, no one other than the license steward has the right to modify or
330+publish new versions of this License. Each version will be given a
331+distinguishing version number.
332+
333+10.2. Effect of New Versions
334+
335+You may distribute the Covered Software under the terms of the version
336+of the License under which You originally received the Covered Software,
337+or under the terms of any subsequent version published by the license
338+steward.
339+
340+10.3. Modified Versions
341+
342+If you create software not governed by this License, and you want to
343+create a new license for such software, you may create and use a
344+modified version of this License if you rename the license and remove
345+any references to the name of the license steward (except to note that
346+such modified license differs from this License).
347+
348+10.4. Distributing Source Code Form that is Incompatible With Secondary
349+Licenses
350+
351+If You choose to distribute Source Code Form that is Incompatible With
352+Secondary Licenses under the terms of this version of the License, the
353+notice described in Exhibit B of this License must be attached.
354+
355+Exhibit A - Source Code Form License Notice
356+-------------------------------------------
357+
358+ This Source Code Form is subject to the terms of the Mozilla Public
359+ License, v. 2.0. If a copy of the MPL was not distributed with this
360+ file, You can obtain one at http://mozilla.org/MPL/2.0/.
361+
362+If it is not possible or desirable to put the notice in a particular
363+file, then You may include the notice in a location (such as a LICENSE
364+file in a relevant directory) where a recipient would be likely to look
365+for such a notice.
366+
367+You may add additional accurate notices of copyright ownership.
gogol-iam/Makefilenew file+1
@@ -0,0 +1 @@
1+include ../share/library.mk
gogol-iam/README.mdnew file+28
@@ -0,0 +1,28 @@
1+# gogol-iam
2+
3+* [Version](#version)
4+* [Description](#description)
5+* [Contribute](#contribute)
6+* [Licence](#licence)
7+
8+
9+## Version
10+
11+`0.1.0`
12+
13+
14+## Description
15+
16+A client library for the Google Identity and Access Management (IAM).
17+
18+
19+## Contribute
20+
21+For any problems, comments, or feedback please create an issue [here on GitHub](https://github.com/brendanhay/gogol/issues).
22+
23+> _Note:_ this library is an auto-generated Haskell package. Please see `gogol-gen` for more information.
24+
25+
26+## Licence
27+
28+`gogol-iam` is released under the [Mozilla Public License Version 2.0](http://www.mozilla.org/MPL/).
gogol-iam/Setup.hsnew file+2
@@ -0,0 +1,2 @@
1+import Distribution.Simple
2+main = defaultMain
gogol-iam/gen/Network/Google/IAM.hsnew file+238
@@ -0,0 +1,238 @@
1+{-# LANGUAGE DataKinds #-}
2+{-# LANGUAGE NoImplicitPrelude #-}
3+{-# LANGUAGE TypeOperators #-}
4+
5+{-# OPTIONS_GHC -fno-warn-unused-imports #-}
6+{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
7+
8+-- |
9+-- Module : Network.Google.IAM
10+-- Copyright : (c) 2015-2016 Brendan Hay
11+-- License : Mozilla Public License, v. 2.0.
12+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>
13+-- Stability : auto-generated
14+-- Portability : non-portable (GHC extensions)
15+--
16+-- Manages identity and access control for Google Cloud Platform resources,
17+-- including the creation of service accounts, which you can use to
18+-- authenticate to Google and make API calls.
19+--
20+-- /See:/ <https://cloud.google.com/iam/ Google Identity and Access Management (IAM) API Reference>
21+module Network.Google.IAM
22+ (
23+ -- * Service Configuration
24+ iAMService
25+
26+ -- * OAuth Scopes
27+ , cloudPlatformScope
28+
29+ -- * API Declaration
30+ , IAMAPI
31+
32+ -- * Resources
33+
34+ -- ** iam.projects.serviceAccounts.create
35+ , module Network.Google.Resource.IAM.Projects.ServiceAccounts.Create
36+
37+ -- ** iam.projects.serviceAccounts.delete
38+ , module Network.Google.Resource.IAM.Projects.ServiceAccounts.Delete
39+
40+ -- ** iam.projects.serviceAccounts.get
41+ , module Network.Google.Resource.IAM.Projects.ServiceAccounts.Get
42+
43+ -- ** iam.projects.serviceAccounts.getIamPolicy
44+ , module Network.Google.Resource.IAM.Projects.ServiceAccounts.GetIAMPolicy
45+
46+ -- ** iam.projects.serviceAccounts.keys.create
47+ , module Network.Google.Resource.IAM.Projects.ServiceAccounts.Keys.Create
48+
49+ -- ** iam.projects.serviceAccounts.keys.delete
50+ , module Network.Google.Resource.IAM.Projects.ServiceAccounts.Keys.Delete
51+
52+ -- ** iam.projects.serviceAccounts.keys.get
53+ , module Network.Google.Resource.IAM.Projects.ServiceAccounts.Keys.Get
54+
55+ -- ** iam.projects.serviceAccounts.keys.list
56+ , module Network.Google.Resource.IAM.Projects.ServiceAccounts.Keys.List
57+
58+ -- ** iam.projects.serviceAccounts.list
59+ , module Network.Google.Resource.IAM.Projects.ServiceAccounts.List
60+
61+ -- ** iam.projects.serviceAccounts.setIamPolicy
62+ , module Network.Google.Resource.IAM.Projects.ServiceAccounts.SetIAMPolicy
63+
64+ -- ** iam.projects.serviceAccounts.signBlob
65+ , module Network.Google.Resource.IAM.Projects.ServiceAccounts.SignBlob
66+
67+ -- ** iam.projects.serviceAccounts.testIamPermissions
68+ , module Network.Google.Resource.IAM.Projects.ServiceAccounts.TestIAMPermissions
69+
70+ -- ** iam.projects.serviceAccounts.update
71+ , module Network.Google.Resource.IAM.Projects.ServiceAccounts.Update
72+
73+ -- ** iam.roles.queryGrantableRoles
74+ , module Network.Google.Resource.IAM.Roles.QueryGrantableRoles
75+
76+ -- * Types
77+
78+ -- ** Empty
79+ , Empty
80+ , empty
81+
82+ -- ** AuditData
83+ , AuditData
84+ , auditData
85+ , adPolicyDelta
86+
87+ -- ** ServiceAccountKey
88+ , ServiceAccountKey
89+ , serviceAccountKey
90+ , sakValidAfterTime
91+ , sakPrivateKeyData
92+ , sakPublicKeyData
93+ , sakName
94+ , sakPrivateKeyType
95+ , sakValidBeforeTime
96+ , sakKeyAlgorithm
97+
98+ -- ** CreateServiceAccountKeyRequest
99+ , CreateServiceAccountKeyRequest
100+ , createServiceAccountKeyRequest
101+ , csakrPrivateKeyType
102+ , csakrKeyAlgorithm
103+
104+ -- ** SetIAMPolicyRequest
105+ , SetIAMPolicyRequest
106+ , setIAMPolicyRequest
107+ , siprPolicy
108+
109+ -- ** BindingDelta
110+ , BindingDelta
111+ , bindingDelta
112+ , bdAction
113+ , bdRole
114+ , bdMember
115+
116+ -- ** SignBlobRequest
117+ , SignBlobRequest
118+ , signBlobRequest
119+ , sbrBytesToSign
120+
121+ -- ** ListServiceAccountKeysResponse
122+ , ListServiceAccountKeysResponse
123+ , listServiceAccountKeysResponse
124+ , lsakrKeys
125+
126+ -- ** Role
127+ , Role
128+ , role'
129+ , rName
130+ , rTitle
131+ , rDescription
132+
133+ -- ** ServiceAccount
134+ , ServiceAccount
135+ , serviceAccount
136+ , saEmail
137+ , saEtag
138+ , saUniqueId
139+ , saName
140+ , saDisplayName
141+ , saProjectId
142+ , saOAuth2ClientId
143+
144+ -- ** QueryGrantableRolesResponse
145+ , QueryGrantableRolesResponse
146+ , queryGrantableRolesResponse
147+ , qgrrRoles
148+
149+ -- ** TestIAMPermissionsRequest
150+ , TestIAMPermissionsRequest
151+ , testIAMPermissionsRequest
152+ , tiprPermissions
153+
154+ -- ** TestIAMPermissionsResponse
155+ , TestIAMPermissionsResponse
156+ , testIAMPermissionsResponse
157+ , tiamprPermissions
158+
159+ -- ** Policy
160+ , Policy
161+ , policy
162+ , pEtag
163+ , pVersion
164+ , pBindings
165+
166+ -- ** PolicyDelta
167+ , PolicyDelta
168+ , policyDelta
169+ , pdBindingDeltas
170+
171+ -- ** QueryGrantableRolesRequest
172+ , QueryGrantableRolesRequest
173+ , queryGrantableRolesRequest
174+ , qgrrFullResourceName
175+
176+ -- ** SignBlobResponse
177+ , SignBlobResponse
178+ , signBlobResponse
179+ , sbrSignature
180+ , sbrKeyId
181+
182+ -- ** ListServiceAccountsResponse
183+ , ListServiceAccountsResponse
184+ , listServiceAccountsResponse
185+ , lsarNextPageToken
186+ , lsarAccounts
187+
188+ -- ** CreateServiceAccountRequest
189+ , CreateServiceAccountRequest
190+ , createServiceAccountRequest
191+ , csarServiceAccount
192+ , csarAccountId
193+
194+ -- ** Binding
195+ , Binding
196+ , binding
197+ , bMembers
198+ , bRole
199+ ) where
200+
201+import Network.Google.IAM.Types
202+import Network.Google.Prelude
203+import Network.Google.Resource.IAM.Projects.ServiceAccounts.Create
204+import Network.Google.Resource.IAM.Projects.ServiceAccounts.Delete
205+import Network.Google.Resource.IAM.Projects.ServiceAccounts.Get
206+import Network.Google.Resource.IAM.Projects.ServiceAccounts.GetIAMPolicy
207+import Network.Google.Resource.IAM.Projects.ServiceAccounts.Keys.Create
208+import Network.Google.Resource.IAM.Projects.ServiceAccounts.Keys.Delete
209+import Network.Google.Resource.IAM.Projects.ServiceAccounts.Keys.Get
210+import Network.Google.Resource.IAM.Projects.ServiceAccounts.Keys.List
211+import Network.Google.Resource.IAM.Projects.ServiceAccounts.List
212+import Network.Google.Resource.IAM.Projects.ServiceAccounts.SetIAMPolicy
213+import Network.Google.Resource.IAM.Projects.ServiceAccounts.SignBlob
214+import Network.Google.Resource.IAM.Projects.ServiceAccounts.TestIAMPermissions
215+import Network.Google.Resource.IAM.Projects.ServiceAccounts.Update
216+import Network.Google.Resource.IAM.Roles.QueryGrantableRoles
217+
218+{- $resources
219+TODO
220+-}
221+
222+-- | Represents the entirety of the methods and resources available for the Google Identity and Access Management (IAM) API service.
223+type IAMAPI =
224+ RolesQueryGrantableRolesResource :<|>
225+ ProjectsServiceAccountsKeysListResource
226+ :<|> ProjectsServiceAccountsKeysGetResource
227+ :<|> ProjectsServiceAccountsKeysCreateResource
228+ :<|> ProjectsServiceAccountsKeysDeleteResource
229+ :<|> ProjectsServiceAccountsListResource
230+ :<|> ProjectsServiceAccountsGetIAMPolicyResource
231+ :<|> ProjectsServiceAccountsGetResource
232+ :<|> ProjectsServiceAccountsCreateResource
233+ :<|> ProjectsServiceAccountsSetIAMPolicyResource
234+ :<|> ProjectsServiceAccountsSignBlobResource
235+ :<|>
236+ ProjectsServiceAccountsTestIAMPermissionsResource
237+ :<|> ProjectsServiceAccountsDeleteResource
238+ :<|> ProjectsServiceAccountsUpdateResource
gogol-iam/gen/Network/Google/IAM/Types.hsnew file+160
@@ -0,0 +1,160 @@
1+{-# LANGUAGE DataKinds #-}
2+{-# LANGUAGE DeriveDataTypeable #-}
3+{-# LANGUAGE DeriveGeneric #-}
4+{-# LANGUAGE NoImplicitPrelude #-}
5+{-# LANGUAGE OverloadedStrings #-}
6+
7+{-# OPTIONS_GHC -fno-warn-unused-imports #-}
8+
9+-- |
10+-- Module : Network.Google.IAM.Types
11+-- Copyright : (c) 2015-2016 Brendan Hay
12+-- License : Mozilla Public License, v. 2.0.
13+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>
14+-- Stability : auto-generated
15+-- Portability : non-portable (GHC extensions)
16+--
17+module Network.Google.IAM.Types
18+ (
19+ -- * Service Configuration
20+ iAMService
21+
22+ -- * OAuth Scopes
23+ , cloudPlatformScope
24+
25+ -- * Empty
26+ , Empty
27+ , empty
28+
29+ -- * AuditData
30+ , AuditData
31+ , auditData
32+ , adPolicyDelta
33+
34+ -- * ServiceAccountKey
35+ , ServiceAccountKey
36+ , serviceAccountKey
37+ , sakValidAfterTime
38+ , sakPrivateKeyData
39+ , sakPublicKeyData
40+ , sakName
41+ , sakPrivateKeyType
42+ , sakValidBeforeTime
43+ , sakKeyAlgorithm
44+
45+ -- * CreateServiceAccountKeyRequest
46+ , CreateServiceAccountKeyRequest
47+ , createServiceAccountKeyRequest
48+ , csakrPrivateKeyType
49+ , csakrKeyAlgorithm
50+
51+ -- * SetIAMPolicyRequest
52+ , SetIAMPolicyRequest
53+ , setIAMPolicyRequest
54+ , siprPolicy
55+
56+ -- * BindingDelta
57+ , BindingDelta
58+ , bindingDelta
59+ , bdAction
60+ , bdRole
61+ , bdMember
62+
63+ -- * SignBlobRequest
64+ , SignBlobRequest
65+ , signBlobRequest
66+ , sbrBytesToSign
67+
68+ -- * ListServiceAccountKeysResponse
69+ , ListServiceAccountKeysResponse
70+ , listServiceAccountKeysResponse
71+ , lsakrKeys
72+
73+ -- * Role
74+ , Role
75+ , role'
76+ , rName
77+ , rTitle
78+ , rDescription
79+
80+ -- * ServiceAccount
81+ , ServiceAccount
82+ , serviceAccount
83+ , saEmail
84+ , saEtag
85+ , saUniqueId
86+ , saName
87+ , saDisplayName
88+ , saProjectId
89+ , saOAuth2ClientId
90+
91+ -- * QueryGrantableRolesResponse
92+ , QueryGrantableRolesResponse
93+ , queryGrantableRolesResponse
94+ , qgrrRoles
95+
96+ -- * TestIAMPermissionsRequest
97+ , TestIAMPermissionsRequest
98+ , testIAMPermissionsRequest
99+ , tiprPermissions
100+
101+ -- * TestIAMPermissionsResponse
102+ , TestIAMPermissionsResponse
103+ , testIAMPermissionsResponse
104+ , tiamprPermissions
105+
106+ -- * Policy
107+ , Policy
108+ , policy
109+ , pEtag
110+ , pVersion
111+ , pBindings
112+
113+ -- * PolicyDelta
114+ , PolicyDelta
115+ , policyDelta
116+ , pdBindingDeltas
117+
118+ -- * QueryGrantableRolesRequest
119+ , QueryGrantableRolesRequest
120+ , queryGrantableRolesRequest
121+ , qgrrFullResourceName
122+
123+ -- * SignBlobResponse
124+ , SignBlobResponse
125+ , signBlobResponse
126+ , sbrSignature
127+ , sbrKeyId
128+
129+ -- * ListServiceAccountsResponse
130+ , ListServiceAccountsResponse
131+ , listServiceAccountsResponse
132+ , lsarNextPageToken
133+ , lsarAccounts
134+
135+ -- * CreateServiceAccountRequest
136+ , CreateServiceAccountRequest
137+ , createServiceAccountRequest
138+ , csarServiceAccount
139+ , csarAccountId
140+
141+ -- * Binding
142+ , Binding
143+ , binding
144+ , bMembers
145+ , bRole
146+ ) where
147+
148+import Network.Google.IAM.Types.Product
149+import Network.Google.IAM.Types.Sum
150+import Network.Google.Prelude
151+
152+-- | Default request referring to version 'v1' of the Google Identity and Access Management (IAM) API. This contains the host and root path used as a starting point for constructing service requests.
153+iAMService :: ServiceConfig
154+iAMService
155+ = defaultService (ServiceId "iam:v1")
156+ "iam.googleapis.com"
157+
158+-- | View and manage your data across Google Cloud Platform services
159+cloudPlatformScope :: Proxy '["https://www.googleapis.com/auth/cloud-platform"]
160+cloudPlatformScope = Proxy;
gogol-iam/gen/Network/Google/IAM/Types/Product.hsnew file+1107
@@ -0,0 +1,1107 @@
1+{-# LANGUAGE DeriveDataTypeable #-}
2+{-# LANGUAGE DeriveGeneric #-}
3+{-# LANGUAGE NoImplicitPrelude #-}
4+{-# LANGUAGE OverloadedStrings #-}
5+{-# LANGUAGE RecordWildCards #-}
6+
7+{-# OPTIONS_GHC -fno-warn-unused-binds #-}
8+{-# OPTIONS_GHC -fno-warn-unused-imports #-}
9+
10+-- |
11+-- Module : Network.Google.IAM.Types.Product
12+-- Copyright : (c) 2015-2016 Brendan Hay
13+-- License : Mozilla Public License, v. 2.0.
14+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>
15+-- Stability : auto-generated
16+-- Portability : non-portable (GHC extensions)
17+--
18+module Network.Google.IAM.Types.Product where
19+
20+import Network.Google.IAM.Types.Sum
21+import Network.Google.Prelude
22+
23+-- | A generic empty message that you can re-use to avoid defining duplicated
24+-- empty messages in your APIs. A typical example is to use it as the
25+-- request or the response type of an API method. For instance: service Foo
26+-- { rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); } The
27+-- JSON representation for \`Empty\` is empty JSON object \`{}\`.
28+--
29+-- /See:/ 'empty' smart constructor.
30+data Empty =
31+ Empty'
32+ deriving (Eq,Show,Data,Typeable,Generic)
33+
34+-- | Creates a value of 'Empty' with the minimum fields required to make a request.
35+--
36+empty
37+ :: Empty
38+empty = Empty'
39+
40+instance FromJSON Empty where
41+ parseJSON = withObject "Empty" (\ o -> pure Empty')
42+
43+instance ToJSON Empty where
44+ toJSON = const emptyObject
45+
46+-- | Audit log information specific to Cloud IAM. This message is serialized
47+-- as an \`Any\` type in the \`ServiceData\` message of an \`AuditLog\`
48+-- message.
49+--
50+-- /See:/ 'auditData' smart constructor.
51+newtype AuditData = AuditData'
52+ { _adPolicyDelta :: Maybe PolicyDelta
53+ } deriving (Eq,Show,Data,Typeable,Generic)
54+
55+-- | Creates a value of 'AuditData' with the minimum fields required to make a request.
56+--
57+-- Use one of the following lenses to modify other fields as desired:
58+--
59+-- * 'adPolicyDelta'
60+auditData
61+ :: AuditData
62+auditData =
63+ AuditData'
64+ { _adPolicyDelta = Nothing
65+ }
66+
67+-- | Policy delta between the original policy and the newly set policy.
68+adPolicyDelta :: Lens' AuditData (Maybe PolicyDelta)
69+adPolicyDelta
70+ = lens _adPolicyDelta
71+ (\ s a -> s{_adPolicyDelta = a})
72+
73+instance FromJSON AuditData where
74+ parseJSON
75+ = withObject "AuditData"
76+ (\ o -> AuditData' <$> (o .:? "policyDelta"))
77+
78+instance ToJSON AuditData where
79+ toJSON AuditData'{..}
80+ = object
81+ (catMaybes [("policyDelta" .=) <$> _adPolicyDelta])
82+
83+-- | Represents a service account key. A service account has two sets of
84+-- key-pairs: user-managed, and system-managed. User-managed key-pairs can
85+-- be created and deleted by users. Users are responsible for rotating
86+-- these keys periodically to ensure security of their service accounts.
87+-- Users retain the private key of these key-pairs, and Google retains ONLY
88+-- the public key. System-managed key-pairs are managed automatically by
89+-- Google, and rotated daily without user intervention. The private key
90+-- never leaves Google\'s servers to maximize security. Public keys for all
91+-- service accounts are also published at the OAuth2 Service Account API.
92+--
93+-- /See:/ 'serviceAccountKey' smart constructor.
94+data ServiceAccountKey = ServiceAccountKey'
95+ { _sakValidAfterTime :: !(Maybe Text)
96+ , _sakPrivateKeyData :: !(Maybe Base64)
97+ , _sakPublicKeyData :: !(Maybe Base64)
98+ , _sakName :: !(Maybe Text)
99+ , _sakPrivateKeyType :: !(Maybe Text)
100+ , _sakValidBeforeTime :: !(Maybe Text)
101+ , _sakKeyAlgorithm :: !(Maybe Text)
102+ } deriving (Eq,Show,Data,Typeable,Generic)
103+
104+-- | Creates a value of 'ServiceAccountKey' with the minimum fields required to make a request.
105+--
106+-- Use one of the following lenses to modify other fields as desired:
107+--
108+-- * 'sakValidAfterTime'
109+--
110+-- * 'sakPrivateKeyData'
111+--
112+-- * 'sakPublicKeyData'
113+--
114+-- * 'sakName'
115+--
116+-- * 'sakPrivateKeyType'
117+--
118+-- * 'sakValidBeforeTime'
119+--
120+-- * 'sakKeyAlgorithm'
121+serviceAccountKey
122+ :: ServiceAccountKey
123+serviceAccountKey =
124+ ServiceAccountKey'
125+ { _sakValidAfterTime = Nothing
126+ , _sakPrivateKeyData = Nothing
127+ , _sakPublicKeyData = Nothing
128+ , _sakName = Nothing
129+ , _sakPrivateKeyType = Nothing
130+ , _sakValidBeforeTime = Nothing
131+ , _sakKeyAlgorithm = Nothing
132+ }
133+
134+-- | The key can be used after this timestamp.
135+sakValidAfterTime :: Lens' ServiceAccountKey (Maybe Text)
136+sakValidAfterTime
137+ = lens _sakValidAfterTime
138+ (\ s a -> s{_sakValidAfterTime = a})
139+
140+-- | The private key data. Only provided in \`CreateServiceAccountKey\`
141+-- responses.
142+sakPrivateKeyData :: Lens' ServiceAccountKey (Maybe ByteString)
143+sakPrivateKeyData
144+ = lens _sakPrivateKeyData
145+ (\ s a -> s{_sakPrivateKeyData = a})
146+ . mapping _Base64
147+
148+-- | The public key data. Only provided in \`GetServiceAccountKey\`
149+-- responses.
150+sakPublicKeyData :: Lens' ServiceAccountKey (Maybe ByteString)
151+sakPublicKeyData
152+ = lens _sakPublicKeyData
153+ (\ s a -> s{_sakPublicKeyData = a})
154+ . mapping _Base64
155+
156+-- | The resource name of the service account key in the following format
157+-- \`projects\/{project}\/serviceAccounts\/{account}\/keys\/{key}\`.
158+sakName :: Lens' ServiceAccountKey (Maybe Text)
159+sakName = lens _sakName (\ s a -> s{_sakName = a})
160+
161+-- | The output format for the private key. Only provided in
162+-- \`CreateServiceAccountKey\` responses, not in \`GetServiceAccountKey\`
163+-- or \`ListServiceAccountKey\` responses. Google never exposes
164+-- system-managed private keys, and never retains user-managed private
165+-- keys.
166+sakPrivateKeyType :: Lens' ServiceAccountKey (Maybe Text)
167+sakPrivateKeyType
168+ = lens _sakPrivateKeyType
169+ (\ s a -> s{_sakPrivateKeyType = a})
170+
171+-- | The key can be used before this timestamp.
172+sakValidBeforeTime :: Lens' ServiceAccountKey (Maybe Text)
173+sakValidBeforeTime
174+ = lens _sakValidBeforeTime
175+ (\ s a -> s{_sakValidBeforeTime = a})
176+
177+-- | Specifies the algorithm (and possibly key size) for the key.
178+sakKeyAlgorithm :: Lens' ServiceAccountKey (Maybe Text)
179+sakKeyAlgorithm
180+ = lens _sakKeyAlgorithm
181+ (\ s a -> s{_sakKeyAlgorithm = a})
182+
183+instance FromJSON ServiceAccountKey where
184+ parseJSON
185+ = withObject "ServiceAccountKey"
186+ (\ o ->
187+ ServiceAccountKey' <$>
188+ (o .:? "validAfterTime") <*> (o .:? "privateKeyData")
189+ <*> (o .:? "publicKeyData")
190+ <*> (o .:? "name")
191+ <*> (o .:? "privateKeyType")
192+ <*> (o .:? "validBeforeTime")
193+ <*> (o .:? "keyAlgorithm"))
194+
195+instance ToJSON ServiceAccountKey where
196+ toJSON ServiceAccountKey'{..}
197+ = object
198+ (catMaybes
199+ [("validAfterTime" .=) <$> _sakValidAfterTime,
200+ ("privateKeyData" .=) <$> _sakPrivateKeyData,
201+ ("publicKeyData" .=) <$> _sakPublicKeyData,
202+ ("name" .=) <$> _sakName,
203+ ("privateKeyType" .=) <$> _sakPrivateKeyType,
204+ ("validBeforeTime" .=) <$> _sakValidBeforeTime,
205+ ("keyAlgorithm" .=) <$> _sakKeyAlgorithm])
206+
207+-- | The service account key create request.
208+--
209+-- /See:/ 'createServiceAccountKeyRequest' smart constructor.
210+data CreateServiceAccountKeyRequest = CreateServiceAccountKeyRequest'
211+ { _csakrPrivateKeyType :: !(Maybe Text)
212+ , _csakrKeyAlgorithm :: !(Maybe Text)
213+ } deriving (Eq,Show,Data,Typeable,Generic)
214+
215+-- | Creates a value of 'CreateServiceAccountKeyRequest' with the minimum fields required to make a request.
216+--
217+-- Use one of the following lenses to modify other fields as desired:
218+--
219+-- * 'csakrPrivateKeyType'
220+--
221+-- * 'csakrKeyAlgorithm'
222+createServiceAccountKeyRequest
223+ :: CreateServiceAccountKeyRequest
224+createServiceAccountKeyRequest =
225+ CreateServiceAccountKeyRequest'
226+ { _csakrPrivateKeyType = Nothing
227+ , _csakrKeyAlgorithm = Nothing
228+ }
229+
230+-- | The output format of the private key. \`GOOGLE_CREDENTIALS_FILE\` is the
231+-- default output format.
232+csakrPrivateKeyType :: Lens' CreateServiceAccountKeyRequest (Maybe Text)
233+csakrPrivateKeyType
234+ = lens _csakrPrivateKeyType
235+ (\ s a -> s{_csakrPrivateKeyType = a})
236+
237+-- | Which type of key and algorithm to use for the key. The default is
238+-- currently a 4K RSA key. However this may change in the future.
239+csakrKeyAlgorithm :: Lens' CreateServiceAccountKeyRequest (Maybe Text)
240+csakrKeyAlgorithm
241+ = lens _csakrKeyAlgorithm
242+ (\ s a -> s{_csakrKeyAlgorithm = a})
243+
244+instance FromJSON CreateServiceAccountKeyRequest
245+ where
246+ parseJSON
247+ = withObject "CreateServiceAccountKeyRequest"
248+ (\ o ->
249+ CreateServiceAccountKeyRequest' <$>
250+ (o .:? "privateKeyType") <*> (o .:? "keyAlgorithm"))
251+
252+instance ToJSON CreateServiceAccountKeyRequest where
253+ toJSON CreateServiceAccountKeyRequest'{..}
254+ = object
255+ (catMaybes
256+ [("privateKeyType" .=) <$> _csakrPrivateKeyType,
257+ ("keyAlgorithm" .=) <$> _csakrKeyAlgorithm])
258+
259+-- | Request message for \`SetIamPolicy\` method.
260+--
261+-- /See:/ 'setIAMPolicyRequest' smart constructor.
262+newtype SetIAMPolicyRequest = SetIAMPolicyRequest'
263+ { _siprPolicy :: Maybe Policy
264+ } deriving (Eq,Show,Data,Typeable,Generic)
265+
266+-- | Creates a value of 'SetIAMPolicyRequest' with the minimum fields required to make a request.
267+--
268+-- Use one of the following lenses to modify other fields as desired:
269+--
270+-- * 'siprPolicy'
271+setIAMPolicyRequest
272+ :: SetIAMPolicyRequest
273+setIAMPolicyRequest =
274+ SetIAMPolicyRequest'
275+ { _siprPolicy = Nothing
276+ }
277+
278+-- | REQUIRED: The complete policy to be applied to the \`resource\`. The
279+-- size of the policy is limited to a few 10s of KB. An empty policy is a
280+-- valid policy but certain Cloud Platform services (such as Projects)
281+-- might reject them.
282+siprPolicy :: Lens' SetIAMPolicyRequest (Maybe Policy)
283+siprPolicy
284+ = lens _siprPolicy (\ s a -> s{_siprPolicy = a})
285+
286+instance FromJSON SetIAMPolicyRequest where
287+ parseJSON
288+ = withObject "SetIAMPolicyRequest"
289+ (\ o -> SetIAMPolicyRequest' <$> (o .:? "policy"))
290+
291+instance ToJSON SetIAMPolicyRequest where
292+ toJSON SetIAMPolicyRequest'{..}
293+ = object (catMaybes [("policy" .=) <$> _siprPolicy])
294+
295+-- | One delta entry for Binding. Each individual change (only one member in
296+-- each entry) to a binding will be a separate entry.
297+--
298+-- /See:/ 'bindingDelta' smart constructor.
299+data BindingDelta = BindingDelta'
300+ { _bdAction :: !(Maybe Text)
301+ , _bdRole :: !(Maybe Text)
302+ , _bdMember :: !(Maybe Text)
303+ } deriving (Eq,Show,Data,Typeable,Generic)
304+
305+-- | Creates a value of 'BindingDelta' with the minimum fields required to make a request.
306+--
307+-- Use one of the following lenses to modify other fields as desired:
308+--
309+-- * 'bdAction'
310+--
311+-- * 'bdRole'
312+--
313+-- * 'bdMember'
314+bindingDelta
315+ :: BindingDelta
316+bindingDelta =
317+ BindingDelta'
318+ { _bdAction = Nothing
319+ , _bdRole = Nothing
320+ , _bdMember = Nothing
321+ }
322+
323+-- | The action that was performed on a Binding. Required
324+bdAction :: Lens' BindingDelta (Maybe Text)
325+bdAction = lens _bdAction (\ s a -> s{_bdAction = a})
326+
327+-- | Role that is assigned to \`members\`. For example, \`roles\/viewer\`,
328+-- \`roles\/editor\`, or \`roles\/owner\`. Required
329+bdRole :: Lens' BindingDelta (Maybe Text)
330+bdRole = lens _bdRole (\ s a -> s{_bdRole = a})
331+
332+-- | A single identity requesting access for a Cloud Platform resource.
333+-- Follows the same format of Binding.members. Required
334+bdMember :: Lens' BindingDelta (Maybe Text)
335+bdMember = lens _bdMember (\ s a -> s{_bdMember = a})
336+
337+instance FromJSON BindingDelta where
338+ parseJSON
339+ = withObject "BindingDelta"
340+ (\ o ->
341+ BindingDelta' <$>
342+ (o .:? "action") <*> (o .:? "role") <*>
343+ (o .:? "member"))
344+
345+instance ToJSON BindingDelta where
346+ toJSON BindingDelta'{..}
347+ = object
348+ (catMaybes
349+ [("action" .=) <$> _bdAction,
350+ ("role" .=) <$> _bdRole,
351+ ("member" .=) <$> _bdMember])
352+
353+-- | The service account sign blob request.
354+--
355+-- /See:/ 'signBlobRequest' smart constructor.
356+newtype SignBlobRequest = SignBlobRequest'
357+ { _sbrBytesToSign :: Maybe Base64
358+ } deriving (Eq,Show,Data,Typeable,Generic)
359+
360+-- | Creates a value of 'SignBlobRequest' with the minimum fields required to make a request.
361+--
362+-- Use one of the following lenses to modify other fields as desired:
363+--
364+-- * 'sbrBytesToSign'
365+signBlobRequest
366+ :: SignBlobRequest
367+signBlobRequest =
368+ SignBlobRequest'
369+ { _sbrBytesToSign = Nothing
370+ }
371+
372+-- | The bytes to sign.
373+sbrBytesToSign :: Lens' SignBlobRequest (Maybe ByteString)
374+sbrBytesToSign
375+ = lens _sbrBytesToSign
376+ (\ s a -> s{_sbrBytesToSign = a})
377+ . mapping _Base64
378+
379+instance FromJSON SignBlobRequest where
380+ parseJSON
381+ = withObject "SignBlobRequest"
382+ (\ o -> SignBlobRequest' <$> (o .:? "bytesToSign"))
383+
384+instance ToJSON SignBlobRequest where
385+ toJSON SignBlobRequest'{..}
386+ = object
387+ (catMaybes [("bytesToSign" .=) <$> _sbrBytesToSign])
388+
389+-- | The service account keys list response.
390+--
391+-- /See:/ 'listServiceAccountKeysResponse' smart constructor.
392+newtype ListServiceAccountKeysResponse = ListServiceAccountKeysResponse'
393+ { _lsakrKeys :: Maybe [ServiceAccountKey]
394+ } deriving (Eq,Show,Data,Typeable,Generic)
395+
396+-- | Creates a value of 'ListServiceAccountKeysResponse' with the minimum fields required to make a request.
397+--
398+-- Use one of the following lenses to modify other fields as desired:
399+--
400+-- * 'lsakrKeys'
401+listServiceAccountKeysResponse
402+ :: ListServiceAccountKeysResponse
403+listServiceAccountKeysResponse =
404+ ListServiceAccountKeysResponse'
405+ { _lsakrKeys = Nothing
406+ }
407+
408+-- | The public keys for the service account.
409+lsakrKeys :: Lens' ListServiceAccountKeysResponse [ServiceAccountKey]
410+lsakrKeys
411+ = lens _lsakrKeys (\ s a -> s{_lsakrKeys = a}) .
412+ _Default
413+ . _Coerce
414+
415+instance FromJSON ListServiceAccountKeysResponse
416+ where
417+ parseJSON
418+ = withObject "ListServiceAccountKeysResponse"
419+ (\ o ->
420+ ListServiceAccountKeysResponse' <$>
421+ (o .:? "keys" .!= mempty))
422+
423+instance ToJSON ListServiceAccountKeysResponse where
424+ toJSON ListServiceAccountKeysResponse'{..}
425+ = object (catMaybes [("keys" .=) <$> _lsakrKeys])
426+
427+-- | A role in the Identity and Access Management API.
428+--
429+-- /See:/ 'role'' smart constructor.
430+data Role = Role'
431+ { _rName :: !(Maybe Text)
432+ , _rTitle :: !(Maybe Text)
433+ , _rDescription :: !(Maybe Text)
434+ } deriving (Eq,Show,Data,Typeable,Generic)
435+
436+-- | Creates a value of 'Role' with the minimum fields required to make a request.
437+--
438+-- Use one of the following lenses to modify other fields as desired:
439+--
440+-- * 'rName'
441+--
442+-- * 'rTitle'
443+--
444+-- * 'rDescription'
445+role'
446+ :: Role
447+role' =
448+ Role'
449+ { _rName = Nothing
450+ , _rTitle = Nothing
451+ , _rDescription = Nothing
452+ }
453+
454+-- | The name of the role. When Role is used in CreateRole, the role name
455+-- must not be set. When Role is used in output and other input such as
456+-- UpdateRole, the role name is the complete path, e.g.,
457+-- roles\/logging.viewer for curated roles and
458+-- organizations\/{organization-id}\/roles\/logging.viewer for custom
459+-- roles.
460+rName :: Lens' Role (Maybe Text)
461+rName = lens _rName (\ s a -> s{_rName = a})
462+
463+-- | Optional. A human-readable title for the role. Typically this is limited
464+-- to 100 UTF-8 bytes.
465+rTitle :: Lens' Role (Maybe Text)
466+rTitle = lens _rTitle (\ s a -> s{_rTitle = a})
467+
468+-- | Optional. A human-readable description for the role.
469+rDescription :: Lens' Role (Maybe Text)
470+rDescription
471+ = lens _rDescription (\ s a -> s{_rDescription = a})
472+
473+instance FromJSON Role where
474+ parseJSON
475+ = withObject "Role"
476+ (\ o ->
477+ Role' <$>
478+ (o .:? "name") <*> (o .:? "title") <*>
479+ (o .:? "description"))
480+
481+instance ToJSON Role where
482+ toJSON Role'{..}
483+ = object
484+ (catMaybes
485+ [("name" .=) <$> _rName, ("title" .=) <$> _rTitle,
486+ ("description" .=) <$> _rDescription])
487+
488+-- | A service account in the Identity and Access Management API. To create a
489+-- service account, specify the \`project_id\` and the \`account_id\` for
490+-- the account. The \`account_id\` is unique within the project, and is
491+-- used to generate the service account email address and a stable
492+-- \`unique_id\`. If the account already exists, the account\'s resource
493+-- name is returned in util::Status\'s ResourceInfo.resource_name in the
494+-- format of projects\/{project}\/serviceAccounts\/{email}. The caller can
495+-- use the name in other methods to access the account. All other methods
496+-- can identify the service account using the format
497+-- \`projects\/{project}\/serviceAccounts\/{account}\`. Using \`-\` as a
498+-- wildcard for the project will infer the project from the account. The
499+-- \`account\` value can be the \`email\` address or the \`unique_id\` of
500+-- the service account.
501+--
502+-- /See:/ 'serviceAccount' smart constructor.
503+data ServiceAccount = ServiceAccount'
504+ { _saEmail :: !(Maybe Text)
505+ , _saEtag :: !(Maybe Base64)
506+ , _saUniqueId :: !(Maybe Text)
507+ , _saName :: !(Maybe Text)
508+ , _saDisplayName :: !(Maybe Text)
509+ , _saProjectId :: !(Maybe Text)
510+ , _saOAuth2ClientId :: !(Maybe Text)
511+ } deriving (Eq,Show,Data,Typeable,Generic)
512+
513+-- | Creates a value of 'ServiceAccount' with the minimum fields required to make a request.
514+--
515+-- Use one of the following lenses to modify other fields as desired:
516+--
517+-- * 'saEmail'
518+--
519+-- * 'saEtag'
520+--
521+-- * 'saUniqueId'
522+--
523+-- * 'saName'
524+--
525+-- * 'saDisplayName'
526+--
527+-- * 'saProjectId'
528+--
529+-- * 'saOAuth2ClientId'
530+serviceAccount
531+ :: ServiceAccount
532+serviceAccount =
533+ ServiceAccount'
534+ { _saEmail = Nothing
535+ , _saEtag = Nothing
536+ , _saUniqueId = Nothing
537+ , _saName = Nothing
538+ , _saDisplayName = Nothing
539+ , _saProjectId = Nothing
540+ , _saOAuth2ClientId = Nothing
541+ }
542+
543+-- | \'OutputOnly The email address of the service account.
544+saEmail :: Lens' ServiceAccount (Maybe Text)
545+saEmail = lens _saEmail (\ s a -> s{_saEmail = a})
546+
547+-- | Used to perform a consistent read-modify-write.
548+saEtag :: Lens' ServiceAccount (Maybe ByteString)
549+saEtag
550+ = lens _saEtag (\ s a -> s{_saEtag = a}) .
551+ mapping _Base64
552+
553+-- | \'OutputOnly The unique and stable id of the service account.
554+saUniqueId :: Lens' ServiceAccount (Maybe Text)
555+saUniqueId
556+ = lens _saUniqueId (\ s a -> s{_saUniqueId = a})
557+
558+-- | The resource name of the service account in the following format:
559+-- \`projects\/{project}\/serviceAccounts\/{account}\`. Requests using
560+-- \`-\` as a wildcard for the project will infer the project from the
561+-- \`account\` and the \`account\` value can be the \`email\` address or
562+-- the \`unique_id\` of the service account. In responses the resource name
563+-- will always be in the format
564+-- \`projects\/{project}\/serviceAccounts\/{email}\`.
565+saName :: Lens' ServiceAccount (Maybe Text)
566+saName = lens _saName (\ s a -> s{_saName = a})
567+
568+-- | Optional. A user-specified description of the service account. Must be
569+-- fewer than 100 UTF-8 bytes.
570+saDisplayName :: Lens' ServiceAccount (Maybe Text)
571+saDisplayName
572+ = lens _saDisplayName
573+ (\ s a -> s{_saDisplayName = a})
574+
575+-- | \'OutputOnly The id of the project that owns the service account.
576+saProjectId :: Lens' ServiceAccount (Maybe Text)
577+saProjectId
578+ = lens _saProjectId (\ s a -> s{_saProjectId = a})
579+
580+-- | \'OutputOnly. The OAuth2 client id for the service account. This is used
581+-- in conjunction with the OAuth2 clientconfig API to make three legged
582+-- OAuth2 (3LO) flows to access the data of Google users.
583+saOAuth2ClientId :: Lens' ServiceAccount (Maybe Text)
584+saOAuth2ClientId
585+ = lens _saOAuth2ClientId
586+ (\ s a -> s{_saOAuth2ClientId = a})
587+
588+instance FromJSON ServiceAccount where
589+ parseJSON
590+ = withObject "ServiceAccount"
591+ (\ o ->
592+ ServiceAccount' <$>
593+ (o .:? "email") <*> (o .:? "etag") <*>
594+ (o .:? "uniqueId")
595+ <*> (o .:? "name")
596+ <*> (o .:? "displayName")
597+ <*> (o .:? "projectId")
598+ <*> (o .:? "oauth2ClientId"))
599+
600+instance ToJSON ServiceAccount where
601+ toJSON ServiceAccount'{..}
602+ = object
603+ (catMaybes
604+ [("email" .=) <$> _saEmail, ("etag" .=) <$> _saEtag,
605+ ("uniqueId" .=) <$> _saUniqueId,
606+ ("name" .=) <$> _saName,
607+ ("displayName" .=) <$> _saDisplayName,
608+ ("projectId" .=) <$> _saProjectId,
609+ ("oauth2ClientId" .=) <$> _saOAuth2ClientId])
610+
611+-- | The grantable role query response.
612+--
613+-- /See:/ 'queryGrantableRolesResponse' smart constructor.
614+newtype QueryGrantableRolesResponse = QueryGrantableRolesResponse'
615+ { _qgrrRoles :: Maybe [Role]
616+ } deriving (Eq,Show,Data,Typeable,Generic)
617+
618+-- | Creates a value of 'QueryGrantableRolesResponse' with the minimum fields required to make a request.
619+--
620+-- Use one of the following lenses to modify other fields as desired:
621+--
622+-- * 'qgrrRoles'
623+queryGrantableRolesResponse
624+ :: QueryGrantableRolesResponse
625+queryGrantableRolesResponse =
626+ QueryGrantableRolesResponse'
627+ { _qgrrRoles = Nothing
628+ }
629+
630+-- | The list of matching roles.
631+qgrrRoles :: Lens' QueryGrantableRolesResponse [Role]
632+qgrrRoles
633+ = lens _qgrrRoles (\ s a -> s{_qgrrRoles = a}) .
634+ _Default
635+ . _Coerce
636+
637+instance FromJSON QueryGrantableRolesResponse where
638+ parseJSON
639+ = withObject "QueryGrantableRolesResponse"
640+ (\ o ->
641+ QueryGrantableRolesResponse' <$>
642+ (o .:? "roles" .!= mempty))
643+
644+instance ToJSON QueryGrantableRolesResponse where
645+ toJSON QueryGrantableRolesResponse'{..}
646+ = object (catMaybes [("roles" .=) <$> _qgrrRoles])
647+
648+-- | Request message for \`TestIamPermissions\` method.
649+--
650+-- /See:/ 'testIAMPermissionsRequest' smart constructor.
651+newtype TestIAMPermissionsRequest = TestIAMPermissionsRequest'
652+ { _tiprPermissions :: Maybe [Text]
653+ } deriving (Eq,Show,Data,Typeable,Generic)
654+
655+-- | Creates a value of 'TestIAMPermissionsRequest' with the minimum fields required to make a request.
656+--
657+-- Use one of the following lenses to modify other fields as desired:
658+--
659+-- * 'tiprPermissions'
660+testIAMPermissionsRequest
661+ :: TestIAMPermissionsRequest
662+testIAMPermissionsRequest =
663+ TestIAMPermissionsRequest'
664+ { _tiprPermissions = Nothing
665+ }
666+
667+-- | The set of permissions to check for the \`resource\`. Permissions with
668+-- wildcards (such as \'*\' or \'storage.*\') are not allowed. For more
669+-- information see [IAM
670+-- Overview](https:\/\/cloud.google.com\/iam\/docs\/overview#permissions).
671+tiprPermissions :: Lens' TestIAMPermissionsRequest [Text]
672+tiprPermissions
673+ = lens _tiprPermissions
674+ (\ s a -> s{_tiprPermissions = a})
675+ . _Default
676+ . _Coerce
677+
678+instance FromJSON TestIAMPermissionsRequest where
679+ parseJSON
680+ = withObject "TestIAMPermissionsRequest"
681+ (\ o ->
682+ TestIAMPermissionsRequest' <$>
683+ (o .:? "permissions" .!= mempty))
684+
685+instance ToJSON TestIAMPermissionsRequest where
686+ toJSON TestIAMPermissionsRequest'{..}
687+ = object
688+ (catMaybes [("permissions" .=) <$> _tiprPermissions])
689+
690+-- | Response message for \`TestIamPermissions\` method.
691+--
692+-- /See:/ 'testIAMPermissionsResponse' smart constructor.
693+newtype TestIAMPermissionsResponse = TestIAMPermissionsResponse'
694+ { _tiamprPermissions :: Maybe [Text]
695+ } deriving (Eq,Show,Data,Typeable,Generic)
696+
697+-- | Creates a value of 'TestIAMPermissionsResponse' with the minimum fields required to make a request.
698+--
699+-- Use one of the following lenses to modify other fields as desired:
700+--
701+-- * 'tiamprPermissions'
702+testIAMPermissionsResponse
703+ :: TestIAMPermissionsResponse
704+testIAMPermissionsResponse =
705+ TestIAMPermissionsResponse'
706+ { _tiamprPermissions = Nothing
707+ }
708+
709+-- | A subset of \`TestPermissionsRequest.permissions\` that the caller is
710+-- allowed.
711+tiamprPermissions :: Lens' TestIAMPermissionsResponse [Text]
712+tiamprPermissions
713+ = lens _tiamprPermissions
714+ (\ s a -> s{_tiamprPermissions = a})
715+ . _Default
716+ . _Coerce
717+
718+instance FromJSON TestIAMPermissionsResponse where
719+ parseJSON
720+ = withObject "TestIAMPermissionsResponse"
721+ (\ o ->
722+ TestIAMPermissionsResponse' <$>
723+ (o .:? "permissions" .!= mempty))
724+
725+instance ToJSON TestIAMPermissionsResponse where
726+ toJSON TestIAMPermissionsResponse'{..}
727+ = object
728+ (catMaybes
729+ [("permissions" .=) <$> _tiamprPermissions])
730+
731+-- | Defines an Identity and Access Management (IAM) policy. It is used to
732+-- specify access control policies for Cloud Platform resources. A
733+-- \`Policy\` consists of a list of \`bindings\`. A \`Binding\` binds a
734+-- list of \`members\` to a \`role\`, where the members can be user
735+-- accounts, Google groups, Google domains, and service accounts. A
736+-- \`role\` is a named list of permissions defined by IAM. **Example** {
737+-- \"bindings\": [ { \"role\": \"roles\/owner\", \"members\": [
738+-- \"user:mike\'example.com\", \"group:admins\'example.com\",
739+-- \"domain:google.com\",
740+-- \"serviceAccount:my-other-app\'appspot.gserviceaccount.com\", ] }, {
741+-- \"role\": \"roles\/viewer\", \"members\": [\"user:sean\'example.com\"] }
742+-- ] } For a description of IAM and its features, see the [IAM developer\'s
743+-- guide](https:\/\/cloud.google.com\/iam).
744+--
745+-- /See:/ 'policy' smart constructor.
746+data Policy = Policy'
747+ { _pEtag :: !(Maybe Base64)
748+ , _pVersion :: !(Maybe (Textual Int32))
749+ , _pBindings :: !(Maybe [Binding])
750+ } deriving (Eq,Show,Data,Typeable,Generic)
751+
752+-- | Creates a value of 'Policy' with the minimum fields required to make a request.
753+--
754+-- Use one of the following lenses to modify other fields as desired:
755+--
756+-- * 'pEtag'
757+--
758+-- * 'pVersion'
759+--
760+-- * 'pBindings'
761+policy
762+ :: Policy
763+policy =
764+ Policy'
765+ { _pEtag = Nothing
766+ , _pVersion = Nothing
767+ , _pBindings = Nothing
768+ }
769+
770+-- | \`etag\` is used for optimistic concurrency control as a way to help
771+-- prevent simultaneous updates of a policy from overwriting each other. It
772+-- is strongly suggested that systems make use of the \`etag\` in the
773+-- read-modify-write cycle to perform policy updates in order to avoid race
774+-- conditions: An \`etag\` is returned in the response to \`getIamPolicy\`,
775+-- and systems are expected to put that etag in the request to
776+-- \`setIamPolicy\` to ensure that their change will be applied to the same
777+-- version of the policy. If no \`etag\` is provided in the call to
778+-- \`setIamPolicy\`, then the existing policy is overwritten blindly.
779+pEtag :: Lens' Policy (Maybe ByteString)
780+pEtag
781+ = lens _pEtag (\ s a -> s{_pEtag = a}) .
782+ mapping _Base64
783+
784+-- | Version of the \`Policy\`. The default version is 0.
785+pVersion :: Lens' Policy (Maybe Int32)
786+pVersion
787+ = lens _pVersion (\ s a -> s{_pVersion = a}) .
788+ mapping _Coerce
789+
790+-- | Associates a list of \`members\` to a \`role\`. Multiple \`bindings\`
791+-- must not be specified for the same \`role\`. \`bindings\` with no
792+-- members will result in an error.
793+pBindings :: Lens' Policy [Binding]
794+pBindings
795+ = lens _pBindings (\ s a -> s{_pBindings = a}) .
796+ _Default
797+ . _Coerce
798+
799+instance FromJSON Policy where
800+ parseJSON
801+ = withObject "Policy"
802+ (\ o ->
803+ Policy' <$>
804+ (o .:? "etag") <*> (o .:? "version") <*>
805+ (o .:? "bindings" .!= mempty))
806+
807+instance ToJSON Policy where
808+ toJSON Policy'{..}
809+ = object
810+ (catMaybes
811+ [("etag" .=) <$> _pEtag,
812+ ("version" .=) <$> _pVersion,
813+ ("bindings" .=) <$> _pBindings])
814+
815+-- | The difference delta between two policies.
816+--
817+-- /See:/ 'policyDelta' smart constructor.
818+newtype PolicyDelta = PolicyDelta'
819+ { _pdBindingDeltas :: Maybe [BindingDelta]
820+ } deriving (Eq,Show,Data,Typeable,Generic)
821+
822+-- | Creates a value of 'PolicyDelta' with the minimum fields required to make a request.
823+--
824+-- Use one of the following lenses to modify other fields as desired:
825+--
826+-- * 'pdBindingDeltas'
827+policyDelta
828+ :: PolicyDelta
829+policyDelta =
830+ PolicyDelta'
831+ { _pdBindingDeltas = Nothing
832+ }
833+
834+-- | The delta for Bindings between two policies.
835+pdBindingDeltas :: Lens' PolicyDelta [BindingDelta]
836+pdBindingDeltas
837+ = lens _pdBindingDeltas
838+ (\ s a -> s{_pdBindingDeltas = a})
839+ . _Default
840+ . _Coerce
841+
842+instance FromJSON PolicyDelta where
843+ parseJSON
844+ = withObject "PolicyDelta"
845+ (\ o ->
846+ PolicyDelta' <$> (o .:? "bindingDeltas" .!= mempty))
847+
848+instance ToJSON PolicyDelta where
849+ toJSON PolicyDelta'{..}
850+ = object
851+ (catMaybes
852+ [("bindingDeltas" .=) <$> _pdBindingDeltas])
853+
854+-- | The grantable role query request.
855+--
856+-- /See:/ 'queryGrantableRolesRequest' smart constructor.
857+newtype QueryGrantableRolesRequest = QueryGrantableRolesRequest'
858+ { _qgrrFullResourceName :: Maybe Text
859+ } deriving (Eq,Show,Data,Typeable,Generic)
860+
861+-- | Creates a value of 'QueryGrantableRolesRequest' with the minimum fields required to make a request.
862+--
863+-- Use one of the following lenses to modify other fields as desired:
864+--
865+-- * 'qgrrFullResourceName'
866+queryGrantableRolesRequest
867+ :: QueryGrantableRolesRequest
868+queryGrantableRolesRequest =
869+ QueryGrantableRolesRequest'
870+ { _qgrrFullResourceName = Nothing
871+ }
872+
873+-- | Required. The full resource name to query from the list of grantable
874+-- roles. The name follows the Google Cloud Platform resource format. For
875+-- example, a Cloud Platform project with id \`my-project\` will be named
876+-- \`\/\/cloudresourcemanager.googleapis.com\/projects\/my-project\`.
877+qgrrFullResourceName :: Lens' QueryGrantableRolesRequest (Maybe Text)
878+qgrrFullResourceName
879+ = lens _qgrrFullResourceName
880+ (\ s a -> s{_qgrrFullResourceName = a})
881+
882+instance FromJSON QueryGrantableRolesRequest where
883+ parseJSON
884+ = withObject "QueryGrantableRolesRequest"
885+ (\ o ->
886+ QueryGrantableRolesRequest' <$>
887+ (o .:? "fullResourceName"))
888+
889+instance ToJSON QueryGrantableRolesRequest where
890+ toJSON QueryGrantableRolesRequest'{..}
891+ = object
892+ (catMaybes
893+ [("fullResourceName" .=) <$> _qgrrFullResourceName])
894+
895+-- | The service account sign blob response.
896+--
897+-- /See:/ 'signBlobResponse' smart constructor.
898+data SignBlobResponse = SignBlobResponse'
899+ { _sbrSignature :: !(Maybe Base64)
900+ , _sbrKeyId :: !(Maybe Text)
901+ } deriving (Eq,Show,Data,Typeable,Generic)
902+
903+-- | Creates a value of 'SignBlobResponse' with the minimum fields required to make a request.
904+--
905+-- Use one of the following lenses to modify other fields as desired:
906+--
907+-- * 'sbrSignature'
908+--
909+-- * 'sbrKeyId'
910+signBlobResponse
911+ :: SignBlobResponse
912+signBlobResponse =
913+ SignBlobResponse'
914+ { _sbrSignature = Nothing
915+ , _sbrKeyId = Nothing
916+ }
917+
918+-- | The signed blob.
919+sbrSignature :: Lens' SignBlobResponse (Maybe ByteString)
920+sbrSignature
921+ = lens _sbrSignature (\ s a -> s{_sbrSignature = a})
922+ . mapping _Base64
923+
924+-- | The id of the key used to sign the blob.
925+sbrKeyId :: Lens' SignBlobResponse (Maybe Text)
926+sbrKeyId = lens _sbrKeyId (\ s a -> s{_sbrKeyId = a})
927+
928+instance FromJSON SignBlobResponse where
929+ parseJSON
930+ = withObject "SignBlobResponse"
931+ (\ o ->
932+ SignBlobResponse' <$>
933+ (o .:? "signature") <*> (o .:? "keyId"))
934+
935+instance ToJSON SignBlobResponse where
936+ toJSON SignBlobResponse'{..}
937+ = object
938+ (catMaybes
939+ [("signature" .=) <$> _sbrSignature,
940+ ("keyId" .=) <$> _sbrKeyId])
941+
942+-- | The service account list response.
943+--
944+-- /See:/ 'listServiceAccountsResponse' smart constructor.
945+data ListServiceAccountsResponse = ListServiceAccountsResponse'
946+ { _lsarNextPageToken :: !(Maybe Text)
947+ , _lsarAccounts :: !(Maybe [ServiceAccount])
948+ } deriving (Eq,Show,Data,Typeable,Generic)
949+
950+-- | Creates a value of 'ListServiceAccountsResponse' with the minimum fields required to make a request.
951+--
952+-- Use one of the following lenses to modify other fields as desired:
953+--
954+-- * 'lsarNextPageToken'
955+--
956+-- * 'lsarAccounts'
957+listServiceAccountsResponse
958+ :: ListServiceAccountsResponse
959+listServiceAccountsResponse =
960+ ListServiceAccountsResponse'
961+ { _lsarNextPageToken = Nothing
962+ , _lsarAccounts = Nothing
963+ }
964+
965+-- | To retrieve the next page of results, set
966+-- ListServiceAccountsRequest.page_token to this value.
967+lsarNextPageToken :: Lens' ListServiceAccountsResponse (Maybe Text)
968+lsarNextPageToken
969+ = lens _lsarNextPageToken
970+ (\ s a -> s{_lsarNextPageToken = a})
971+
972+-- | The list of matching service accounts.
973+lsarAccounts :: Lens' ListServiceAccountsResponse [ServiceAccount]
974+lsarAccounts
975+ = lens _lsarAccounts (\ s a -> s{_lsarAccounts = a})
976+ . _Default
977+ . _Coerce
978+
979+instance FromJSON ListServiceAccountsResponse where
980+ parseJSON
981+ = withObject "ListServiceAccountsResponse"
982+ (\ o ->
983+ ListServiceAccountsResponse' <$>
984+ (o .:? "nextPageToken") <*>
985+ (o .:? "accounts" .!= mempty))
986+
987+instance ToJSON ListServiceAccountsResponse where
988+ toJSON ListServiceAccountsResponse'{..}
989+ = object
990+ (catMaybes
991+ [("nextPageToken" .=) <$> _lsarNextPageToken,
992+ ("accounts" .=) <$> _lsarAccounts])
993+
994+-- | The service account create request.
995+--
996+-- /See:/ 'createServiceAccountRequest' smart constructor.
997+data CreateServiceAccountRequest = CreateServiceAccountRequest'
998+ { _csarServiceAccount :: !(Maybe ServiceAccount)
999+ , _csarAccountId :: !(Maybe Text)
1000+ } deriving (Eq,Show,Data,Typeable,Generic)
1001+
1002+-- | Creates a value of 'CreateServiceAccountRequest' with the minimum fields required to make a request.
1003+--
1004+-- Use one of the following lenses to modify other fields as desired:
1005+--
1006+-- * 'csarServiceAccount'
1007+--
1008+-- * 'csarAccountId'
1009+createServiceAccountRequest
1010+ :: CreateServiceAccountRequest
1011+createServiceAccountRequest =
1012+ CreateServiceAccountRequest'
1013+ { _csarServiceAccount = Nothing
1014+ , _csarAccountId = Nothing
1015+ }
1016+
1017+-- | The ServiceAccount resource to create. Currently, only the following
1018+-- values are user assignable: \`display_name\` .
1019+csarServiceAccount :: Lens' CreateServiceAccountRequest (Maybe ServiceAccount)
1020+csarServiceAccount
1021+ = lens _csarServiceAccount
1022+ (\ s a -> s{_csarServiceAccount = a})
1023+
1024+-- | Required. The account id that is used to generate the service account
1025+-- email address and a stable unique id. It is unique within a project,
1026+-- must be 6-30 characters long, and match the regular expression
1027+-- \`[a-z]([-a-z0-9]*[a-z0-9])\` to comply with RFC1035.
1028+csarAccountId :: Lens' CreateServiceAccountRequest (Maybe Text)
1029+csarAccountId
1030+ = lens _csarAccountId
1031+ (\ s a -> s{_csarAccountId = a})
1032+
1033+instance FromJSON CreateServiceAccountRequest where
1034+ parseJSON
1035+ = withObject "CreateServiceAccountRequest"
1036+ (\ o ->
1037+ CreateServiceAccountRequest' <$>
1038+ (o .:? "serviceAccount") <*> (o .:? "accountId"))
1039+
1040+instance ToJSON CreateServiceAccountRequest where
1041+ toJSON CreateServiceAccountRequest'{..}
1042+ = object
1043+ (catMaybes
1044+ [("serviceAccount" .=) <$> _csarServiceAccount,
1045+ ("accountId" .=) <$> _csarAccountId])
1046+
1047+-- | Associates \`members\` with a \`role\`.
1048+--
1049+-- /See:/ 'binding' smart constructor.
1050+data Binding = Binding'
1051+ { _bMembers :: !(Maybe [Text])
1052+ , _bRole :: !(Maybe Text)
1053+ } deriving (Eq,Show,Data,Typeable,Generic)
1054+
1055+-- | Creates a value of 'Binding' with the minimum fields required to make a request.
1056+--
1057+-- Use one of the following lenses to modify other fields as desired:
1058+--
1059+-- * 'bMembers'
1060+--
1061+-- * 'bRole'
1062+binding
1063+ :: Binding
1064+binding =
1065+ Binding'
1066+ { _bMembers = Nothing
1067+ , _bRole = Nothing
1068+ }
1069+
1070+-- | Specifies the identities requesting access for a Cloud Platform
1071+-- resource. \`members\` can have the following values: * \`allUsers\`: A
1072+-- special identifier that represents anyone who is on the internet; with
1073+-- or without a Google account. * \`allAuthenticatedUsers\`: A special
1074+-- identifier that represents anyone who is authenticated with a Google
1075+-- account or a service account. * \`user:{emailid}\`: An email address
1076+-- that represents a specific Google account. For example,
1077+-- \`alice\'gmail.com\` or \`joe\'example.com\`. *
1078+-- \`serviceAccount:{emailid}\`: An email address that represents a service
1079+-- account. For example, \`my-other-app\'appspot.gserviceaccount.com\`. *
1080+-- \`group:{emailid}\`: An email address that represents a Google group.
1081+-- For example, \`admins\'example.com\`. * \`domain:{domain}\`: A Google
1082+-- Apps domain name that represents all the users of that domain. For
1083+-- example, \`google.com\` or \`example.com\`.
1084+bMembers :: Lens' Binding [Text]
1085+bMembers
1086+ = lens _bMembers (\ s a -> s{_bMembers = a}) .
1087+ _Default
1088+ . _Coerce
1089+
1090+-- | Role that is assigned to \`members\`. For example, \`roles\/viewer\`,
1091+-- \`roles\/editor\`, or \`roles\/owner\`. Required
1092+bRole :: Lens' Binding (Maybe Text)
1093+bRole = lens _bRole (\ s a -> s{_bRole = a})
1094+
1095+instance FromJSON Binding where
1096+ parseJSON
1097+ = withObject "Binding"
1098+ (\ o ->
1099+ Binding' <$>
1100+ (o .:? "members" .!= mempty) <*> (o .:? "role"))
1101+
1102+instance ToJSON Binding where
1103+ toJSON Binding'{..}
1104+ = object
1105+ (catMaybes
1106+ [("members" .=) <$> _bMembers,
1107+ ("role" .=) <$> _bRole])
gogol-iam/gen/Network/Google/IAM/Types/Sum.hsnew file+19
@@ -0,0 +1,19 @@
1+{-# LANGUAGE DeriveDataTypeable #-}
2+{-# LANGUAGE DeriveGeneric #-}
3+{-# LANGUAGE LambdaCase #-}
4+{-# LANGUAGE NoImplicitPrelude #-}
5+{-# LANGUAGE OverloadedStrings #-}
6+
7+{-# OPTIONS_GHC -fno-warn-unused-imports #-}
8+
9+-- |
10+-- Module : Network.Google.IAM.Types.Sum
11+-- Copyright : (c) 2015-2016 Brendan Hay
12+-- License : Mozilla Public License, v. 2.0.
13+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>
14+-- Stability : auto-generated
15+-- Portability : non-portable (GHC extensions)
16+--
17+module Network.Google.IAM.Types.Sum where
18+
19+import Network.Google.Prelude
gogol-iam/gen/Network/Google/Resource/IAM/Projects/ServiceAccounts/Create.hsnew file+188
@@ -0,0 +1,188 @@
1+{-# LANGUAGE DataKinds #-}
2+{-# LANGUAGE DeriveDataTypeable #-}
3+{-# LANGUAGE DeriveGeneric #-}
4+{-# LANGUAGE FlexibleInstances #-}
5+{-# LANGUAGE NoImplicitPrelude #-}
6+{-# LANGUAGE OverloadedStrings #-}
7+{-# LANGUAGE RecordWildCards #-}
8+{-# LANGUAGE TypeFamilies #-}
9+{-# LANGUAGE TypeOperators #-}
10+
11+{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
12+{-# OPTIONS_GHC -fno-warn-unused-binds #-}
13+{-# OPTIONS_GHC -fno-warn-unused-imports #-}
14+
15+-- |
16+-- Module : Network.Google.Resource.IAM.Projects.ServiceAccounts.Create
17+-- Copyright : (c) 2015-2016 Brendan Hay
18+-- License : Mozilla Public License, v. 2.0.
19+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>
20+-- Stability : auto-generated
21+-- Portability : non-portable (GHC extensions)
22+--
23+-- Creates a ServiceAccount and returns it.
24+--
25+-- /See:/ <https://cloud.google.com/iam/ Google Identity and Access Management (IAM) API Reference> for @iam.projects.serviceAccounts.create@.
26+module Network.Google.Resource.IAM.Projects.ServiceAccounts.Create
27+ (
28+ -- * REST Resource
29+ ProjectsServiceAccountsCreateResource
30+
31+ -- * Creating a Request
32+ , projectsServiceAccountsCreate
33+ , ProjectsServiceAccountsCreate
34+
35+ -- * Request Lenses
36+ , psacXgafv
37+ , psacUploadProtocol
38+ , psacPp
39+ , psacAccessToken
40+ , psacUploadType
41+ , psacPayload
42+ , psacBearerToken
43+ , psacName
44+ , psacCallback
45+ ) where
46+
47+import Network.Google.IAM.Types
48+import Network.Google.Prelude
49+
50+-- | A resource alias for @iam.projects.serviceAccounts.create@ method which the
51+-- 'ProjectsServiceAccountsCreate' request conforms to.
52+type ProjectsServiceAccountsCreateResource =
53+ "v1" :>
54+ Capture "name" Text :>
55+ "serviceAccounts" :>
56+ QueryParam "$.xgafv" Text :>
57+ QueryParam "upload_protocol" Text :>
58+ QueryParam "pp" Bool :>
59+ QueryParam "access_token" Text :>
60+ QueryParam "uploadType" Text :>
61+ QueryParam "bearer_token" Text :>
62+ QueryParam "callback" Text :>
63+ QueryParam "alt" AltJSON :>
64+ ReqBody '[JSON] CreateServiceAccountRequest :>
65+ Post '[JSON] ServiceAccount
66+
67+-- | Creates a ServiceAccount and returns it.
68+--
69+-- /See:/ 'projectsServiceAccountsCreate' smart constructor.
70+data ProjectsServiceAccountsCreate = ProjectsServiceAccountsCreate'
71+ { _psacXgafv :: !(Maybe Text)
72+ , _psacUploadProtocol :: !(Maybe Text)
73+ , _psacPp :: !Bool
74+ , _psacAccessToken :: !(Maybe Text)
75+ , _psacUploadType :: !(Maybe Text)
76+ , _psacPayload :: !CreateServiceAccountRequest
77+ , _psacBearerToken :: !(Maybe Text)
78+ , _psacName :: !Text
79+ , _psacCallback :: !(Maybe Text)
80+ } deriving (Eq,Show,Data,Typeable,Generic)
81+
82+-- | Creates a value of 'ProjectsServiceAccountsCreate' with the minimum fields required to make a request.
83+--
84+-- Use one of the following lenses to modify other fields as desired:
85+--
86+-- * 'psacXgafv'
87+--
88+-- * 'psacUploadProtocol'
89+--
90+-- * 'psacPp'
91+--
92+-- * 'psacAccessToken'
93+--
94+-- * 'psacUploadType'
95+--
96+-- * 'psacPayload'
97+--
98+-- * 'psacBearerToken'
99+--
100+-- * 'psacName'
101+--
102+-- * 'psacCallback'
103+projectsServiceAccountsCreate
104+ :: CreateServiceAccountRequest -- ^ 'psacPayload'
105+ -> Text -- ^ 'psacName'
106+ -> ProjectsServiceAccountsCreate
107+projectsServiceAccountsCreate pPsacPayload_ pPsacName_ =
108+ ProjectsServiceAccountsCreate'
109+ { _psacXgafv = Nothing
110+ , _psacUploadProtocol = Nothing
111+ , _psacPp = True
112+ , _psacAccessToken = Nothing
113+ , _psacUploadType = Nothing
114+ , _psacPayload = pPsacPayload_
115+ , _psacBearerToken = Nothing
116+ , _psacName = pPsacName_
117+ , _psacCallback = Nothing
118+ }
119+
120+-- | V1 error format.
121+psacXgafv :: Lens' ProjectsServiceAccountsCreate (Maybe Text)
122+psacXgafv
123+ = lens _psacXgafv (\ s a -> s{_psacXgafv = a})
124+
125+-- | Upload protocol for media (e.g. \"raw\", \"multipart\").
126+psacUploadProtocol :: Lens' ProjectsServiceAccountsCreate (Maybe Text)
127+psacUploadProtocol
128+ = lens _psacUploadProtocol
129+ (\ s a -> s{_psacUploadProtocol = a})
130+
131+-- | Pretty-print response.
132+psacPp :: Lens' ProjectsServiceAccountsCreate Bool
133+psacPp = lens _psacPp (\ s a -> s{_psacPp = a})
134+
135+-- | OAuth access token.
136+psacAccessToken :: Lens' ProjectsServiceAccountsCreate (Maybe Text)
137+psacAccessToken
138+ = lens _psacAccessToken
139+ (\ s a -> s{_psacAccessToken = a})
140+
141+-- | Legacy upload protocol for media (e.g. \"media\", \"multipart\").
142+psacUploadType :: Lens' ProjectsServiceAccountsCreate (Maybe Text)
143+psacUploadType
144+ = lens _psacUploadType
145+ (\ s a -> s{_psacUploadType = a})
146+
147+-- | Multipart request metadata.
148+psacPayload :: Lens' ProjectsServiceAccountsCreate CreateServiceAccountRequest
149+psacPayload
150+ = lens _psacPayload (\ s a -> s{_psacPayload = a})
151+
152+-- | OAuth bearer token.
153+psacBearerToken :: Lens' ProjectsServiceAccountsCreate (Maybe Text)
154+psacBearerToken
155+ = lens _psacBearerToken
156+ (\ s a -> s{_psacBearerToken = a})
157+
158+-- | Required. The resource name of the project associated with the service
159+-- accounts, such as \`projects\/my-project-123\`.
160+psacName :: Lens' ProjectsServiceAccountsCreate Text
161+psacName = lens _psacName (\ s a -> s{_psacName = a})
162+
163+-- | JSONP
164+psacCallback :: Lens' ProjectsServiceAccountsCreate (Maybe Text)
165+psacCallback
166+ = lens _psacCallback (\ s a -> s{_psacCallback = a})
167+
168+instance GoogleRequest ProjectsServiceAccountsCreate
169+ where
170+ type Rs ProjectsServiceAccountsCreate =
171+ ServiceAccount
172+ type Scopes ProjectsServiceAccountsCreate =
173+ '["https://www.googleapis.com/auth/cloud-platform"]
174+ requestClient ProjectsServiceAccountsCreate'{..}
175+ = go _psacName _psacXgafv _psacUploadProtocol
176+ (Just _psacPp)
177+ _psacAccessToken
178+ _psacUploadType
179+ _psacBearerToken
180+ _psacCallback
181+ (Just AltJSON)
182+ _psacPayload
183+ iAMService
184+ where go
185+ = buildClient
186+ (Proxy ::
187+ Proxy ProjectsServiceAccountsCreateResource)
188+ mempty
gogol-iam/gen/Network/Google/Resource/IAM/Projects/ServiceAccounts/Delete.hsnew file+175
@@ -0,0 +1,175 @@
1+{-# LANGUAGE DataKinds #-}
2+{-# LANGUAGE DeriveDataTypeable #-}
3+{-# LANGUAGE DeriveGeneric #-}
4+{-# LANGUAGE FlexibleInstances #-}
5+{-# LANGUAGE NoImplicitPrelude #-}
6+{-# LANGUAGE OverloadedStrings #-}
7+{-# LANGUAGE RecordWildCards #-}
8+{-# LANGUAGE TypeFamilies #-}
9+{-# LANGUAGE TypeOperators #-}
10+
11+{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
12+{-# OPTIONS_GHC -fno-warn-unused-binds #-}
13+{-# OPTIONS_GHC -fno-warn-unused-imports #-}
14+
15+-- |
16+-- Module : Network.Google.Resource.IAM.Projects.ServiceAccounts.Delete
17+-- Copyright : (c) 2015-2016 Brendan Hay
18+-- License : Mozilla Public License, v. 2.0.
19+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>
20+-- Stability : auto-generated
21+-- Portability : non-portable (GHC extensions)
22+--
23+-- Deletes a ServiceAccount.
24+--
25+-- /See:/ <https://cloud.google.com/iam/ Google Identity and Access Management (IAM) API Reference> for @iam.projects.serviceAccounts.delete@.
26+module Network.Google.Resource.IAM.Projects.ServiceAccounts.Delete
27+ (
28+ -- * REST Resource
29+ ProjectsServiceAccountsDeleteResource
30+
31+ -- * Creating a Request
32+ , projectsServiceAccountsDelete
33+ , ProjectsServiceAccountsDelete
34+
35+ -- * Request Lenses
36+ , psadXgafv
37+ , psadUploadProtocol
38+ , psadPp
39+ , psadAccessToken
40+ , psadUploadType
41+ , psadBearerToken
42+ , psadName
43+ , psadCallback
44+ ) where
45+
46+import Network.Google.IAM.Types
47+import Network.Google.Prelude
48+
49+-- | A resource alias for @iam.projects.serviceAccounts.delete@ method which the
50+-- 'ProjectsServiceAccountsDelete' request conforms to.
51+type ProjectsServiceAccountsDeleteResource =
52+ "v1" :>
53+ Capture "name" Text :>
54+ QueryParam "$.xgafv" Text :>
55+ QueryParam "upload_protocol" Text :>
56+ QueryParam "pp" Bool :>
57+ QueryParam "access_token" Text :>
58+ QueryParam "uploadType" Text :>
59+ QueryParam "bearer_token" Text :>
60+ QueryParam "callback" Text :>
61+ QueryParam "alt" AltJSON :> Delete '[JSON] Empty
62+
63+-- | Deletes a ServiceAccount.
64+--
65+-- /See:/ 'projectsServiceAccountsDelete' smart constructor.
66+data ProjectsServiceAccountsDelete = ProjectsServiceAccountsDelete'
67+ { _psadXgafv :: !(Maybe Text)
68+ , _psadUploadProtocol :: !(Maybe Text)
69+ , _psadPp :: !Bool
70+ , _psadAccessToken :: !(Maybe Text)
71+ , _psadUploadType :: !(Maybe Text)
72+ , _psadBearerToken :: !(Maybe Text)
73+ , _psadName :: !Text
74+ , _psadCallback :: !(Maybe Text)
75+ } deriving (Eq,Show,Data,Typeable,Generic)
76+
77+-- | Creates a value of 'ProjectsServiceAccountsDelete' with the minimum fields required to make a request.
78+--
79+-- Use one of the following lenses to modify other fields as desired:
80+--
81+-- * 'psadXgafv'
82+--
83+-- * 'psadUploadProtocol'
84+--
85+-- * 'psadPp'
86+--
87+-- * 'psadAccessToken'
88+--
89+-- * 'psadUploadType'
90+--
91+-- * 'psadBearerToken'
92+--
93+-- * 'psadName'
94+--
95+-- * 'psadCallback'
96+projectsServiceAccountsDelete
97+ :: Text -- ^ 'psadName'
98+ -> ProjectsServiceAccountsDelete
99+projectsServiceAccountsDelete pPsadName_ =
100+ ProjectsServiceAccountsDelete'
101+ { _psadXgafv = Nothing
102+ , _psadUploadProtocol = Nothing
103+ , _psadPp = True
104+ , _psadAccessToken = Nothing
105+ , _psadUploadType = Nothing
106+ , _psadBearerToken = Nothing
107+ , _psadName = pPsadName_
108+ , _psadCallback = Nothing
109+ }
110+
111+-- | V1 error format.
112+psadXgafv :: Lens' ProjectsServiceAccountsDelete (Maybe Text)
113+psadXgafv
114+ = lens _psadXgafv (\ s a -> s{_psadXgafv = a})
115+
116+-- | Upload protocol for media (e.g. \"raw\", \"multipart\").
117+psadUploadProtocol :: Lens' ProjectsServiceAccountsDelete (Maybe Text)
118+psadUploadProtocol
119+ = lens _psadUploadProtocol
120+ (\ s a -> s{_psadUploadProtocol = a})
121+
122+-- | Pretty-print response.
123+psadPp :: Lens' ProjectsServiceAccountsDelete Bool
124+psadPp = lens _psadPp (\ s a -> s{_psadPp = a})
125+
126+-- | OAuth access token.
127+psadAccessToken :: Lens' ProjectsServiceAccountsDelete (Maybe Text)
128+psadAccessToken
129+ = lens _psadAccessToken
130+ (\ s a -> s{_psadAccessToken = a})
131+
132+-- | Legacy upload protocol for media (e.g. \"media\", \"multipart\").
133+psadUploadType :: Lens' ProjectsServiceAccountsDelete (Maybe Text)
134+psadUploadType
135+ = lens _psadUploadType
136+ (\ s a -> s{_psadUploadType = a})
137+
138+-- | OAuth bearer token.
139+psadBearerToken :: Lens' ProjectsServiceAccountsDelete (Maybe Text)
140+psadBearerToken
141+ = lens _psadBearerToken
142+ (\ s a -> s{_psadBearerToken = a})
143+
144+-- | The resource name of the service account in the following format:
145+-- \`projects\/{project}\/serviceAccounts\/{account}\`. Using \`-\` as a
146+-- wildcard for the project will infer the project from the account. The
147+-- \`account\` value can be the \`email\` address or the \`unique_id\` of
148+-- the service account.
149+psadName :: Lens' ProjectsServiceAccountsDelete Text
150+psadName = lens _psadName (\ s a -> s{_psadName = a})
151+
152+-- | JSONP
153+psadCallback :: Lens' ProjectsServiceAccountsDelete (Maybe Text)
154+psadCallback
155+ = lens _psadCallback (\ s a -> s{_psadCallback = a})
156+
157+instance GoogleRequest ProjectsServiceAccountsDelete
158+ where
159+ type Rs ProjectsServiceAccountsDelete = Empty
160+ type Scopes ProjectsServiceAccountsDelete =
161+ '["https://www.googleapis.com/auth/cloud-platform"]
162+ requestClient ProjectsServiceAccountsDelete'{..}
163+ = go _psadName _psadXgafv _psadUploadProtocol
164+ (Just _psadPp)
165+ _psadAccessToken
166+ _psadUploadType
167+ _psadBearerToken
168+ _psadCallback
169+ (Just AltJSON)
170+ iAMService
171+ where go
172+ = buildClient
173+ (Proxy ::
174+ Proxy ProjectsServiceAccountsDeleteResource)
175+ mempty
gogol-iam/gen/Network/Google/Resource/IAM/Projects/ServiceAccounts/Get.hsnew file+175
@@ -0,0 +1,175 @@
1+{-# LANGUAGE DataKinds #-}
2+{-# LANGUAGE DeriveDataTypeable #-}
3+{-# LANGUAGE DeriveGeneric #-}
4+{-# LANGUAGE FlexibleInstances #-}
5+{-# LANGUAGE NoImplicitPrelude #-}
6+{-# LANGUAGE OverloadedStrings #-}
7+{-# LANGUAGE RecordWildCards #-}
8+{-# LANGUAGE TypeFamilies #-}
9+{-# LANGUAGE TypeOperators #-}
10+
11+{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
12+{-# OPTIONS_GHC -fno-warn-unused-binds #-}
13+{-# OPTIONS_GHC -fno-warn-unused-imports #-}
14+
15+-- |
16+-- Module : Network.Google.Resource.IAM.Projects.ServiceAccounts.Get
17+-- Copyright : (c) 2015-2016 Brendan Hay
18+-- License : Mozilla Public License, v. 2.0.
19+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>
20+-- Stability : auto-generated
21+-- Portability : non-portable (GHC extensions)
22+--
23+-- Gets a ServiceAccount.
24+--
25+-- /See:/ <https://cloud.google.com/iam/ Google Identity and Access Management (IAM) API Reference> for @iam.projects.serviceAccounts.get@.
26+module Network.Google.Resource.IAM.Projects.ServiceAccounts.Get
27+ (
28+ -- * REST Resource
29+ ProjectsServiceAccountsGetResource
30+
31+ -- * Creating a Request
32+ , projectsServiceAccountsGet
33+ , ProjectsServiceAccountsGet
34+
35+ -- * Request Lenses
36+ , psagXgafv
37+ , psagUploadProtocol
38+ , psagPp
39+ , psagAccessToken
40+ , psagUploadType
41+ , psagBearerToken
42+ , psagName
43+ , psagCallback
44+ ) where
45+
46+import Network.Google.IAM.Types
47+import Network.Google.Prelude
48+
49+-- | A resource alias for @iam.projects.serviceAccounts.get@ method which the
50+-- 'ProjectsServiceAccountsGet' request conforms to.
51+type ProjectsServiceAccountsGetResource =
52+ "v1" :>
53+ Capture "name" Text :>
54+ QueryParam "$.xgafv" Text :>
55+ QueryParam "upload_protocol" Text :>
56+ QueryParam "pp" Bool :>
57+ QueryParam "access_token" Text :>
58+ QueryParam "uploadType" Text :>
59+ QueryParam "bearer_token" Text :>
60+ QueryParam "callback" Text :>
61+ QueryParam "alt" AltJSON :>
62+ Get '[JSON] ServiceAccount
63+
64+-- | Gets a ServiceAccount.
65+--
66+-- /See:/ 'projectsServiceAccountsGet' smart constructor.
67+data ProjectsServiceAccountsGet = ProjectsServiceAccountsGet'
68+ { _psagXgafv :: !(Maybe Text)
69+ , _psagUploadProtocol :: !(Maybe Text)
70+ , _psagPp :: !Bool
71+ , _psagAccessToken :: !(Maybe Text)
72+ , _psagUploadType :: !(Maybe Text)
73+ , _psagBearerToken :: !(Maybe Text)
74+ , _psagName :: !Text
75+ , _psagCallback :: !(Maybe Text)
76+ } deriving (Eq,Show,Data,Typeable,Generic)
77+
78+-- | Creates a value of 'ProjectsServiceAccountsGet' with the minimum fields required to make a request.
79+--
80+-- Use one of the following lenses to modify other fields as desired:
81+--
82+-- * 'psagXgafv'
83+--
84+-- * 'psagUploadProtocol'
85+--
86+-- * 'psagPp'
87+--
88+-- * 'psagAccessToken'
89+--
90+-- * 'psagUploadType'
91+--
92+-- * 'psagBearerToken'
93+--
94+-- * 'psagName'
95+--
96+-- * 'psagCallback'
97+projectsServiceAccountsGet
98+ :: Text -- ^ 'psagName'
99+ -> ProjectsServiceAccountsGet
100+projectsServiceAccountsGet pPsagName_ =
101+ ProjectsServiceAccountsGet'
102+ { _psagXgafv = Nothing
103+ , _psagUploadProtocol = Nothing
104+ , _psagPp = True
105+ , _psagAccessToken = Nothing
106+ , _psagUploadType = Nothing
107+ , _psagBearerToken = Nothing
108+ , _psagName = pPsagName_
109+ , _psagCallback = Nothing
110+ }
111+
112+-- | V1 error format.
113+psagXgafv :: Lens' ProjectsServiceAccountsGet (Maybe Text)
114+psagXgafv
115+ = lens _psagXgafv (\ s a -> s{_psagXgafv = a})
116+
117+-- | Upload protocol for media (e.g. \"raw\", \"multipart\").
118+psagUploadProtocol :: Lens' ProjectsServiceAccountsGet (Maybe Text)
119+psagUploadProtocol
120+ = lens _psagUploadProtocol
121+ (\ s a -> s{_psagUploadProtocol = a})
122+
123+-- | Pretty-print response.
124+psagPp :: Lens' ProjectsServiceAccountsGet Bool
125+psagPp = lens _psagPp (\ s a -> s{_psagPp = a})
126+
127+-- | OAuth access token.
128+psagAccessToken :: Lens' ProjectsServiceAccountsGet (Maybe Text)
129+psagAccessToken
130+ = lens _psagAccessToken
131+ (\ s a -> s{_psagAccessToken = a})
132+
133+-- | Legacy upload protocol for media (e.g. \"media\", \"multipart\").
134+psagUploadType :: Lens' ProjectsServiceAccountsGet (Maybe Text)
135+psagUploadType
136+ = lens _psagUploadType
137+ (\ s a -> s{_psagUploadType = a})
138+
139+-- | OAuth bearer token.
140+psagBearerToken :: Lens' ProjectsServiceAccountsGet (Maybe Text)
141+psagBearerToken
142+ = lens _psagBearerToken
143+ (\ s a -> s{_psagBearerToken = a})
144+
145+-- | The resource name of the service account in the following format:
146+-- \`projects\/{project}\/serviceAccounts\/{account}\`. Using \`-\` as a
147+-- wildcard for the project will infer the project from the account. The
148+-- \`account\` value can be the \`email\` address or the \`unique_id\` of
149+-- the service account.
150+psagName :: Lens' ProjectsServiceAccountsGet Text
151+psagName = lens _psagName (\ s a -> s{_psagName = a})
152+
153+-- | JSONP
154+psagCallback :: Lens' ProjectsServiceAccountsGet (Maybe Text)
155+psagCallback
156+ = lens _psagCallback (\ s a -> s{_psagCallback = a})
157+
158+instance GoogleRequest ProjectsServiceAccountsGet
159+ where
160+ type Rs ProjectsServiceAccountsGet = ServiceAccount
161+ type Scopes ProjectsServiceAccountsGet =
162+ '["https://www.googleapis.com/auth/cloud-platform"]
163+ requestClient ProjectsServiceAccountsGet'{..}
164+ = go _psagName _psagXgafv _psagUploadProtocol
165+ (Just _psagPp)
166+ _psagAccessToken
167+ _psagUploadType
168+ _psagBearerToken
169+ _psagCallback
170+ (Just AltJSON)
171+ iAMService
172+ where go
173+ = buildClient
174+ (Proxy :: Proxy ProjectsServiceAccountsGetResource)
175+ mempty
gogol-iam/gen/Network/Google/Resource/IAM/Projects/ServiceAccounts/GetIAMPolicy.hsnew file+178
@@ -0,0 +1,178 @@
1+{-# LANGUAGE DataKinds #-}
2+{-# LANGUAGE DeriveDataTypeable #-}
3+{-# LANGUAGE DeriveGeneric #-}
4+{-# LANGUAGE FlexibleInstances #-}
5+{-# LANGUAGE NoImplicitPrelude #-}
6+{-# LANGUAGE OverloadedStrings #-}
7+{-# LANGUAGE RecordWildCards #-}
8+{-# LANGUAGE TypeFamilies #-}
9+{-# LANGUAGE TypeOperators #-}
10+
11+{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
12+{-# OPTIONS_GHC -fno-warn-unused-binds #-}
13+{-# OPTIONS_GHC -fno-warn-unused-imports #-}
14+
15+-- |
16+-- Module : Network.Google.Resource.IAM.Projects.ServiceAccounts.GetIAMPolicy
17+-- Copyright : (c) 2015-2016 Brendan Hay
18+-- License : Mozilla Public License, v. 2.0.
19+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>
20+-- Stability : auto-generated
21+-- Portability : non-portable (GHC extensions)
22+--
23+-- Returns the IAM access control policy for a ServiceAccount.
24+--
25+-- /See:/ <https://cloud.google.com/iam/ Google Identity and Access Management (IAM) API Reference> for @iam.projects.serviceAccounts.getIamPolicy@.
26+module Network.Google.Resource.IAM.Projects.ServiceAccounts.GetIAMPolicy
27+ (
28+ -- * REST Resource
29+ ProjectsServiceAccountsGetIAMPolicyResource
30+
31+ -- * Creating a Request
32+ , projectsServiceAccountsGetIAMPolicy
33+ , ProjectsServiceAccountsGetIAMPolicy
34+
35+ -- * Request Lenses
36+ , psagipXgafv
37+ , psagipUploadProtocol
38+ , psagipPp
39+ , psagipAccessToken
40+ , psagipUploadType
41+ , psagipBearerToken
42+ , psagipResource
43+ , psagipCallback
44+ ) where
45+
46+import Network.Google.IAM.Types
47+import Network.Google.Prelude
48+
49+-- | A resource alias for @iam.projects.serviceAccounts.getIamPolicy@ method which the
50+-- 'ProjectsServiceAccountsGetIAMPolicy' request conforms to.
51+type ProjectsServiceAccountsGetIAMPolicyResource =
52+ "v1" :>
53+ CaptureMode "resource" "getIamPolicy" Text :>
54+ QueryParam "$.xgafv" Text :>
55+ QueryParam "upload_protocol" Text :>
56+ QueryParam "pp" Bool :>
57+ QueryParam "access_token" Text :>
58+ QueryParam "uploadType" Text :>
59+ QueryParam "bearer_token" Text :>
60+ QueryParam "callback" Text :>
61+ QueryParam "alt" AltJSON :> Post '[JSON] Policy
62+
63+-- | Returns the IAM access control policy for a ServiceAccount.
64+--
65+-- /See:/ 'projectsServiceAccountsGetIAMPolicy' smart constructor.
66+data ProjectsServiceAccountsGetIAMPolicy = ProjectsServiceAccountsGetIAMPolicy'
67+ { _psagipXgafv :: !(Maybe Text)
68+ , _psagipUploadProtocol :: !(Maybe Text)
69+ , _psagipPp :: !Bool
70+ , _psagipAccessToken :: !(Maybe Text)
71+ , _psagipUploadType :: !(Maybe Text)
72+ , _psagipBearerToken :: !(Maybe Text)
73+ , _psagipResource :: !Text
74+ , _psagipCallback :: !(Maybe Text)
75+ } deriving (Eq,Show,Data,Typeable,Generic)
76+
77+-- | Creates a value of 'ProjectsServiceAccountsGetIAMPolicy' with the minimum fields required to make a request.
78+--
79+-- Use one of the following lenses to modify other fields as desired:
80+--
81+-- * 'psagipXgafv'
82+--
83+-- * 'psagipUploadProtocol'
84+--
85+-- * 'psagipPp'
86+--
87+-- * 'psagipAccessToken'
88+--
89+-- * 'psagipUploadType'
90+--
91+-- * 'psagipBearerToken'
92+--
93+-- * 'psagipResource'
94+--
95+-- * 'psagipCallback'
96+projectsServiceAccountsGetIAMPolicy
97+ :: Text -- ^ 'psagipResource'
98+ -> ProjectsServiceAccountsGetIAMPolicy
99+projectsServiceAccountsGetIAMPolicy pPsagipResource_ =
100+ ProjectsServiceAccountsGetIAMPolicy'
101+ { _psagipXgafv = Nothing
102+ , _psagipUploadProtocol = Nothing
103+ , _psagipPp = True
104+ , _psagipAccessToken = Nothing
105+ , _psagipUploadType = Nothing
106+ , _psagipBearerToken = Nothing
107+ , _psagipResource = pPsagipResource_
108+ , _psagipCallback = Nothing
109+ }
110+
111+-- | V1 error format.
112+psagipXgafv :: Lens' ProjectsServiceAccountsGetIAMPolicy (Maybe Text)
113+psagipXgafv
114+ = lens _psagipXgafv (\ s a -> s{_psagipXgafv = a})
115+
116+-- | Upload protocol for media (e.g. \"raw\", \"multipart\").
117+psagipUploadProtocol :: Lens' ProjectsServiceAccountsGetIAMPolicy (Maybe Text)
118+psagipUploadProtocol
119+ = lens _psagipUploadProtocol
120+ (\ s a -> s{_psagipUploadProtocol = a})
121+
122+-- | Pretty-print response.
123+psagipPp :: Lens' ProjectsServiceAccountsGetIAMPolicy Bool
124+psagipPp = lens _psagipPp (\ s a -> s{_psagipPp = a})
125+
126+-- | OAuth access token.
127+psagipAccessToken :: Lens' ProjectsServiceAccountsGetIAMPolicy (Maybe Text)
128+psagipAccessToken
129+ = lens _psagipAccessToken
130+ (\ s a -> s{_psagipAccessToken = a})
131+
132+-- | Legacy upload protocol for media (e.g. \"media\", \"multipart\").
133+psagipUploadType :: Lens' ProjectsServiceAccountsGetIAMPolicy (Maybe Text)
134+psagipUploadType
135+ = lens _psagipUploadType
136+ (\ s a -> s{_psagipUploadType = a})
137+
138+-- | OAuth bearer token.
139+psagipBearerToken :: Lens' ProjectsServiceAccountsGetIAMPolicy (Maybe Text)
140+psagipBearerToken
141+ = lens _psagipBearerToken
142+ (\ s a -> s{_psagipBearerToken = a})
143+
144+-- | REQUIRED: The resource for which the policy is being requested.
145+-- \`resource\` is usually specified as a path. For example, a Project
146+-- resource is specified as \`projects\/{project}\`.
147+psagipResource :: Lens' ProjectsServiceAccountsGetIAMPolicy Text
148+psagipResource
149+ = lens _psagipResource
150+ (\ s a -> s{_psagipResource = a})
151+
152+-- | JSONP
153+psagipCallback :: Lens' ProjectsServiceAccountsGetIAMPolicy (Maybe Text)
154+psagipCallback
155+ = lens _psagipCallback
156+ (\ s a -> s{_psagipCallback = a})
157+
158+instance GoogleRequest
159+ ProjectsServiceAccountsGetIAMPolicy where
160+ type Rs ProjectsServiceAccountsGetIAMPolicy = Policy
161+ type Scopes ProjectsServiceAccountsGetIAMPolicy =
162+ '["https://www.googleapis.com/auth/cloud-platform"]
163+ requestClient
164+ ProjectsServiceAccountsGetIAMPolicy'{..}
165+ = go _psagipResource _psagipXgafv
166+ _psagipUploadProtocol
167+ (Just _psagipPp)
168+ _psagipAccessToken
169+ _psagipUploadType
170+ _psagipBearerToken
171+ _psagipCallback
172+ (Just AltJSON)
173+ iAMService
174+ where go
175+ = buildClient
176+ (Proxy ::
177+ Proxy ProjectsServiceAccountsGetIAMPolicyResource)
178+ mempty
gogol-iam/gen/Network/Google/Resource/IAM/Projects/ServiceAccounts/Keys/Create.hsnew file+193
@@ -0,0 +1,193 @@
1+{-# LANGUAGE DataKinds #-}
2+{-# LANGUAGE DeriveDataTypeable #-}
3+{-# LANGUAGE DeriveGeneric #-}
4+{-# LANGUAGE FlexibleInstances #-}
5+{-# LANGUAGE NoImplicitPrelude #-}
6+{-# LANGUAGE OverloadedStrings #-}
7+{-# LANGUAGE RecordWildCards #-}
8+{-# LANGUAGE TypeFamilies #-}
9+{-# LANGUAGE TypeOperators #-}
10+
11+{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
12+{-# OPTIONS_GHC -fno-warn-unused-binds #-}
13+{-# OPTIONS_GHC -fno-warn-unused-imports #-}
14+
15+-- |
16+-- Module : Network.Google.Resource.IAM.Projects.ServiceAccounts.Keys.Create
17+-- Copyright : (c) 2015-2016 Brendan Hay
18+-- License : Mozilla Public License, v. 2.0.
19+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>
20+-- Stability : auto-generated
21+-- Portability : non-portable (GHC extensions)
22+--
23+-- Creates a ServiceAccountKey and returns it.
24+--
25+-- /See:/ <https://cloud.google.com/iam/ Google Identity and Access Management (IAM) API Reference> for @iam.projects.serviceAccounts.keys.create@.
26+module Network.Google.Resource.IAM.Projects.ServiceAccounts.Keys.Create
27+ (
28+ -- * REST Resource
29+ ProjectsServiceAccountsKeysCreateResource
30+
31+ -- * Creating a Request
32+ , projectsServiceAccountsKeysCreate
33+ , ProjectsServiceAccountsKeysCreate
34+
35+ -- * Request Lenses
36+ , psakcXgafv
37+ , psakcUploadProtocol
38+ , psakcPp
39+ , psakcAccessToken
40+ , psakcUploadType
41+ , psakcPayload
42+ , psakcBearerToken
43+ , psakcName
44+ , psakcCallback
45+ ) where
46+
47+import Network.Google.IAM.Types
48+import Network.Google.Prelude
49+
50+-- | A resource alias for @iam.projects.serviceAccounts.keys.create@ method which the
51+-- 'ProjectsServiceAccountsKeysCreate' request conforms to.
52+type ProjectsServiceAccountsKeysCreateResource =
53+ "v1" :>
54+ Capture "name" Text :>
55+ "keys" :>
56+ QueryParam "$.xgafv" Text :>
57+ QueryParam "upload_protocol" Text :>
58+ QueryParam "pp" Bool :>
59+ QueryParam "access_token" Text :>
60+ QueryParam "uploadType" Text :>
61+ QueryParam "bearer_token" Text :>
62+ QueryParam "callback" Text :>
63+ QueryParam "alt" AltJSON :>
64+ ReqBody '[JSON] CreateServiceAccountKeyRequest :>
65+ Post '[JSON] ServiceAccountKey
66+
67+-- | Creates a ServiceAccountKey and returns it.
68+--
69+-- /See:/ 'projectsServiceAccountsKeysCreate' smart constructor.
70+data ProjectsServiceAccountsKeysCreate = ProjectsServiceAccountsKeysCreate'
71+ { _psakcXgafv :: !(Maybe Text)
72+ , _psakcUploadProtocol :: !(Maybe Text)
73+ , _psakcPp :: !Bool
74+ , _psakcAccessToken :: !(Maybe Text)
75+ , _psakcUploadType :: !(Maybe Text)
76+ , _psakcPayload :: !CreateServiceAccountKeyRequest
77+ , _psakcBearerToken :: !(Maybe Text)
78+ , _psakcName :: !Text
79+ , _psakcCallback :: !(Maybe Text)
80+ } deriving (Eq,Show,Data,Typeable,Generic)
81+
82+-- | Creates a value of 'ProjectsServiceAccountsKeysCreate' with the minimum fields required to make a request.
83+--
84+-- Use one of the following lenses to modify other fields as desired:
85+--
86+-- * 'psakcXgafv'
87+--
88+-- * 'psakcUploadProtocol'
89+--
90+-- * 'psakcPp'
91+--
92+-- * 'psakcAccessToken'
93+--
94+-- * 'psakcUploadType'
95+--
96+-- * 'psakcPayload'
97+--
98+-- * 'psakcBearerToken'
99+--
100+-- * 'psakcName'
101+--
102+-- * 'psakcCallback'
103+projectsServiceAccountsKeysCreate
104+ :: CreateServiceAccountKeyRequest -- ^ 'psakcPayload'
105+ -> Text -- ^ 'psakcName'
106+ -> ProjectsServiceAccountsKeysCreate
107+projectsServiceAccountsKeysCreate pPsakcPayload_ pPsakcName_ =
108+ ProjectsServiceAccountsKeysCreate'
109+ { _psakcXgafv = Nothing
110+ , _psakcUploadProtocol = Nothing
111+ , _psakcPp = True
112+ , _psakcAccessToken = Nothing
113+ , _psakcUploadType = Nothing
114+ , _psakcPayload = pPsakcPayload_
115+ , _psakcBearerToken = Nothing
116+ , _psakcName = pPsakcName_
117+ , _psakcCallback = Nothing
118+ }
119+
120+-- | V1 error format.
121+psakcXgafv :: Lens' ProjectsServiceAccountsKeysCreate (Maybe Text)
122+psakcXgafv
123+ = lens _psakcXgafv (\ s a -> s{_psakcXgafv = a})
124+
125+-- | Upload protocol for media (e.g. \"raw\", \"multipart\").
126+psakcUploadProtocol :: Lens' ProjectsServiceAccountsKeysCreate (Maybe Text)
127+psakcUploadProtocol
128+ = lens _psakcUploadProtocol
129+ (\ s a -> s{_psakcUploadProtocol = a})
130+
131+-- | Pretty-print response.
132+psakcPp :: Lens' ProjectsServiceAccountsKeysCreate Bool
133+psakcPp = lens _psakcPp (\ s a -> s{_psakcPp = a})
134+
135+-- | OAuth access token.
136+psakcAccessToken :: Lens' ProjectsServiceAccountsKeysCreate (Maybe Text)
137+psakcAccessToken
138+ = lens _psakcAccessToken
139+ (\ s a -> s{_psakcAccessToken = a})
140+
141+-- | Legacy upload protocol for media (e.g. \"media\", \"multipart\").
142+psakcUploadType :: Lens' ProjectsServiceAccountsKeysCreate (Maybe Text)
143+psakcUploadType
144+ = lens _psakcUploadType
145+ (\ s a -> s{_psakcUploadType = a})
146+
147+-- | Multipart request metadata.
148+psakcPayload :: Lens' ProjectsServiceAccountsKeysCreate CreateServiceAccountKeyRequest
149+psakcPayload
150+ = lens _psakcPayload (\ s a -> s{_psakcPayload = a})
151+
152+-- | OAuth bearer token.
153+psakcBearerToken :: Lens' ProjectsServiceAccountsKeysCreate (Maybe Text)
154+psakcBearerToken
155+ = lens _psakcBearerToken
156+ (\ s a -> s{_psakcBearerToken = a})
157+
158+-- | The resource name of the service account in the following format:
159+-- \`projects\/{project}\/serviceAccounts\/{account}\`. Using \`-\` as a
160+-- wildcard for the project will infer the project from the account. The
161+-- \`account\` value can be the \`email\` address or the \`unique_id\` of
162+-- the service account.
163+psakcName :: Lens' ProjectsServiceAccountsKeysCreate Text
164+psakcName
165+ = lens _psakcName (\ s a -> s{_psakcName = a})
166+
167+-- | JSONP
168+psakcCallback :: Lens' ProjectsServiceAccountsKeysCreate (Maybe Text)
169+psakcCallback
170+ = lens _psakcCallback
171+ (\ s a -> s{_psakcCallback = a})
172+
173+instance GoogleRequest
174+ ProjectsServiceAccountsKeysCreate where
175+ type Rs ProjectsServiceAccountsKeysCreate =
176+ ServiceAccountKey
177+ type Scopes ProjectsServiceAccountsKeysCreate =
178+ '["https://www.googleapis.com/auth/cloud-platform"]
179+ requestClient ProjectsServiceAccountsKeysCreate'{..}
180+ = go _psakcName _psakcXgafv _psakcUploadProtocol
181+ (Just _psakcPp)
182+ _psakcAccessToken
183+ _psakcUploadType
184+ _psakcBearerToken
185+ _psakcCallback
186+ (Just AltJSON)
187+ _psakcPayload
188+ iAMService
189+ where go
190+ = buildClient
191+ (Proxy ::
192+ Proxy ProjectsServiceAccountsKeysCreateResource)
193+ mempty
gogol-iam/gen/Network/Google/Resource/IAM/Projects/ServiceAccounts/Keys/Delete.hsnew file+177
@@ -0,0 +1,177 @@
1+{-# LANGUAGE DataKinds #-}
2+{-# LANGUAGE DeriveDataTypeable #-}
3+{-# LANGUAGE DeriveGeneric #-}
4+{-# LANGUAGE FlexibleInstances #-}
5+{-# LANGUAGE NoImplicitPrelude #-}
6+{-# LANGUAGE OverloadedStrings #-}
7+{-# LANGUAGE RecordWildCards #-}
8+{-# LANGUAGE TypeFamilies #-}
9+{-# LANGUAGE TypeOperators #-}
10+
11+{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
12+{-# OPTIONS_GHC -fno-warn-unused-binds #-}
13+{-# OPTIONS_GHC -fno-warn-unused-imports #-}
14+
15+-- |
16+-- Module : Network.Google.Resource.IAM.Projects.ServiceAccounts.Keys.Delete
17+-- Copyright : (c) 2015-2016 Brendan Hay
18+-- License : Mozilla Public License, v. 2.0.
19+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>
20+-- Stability : auto-generated
21+-- Portability : non-portable (GHC extensions)
22+--
23+-- Deletes a ServiceAccountKey.
24+--
25+-- /See:/ <https://cloud.google.com/iam/ Google Identity and Access Management (IAM) API Reference> for @iam.projects.serviceAccounts.keys.delete@.
26+module Network.Google.Resource.IAM.Projects.ServiceAccounts.Keys.Delete
27+ (
28+ -- * REST Resource
29+ ProjectsServiceAccountsKeysDeleteResource
30+
31+ -- * Creating a Request
32+ , projectsServiceAccountsKeysDelete
33+ , ProjectsServiceAccountsKeysDelete
34+
35+ -- * Request Lenses
36+ , psakdXgafv
37+ , psakdUploadProtocol
38+ , psakdPp
39+ , psakdAccessToken
40+ , psakdUploadType
41+ , psakdBearerToken
42+ , psakdName
43+ , psakdCallback
44+ ) where
45+
46+import Network.Google.IAM.Types
47+import Network.Google.Prelude
48+
49+-- | A resource alias for @iam.projects.serviceAccounts.keys.delete@ method which the
50+-- 'ProjectsServiceAccountsKeysDelete' request conforms to.
51+type ProjectsServiceAccountsKeysDeleteResource =
52+ "v1" :>
53+ Capture "name" Text :>
54+ QueryParam "$.xgafv" Text :>
55+ QueryParam "upload_protocol" Text :>
56+ QueryParam "pp" Bool :>
57+ QueryParam "access_token" Text :>
58+ QueryParam "uploadType" Text :>
59+ QueryParam "bearer_token" Text :>
60+ QueryParam "callback" Text :>
61+ QueryParam "alt" AltJSON :> Delete '[JSON] Empty
62+
63+-- | Deletes a ServiceAccountKey.
64+--
65+-- /See:/ 'projectsServiceAccountsKeysDelete' smart constructor.
66+data ProjectsServiceAccountsKeysDelete = ProjectsServiceAccountsKeysDelete'
67+ { _psakdXgafv :: !(Maybe Text)
68+ , _psakdUploadProtocol :: !(Maybe Text)
69+ , _psakdPp :: !Bool
70+ , _psakdAccessToken :: !(Maybe Text)
71+ , _psakdUploadType :: !(Maybe Text)
72+ , _psakdBearerToken :: !(Maybe Text)
73+ , _psakdName :: !Text
74+ , _psakdCallback :: !(Maybe Text)
75+ } deriving (Eq,Show,Data,Typeable,Generic)
76+
77+-- | Creates a value of 'ProjectsServiceAccountsKeysDelete' with the minimum fields required to make a request.
78+--
79+-- Use one of the following lenses to modify other fields as desired:
80+--
81+-- * 'psakdXgafv'
82+--
83+-- * 'psakdUploadProtocol'
84+--
85+-- * 'psakdPp'
86+--
87+-- * 'psakdAccessToken'
88+--
89+-- * 'psakdUploadType'
90+--
91+-- * 'psakdBearerToken'
92+--
93+-- * 'psakdName'
94+--
95+-- * 'psakdCallback'
96+projectsServiceAccountsKeysDelete
97+ :: Text -- ^ 'psakdName'
98+ -> ProjectsServiceAccountsKeysDelete
99+projectsServiceAccountsKeysDelete pPsakdName_ =
100+ ProjectsServiceAccountsKeysDelete'
101+ { _psakdXgafv = Nothing
102+ , _psakdUploadProtocol = Nothing
103+ , _psakdPp = True
104+ , _psakdAccessToken = Nothing
105+ , _psakdUploadType = Nothing
106+ , _psakdBearerToken = Nothing
107+ , _psakdName = pPsakdName_
108+ , _psakdCallback = Nothing
109+ }
110+
111+-- | V1 error format.
112+psakdXgafv :: Lens' ProjectsServiceAccountsKeysDelete (Maybe Text)
113+psakdXgafv
114+ = lens _psakdXgafv (\ s a -> s{_psakdXgafv = a})
115+
116+-- | Upload protocol for media (e.g. \"raw\", \"multipart\").
117+psakdUploadProtocol :: Lens' ProjectsServiceAccountsKeysDelete (Maybe Text)
118+psakdUploadProtocol
119+ = lens _psakdUploadProtocol
120+ (\ s a -> s{_psakdUploadProtocol = a})
121+
122+-- | Pretty-print response.
123+psakdPp :: Lens' ProjectsServiceAccountsKeysDelete Bool
124+psakdPp = lens _psakdPp (\ s a -> s{_psakdPp = a})
125+
126+-- | OAuth access token.
127+psakdAccessToken :: Lens' ProjectsServiceAccountsKeysDelete (Maybe Text)
128+psakdAccessToken
129+ = lens _psakdAccessToken
130+ (\ s a -> s{_psakdAccessToken = a})
131+
132+-- | Legacy upload protocol for media (e.g. \"media\", \"multipart\").
133+psakdUploadType :: Lens' ProjectsServiceAccountsKeysDelete (Maybe Text)
134+psakdUploadType
135+ = lens _psakdUploadType
136+ (\ s a -> s{_psakdUploadType = a})
137+
138+-- | OAuth bearer token.
139+psakdBearerToken :: Lens' ProjectsServiceAccountsKeysDelete (Maybe Text)
140+psakdBearerToken
141+ = lens _psakdBearerToken
142+ (\ s a -> s{_psakdBearerToken = a})
143+
144+-- | The resource name of the service account key in the following format:
145+-- \`projects\/{project}\/serviceAccounts\/{account}\/keys\/{key}\`. Using
146+-- \`-\` as a wildcard for the project will infer the project from the
147+-- account. The \`account\` value can be the \`email\` address or the
148+-- \`unique_id\` of the service account.
149+psakdName :: Lens' ProjectsServiceAccountsKeysDelete Text
150+psakdName
151+ = lens _psakdName (\ s a -> s{_psakdName = a})
152+
153+-- | JSONP
154+psakdCallback :: Lens' ProjectsServiceAccountsKeysDelete (Maybe Text)
155+psakdCallback
156+ = lens _psakdCallback
157+ (\ s a -> s{_psakdCallback = a})
158+
159+instance GoogleRequest
160+ ProjectsServiceAccountsKeysDelete where
161+ type Rs ProjectsServiceAccountsKeysDelete = Empty
162+ type Scopes ProjectsServiceAccountsKeysDelete =
163+ '["https://www.googleapis.com/auth/cloud-platform"]
164+ requestClient ProjectsServiceAccountsKeysDelete'{..}
165+ = go _psakdName _psakdXgafv _psakdUploadProtocol
166+ (Just _psakdPp)
167+ _psakdAccessToken
168+ _psakdUploadType
169+ _psakdBearerToken
170+ _psakdCallback
171+ (Just AltJSON)
172+ iAMService
173+ where go
174+ = buildClient
175+ (Proxy ::
176+ Proxy ProjectsServiceAccountsKeysDeleteResource)
177+ mempty
gogol-iam/gen/Network/Google/Resource/IAM/Projects/ServiceAccounts/Keys/Get.hsnew file+193
@@ -0,0 +1,193 @@
1+{-# LANGUAGE DataKinds #-}
2+{-# LANGUAGE DeriveDataTypeable #-}
3+{-# LANGUAGE DeriveGeneric #-}
4+{-# LANGUAGE FlexibleInstances #-}
5+{-# LANGUAGE NoImplicitPrelude #-}
6+{-# LANGUAGE OverloadedStrings #-}
7+{-# LANGUAGE RecordWildCards #-}
8+{-# LANGUAGE TypeFamilies #-}
9+{-# LANGUAGE TypeOperators #-}
10+
11+{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
12+{-# OPTIONS_GHC -fno-warn-unused-binds #-}
13+{-# OPTIONS_GHC -fno-warn-unused-imports #-}
14+
15+-- |
16+-- Module : Network.Google.Resource.IAM.Projects.ServiceAccounts.Keys.Get
17+-- Copyright : (c) 2015-2016 Brendan Hay
18+-- License : Mozilla Public License, v. 2.0.
19+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>
20+-- Stability : auto-generated
21+-- Portability : non-portable (GHC extensions)
22+--
23+-- Gets the ServiceAccountKey by key id.
24+--
25+-- /See:/ <https://cloud.google.com/iam/ Google Identity and Access Management (IAM) API Reference> for @iam.projects.serviceAccounts.keys.get@.
26+module Network.Google.Resource.IAM.Projects.ServiceAccounts.Keys.Get
27+ (
28+ -- * REST Resource
29+ ProjectsServiceAccountsKeysGetResource
30+
31+ -- * Creating a Request
32+ , projectsServiceAccountsKeysGet
33+ , ProjectsServiceAccountsKeysGet
34+
35+ -- * Request Lenses
36+ , psakgXgafv
37+ , psakgUploadProtocol
38+ , psakgPp
39+ , psakgAccessToken
40+ , psakgUploadType
41+ , psakgBearerToken
42+ , psakgName
43+ , psakgPublicKeyType
44+ , psakgCallback
45+ ) where
46+
47+import Network.Google.IAM.Types
48+import Network.Google.Prelude
49+
50+-- | A resource alias for @iam.projects.serviceAccounts.keys.get@ method which the
51+-- 'ProjectsServiceAccountsKeysGet' request conforms to.
52+type ProjectsServiceAccountsKeysGetResource =
53+ "v1" :>
54+ Capture "name" Text :>
55+ QueryParam "$.xgafv" Text :>
56+ QueryParam "upload_protocol" Text :>
57+ QueryParam "pp" Bool :>
58+ QueryParam "access_token" Text :>
59+ QueryParam "uploadType" Text :>
60+ QueryParam "bearer_token" Text :>
61+ QueryParam "publicKeyType" Text :>
62+ QueryParam "callback" Text :>
63+ QueryParam "alt" AltJSON :>
64+ Get '[JSON] ServiceAccountKey
65+
66+-- | Gets the ServiceAccountKey by key id.
67+--
68+-- /See:/ 'projectsServiceAccountsKeysGet' smart constructor.
69+data ProjectsServiceAccountsKeysGet = ProjectsServiceAccountsKeysGet'
70+ { _psakgXgafv :: !(Maybe Text)
71+ , _psakgUploadProtocol :: !(Maybe Text)
72+ , _psakgPp :: !Bool
73+ , _psakgAccessToken :: !(Maybe Text)
74+ , _psakgUploadType :: !(Maybe Text)
75+ , _psakgBearerToken :: !(Maybe Text)
76+ , _psakgName :: !Text
77+ , _psakgPublicKeyType :: !(Maybe Text)
78+ , _psakgCallback :: !(Maybe Text)
79+ } deriving (Eq,Show,Data,Typeable,Generic)
80+
81+-- | Creates a value of 'ProjectsServiceAccountsKeysGet' with the minimum fields required to make a request.
82+--
83+-- Use one of the following lenses to modify other fields as desired:
84+--
85+-- * 'psakgXgafv'
86+--
87+-- * 'psakgUploadProtocol'
88+--
89+-- * 'psakgPp'
90+--
91+-- * 'psakgAccessToken'
92+--
93+-- * 'psakgUploadType'
94+--
95+-- * 'psakgBearerToken'
96+--
97+-- * 'psakgName'
98+--
99+-- * 'psakgPublicKeyType'
100+--
101+-- * 'psakgCallback'
102+projectsServiceAccountsKeysGet
103+ :: Text -- ^ 'psakgName'
104+ -> ProjectsServiceAccountsKeysGet
105+projectsServiceAccountsKeysGet pPsakgName_ =
106+ ProjectsServiceAccountsKeysGet'
107+ { _psakgXgafv = Nothing
108+ , _psakgUploadProtocol = Nothing
109+ , _psakgPp = True
110+ , _psakgAccessToken = Nothing
111+ , _psakgUploadType = Nothing
112+ , _psakgBearerToken = Nothing
113+ , _psakgName = pPsakgName_
114+ , _psakgPublicKeyType = Nothing
115+ , _psakgCallback = Nothing
116+ }
117+
118+-- | V1 error format.
119+psakgXgafv :: Lens' ProjectsServiceAccountsKeysGet (Maybe Text)
120+psakgXgafv
121+ = lens _psakgXgafv (\ s a -> s{_psakgXgafv = a})
122+
123+-- | Upload protocol for media (e.g. \"raw\", \"multipart\").
124+psakgUploadProtocol :: Lens' ProjectsServiceAccountsKeysGet (Maybe Text)
125+psakgUploadProtocol
126+ = lens _psakgUploadProtocol
127+ (\ s a -> s{_psakgUploadProtocol = a})
128+
129+-- | Pretty-print response.
130+psakgPp :: Lens' ProjectsServiceAccountsKeysGet Bool
131+psakgPp = lens _psakgPp (\ s a -> s{_psakgPp = a})
132+
133+-- | OAuth access token.
134+psakgAccessToken :: Lens' ProjectsServiceAccountsKeysGet (Maybe Text)
135+psakgAccessToken
136+ = lens _psakgAccessToken
137+ (\ s a -> s{_psakgAccessToken = a})
138+
139+-- | Legacy upload protocol for media (e.g. \"media\", \"multipart\").
140+psakgUploadType :: Lens' ProjectsServiceAccountsKeysGet (Maybe Text)
141+psakgUploadType
142+ = lens _psakgUploadType
143+ (\ s a -> s{_psakgUploadType = a})
144+
145+-- | OAuth bearer token.
146+psakgBearerToken :: Lens' ProjectsServiceAccountsKeysGet (Maybe Text)
147+psakgBearerToken
148+ = lens _psakgBearerToken
149+ (\ s a -> s{_psakgBearerToken = a})
150+
151+-- | The resource name of the service account key in the following format:
152+-- \`projects\/{project}\/serviceAccounts\/{account}\/keys\/{key}\`. Using
153+-- \`-\` as a wildcard for the project will infer the project from the
154+-- account. The \`account\` value can be the \`email\` address or the
155+-- \`unique_id\` of the service account.
156+psakgName :: Lens' ProjectsServiceAccountsKeysGet Text
157+psakgName
158+ = lens _psakgName (\ s a -> s{_psakgName = a})
159+
160+-- | The output format of the public key requested. X509_PEM is the default
161+-- output format.
162+psakgPublicKeyType :: Lens' ProjectsServiceAccountsKeysGet (Maybe Text)
163+psakgPublicKeyType
164+ = lens _psakgPublicKeyType
165+ (\ s a -> s{_psakgPublicKeyType = a})
166+
167+-- | JSONP
168+psakgCallback :: Lens' ProjectsServiceAccountsKeysGet (Maybe Text)
169+psakgCallback
170+ = lens _psakgCallback
171+ (\ s a -> s{_psakgCallback = a})
172+
173+instance GoogleRequest ProjectsServiceAccountsKeysGet
174+ where
175+ type Rs ProjectsServiceAccountsKeysGet =
176+ ServiceAccountKey
177+ type Scopes ProjectsServiceAccountsKeysGet =
178+ '["https://www.googleapis.com/auth/cloud-platform"]
179+ requestClient ProjectsServiceAccountsKeysGet'{..}
180+ = go _psakgName _psakgXgafv _psakgUploadProtocol
181+ (Just _psakgPp)
182+ _psakgAccessToken
183+ _psakgUploadType
184+ _psakgBearerToken
185+ _psakgPublicKeyType
186+ _psakgCallback
187+ (Just AltJSON)
188+ iAMService
189+ where go
190+ = buildClient
191+ (Proxy ::
192+ Proxy ProjectsServiceAccountsKeysGetResource)
193+ mempty
gogol-iam/gen/Network/Google/Resource/IAM/Projects/ServiceAccounts/Keys/List.hsnew file+198
@@ -0,0 +1,198 @@
1+{-# LANGUAGE DataKinds #-}
2+{-# LANGUAGE DeriveDataTypeable #-}
3+{-# LANGUAGE DeriveGeneric #-}
4+{-# LANGUAGE FlexibleInstances #-}
5+{-# LANGUAGE NoImplicitPrelude #-}
6+{-# LANGUAGE OverloadedStrings #-}
7+{-# LANGUAGE RecordWildCards #-}
8+{-# LANGUAGE TypeFamilies #-}
9+{-# LANGUAGE TypeOperators #-}
10+
11+{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
12+{-# OPTIONS_GHC -fno-warn-unused-binds #-}
13+{-# OPTIONS_GHC -fno-warn-unused-imports #-}
14+
15+-- |
16+-- Module : Network.Google.Resource.IAM.Projects.ServiceAccounts.Keys.List
17+-- Copyright : (c) 2015-2016 Brendan Hay
18+-- License : Mozilla Public License, v. 2.0.
19+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>
20+-- Stability : auto-generated
21+-- Portability : non-portable (GHC extensions)
22+--
23+-- Lists ServiceAccountKeys.
24+--
25+-- /See:/ <https://cloud.google.com/iam/ Google Identity and Access Management (IAM) API Reference> for @iam.projects.serviceAccounts.keys.list@.
26+module Network.Google.Resource.IAM.Projects.ServiceAccounts.Keys.List
27+ (
28+ -- * REST Resource
29+ ProjectsServiceAccountsKeysListResource
30+
31+ -- * Creating a Request
32+ , projectsServiceAccountsKeysList
33+ , ProjectsServiceAccountsKeysList
34+
35+ -- * Request Lenses
36+ , psaklKeyTypes
37+ , psaklXgafv
38+ , psaklUploadProtocol
39+ , psaklPp
40+ , psaklAccessToken
41+ , psaklUploadType
42+ , psaklBearerToken
43+ , psaklName
44+ , psaklCallback
45+ ) where
46+
47+import Network.Google.IAM.Types
48+import Network.Google.Prelude
49+
50+-- | A resource alias for @iam.projects.serviceAccounts.keys.list@ method which the
51+-- 'ProjectsServiceAccountsKeysList' request conforms to.
52+type ProjectsServiceAccountsKeysListResource =
53+ "v1" :>
54+ Capture "name" Text :>
55+ "keys" :>
56+ QueryParams "keyTypes" Text :>
57+ QueryParam "$.xgafv" Text :>
58+ QueryParam "upload_protocol" Text :>
59+ QueryParam "pp" Bool :>
60+ QueryParam "access_token" Text :>
61+ QueryParam "uploadType" Text :>
62+ QueryParam "bearer_token" Text :>
63+ QueryParam "callback" Text :>
64+ QueryParam "alt" AltJSON :>
65+ Get '[JSON] ListServiceAccountKeysResponse
66+
67+-- | Lists ServiceAccountKeys.
68+--
69+-- /See:/ 'projectsServiceAccountsKeysList' smart constructor.
70+data ProjectsServiceAccountsKeysList = ProjectsServiceAccountsKeysList'
71+ { _psaklKeyTypes :: !(Maybe [Text])
72+ , _psaklXgafv :: !(Maybe Text)
73+ , _psaklUploadProtocol :: !(Maybe Text)
74+ , _psaklPp :: !Bool
75+ , _psaklAccessToken :: !(Maybe Text)
76+ , _psaklUploadType :: !(Maybe Text)
77+ , _psaklBearerToken :: !(Maybe Text)
78+ , _psaklName :: !Text
79+ , _psaklCallback :: !(Maybe Text)
80+ } deriving (Eq,Show,Data,Typeable,Generic)
81+
82+-- | Creates a value of 'ProjectsServiceAccountsKeysList' with the minimum fields required to make a request.
83+--
84+-- Use one of the following lenses to modify other fields as desired:
85+--
86+-- * 'psaklKeyTypes'
87+--
88+-- * 'psaklXgafv'
89+--
90+-- * 'psaklUploadProtocol'
91+--
92+-- * 'psaklPp'
93+--
94+-- * 'psaklAccessToken'
95+--
96+-- * 'psaklUploadType'
97+--
98+-- * 'psaklBearerToken'
99+--
100+-- * 'psaklName'
101+--
102+-- * 'psaklCallback'
103+projectsServiceAccountsKeysList
104+ :: Text -- ^ 'psaklName'
105+ -> ProjectsServiceAccountsKeysList
106+projectsServiceAccountsKeysList pPsaklName_ =
107+ ProjectsServiceAccountsKeysList'
108+ { _psaklKeyTypes = Nothing
109+ , _psaklXgafv = Nothing
110+ , _psaklUploadProtocol = Nothing
111+ , _psaklPp = True
112+ , _psaklAccessToken = Nothing
113+ , _psaklUploadType = Nothing
114+ , _psaklBearerToken = Nothing
115+ , _psaklName = pPsaklName_
116+ , _psaklCallback = Nothing
117+ }
118+
119+-- | Filters the types of keys the user wants to include in the list
120+-- response. Duplicate key types are not allowed. If no key type is
121+-- provided, all keys are returned.
122+psaklKeyTypes :: Lens' ProjectsServiceAccountsKeysList [Text]
123+psaklKeyTypes
124+ = lens _psaklKeyTypes
125+ (\ s a -> s{_psaklKeyTypes = a})
126+ . _Default
127+ . _Coerce
128+
129+-- | V1 error format.
130+psaklXgafv :: Lens' ProjectsServiceAccountsKeysList (Maybe Text)
131+psaklXgafv
132+ = lens _psaklXgafv (\ s a -> s{_psaklXgafv = a})
133+
134+-- | Upload protocol for media (e.g. \"raw\", \"multipart\").
135+psaklUploadProtocol :: Lens' ProjectsServiceAccountsKeysList (Maybe Text)
136+psaklUploadProtocol
137+ = lens _psaklUploadProtocol
138+ (\ s a -> s{_psaklUploadProtocol = a})
139+
140+-- | Pretty-print response.
141+psaklPp :: Lens' ProjectsServiceAccountsKeysList Bool
142+psaklPp = lens _psaklPp (\ s a -> s{_psaklPp = a})
143+
144+-- | OAuth access token.
145+psaklAccessToken :: Lens' ProjectsServiceAccountsKeysList (Maybe Text)
146+psaklAccessToken
147+ = lens _psaklAccessToken
148+ (\ s a -> s{_psaklAccessToken = a})
149+
150+-- | Legacy upload protocol for media (e.g. \"media\", \"multipart\").
151+psaklUploadType :: Lens' ProjectsServiceAccountsKeysList (Maybe Text)
152+psaklUploadType
153+ = lens _psaklUploadType
154+ (\ s a -> s{_psaklUploadType = a})
155+
156+-- | OAuth bearer token.
157+psaklBearerToken :: Lens' ProjectsServiceAccountsKeysList (Maybe Text)
158+psaklBearerToken
159+ = lens _psaklBearerToken
160+ (\ s a -> s{_psaklBearerToken = a})
161+
162+-- | The resource name of the service account in the following format:
163+-- \`projects\/{project}\/serviceAccounts\/{account}\`. Using \`-\` as a
164+-- wildcard for the project, will infer the project from the account. The
165+-- \`account\` value can be the \`email\` address or the \`unique_id\` of
166+-- the service account.
167+psaklName :: Lens' ProjectsServiceAccountsKeysList Text
168+psaklName
169+ = lens _psaklName (\ s a -> s{_psaklName = a})
170+
171+-- | JSONP
172+psaklCallback :: Lens' ProjectsServiceAccountsKeysList (Maybe Text)
173+psaklCallback
174+ = lens _psaklCallback
175+ (\ s a -> s{_psaklCallback = a})
176+
177+instance GoogleRequest
178+ ProjectsServiceAccountsKeysList where
179+ type Rs ProjectsServiceAccountsKeysList =
180+ ListServiceAccountKeysResponse
181+ type Scopes ProjectsServiceAccountsKeysList =
182+ '["https://www.googleapis.com/auth/cloud-platform"]
183+ requestClient ProjectsServiceAccountsKeysList'{..}
184+ = go _psaklName (_psaklKeyTypes ^. _Default)
185+ _psaklXgafv
186+ _psaklUploadProtocol
187+ (Just _psaklPp)
188+ _psaklAccessToken
189+ _psaklUploadType
190+ _psaklBearerToken
191+ _psaklCallback
192+ (Just AltJSON)
193+ iAMService
194+ where go
195+ = buildClient
196+ (Proxy ::
197+ Proxy ProjectsServiceAccountsKeysListResource)
198+ mempty
gogol-iam/gen/Network/Google/Resource/IAM/Projects/ServiceAccounts/List.hsnew file+203
@@ -0,0 +1,203 @@
1+{-# LANGUAGE DataKinds #-}
2+{-# LANGUAGE DeriveDataTypeable #-}
3+{-# LANGUAGE DeriveGeneric #-}
4+{-# LANGUAGE FlexibleInstances #-}
5+{-# LANGUAGE NoImplicitPrelude #-}
6+{-# LANGUAGE OverloadedStrings #-}
7+{-# LANGUAGE RecordWildCards #-}
8+{-# LANGUAGE TypeFamilies #-}
9+{-# LANGUAGE TypeOperators #-}
10+
11+{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
12+{-# OPTIONS_GHC -fno-warn-unused-binds #-}
13+{-# OPTIONS_GHC -fno-warn-unused-imports #-}
14+
15+-- |
16+-- Module : Network.Google.Resource.IAM.Projects.ServiceAccounts.List
17+-- Copyright : (c) 2015-2016 Brendan Hay
18+-- License : Mozilla Public License, v. 2.0.
19+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>
20+-- Stability : auto-generated
21+-- Portability : non-portable (GHC extensions)
22+--
23+-- Lists ServiceAccounts for a project.
24+--
25+-- /See:/ <https://cloud.google.com/iam/ Google Identity and Access Management (IAM) API Reference> for @iam.projects.serviceAccounts.list@.
26+module Network.Google.Resource.IAM.Projects.ServiceAccounts.List
27+ (
28+ -- * REST Resource
29+ ProjectsServiceAccountsListResource
30+
31+ -- * Creating a Request
32+ , projectsServiceAccountsList
33+ , ProjectsServiceAccountsList
34+
35+ -- * Request Lenses
36+ , psalXgafv
37+ , psalUploadProtocol
38+ , psalPp
39+ , psalAccessToken
40+ , psalUploadType
41+ , psalBearerToken
42+ , psalName
43+ , psalPageToken
44+ , psalPageSize
45+ , psalCallback
46+ ) where
47+
48+import Network.Google.IAM.Types
49+import Network.Google.Prelude
50+
51+-- | A resource alias for @iam.projects.serviceAccounts.list@ method which the
52+-- 'ProjectsServiceAccountsList' request conforms to.
53+type ProjectsServiceAccountsListResource =
54+ "v1" :>
55+ Capture "name" Text :>
56+ "serviceAccounts" :>
57+ QueryParam "$.xgafv" Text :>
58+ QueryParam "upload_protocol" Text :>
59+ QueryParam "pp" Bool :>
60+ QueryParam "access_token" Text :>
61+ QueryParam "uploadType" Text :>
62+ QueryParam "bearer_token" Text :>
63+ QueryParam "pageToken" Text :>
64+ QueryParam "pageSize" (Textual Int32) :>
65+ QueryParam "callback" Text :>
66+ QueryParam "alt" AltJSON :>
67+ Get '[JSON] ListServiceAccountsResponse
68+
69+-- | Lists ServiceAccounts for a project.
70+--
71+-- /See:/ 'projectsServiceAccountsList' smart constructor.
72+data ProjectsServiceAccountsList = ProjectsServiceAccountsList'
73+ { _psalXgafv :: !(Maybe Text)
74+ , _psalUploadProtocol :: !(Maybe Text)
75+ , _psalPp :: !Bool
76+ , _psalAccessToken :: !(Maybe Text)
77+ , _psalUploadType :: !(Maybe Text)
78+ , _psalBearerToken :: !(Maybe Text)
79+ , _psalName :: !Text
80+ , _psalPageToken :: !(Maybe Text)
81+ , _psalPageSize :: !(Maybe (Textual Int32))
82+ , _psalCallback :: !(Maybe Text)
83+ } deriving (Eq,Show,Data,Typeable,Generic)
84+
85+-- | Creates a value of 'ProjectsServiceAccountsList' with the minimum fields required to make a request.
86+--
87+-- Use one of the following lenses to modify other fields as desired:
88+--
89+-- * 'psalXgafv'
90+--
91+-- * 'psalUploadProtocol'
92+--
93+-- * 'psalPp'
94+--
95+-- * 'psalAccessToken'
96+--
97+-- * 'psalUploadType'
98+--
99+-- * 'psalBearerToken'
100+--
101+-- * 'psalName'
102+--
103+-- * 'psalPageToken'
104+--
105+-- * 'psalPageSize'
106+--
107+-- * 'psalCallback'
108+projectsServiceAccountsList
109+ :: Text -- ^ 'psalName'
110+ -> ProjectsServiceAccountsList
111+projectsServiceAccountsList pPsalName_ =
112+ ProjectsServiceAccountsList'
113+ { _psalXgafv = Nothing
114+ , _psalUploadProtocol = Nothing
115+ , _psalPp = True
116+ , _psalAccessToken = Nothing
117+ , _psalUploadType = Nothing
118+ , _psalBearerToken = Nothing
119+ , _psalName = pPsalName_
120+ , _psalPageToken = Nothing
121+ , _psalPageSize = Nothing
122+ , _psalCallback = Nothing
123+ }
124+
125+-- | V1 error format.
126+psalXgafv :: Lens' ProjectsServiceAccountsList (Maybe Text)
127+psalXgafv
128+ = lens _psalXgafv (\ s a -> s{_psalXgafv = a})
129+
130+-- | Upload protocol for media (e.g. \"raw\", \"multipart\").
131+psalUploadProtocol :: Lens' ProjectsServiceAccountsList (Maybe Text)
132+psalUploadProtocol
133+ = lens _psalUploadProtocol
134+ (\ s a -> s{_psalUploadProtocol = a})
135+
136+-- | Pretty-print response.
137+psalPp :: Lens' ProjectsServiceAccountsList Bool
138+psalPp = lens _psalPp (\ s a -> s{_psalPp = a})
139+
140+-- | OAuth access token.
141+psalAccessToken :: Lens' ProjectsServiceAccountsList (Maybe Text)
142+psalAccessToken
143+ = lens _psalAccessToken
144+ (\ s a -> s{_psalAccessToken = a})
145+
146+-- | Legacy upload protocol for media (e.g. \"media\", \"multipart\").
147+psalUploadType :: Lens' ProjectsServiceAccountsList (Maybe Text)
148+psalUploadType
149+ = lens _psalUploadType
150+ (\ s a -> s{_psalUploadType = a})
151+
152+-- | OAuth bearer token.
153+psalBearerToken :: Lens' ProjectsServiceAccountsList (Maybe Text)
154+psalBearerToken
155+ = lens _psalBearerToken
156+ (\ s a -> s{_psalBearerToken = a})
157+
158+-- | Required. The resource name of the project associated with the service
159+-- accounts, such as \`projects\/my-project-123\`.
160+psalName :: Lens' ProjectsServiceAccountsList Text
161+psalName = lens _psalName (\ s a -> s{_psalName = a})
162+
163+-- | Optional pagination token returned in an earlier
164+-- ListServiceAccountsResponse.next_page_token.
165+psalPageToken :: Lens' ProjectsServiceAccountsList (Maybe Text)
166+psalPageToken
167+ = lens _psalPageToken
168+ (\ s a -> s{_psalPageToken = a})
169+
170+-- | Optional limit on the number of service accounts to include in the
171+-- response. Further accounts can subsequently be obtained by including the
172+-- ListServiceAccountsResponse.next_page_token in a subsequent request.
173+psalPageSize :: Lens' ProjectsServiceAccountsList (Maybe Int32)
174+psalPageSize
175+ = lens _psalPageSize (\ s a -> s{_psalPageSize = a})
176+ . mapping _Coerce
177+
178+-- | JSONP
179+psalCallback :: Lens' ProjectsServiceAccountsList (Maybe Text)
180+psalCallback
181+ = lens _psalCallback (\ s a -> s{_psalCallback = a})
182+
183+instance GoogleRequest ProjectsServiceAccountsList
184+ where
185+ type Rs ProjectsServiceAccountsList =
186+ ListServiceAccountsResponse
187+ type Scopes ProjectsServiceAccountsList =
188+ '["https://www.googleapis.com/auth/cloud-platform"]
189+ requestClient ProjectsServiceAccountsList'{..}
190+ = go _psalName _psalXgafv _psalUploadProtocol
191+ (Just _psalPp)
192+ _psalAccessToken
193+ _psalUploadType
194+ _psalBearerToken
195+ _psalPageToken
196+ _psalPageSize
197+ _psalCallback
198+ (Just AltJSON)
199+ iAMService
200+ where go
201+ = buildClient
202+ (Proxy :: Proxy ProjectsServiceAccountsListResource)
203+ mempty
gogol-iam/gen/Network/Google/Resource/IAM/Projects/ServiceAccounts/SetIAMPolicy.hsnew file+193
@@ -0,0 +1,193 @@
1+{-# LANGUAGE DataKinds #-}
2+{-# LANGUAGE DeriveDataTypeable #-}
3+{-# LANGUAGE DeriveGeneric #-}
4+{-# LANGUAGE FlexibleInstances #-}
5+{-# LANGUAGE NoImplicitPrelude #-}
6+{-# LANGUAGE OverloadedStrings #-}
7+{-# LANGUAGE RecordWildCards #-}
8+{-# LANGUAGE TypeFamilies #-}
9+{-# LANGUAGE TypeOperators #-}
10+
11+{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
12+{-# OPTIONS_GHC -fno-warn-unused-binds #-}
13+{-# OPTIONS_GHC -fno-warn-unused-imports #-}
14+
15+-- |
16+-- Module : Network.Google.Resource.IAM.Projects.ServiceAccounts.SetIAMPolicy
17+-- Copyright : (c) 2015-2016 Brendan Hay
18+-- License : Mozilla Public License, v. 2.0.
19+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>
20+-- Stability : auto-generated
21+-- Portability : non-portable (GHC extensions)
22+--
23+-- Sets the IAM access control policy for a ServiceAccount.
24+--
25+-- /See:/ <https://cloud.google.com/iam/ Google Identity and Access Management (IAM) API Reference> for @iam.projects.serviceAccounts.setIamPolicy@.
26+module Network.Google.Resource.IAM.Projects.ServiceAccounts.SetIAMPolicy
27+ (
28+ -- * REST Resource
29+ ProjectsServiceAccountsSetIAMPolicyResource
30+
31+ -- * Creating a Request
32+ , projectsServiceAccountsSetIAMPolicy
33+ , ProjectsServiceAccountsSetIAMPolicy
34+
35+ -- * Request Lenses
36+ , psasipXgafv
37+ , psasipUploadProtocol
38+ , psasipPp
39+ , psasipAccessToken
40+ , psasipUploadType
41+ , psasipPayload
42+ , psasipBearerToken
43+ , psasipResource
44+ , psasipCallback
45+ ) where
46+
47+import Network.Google.IAM.Types
48+import Network.Google.Prelude
49+
50+-- | A resource alias for @iam.projects.serviceAccounts.setIamPolicy@ method which the
51+-- 'ProjectsServiceAccountsSetIAMPolicy' request conforms to.
52+type ProjectsServiceAccountsSetIAMPolicyResource =
53+ "v1" :>
54+ CaptureMode "resource" "setIamPolicy" Text :>
55+ QueryParam "$.xgafv" Text :>
56+ QueryParam "upload_protocol" Text :>
57+ QueryParam "pp" Bool :>
58+ QueryParam "access_token" Text :>
59+ QueryParam "uploadType" Text :>
60+ QueryParam "bearer_token" Text :>
61+ QueryParam "callback" Text :>
62+ QueryParam "alt" AltJSON :>
63+ ReqBody '[JSON] SetIAMPolicyRequest :>
64+ Post '[JSON] Policy
65+
66+-- | Sets the IAM access control policy for a ServiceAccount.
67+--
68+-- /See:/ 'projectsServiceAccountsSetIAMPolicy' smart constructor.
69+data ProjectsServiceAccountsSetIAMPolicy = ProjectsServiceAccountsSetIAMPolicy'
70+ { _psasipXgafv :: !(Maybe Text)
71+ , _psasipUploadProtocol :: !(Maybe Text)
72+ , _psasipPp :: !Bool
73+ , _psasipAccessToken :: !(Maybe Text)
74+ , _psasipUploadType :: !(Maybe Text)
75+ , _psasipPayload :: !SetIAMPolicyRequest
76+ , _psasipBearerToken :: !(Maybe Text)
77+ , _psasipResource :: !Text
78+ , _psasipCallback :: !(Maybe Text)
79+ } deriving (Eq,Show,Data,Typeable,Generic)
80+
81+-- | Creates a value of 'ProjectsServiceAccountsSetIAMPolicy' with the minimum fields required to make a request.
82+--
83+-- Use one of the following lenses to modify other fields as desired:
84+--
85+-- * 'psasipXgafv'
86+--
87+-- * 'psasipUploadProtocol'
88+--
89+-- * 'psasipPp'
90+--
91+-- * 'psasipAccessToken'
92+--
93+-- * 'psasipUploadType'
94+--
95+-- * 'psasipPayload'
96+--
97+-- * 'psasipBearerToken'
98+--
99+-- * 'psasipResource'
100+--
101+-- * 'psasipCallback'
102+projectsServiceAccountsSetIAMPolicy
103+ :: SetIAMPolicyRequest -- ^ 'psasipPayload'
104+ -> Text -- ^ 'psasipResource'
105+ -> ProjectsServiceAccountsSetIAMPolicy
106+projectsServiceAccountsSetIAMPolicy pPsasipPayload_ pPsasipResource_ =
107+ ProjectsServiceAccountsSetIAMPolicy'
108+ { _psasipXgafv = Nothing
109+ , _psasipUploadProtocol = Nothing
110+ , _psasipPp = True
111+ , _psasipAccessToken = Nothing
112+ , _psasipUploadType = Nothing
113+ , _psasipPayload = pPsasipPayload_
114+ , _psasipBearerToken = Nothing
115+ , _psasipResource = pPsasipResource_
116+ , _psasipCallback = Nothing
117+ }
118+
119+-- | V1 error format.
120+psasipXgafv :: Lens' ProjectsServiceAccountsSetIAMPolicy (Maybe Text)
121+psasipXgafv
122+ = lens _psasipXgafv (\ s a -> s{_psasipXgafv = a})
123+
124+-- | Upload protocol for media (e.g. \"raw\", \"multipart\").
125+psasipUploadProtocol :: Lens' ProjectsServiceAccountsSetIAMPolicy (Maybe Text)
126+psasipUploadProtocol
127+ = lens _psasipUploadProtocol
128+ (\ s a -> s{_psasipUploadProtocol = a})
129+
130+-- | Pretty-print response.
131+psasipPp :: Lens' ProjectsServiceAccountsSetIAMPolicy Bool
132+psasipPp = lens _psasipPp (\ s a -> s{_psasipPp = a})
133+
134+-- | OAuth access token.
135+psasipAccessToken :: Lens' ProjectsServiceAccountsSetIAMPolicy (Maybe Text)
136+psasipAccessToken
137+ = lens _psasipAccessToken
138+ (\ s a -> s{_psasipAccessToken = a})
139+
140+-- | Legacy upload protocol for media (e.g. \"media\", \"multipart\").
141+psasipUploadType :: Lens' ProjectsServiceAccountsSetIAMPolicy (Maybe Text)
142+psasipUploadType
143+ = lens _psasipUploadType
144+ (\ s a -> s{_psasipUploadType = a})
145+
146+-- | Multipart request metadata.
147+psasipPayload :: Lens' ProjectsServiceAccountsSetIAMPolicy SetIAMPolicyRequest
148+psasipPayload
149+ = lens _psasipPayload
150+ (\ s a -> s{_psasipPayload = a})
151+
152+-- | OAuth bearer token.
153+psasipBearerToken :: Lens' ProjectsServiceAccountsSetIAMPolicy (Maybe Text)
154+psasipBearerToken
155+ = lens _psasipBearerToken
156+ (\ s a -> s{_psasipBearerToken = a})
157+
158+-- | REQUIRED: The resource for which the policy is being specified.
159+-- \`resource\` is usually specified as a path. For example, a Project
160+-- resource is specified as \`projects\/{project}\`.
161+psasipResource :: Lens' ProjectsServiceAccountsSetIAMPolicy Text
162+psasipResource
163+ = lens _psasipResource
164+ (\ s a -> s{_psasipResource = a})
165+
166+-- | JSONP
167+psasipCallback :: Lens' ProjectsServiceAccountsSetIAMPolicy (Maybe Text)
168+psasipCallback
169+ = lens _psasipCallback
170+ (\ s a -> s{_psasipCallback = a})
171+
172+instance GoogleRequest
173+ ProjectsServiceAccountsSetIAMPolicy where
174+ type Rs ProjectsServiceAccountsSetIAMPolicy = Policy
175+ type Scopes ProjectsServiceAccountsSetIAMPolicy =
176+ '["https://www.googleapis.com/auth/cloud-platform"]
177+ requestClient
178+ ProjectsServiceAccountsSetIAMPolicy'{..}
179+ = go _psasipResource _psasipXgafv
180+ _psasipUploadProtocol
181+ (Just _psasipPp)
182+ _psasipAccessToken
183+ _psasipUploadType
184+ _psasipBearerToken
185+ _psasipCallback
186+ (Just AltJSON)
187+ _psasipPayload
188+ iAMService
189+ where go
190+ = buildClient
191+ (Proxy ::
192+ Proxy ProjectsServiceAccountsSetIAMPolicyResource)
193+ mempty
gogol-iam/gen/Network/Google/Resource/IAM/Projects/ServiceAccounts/SignBlob.hsnew file+192
@@ -0,0 +1,192 @@
1+{-# LANGUAGE DataKinds #-}
2+{-# LANGUAGE DeriveDataTypeable #-}
3+{-# LANGUAGE DeriveGeneric #-}
4+{-# LANGUAGE FlexibleInstances #-}
5+{-# LANGUAGE NoImplicitPrelude #-}
6+{-# LANGUAGE OverloadedStrings #-}
7+{-# LANGUAGE RecordWildCards #-}
8+{-# LANGUAGE TypeFamilies #-}
9+{-# LANGUAGE TypeOperators #-}
10+
11+{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
12+{-# OPTIONS_GHC -fno-warn-unused-binds #-}
13+{-# OPTIONS_GHC -fno-warn-unused-imports #-}
14+
15+-- |
16+-- Module : Network.Google.Resource.IAM.Projects.ServiceAccounts.SignBlob
17+-- Copyright : (c) 2015-2016 Brendan Hay
18+-- License : Mozilla Public License, v. 2.0.
19+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>
20+-- Stability : auto-generated
21+-- Portability : non-portable (GHC extensions)
22+--
23+-- Signs a blob using a service account\'s system-managed private key.
24+--
25+-- /See:/ <https://cloud.google.com/iam/ Google Identity and Access Management (IAM) API Reference> for @iam.projects.serviceAccounts.signBlob@.
26+module Network.Google.Resource.IAM.Projects.ServiceAccounts.SignBlob
27+ (
28+ -- * REST Resource
29+ ProjectsServiceAccountsSignBlobResource
30+
31+ -- * Creating a Request
32+ , projectsServiceAccountsSignBlob
33+ , ProjectsServiceAccountsSignBlob
34+
35+ -- * Request Lenses
36+ , psasbXgafv
37+ , psasbUploadProtocol
38+ , psasbPp
39+ , psasbAccessToken
40+ , psasbUploadType
41+ , psasbPayload
42+ , psasbBearerToken
43+ , psasbName
44+ , psasbCallback
45+ ) where
46+
47+import Network.Google.IAM.Types
48+import Network.Google.Prelude
49+
50+-- | A resource alias for @iam.projects.serviceAccounts.signBlob@ method which the
51+-- 'ProjectsServiceAccountsSignBlob' request conforms to.
52+type ProjectsServiceAccountsSignBlobResource =
53+ "v1" :>
54+ CaptureMode "name" "signBlob" Text :>
55+ QueryParam "$.xgafv" Text :>
56+ QueryParam "upload_protocol" Text :>
57+ QueryParam "pp" Bool :>
58+ QueryParam "access_token" Text :>
59+ QueryParam "uploadType" Text :>
60+ QueryParam "bearer_token" Text :>
61+ QueryParam "callback" Text :>
62+ QueryParam "alt" AltJSON :>
63+ ReqBody '[JSON] SignBlobRequest :>
64+ Post '[JSON] SignBlobResponse
65+
66+-- | Signs a blob using a service account\'s system-managed private key.
67+--
68+-- /See:/ 'projectsServiceAccountsSignBlob' smart constructor.
69+data ProjectsServiceAccountsSignBlob = ProjectsServiceAccountsSignBlob'
70+ { _psasbXgafv :: !(Maybe Text)
71+ , _psasbUploadProtocol :: !(Maybe Text)
72+ , _psasbPp :: !Bool
73+ , _psasbAccessToken :: !(Maybe Text)
74+ , _psasbUploadType :: !(Maybe Text)
75+ , _psasbPayload :: !SignBlobRequest
76+ , _psasbBearerToken :: !(Maybe Text)
77+ , _psasbName :: !Text
78+ , _psasbCallback :: !(Maybe Text)
79+ } deriving (Eq,Show,Data,Typeable,Generic)
80+
81+-- | Creates a value of 'ProjectsServiceAccountsSignBlob' with the minimum fields required to make a request.
82+--
83+-- Use one of the following lenses to modify other fields as desired:
84+--
85+-- * 'psasbXgafv'
86+--
87+-- * 'psasbUploadProtocol'
88+--
89+-- * 'psasbPp'
90+--
91+-- * 'psasbAccessToken'
92+--
93+-- * 'psasbUploadType'
94+--
95+-- * 'psasbPayload'
96+--
97+-- * 'psasbBearerToken'
98+--
99+-- * 'psasbName'
100+--
101+-- * 'psasbCallback'
102+projectsServiceAccountsSignBlob
103+ :: SignBlobRequest -- ^ 'psasbPayload'
104+ -> Text -- ^ 'psasbName'
105+ -> ProjectsServiceAccountsSignBlob
106+projectsServiceAccountsSignBlob pPsasbPayload_ pPsasbName_ =
107+ ProjectsServiceAccountsSignBlob'
108+ { _psasbXgafv = Nothing
109+ , _psasbUploadProtocol = Nothing
110+ , _psasbPp = True
111+ , _psasbAccessToken = Nothing
112+ , _psasbUploadType = Nothing
113+ , _psasbPayload = pPsasbPayload_
114+ , _psasbBearerToken = Nothing
115+ , _psasbName = pPsasbName_
116+ , _psasbCallback = Nothing
117+ }
118+
119+-- | V1 error format.
120+psasbXgafv :: Lens' ProjectsServiceAccountsSignBlob (Maybe Text)
121+psasbXgafv
122+ = lens _psasbXgafv (\ s a -> s{_psasbXgafv = a})
123+
124+-- | Upload protocol for media (e.g. \"raw\", \"multipart\").
125+psasbUploadProtocol :: Lens' ProjectsServiceAccountsSignBlob (Maybe Text)
126+psasbUploadProtocol
127+ = lens _psasbUploadProtocol
128+ (\ s a -> s{_psasbUploadProtocol = a})
129+
130+-- | Pretty-print response.
131+psasbPp :: Lens' ProjectsServiceAccountsSignBlob Bool
132+psasbPp = lens _psasbPp (\ s a -> s{_psasbPp = a})
133+
134+-- | OAuth access token.
135+psasbAccessToken :: Lens' ProjectsServiceAccountsSignBlob (Maybe Text)
136+psasbAccessToken
137+ = lens _psasbAccessToken
138+ (\ s a -> s{_psasbAccessToken = a})
139+
140+-- | Legacy upload protocol for media (e.g. \"media\", \"multipart\").
141+psasbUploadType :: Lens' ProjectsServiceAccountsSignBlob (Maybe Text)
142+psasbUploadType
143+ = lens _psasbUploadType
144+ (\ s a -> s{_psasbUploadType = a})
145+
146+-- | Multipart request metadata.
147+psasbPayload :: Lens' ProjectsServiceAccountsSignBlob SignBlobRequest
148+psasbPayload
149+ = lens _psasbPayload (\ s a -> s{_psasbPayload = a})
150+
151+-- | OAuth bearer token.
152+psasbBearerToken :: Lens' ProjectsServiceAccountsSignBlob (Maybe Text)
153+psasbBearerToken
154+ = lens _psasbBearerToken
155+ (\ s a -> s{_psasbBearerToken = a})
156+
157+-- | The resource name of the service account in the following format:
158+-- \`projects\/{project}\/serviceAccounts\/{account}\`. Using \`-\` as a
159+-- wildcard for the project will infer the project from the account. The
160+-- \`account\` value can be the \`email\` address or the \`unique_id\` of
161+-- the service account.
162+psasbName :: Lens' ProjectsServiceAccountsSignBlob Text
163+psasbName
164+ = lens _psasbName (\ s a -> s{_psasbName = a})
165+
166+-- | JSONP
167+psasbCallback :: Lens' ProjectsServiceAccountsSignBlob (Maybe Text)
168+psasbCallback
169+ = lens _psasbCallback
170+ (\ s a -> s{_psasbCallback = a})
171+
172+instance GoogleRequest
173+ ProjectsServiceAccountsSignBlob where
174+ type Rs ProjectsServiceAccountsSignBlob =
175+ SignBlobResponse
176+ type Scopes ProjectsServiceAccountsSignBlob =
177+ '["https://www.googleapis.com/auth/cloud-platform"]
178+ requestClient ProjectsServiceAccountsSignBlob'{..}
179+ = go _psasbName _psasbXgafv _psasbUploadProtocol
180+ (Just _psasbPp)
181+ _psasbAccessToken
182+ _psasbUploadType
183+ _psasbBearerToken
184+ _psasbCallback
185+ (Just AltJSON)
186+ _psasbPayload
187+ iAMService
188+ where go
189+ = buildClient
190+ (Proxy ::
191+ Proxy ProjectsServiceAccountsSignBlobResource)
192+ mempty
gogol-iam/gen/Network/Google/Resource/IAM/Projects/ServiceAccounts/TestIAMPermissions.hsnew file+198
@@ -0,0 +1,198 @@
1+{-# LANGUAGE DataKinds #-}
2+{-# LANGUAGE DeriveDataTypeable #-}
3+{-# LANGUAGE DeriveGeneric #-}
4+{-# LANGUAGE FlexibleInstances #-}
5+{-# LANGUAGE NoImplicitPrelude #-}
6+{-# LANGUAGE OverloadedStrings #-}
7+{-# LANGUAGE RecordWildCards #-}
8+{-# LANGUAGE TypeFamilies #-}
9+{-# LANGUAGE TypeOperators #-}
10+
11+{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
12+{-# OPTIONS_GHC -fno-warn-unused-binds #-}
13+{-# OPTIONS_GHC -fno-warn-unused-imports #-}
14+
15+-- |
16+-- Module : Network.Google.Resource.IAM.Projects.ServiceAccounts.TestIAMPermissions
17+-- Copyright : (c) 2015-2016 Brendan Hay
18+-- License : Mozilla Public License, v. 2.0.
19+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>
20+-- Stability : auto-generated
21+-- Portability : non-portable (GHC extensions)
22+--
23+-- Tests the specified permissions against the IAM access control policy
24+-- for a ServiceAccount.
25+--
26+-- /See:/ <https://cloud.google.com/iam/ Google Identity and Access Management (IAM) API Reference> for @iam.projects.serviceAccounts.testIamPermissions@.
27+module Network.Google.Resource.IAM.Projects.ServiceAccounts.TestIAMPermissions
28+ (
29+ -- * REST Resource
30+ ProjectsServiceAccountsTestIAMPermissionsResource
31+
32+ -- * Creating a Request
33+ , projectsServiceAccountsTestIAMPermissions
34+ , ProjectsServiceAccountsTestIAMPermissions
35+
36+ -- * Request Lenses
37+ , psatipXgafv
38+ , psatipUploadProtocol
39+ , psatipPp
40+ , psatipAccessToken
41+ , psatipUploadType
42+ , psatipPayload
43+ , psatipBearerToken
44+ , psatipResource
45+ , psatipCallback
46+ ) where
47+
48+import Network.Google.IAM.Types
49+import Network.Google.Prelude
50+
51+-- | A resource alias for @iam.projects.serviceAccounts.testIamPermissions@ method which the
52+-- 'ProjectsServiceAccountsTestIAMPermissions' request conforms to.
53+type ProjectsServiceAccountsTestIAMPermissionsResource
54+ =
55+ "v1" :>
56+ CaptureMode "resource" "testIamPermissions" Text :>
57+ QueryParam "$.xgafv" Text :>
58+ QueryParam "upload_protocol" Text :>
59+ QueryParam "pp" Bool :>
60+ QueryParam "access_token" Text :>
61+ QueryParam "uploadType" Text :>
62+ QueryParam "bearer_token" Text :>
63+ QueryParam "callback" Text :>
64+ QueryParam "alt" AltJSON :>
65+ ReqBody '[JSON] TestIAMPermissionsRequest :>
66+ Post '[JSON] TestIAMPermissionsResponse
67+
68+-- | Tests the specified permissions against the IAM access control policy
69+-- for a ServiceAccount.
70+--
71+-- /See:/ 'projectsServiceAccountsTestIAMPermissions' smart constructor.
72+data ProjectsServiceAccountsTestIAMPermissions = ProjectsServiceAccountsTestIAMPermissions'
73+ { _psatipXgafv :: !(Maybe Text)
74+ , _psatipUploadProtocol :: !(Maybe Text)
75+ , _psatipPp :: !Bool
76+ , _psatipAccessToken :: !(Maybe Text)
77+ , _psatipUploadType :: !(Maybe Text)
78+ , _psatipPayload :: !TestIAMPermissionsRequest
79+ , _psatipBearerToken :: !(Maybe Text)
80+ , _psatipResource :: !Text
81+ , _psatipCallback :: !(Maybe Text)
82+ } deriving (Eq,Show,Data,Typeable,Generic)
83+
84+-- | Creates a value of 'ProjectsServiceAccountsTestIAMPermissions' with the minimum fields required to make a request.
85+--
86+-- Use one of the following lenses to modify other fields as desired:
87+--
88+-- * 'psatipXgafv'
89+--
90+-- * 'psatipUploadProtocol'
91+--
92+-- * 'psatipPp'
93+--
94+-- * 'psatipAccessToken'
95+--
96+-- * 'psatipUploadType'
97+--
98+-- * 'psatipPayload'
99+--
100+-- * 'psatipBearerToken'
101+--
102+-- * 'psatipResource'
103+--
104+-- * 'psatipCallback'
105+projectsServiceAccountsTestIAMPermissions
106+ :: TestIAMPermissionsRequest -- ^ 'psatipPayload'
107+ -> Text -- ^ 'psatipResource'
108+ -> ProjectsServiceAccountsTestIAMPermissions
109+projectsServiceAccountsTestIAMPermissions pPsatipPayload_ pPsatipResource_ =
110+ ProjectsServiceAccountsTestIAMPermissions'
111+ { _psatipXgafv = Nothing
112+ , _psatipUploadProtocol = Nothing
113+ , _psatipPp = True
114+ , _psatipAccessToken = Nothing
115+ , _psatipUploadType = Nothing
116+ , _psatipPayload = pPsatipPayload_
117+ , _psatipBearerToken = Nothing
118+ , _psatipResource = pPsatipResource_
119+ , _psatipCallback = Nothing
120+ }
121+
122+-- | V1 error format.
123+psatipXgafv :: Lens' ProjectsServiceAccountsTestIAMPermissions (Maybe Text)
124+psatipXgafv
125+ = lens _psatipXgafv (\ s a -> s{_psatipXgafv = a})
126+
127+-- | Upload protocol for media (e.g. \"raw\", \"multipart\").
128+psatipUploadProtocol :: Lens' ProjectsServiceAccountsTestIAMPermissions (Maybe Text)
129+psatipUploadProtocol
130+ = lens _psatipUploadProtocol
131+ (\ s a -> s{_psatipUploadProtocol = a})
132+
133+-- | Pretty-print response.
134+psatipPp :: Lens' ProjectsServiceAccountsTestIAMPermissions Bool
135+psatipPp = lens _psatipPp (\ s a -> s{_psatipPp = a})
136+
137+-- | OAuth access token.
138+psatipAccessToken :: Lens' ProjectsServiceAccountsTestIAMPermissions (Maybe Text)
139+psatipAccessToken
140+ = lens _psatipAccessToken
141+ (\ s a -> s{_psatipAccessToken = a})
142+
143+-- | Legacy upload protocol for media (e.g. \"media\", \"multipart\").
144+psatipUploadType :: Lens' ProjectsServiceAccountsTestIAMPermissions (Maybe Text)
145+psatipUploadType
146+ = lens _psatipUploadType
147+ (\ s a -> s{_psatipUploadType = a})
148+
149+-- | Multipart request metadata.
150+psatipPayload :: Lens' ProjectsServiceAccountsTestIAMPermissions TestIAMPermissionsRequest
151+psatipPayload
152+ = lens _psatipPayload
153+ (\ s a -> s{_psatipPayload = a})
154+
155+-- | OAuth bearer token.
156+psatipBearerToken :: Lens' ProjectsServiceAccountsTestIAMPermissions (Maybe Text)
157+psatipBearerToken
158+ = lens _psatipBearerToken
159+ (\ s a -> s{_psatipBearerToken = a})
160+
161+-- | REQUIRED: The resource for which the policy detail is being requested.
162+-- \`resource\` is usually specified as a path. For example, a Project
163+-- resource is specified as \`projects\/{project}\`.
164+psatipResource :: Lens' ProjectsServiceAccountsTestIAMPermissions Text
165+psatipResource
166+ = lens _psatipResource
167+ (\ s a -> s{_psatipResource = a})
168+
169+-- | JSONP
170+psatipCallback :: Lens' ProjectsServiceAccountsTestIAMPermissions (Maybe Text)
171+psatipCallback
172+ = lens _psatipCallback
173+ (\ s a -> s{_psatipCallback = a})
174+
175+instance GoogleRequest
176+ ProjectsServiceAccountsTestIAMPermissions where
177+ type Rs ProjectsServiceAccountsTestIAMPermissions =
178+ TestIAMPermissionsResponse
179+ type Scopes ProjectsServiceAccountsTestIAMPermissions
180+ = '["https://www.googleapis.com/auth/cloud-platform"]
181+ requestClient
182+ ProjectsServiceAccountsTestIAMPermissions'{..}
183+ = go _psatipResource _psatipXgafv
184+ _psatipUploadProtocol
185+ (Just _psatipPp)
186+ _psatipAccessToken
187+ _psatipUploadType
188+ _psatipBearerToken
189+ _psatipCallback
190+ (Just AltJSON)
191+ _psatipPayload
192+ iAMService
193+ where go
194+ = buildClient
195+ (Proxy ::
196+ Proxy
197+ ProjectsServiceAccountsTestIAMPermissionsResource)
198+ mempty
gogol-iam/gen/Network/Google/Resource/IAM/Projects/ServiceAccounts/Update.hsnew file+194
@@ -0,0 +1,194 @@
1+{-# LANGUAGE DataKinds #-}
2+{-# LANGUAGE DeriveDataTypeable #-}
3+{-# LANGUAGE DeriveGeneric #-}
4+{-# LANGUAGE FlexibleInstances #-}
5+{-# LANGUAGE NoImplicitPrelude #-}
6+{-# LANGUAGE OverloadedStrings #-}
7+{-# LANGUAGE RecordWildCards #-}
8+{-# LANGUAGE TypeFamilies #-}
9+{-# LANGUAGE TypeOperators #-}
10+
11+{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
12+{-# OPTIONS_GHC -fno-warn-unused-binds #-}
13+{-# OPTIONS_GHC -fno-warn-unused-imports #-}
14+
15+-- |
16+-- Module : Network.Google.Resource.IAM.Projects.ServiceAccounts.Update
17+-- Copyright : (c) 2015-2016 Brendan Hay
18+-- License : Mozilla Public License, v. 2.0.
19+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>
20+-- Stability : auto-generated
21+-- Portability : non-portable (GHC extensions)
22+--
23+-- Updates a ServiceAccount. Currently, only the following fields are
24+-- updatable: \`display_name\` . The \`etag\` is mandatory.
25+--
26+-- /See:/ <https://cloud.google.com/iam/ Google Identity and Access Management (IAM) API Reference> for @iam.projects.serviceAccounts.update@.
27+module Network.Google.Resource.IAM.Projects.ServiceAccounts.Update
28+ (
29+ -- * REST Resource
30+ ProjectsServiceAccountsUpdateResource
31+
32+ -- * Creating a Request
33+ , projectsServiceAccountsUpdate
34+ , ProjectsServiceAccountsUpdate
35+
36+ -- * Request Lenses
37+ , psauXgafv
38+ , psauUploadProtocol
39+ , psauPp
40+ , psauAccessToken
41+ , psauUploadType
42+ , psauPayload
43+ , psauBearerToken
44+ , psauName
45+ , psauCallback
46+ ) where
47+
48+import Network.Google.IAM.Types
49+import Network.Google.Prelude
50+
51+-- | A resource alias for @iam.projects.serviceAccounts.update@ method which the
52+-- 'ProjectsServiceAccountsUpdate' request conforms to.
53+type ProjectsServiceAccountsUpdateResource =
54+ "v1" :>
55+ Capture "name" Text :>
56+ QueryParam "$.xgafv" Text :>
57+ QueryParam "upload_protocol" Text :>
58+ QueryParam "pp" Bool :>
59+ QueryParam "access_token" Text :>
60+ QueryParam "uploadType" Text :>
61+ QueryParam "bearer_token" Text :>
62+ QueryParam "callback" Text :>
63+ QueryParam "alt" AltJSON :>
64+ ReqBody '[JSON] ServiceAccount :>
65+ Put '[JSON] ServiceAccount
66+
67+-- | Updates a ServiceAccount. Currently, only the following fields are
68+-- updatable: \`display_name\` . The \`etag\` is mandatory.
69+--
70+-- /See:/ 'projectsServiceAccountsUpdate' smart constructor.
71+data ProjectsServiceAccountsUpdate = ProjectsServiceAccountsUpdate'
72+ { _psauXgafv :: !(Maybe Text)
73+ , _psauUploadProtocol :: !(Maybe Text)
74+ , _psauPp :: !Bool
75+ , _psauAccessToken :: !(Maybe Text)
76+ , _psauUploadType :: !(Maybe Text)
77+ , _psauPayload :: !ServiceAccount
78+ , _psauBearerToken :: !(Maybe Text)
79+ , _psauName :: !Text
80+ , _psauCallback :: !(Maybe Text)
81+ } deriving (Eq,Show,Data,Typeable,Generic)
82+
83+-- | Creates a value of 'ProjectsServiceAccountsUpdate' with the minimum fields required to make a request.
84+--
85+-- Use one of the following lenses to modify other fields as desired:
86+--
87+-- * 'psauXgafv'
88+--
89+-- * 'psauUploadProtocol'
90+--
91+-- * 'psauPp'
92+--
93+-- * 'psauAccessToken'
94+--
95+-- * 'psauUploadType'
96+--
97+-- * 'psauPayload'
98+--
99+-- * 'psauBearerToken'
100+--
101+-- * 'psauName'
102+--
103+-- * 'psauCallback'
104+projectsServiceAccountsUpdate
105+ :: ServiceAccount -- ^ 'psauPayload'
106+ -> Text -- ^ 'psauName'
107+ -> ProjectsServiceAccountsUpdate
108+projectsServiceAccountsUpdate pPsauPayload_ pPsauName_ =
109+ ProjectsServiceAccountsUpdate'
110+ { _psauXgafv = Nothing
111+ , _psauUploadProtocol = Nothing
112+ , _psauPp = True
113+ , _psauAccessToken = Nothing
114+ , _psauUploadType = Nothing
115+ , _psauPayload = pPsauPayload_
116+ , _psauBearerToken = Nothing
117+ , _psauName = pPsauName_
118+ , _psauCallback = Nothing
119+ }
120+
121+-- | V1 error format.
122+psauXgafv :: Lens' ProjectsServiceAccountsUpdate (Maybe Text)
123+psauXgafv
124+ = lens _psauXgafv (\ s a -> s{_psauXgafv = a})
125+
126+-- | Upload protocol for media (e.g. \"raw\", \"multipart\").
127+psauUploadProtocol :: Lens' ProjectsServiceAccountsUpdate (Maybe Text)
128+psauUploadProtocol
129+ = lens _psauUploadProtocol
130+ (\ s a -> s{_psauUploadProtocol = a})
131+
132+-- | Pretty-print response.
133+psauPp :: Lens' ProjectsServiceAccountsUpdate Bool
134+psauPp = lens _psauPp (\ s a -> s{_psauPp = a})
135+
136+-- | OAuth access token.
137+psauAccessToken :: Lens' ProjectsServiceAccountsUpdate (Maybe Text)
138+psauAccessToken
139+ = lens _psauAccessToken
140+ (\ s a -> s{_psauAccessToken = a})
141+
142+-- | Legacy upload protocol for media (e.g. \"media\", \"multipart\").
143+psauUploadType :: Lens' ProjectsServiceAccountsUpdate (Maybe Text)
144+psauUploadType
145+ = lens _psauUploadType
146+ (\ s a -> s{_psauUploadType = a})
147+
148+-- | Multipart request metadata.
149+psauPayload :: Lens' ProjectsServiceAccountsUpdate ServiceAccount
150+psauPayload
151+ = lens _psauPayload (\ s a -> s{_psauPayload = a})
152+
153+-- | OAuth bearer token.
154+psauBearerToken :: Lens' ProjectsServiceAccountsUpdate (Maybe Text)
155+psauBearerToken
156+ = lens _psauBearerToken
157+ (\ s a -> s{_psauBearerToken = a})
158+
159+-- | The resource name of the service account in the following format:
160+-- \`projects\/{project}\/serviceAccounts\/{account}\`. Requests using
161+-- \`-\` as a wildcard for the project will infer the project from the
162+-- \`account\` and the \`account\` value can be the \`email\` address or
163+-- the \`unique_id\` of the service account. In responses the resource name
164+-- will always be in the format
165+-- \`projects\/{project}\/serviceAccounts\/{email}\`.
166+psauName :: Lens' ProjectsServiceAccountsUpdate Text
167+psauName = lens _psauName (\ s a -> s{_psauName = a})
168+
169+-- | JSONP
170+psauCallback :: Lens' ProjectsServiceAccountsUpdate (Maybe Text)
171+psauCallback
172+ = lens _psauCallback (\ s a -> s{_psauCallback = a})
173+
174+instance GoogleRequest ProjectsServiceAccountsUpdate
175+ where
176+ type Rs ProjectsServiceAccountsUpdate =
177+ ServiceAccount
178+ type Scopes ProjectsServiceAccountsUpdate =
179+ '["https://www.googleapis.com/auth/cloud-platform"]
180+ requestClient ProjectsServiceAccountsUpdate'{..}
181+ = go _psauName _psauXgafv _psauUploadProtocol
182+ (Just _psauPp)
183+ _psauAccessToken
184+ _psauUploadType
185+ _psauBearerToken
186+ _psauCallback
187+ (Just AltJSON)
188+ _psauPayload
189+ iAMService
190+ where go
191+ = buildClient
192+ (Proxy ::
193+ Proxy ProjectsServiceAccountsUpdateResource)
194+ mempty
gogol-iam/gen/Network/Google/Resource/IAM/Roles/QueryGrantableRoles.hsnew file+177
@@ -0,0 +1,177 @@
1+{-# LANGUAGE DataKinds #-}
2+{-# LANGUAGE DeriveDataTypeable #-}
3+{-# LANGUAGE DeriveGeneric #-}
4+{-# LANGUAGE FlexibleInstances #-}
5+{-# LANGUAGE NoImplicitPrelude #-}
6+{-# LANGUAGE OverloadedStrings #-}
7+{-# LANGUAGE RecordWildCards #-}
8+{-# LANGUAGE TypeFamilies #-}
9+{-# LANGUAGE TypeOperators #-}
10+
11+{-# OPTIONS_GHC -fno-warn-duplicate-exports #-}
12+{-# OPTIONS_GHC -fno-warn-unused-binds #-}
13+{-# OPTIONS_GHC -fno-warn-unused-imports #-}
14+
15+-- |
16+-- Module : Network.Google.Resource.IAM.Roles.QueryGrantableRoles
17+-- Copyright : (c) 2015-2016 Brendan Hay
18+-- License : Mozilla Public License, v. 2.0.
19+-- Maintainer : Brendan Hay <brendan.g.hay@gmail.com>
20+-- Stability : auto-generated
21+-- Portability : non-portable (GHC extensions)
22+--
23+-- Queries roles that can be granted on a particular resource. A role is
24+-- grantable if it can be used as the role in a binding for a policy for
25+-- that resource.
26+--
27+-- /See:/ <https://cloud.google.com/iam/ Google Identity and Access Management (IAM) API Reference> for @iam.roles.queryGrantableRoles@.
28+module Network.Google.Resource.IAM.Roles.QueryGrantableRoles
29+ (
30+ -- * REST Resource
31+ RolesQueryGrantableRolesResource
32+
33+ -- * Creating a Request
34+ , rolesQueryGrantableRoles
35+ , RolesQueryGrantableRoles
36+
37+ -- * Request Lenses
38+ , rqgrXgafv
39+ , rqgrUploadProtocol
40+ , rqgrPp
41+ , rqgrAccessToken
42+ , rqgrUploadType
43+ , rqgrPayload
44+ , rqgrBearerToken
45+ , rqgrCallback
46+ ) where
47+
48+import Network.Google.IAM.Types
49+import Network.Google.Prelude
50+
51+-- | A resource alias for @iam.roles.queryGrantableRoles@ method which the
52+-- 'RolesQueryGrantableRoles' request conforms to.
53+type RolesQueryGrantableRolesResource =
54+ "v1" :>
55+ "roles:queryGrantableRoles" :>
56+ QueryParam "$.xgafv" Text :>
57+ QueryParam "upload_protocol" Text :>
58+ QueryParam "pp" Bool :>
59+ QueryParam "access_token" Text :>
60+ QueryParam "uploadType" Text :>
61+ QueryParam "bearer_token" Text :>
62+ QueryParam "callback" Text :>
63+ QueryParam "alt" AltJSON :>
64+ ReqBody '[JSON] QueryGrantableRolesRequest :>
65+ Post '[JSON] QueryGrantableRolesResponse
66+
67+-- | Queries roles that can be granted on a particular resource. A role is
68+-- grantable if it can be used as the role in a binding for a policy for
69+-- that resource.
70+--
71+-- /See:/ 'rolesQueryGrantableRoles' smart constructor.
72+data RolesQueryGrantableRoles = RolesQueryGrantableRoles'
73+ { _rqgrXgafv :: !(Maybe Text)
74+ , _rqgrUploadProtocol :: !(Maybe Text)
75+ , _rqgrPp :: !Bool
76+ , _rqgrAccessToken :: !(Maybe Text)
77+ , _rqgrUploadType :: !(Maybe Text)
78+ , _rqgrPayload :: !QueryGrantableRolesRequest
79+ , _rqgrBearerToken :: !(Maybe Text)
80+ , _rqgrCallback :: !(Maybe Text)
81+ } deriving (Eq,Show,Data,Typeable,Generic)
82+
83+-- | Creates a value of 'RolesQueryGrantableRoles' with the minimum fields required to make a request.
84+--
85+-- Use one of the following lenses to modify other fields as desired:
86+--
87+-- * 'rqgrXgafv'
88+--
89+-- * 'rqgrUploadProtocol'
90+--
91+-- * 'rqgrPp'
92+--
93+-- * 'rqgrAccessToken'
94+--
95+-- * 'rqgrUploadType'
96+--
97+-- * 'rqgrPayload'
98+--
99+-- * 'rqgrBearerToken'
100+--
101+-- * 'rqgrCallback'
102+rolesQueryGrantableRoles
103+ :: QueryGrantableRolesRequest -- ^ 'rqgrPayload'
104+ -> RolesQueryGrantableRoles
105+rolesQueryGrantableRoles pRqgrPayload_ =
106+ RolesQueryGrantableRoles'
107+ { _rqgrXgafv = Nothing
108+ , _rqgrUploadProtocol = Nothing
109+ , _rqgrPp = True
110+ , _rqgrAccessToken = Nothing
111+ , _rqgrUploadType = Nothing
112+ , _rqgrPayload = pRqgrPayload_
113+ , _rqgrBearerToken = Nothing
114+ , _rqgrCallback = Nothing
115+ }
116+
117+-- | V1 error format.
118+rqgrXgafv :: Lens' RolesQueryGrantableRoles (Maybe Text)
119+rqgrXgafv
120+ = lens _rqgrXgafv (\ s a -> s{_rqgrXgafv = a})
121+
122+-- | Upload protocol for media (e.g. \"raw\", \"multipart\").
123+rqgrUploadProtocol :: Lens' RolesQueryGrantableRoles (Maybe Text)
124+rqgrUploadProtocol
125+ = lens _rqgrUploadProtocol
126+ (\ s a -> s{_rqgrUploadProtocol = a})
127+
128+-- | Pretty-print response.
129+rqgrPp :: Lens' RolesQueryGrantableRoles Bool
130+rqgrPp = lens _rqgrPp (\ s a -> s{_rqgrPp = a})
131+
132+-- | OAuth access token.
133+rqgrAccessToken :: Lens' RolesQueryGrantableRoles (Maybe Text)
134+rqgrAccessToken
135+ = lens _rqgrAccessToken
136+ (\ s a -> s{_rqgrAccessToken = a})
137+
138+-- | Legacy upload protocol for media (e.g. \"media\", \"multipart\").
139+rqgrUploadType :: Lens' RolesQueryGrantableRoles (Maybe Text)
140+rqgrUploadType
141+ = lens _rqgrUploadType
142+ (\ s a -> s{_rqgrUploadType = a})
143+
144+-- | Multipart request metadata.
145+rqgrPayload :: Lens' RolesQueryGrantableRoles QueryGrantableRolesRequest
146+rqgrPayload
147+ = lens _rqgrPayload (\ s a -> s{_rqgrPayload = a})
148+
149+-- | OAuth bearer token.
150+rqgrBearerToken :: Lens' RolesQueryGrantableRoles (Maybe Text)
151+rqgrBearerToken
152+ = lens _rqgrBearerToken
153+ (\ s a -> s{_rqgrBearerToken = a})
154+
155+-- | JSONP
156+rqgrCallback :: Lens' RolesQueryGrantableRoles (Maybe Text)
157+rqgrCallback
158+ = lens _rqgrCallback (\ s a -> s{_rqgrCallback = a})
159+
160+instance GoogleRequest RolesQueryGrantableRoles where
161+ type Rs RolesQueryGrantableRoles =
162+ QueryGrantableRolesResponse
163+ type Scopes RolesQueryGrantableRoles =
164+ '["https://www.googleapis.com/auth/cloud-platform"]
165+ requestClient RolesQueryGrantableRoles'{..}
166+ = go _rqgrXgafv _rqgrUploadProtocol (Just _rqgrPp)
167+ _rqgrAccessToken
168+ _rqgrUploadType
169+ _rqgrBearerToken
170+ _rqgrCallback
171+ (Just AltJSON)
172+ _rqgrPayload
173+ iAMService
174+ where go
175+ = buildClient
176+ (Proxy :: Proxy RolesQueryGrantableRolesResource)
177+ mempty
gogol-iam/gogol-iam.cabalnew file+61
@@ -0,0 +1,61 @@
1+name: gogol-iam
2+version: 0.1.0
3+synopsis: Google Identity and Access Management (IAM) SDK.
4+homepage: https://github.com/brendanhay/gogol
5+bug-reports: https://github.com/brendanhay/gogol/issues
6+license: OtherLicense
7+license-file: LICENSE
8+author: Brendan Hay
9+maintainer: Brendan Hay <brendan.g.hay@gmail.com>
10+copyright: Copyright (c) 2015-2016 Brendan Hay
11+category: Network, Google, Cloud
12+build-type: Simple
13+cabal-version: >= 1.10
14+extra-source-files: README.md
15+
16+description:
17+ Manages identity and access control for Google Cloud Platform resources,
18+ including the creation of service accounts, which you can use to
19+ authenticate to Google and make API calls.
20+ .
21+ /Warning:/ This is an experimental prototype/preview release which is still
22+ under exploratory development and not intended for public use, caveat emptor!
23+ .
24+ This library is compatible with version @v1@
25+ of the API.
26+
27+source-repository head
28+ type: git
29+ location: git://github.com/brendanhay/gogol.git
30+
31+library
32+ default-language: Haskell2010
33+ hs-source-dirs: src gen
34+
35+ ghc-options: -Wall
36+
37+ exposed-modules:
38+ Network.Google.IAM
39+ , Network.Google.IAM.Types
40+ , Network.Google.Resource.IAM.Projects.ServiceAccounts.Create
41+ , Network.Google.Resource.IAM.Projects.ServiceAccounts.Delete
42+ , Network.Google.Resource.IAM.Projects.ServiceAccounts.Get
43+ , Network.Google.Resource.IAM.Projects.ServiceAccounts.GetIAMPolicy
44+ , Network.Google.Resource.IAM.Projects.ServiceAccounts.Keys.Create
45+ , Network.Google.Resource.IAM.Projects.ServiceAccounts.Keys.Delete
46+ , Network.Google.Resource.IAM.Projects.ServiceAccounts.Keys.Get
47+ , Network.Google.Resource.IAM.Projects.ServiceAccounts.Keys.List
48+ , Network.Google.Resource.IAM.Projects.ServiceAccounts.List
49+ , Network.Google.Resource.IAM.Projects.ServiceAccounts.SetIAMPolicy
50+ , Network.Google.Resource.IAM.Projects.ServiceAccounts.SignBlob
51+ , Network.Google.Resource.IAM.Projects.ServiceAccounts.TestIAMPermissions
52+ , Network.Google.Resource.IAM.Projects.ServiceAccounts.Update
53+ , Network.Google.Resource.IAM.Roles.QueryGrantableRoles
54+
55+ other-modules:
56+ Network.Google.IAM.Types.Product
57+ , Network.Google.IAM.Types.Sum
58+
59+ build-depends:
60+ gogol-core == 0.1.0.*
61+ , base >= 4.7 && < 5
gogol-iam/src/.gitkeepnew file

No changes to the content.