blob: d3385f9d73579c2ff5a14a81480d6d4cac04e79e [file] [log] [blame]
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001<html><body>
2<style>
3
4body, h1, h2, h3, div, span, p, pre, a {
5 margin: 0;
6 padding: 0;
7 border: 0;
8 font-weight: inherit;
9 font-style: inherit;
10 font-size: 100%;
11 font-family: inherit;
12 vertical-align: baseline;
13}
14
15body {
16 font-size: 13px;
17 padding: 1em;
18}
19
20h1 {
21 font-size: 26px;
22 margin-bottom: 1em;
23}
24
25h2 {
26 font-size: 24px;
27 margin-bottom: 1em;
28}
29
30h3 {
31 font-size: 20px;
32 margin-bottom: 1em;
33 margin-top: 1em;
34}
35
36pre, code {
37 line-height: 1.5;
38 font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace;
39}
40
41pre {
42 margin-top: 0.5em;
43}
44
45h1, h2, h3, p {
46 font-family: Arial, sans serif;
47}
48
49h1, h2, h3 {
50 border-bottom: solid #CCC 1px;
51}
52
53.toc_element {
54 margin-top: 0.5em;
55}
56
57.firstline {
58 margin-left: 2 em;
59}
60
61.method {
62 margin-top: 1em;
63 border: solid 1px #CCC;
64 padding: 1em;
65 background: #EEE;
66}
67
68.details {
69 font-weight: bold;
70 font-size: 14px;
71}
72
73</style>
74
75<h1><a href="iap_v1.html">Cloud Identity-Aware Proxy API</a> . <a href="iap_v1.v1.html">v1</a></h1>
76<h2>Instance Methods</h2>
77<p class="toc_element">
78 <code><a href="#getIamPolicy">getIamPolicy(resource, body=None, x__xgafv=None)</a></code></p>
79<p class="firstline">Gets the access control policy for an Identity-Aware Proxy protected</p>
80<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -070081 <code><a href="#getIapSettings">getIapSettings(name, x__xgafv=None)</a></code></p>
82<p class="firstline">Gets the IAP settings on a particular IAP protected resource.</p>
83<p class="toc_element">
84 <code><a href="#setIamPolicy">setIamPolicy(resource, body=None, x__xgafv=None)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070085<p class="firstline">Sets the access control policy for an Identity-Aware Proxy protected</p>
86<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -070087 <code><a href="#testIamPermissions">testIamPermissions(resource, body=None, x__xgafv=None)</a></code></p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070088<p class="firstline">Returns permissions that a caller has on the Identity-Aware Proxy protected</p>
Dan O'Mearadd494642020-05-01 07:42:23 -070089<p class="toc_element">
90 <code><a href="#updateIapSettings">updateIapSettings(name, body=None, updateMask=None, x__xgafv=None)</a></code></p>
91<p class="firstline">Updates the IAP settings on a particular IAP protected resource. It</p>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070092<h3>Method Details</h3>
93<div class="method">
94 <code class="details" id="getIamPolicy">getIamPolicy(resource, body=None, x__xgafv=None)</code>
95 <pre>Gets the access control policy for an Identity-Aware Proxy protected
96resource.
97More information about managing access via IAP can be found at:
98https://cloud.google.com/iap/docs/managing-access#managing_access_via_the_api
99
100Args:
101 resource: string, REQUIRED: The resource for which the policy is being requested.
102See the operation documentation for the appropriate value for this field. (required)
103 body: object, The request body.
104 The object takes the form of:
105
106{ # Request message for `GetIamPolicy` method.
Bu Sun Kim65020912020-05-20 12:08:20 -0700107 &quot;options&quot;: { # Encapsulates settings provided to GetIamPolicy. # OPTIONAL: A `GetPolicyOptions` object for specifying options to
108 # `GetIamPolicy`.
109 &quot;requestedPolicyVersion&quot;: 42, # Optional. The policy format version to be returned.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700110 #
Dan O'Mearadd494642020-05-01 07:42:23 -0700111 # Valid values are 0, 1, and 3. Requests specifying an invalid value will be
112 # rejected.
113 #
114 # Requests for policies with any conditional bindings must specify version 3.
115 # Policies without any conditional bindings may specify any valid value or
116 # leave the field unset.
Bu Sun Kim65020912020-05-20 12:08:20 -0700117 #
118 # To learn which resources support conditions in their IAM policies, see the
119 # [IAM
120 # documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700121 },
122 }
123
124 x__xgafv: string, V1 error format.
125 Allowed values
126 1 - v1 error format
127 2 - v2 error format
128
129Returns:
130 An object of the form:
131
Dan O'Mearadd494642020-05-01 07:42:23 -0700132 { # An Identity and Access Management (IAM) policy, which specifies access
133 # controls for Google Cloud resources.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700134 #
135 #
Dan O'Mearadd494642020-05-01 07:42:23 -0700136 # A `Policy` is a collection of `bindings`. A `binding` binds one or more
137 # `members` to a single `role`. Members can be user accounts, service accounts,
138 # Google groups, and domains (such as G Suite). A `role` is a named list of
139 # permissions; each `role` can be an IAM predefined role or a user-created
140 # custom role.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700141 #
Bu Sun Kim65020912020-05-20 12:08:20 -0700142 # For some types of Google Cloud resources, a `binding` can also specify a
143 # `condition`, which is a logical expression that allows access to a resource
144 # only if the expression evaluates to `true`. A condition can add constraints
145 # based on attributes of the request, the resource, or both. To learn which
146 # resources support conditions in their IAM policies, see the
147 # [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
Dan O'Mearadd494642020-05-01 07:42:23 -0700148 #
149 # **JSON example:**
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700150 #
151 # {
Bu Sun Kim65020912020-05-20 12:08:20 -0700152 # &quot;bindings&quot;: [
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700153 # {
Bu Sun Kim65020912020-05-20 12:08:20 -0700154 # &quot;role&quot;: &quot;roles/resourcemanager.organizationAdmin&quot;,
155 # &quot;members&quot;: [
156 # &quot;user:mike@example.com&quot;,
157 # &quot;group:admins@example.com&quot;,
158 # &quot;domain:google.com&quot;,
159 # &quot;serviceAccount:my-project-id@appspot.gserviceaccount.com&quot;
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700160 # ]
161 # },
162 # {
Bu Sun Kim65020912020-05-20 12:08:20 -0700163 # &quot;role&quot;: &quot;roles/resourcemanager.organizationViewer&quot;,
164 # &quot;members&quot;: [
165 # &quot;user:eve@example.com&quot;
166 # ],
167 # &quot;condition&quot;: {
168 # &quot;title&quot;: &quot;expirable access&quot;,
169 # &quot;description&quot;: &quot;Does not grant access after Sep 2020&quot;,
170 # &quot;expression&quot;: &quot;request.time &lt; timestamp(&#x27;2020-10-01T00:00:00.000Z&#x27;)&quot;,
Dan O'Mearadd494642020-05-01 07:42:23 -0700171 # }
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700172 # }
Dan O'Mearadd494642020-05-01 07:42:23 -0700173 # ],
Bu Sun Kim65020912020-05-20 12:08:20 -0700174 # &quot;etag&quot;: &quot;BwWWja0YfJA=&quot;,
175 # &quot;version&quot;: 3
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700176 # }
177 #
Dan O'Mearadd494642020-05-01 07:42:23 -0700178 # **YAML example:**
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700179 #
180 # bindings:
181 # - members:
182 # - user:mike@example.com
183 # - group:admins@example.com
184 # - domain:google.com
Dan O'Mearadd494642020-05-01 07:42:23 -0700185 # - serviceAccount:my-project-id@appspot.gserviceaccount.com
186 # role: roles/resourcemanager.organizationAdmin
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700187 # - members:
Dan O'Mearadd494642020-05-01 07:42:23 -0700188 # - user:eve@example.com
189 # role: roles/resourcemanager.organizationViewer
190 # condition:
191 # title: expirable access
192 # description: Does not grant access after Sep 2020
Bu Sun Kim65020912020-05-20 12:08:20 -0700193 # expression: request.time &lt; timestamp(&#x27;2020-10-01T00:00:00.000Z&#x27;)
Dan O'Mearadd494642020-05-01 07:42:23 -0700194 # - etag: BwWWja0YfJA=
195 # - version: 3
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700196 #
197 # For a description of IAM and its features, see the
Dan O'Mearadd494642020-05-01 07:42:23 -0700198 # [IAM documentation](https://cloud.google.com/iam/docs/).
Bu Sun Kim65020912020-05-20 12:08:20 -0700199 &quot;etag&quot;: &quot;A String&quot;, # `etag` is used for optimistic concurrency control as a way to help
200 # prevent simultaneous updates of a policy from overwriting each other.
201 # It is strongly suggested that systems make use of the `etag` in the
202 # read-modify-write cycle to perform policy updates in order to avoid race
203 # conditions: An `etag` is returned in the response to `getIamPolicy`, and
204 # systems are expected to put that etag in the request to `setIamPolicy` to
205 # ensure that their change will be applied to the same version of the policy.
206 #
207 # **Important:** If you use IAM Conditions, you must include the `etag` field
208 # whenever you call `setIamPolicy`. If you omit this field, then IAM allows
209 # you to overwrite a version `3` policy with a version `1` policy, and all of
210 # the conditions in the version `3` policy are lost.
211 &quot;version&quot;: 42, # Specifies the format of the policy.
212 #
213 # Valid values are `0`, `1`, and `3`. Requests that specify an invalid value
214 # are rejected.
215 #
216 # Any operation that affects conditional role bindings must specify version
217 # `3`. This requirement applies to the following operations:
218 #
219 # * Getting a policy that includes a conditional role binding
220 # * Adding a conditional role binding to a policy
221 # * Changing a conditional role binding in a policy
222 # * Removing any role binding, with or without a condition, from a policy
223 # that includes conditions
224 #
225 # **Important:** If you use IAM Conditions, you must include the `etag` field
226 # whenever you call `setIamPolicy`. If you omit this field, then IAM allows
227 # you to overwrite a version `3` policy with a version `1` policy, and all of
228 # the conditions in the version `3` policy are lost.
229 #
230 # If a policy does not include any conditions, operations on that policy may
231 # specify any valid version or leave the field unset.
232 #
233 # To learn which resources support conditions in their IAM policies, see the
234 # [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
235 &quot;bindings&quot;: [ # Associates a list of `members` to a `role`. Optionally, may specify a
Dan O'Mearadd494642020-05-01 07:42:23 -0700236 # `condition` that determines how and when the `bindings` are applied. Each
237 # of the `bindings` must contain at least one member.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700238 { # Associates `members` with a `role`.
Bu Sun Kim65020912020-05-20 12:08:20 -0700239 &quot;role&quot;: &quot;A String&quot;, # Role that is assigned to `members`.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700240 # For example, `roles/viewer`, `roles/editor`, or `roles/owner`.
Bu Sun Kim65020912020-05-20 12:08:20 -0700241 &quot;condition&quot;: { # Represents a textual expression in the Common Expression Language (CEL) # The condition that is associated with this binding.
242 #
243 # If the condition evaluates to `true`, then this binding applies to the
244 # current request.
245 #
246 # If the condition evaluates to `false`, then this binding does not apply to
247 # the current request. However, a different role binding might grant the same
248 # role to one or more of the members in this binding.
249 #
250 # To learn which resources support conditions in their IAM policies, see the
251 # [IAM
252 # documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
253 # syntax. CEL is a C-like expression language. The syntax and semantics of CEL
254 # are documented at https://github.com/google/cel-spec.
255 #
256 # Example (Comparison):
257 #
258 # title: &quot;Summary size limit&quot;
259 # description: &quot;Determines if a summary is less than 100 chars&quot;
260 # expression: &quot;document.summary.size() &lt; 100&quot;
261 #
262 # Example (Equality):
263 #
264 # title: &quot;Requestor is owner&quot;
265 # description: &quot;Determines if requestor is the document owner&quot;
266 # expression: &quot;document.owner == request.auth.claims.email&quot;
267 #
268 # Example (Logic):
269 #
270 # title: &quot;Public documents&quot;
271 # description: &quot;Determine whether the document should be publicly visible&quot;
272 # expression: &quot;document.type != &#x27;private&#x27; &amp;&amp; document.type != &#x27;internal&#x27;&quot;
273 #
274 # Example (Data Manipulation):
275 #
276 # title: &quot;Notification string&quot;
277 # description: &quot;Create a notification string with a timestamp.&quot;
278 # expression: &quot;&#x27;New message received at &#x27; + string(document.create_time)&quot;
279 #
280 # The exact variables and functions that may be referenced within an expression
281 # are determined by the service that evaluates it. See the service
282 # documentation for additional information.
283 &quot;expression&quot;: &quot;A String&quot;, # Textual representation of an expression in Common Expression Language
284 # syntax.
285 &quot;title&quot;: &quot;A String&quot;, # Optional. Title for the expression, i.e. a short string describing
286 # its purpose. This can be used e.g. in UIs which allow to enter the
287 # expression.
288 &quot;location&quot;: &quot;A String&quot;, # Optional. String indicating the location of the expression for error
289 # reporting, e.g. a file name and a position in the file.
290 &quot;description&quot;: &quot;A String&quot;, # Optional. Description of the expression. This is a longer text which
291 # describes the expression, e.g. when hovered over it in a UI.
292 },
293 &quot;members&quot;: [ # Specifies the identities requesting access for a Cloud Platform resource.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700294 # `members` can have the following values:
295 #
296 # * `allUsers`: A special identifier that represents anyone who is
297 # on the internet; with or without a Google account.
298 #
299 # * `allAuthenticatedUsers`: A special identifier that represents anyone
300 # who is authenticated with a Google account or a service account.
301 #
302 # * `user:{emailid}`: An email address that represents a specific Google
Dan O'Mearadd494642020-05-01 07:42:23 -0700303 # account. For example, `alice@example.com` .
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700304 #
305 #
306 # * `serviceAccount:{emailid}`: An email address that represents a service
307 # account. For example, `my-other-app@appspot.gserviceaccount.com`.
308 #
309 # * `group:{emailid}`: An email address that represents a Google group.
310 # For example, `admins@example.com`.
311 #
Dan O'Mearadd494642020-05-01 07:42:23 -0700312 # * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique
313 # identifier) representing a user that has been recently deleted. For
314 # example, `alice@example.com?uid=123456789012345678901`. If the user is
315 # recovered, this value reverts to `user:{emailid}` and the recovered user
316 # retains the role in the binding.
317 #
318 # * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus
319 # unique identifier) representing a service account that has been recently
320 # deleted. For example,
321 # `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`.
322 # If the service account is undeleted, this value reverts to
323 # `serviceAccount:{emailid}` and the undeleted service account retains the
324 # role in the binding.
325 #
326 # * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique
327 # identifier) representing a Google group that has been recently
328 # deleted. For example, `admins@example.com?uid=123456789012345678901`. If
329 # the group is recovered, this value reverts to `group:{emailid}` and the
330 # recovered group retains the role in the binding.
331 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700332 #
333 # * `domain:{domain}`: The G Suite domain (primary) that represents all the
334 # users of that domain. For example, `google.com` or `example.com`.
335 #
Bu Sun Kim65020912020-05-20 12:08:20 -0700336 &quot;A String&quot;,
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700337 ],
338 },
339 ],
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700340 }</pre>
341</div>
342
343<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -0700344 <code class="details" id="getIapSettings">getIapSettings(name, x__xgafv=None)</code>
345 <pre>Gets the IAP settings on a particular IAP protected resource.
346
347Args:
348 name: string, Required. The resource name for which to retrieve the settings.
349Authorization: Requires the `getSettings` permission for the associated
350resource. (required)
351 x__xgafv: string, V1 error format.
352 Allowed values
353 1 - v1 error format
354 2 - v2 error format
355
356Returns:
357 An object of the form:
358
359 { # The IAP configurable settings.
Bu Sun Kim65020912020-05-20 12:08:20 -0700360 &quot;applicationSettings&quot;: { # Wrapper over application specific settings for IAP. # Top level wrapper for all application related settings in IAP
361 &quot;csmSettings&quot;: { # Configuration for RCTokens generated for CSM workloads protected by IAP. # Settings to configure IAP&#x27;s behavior for a CSM mesh.
362 # RCTokens are IAP generated JWTs that can be verified at the application. The
363 # RCToken is primarily used for ISTIO deployments, and can be scoped to a
364 # single mesh by configuring the audience field accordingly
365 &quot;rctokenAud&quot;: &quot;A String&quot;, # Audience claim set in the generated RCToken. This value is not validated by
366 # IAP.
Dan O'Mearadd494642020-05-01 07:42:23 -0700367 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700368 &quot;cookieDomain&quot;: &quot;A String&quot;, # The Domain value to set for cookies generated by IAP. This value is not
369 # validated by the API, but will be ignored at runtime if invalid.
370 &quot;accessDeniedPageSettings&quot;: { # Custom content configuration for access denied page. # Customization for Access Denied page.
371 # IAP allows customers to define a custom URI to use as the error page when
372 # access is denied to users. If IAP prevents access to this page, the default
373 # IAP error page will be displayed instead.
374 &quot;accessDeniedPageUri&quot;: &quot;A String&quot;, # The URI to be redirected to when access is denied.
375 },
376 },
377 &quot;accessSettings&quot;: { # Access related settings for IAP protected apps. # Top level wrapper for all access related setting in IAP
378 &quot;corsSettings&quot;: { # Allows customers to configure HTTP request paths that&#x27;ll allow HTTP OPTIONS # Configuration to allow cross-origin requests via IAP.
379 # call to bypass authentication and authorization.
380 &quot;allowHttpOptions&quot;: True or False, # Configuration to allow HTTP OPTIONS calls to skip authorization. If
381 # undefined, IAP will not apply any special logic to OPTIONS requests.
382 },
383 &quot;gcipSettings&quot;: { # Allows customers to configure tenant_id for GCIP instance per-app. # GCIP claims and endpoint configurations for 3p identity providers.
384 &quot;loginPageUri&quot;: &quot;A String&quot;, # Login page URI associated with the GCIP tenants.
385 # Typically, all resources within the same project share the same login page,
386 # though it could be overridden at the sub resource level.
387 &quot;tenantIds&quot;: [ # GCIP tenant ids that are linked to the IAP resource.
388 # tenant_ids could be a string beginning with a number character to indicate
389 # authenticating with GCIP tenant flow, or in the format of _&lt;ProjectNumber&gt;
390 # to indicate authenticating with GCIP agent flow.
391 # If agent flow is used, tenant_ids should only contain one single element,
392 # while for tenant flow, tenant_ids can contain multiple elements.
393 &quot;A String&quot;,
394 ],
395 },
396 &quot;policyDelegationSettings&quot;: { # PolicyDelegationConfig allows google-internal teams to use IAP for apps # Settings to configure Policy delegation for apps hosted in tenant projects.
397 # INTERNAL_ONLY.
398 # hosted in a tenant project. Using these settings, the app can delegate
399 # permission check to happen against the linked customer project.
400 # This is only ever supposed to be used by google internal teams, hence the
401 # restriction on the proto.
402 &quot;iamServiceName&quot;: &quot;A String&quot;, # The DNS name of the service (e.g. &quot;resourcemanager.googleapis.com&quot;).
403 # This should be the domain name part of the full resource names (see
404 # https://aip.dev/122#full-resource-names), which is usually
405 # the same as IamServiceSpec.service of the service where the resource type
406 # is defined.
407 &quot;iamPermission&quot;: &quot;A String&quot;, # Permission to check in IAM.
408 &quot;policyName&quot;: { # Policy name to be checked
409 &quot;type&quot;: &quot;A String&quot;, # Valid values for type might be &#x27;gce&#x27;, &#x27;gcs&#x27;, &#x27;project&#x27;, &#x27;account&#x27; etc.
410 &quot;id&quot;: &quot;A String&quot;,
411 &quot;region&quot;: &quot;A String&quot;, # For Cloud IAM:
412 # The location of the Policy.
413 # Must be empty or &quot;global&quot; for Policies owned by global IAM. Must name a
414 # region from prodspec/cloud-iam-cloudspec for Regional IAM Policies, see
415 # go/iam-faq#where-is-iam-currently-deployed.
416 #
417 # For Local IAM:
418 # This field should be set to &quot;local&quot;.
Dan O'Mearadd494642020-05-01 07:42:23 -0700419 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700420 &quot;resource&quot;: { # IAM resource to check permission on
421 &quot;type&quot;: &quot;A String&quot;, # The public resource type name of the resource on which conditions will be
422 # evaluated. It is configured using the official_name of the ResourceType as
423 # defined in service configurations under //configs/cloud/resourcetypes.
424 # For example, the official_name for GCP projects is set as
425 # &#x27;cloudresourcemanager.googleapis.com/Project&#x27; according to
426 # //configs/cloud/resourcetypes/google/cloud/resourcemanager/prod.yaml
427 # For details see go/iam-conditions-integration-guide.
428 &quot;labels&quot;: { # The service defined labels of the resource on which the conditions will be
429 # evaluated. The semantics - including the key names - are vague to IAM.
430 # If the effective condition has a reference to a `resource.labels[foo]`
431 # construct, IAM consults with this map to retrieve the values associated
432 # with `foo` key for Conditions evaluation. If the provided key is not found
433 # in the labels map, the condition would evaluate to false.
434 #
435 # This field is in limited use. If your intended use case is not expected
436 # to express resource.labels attribute in IAM Conditions, leave this field
437 # empty. Before planning on using this attribute please:
438 # * Read go/iam-conditions-labels-comm and ensure your service can meet the
439 # data availability and management requirements.
440 # * Talk to iam-conditions-eng@ about your use case.
441 &quot;a_key&quot;: &quot;A String&quot;,
442 },
443 &quot;service&quot;: &quot;A String&quot;, # The name of the service this resource belongs to. It is configured using
444 # the official_service_name of the Service as defined in service
445 # configurations under //configs/cloud/resourcetypes.
446 # For example, the official_service_name of cloud resource manager service
447 # is set as &#x27;cloudresourcemanager.googleapis.com&#x27; according to
448 # //configs/cloud/resourcetypes/google/cloud/resourcemanager/prod.yaml
449 &quot;name&quot;: &quot;A String&quot;, # Name of the resource on which conditions will be evaluated.
450 # Must use the Relative Resource Name of the resource, which is the URI
451 # path of the resource without the leading &quot;/&quot;. Examples are
452 # &quot;projects/_/buckets/[BUCKET-ID]&quot; for storage buckets or
453 # &quot;projects/[PROJECT-ID]/global/firewalls/[FIREWALL-ID]&quot; for a firewall.
454 #
455 # This field is required for evaluating conditions with rules on resource
456 # names. For a `list` permission check, the resource.name value must be set
457 # to the parent resource. If the parent resource is a project, this field
458 # should be left unset.
459 },
Dan O'Mearadd494642020-05-01 07:42:23 -0700460 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700461 &quot;oauthSettings&quot;: { # Configuration for OAuth login&amp;consent flow behavior as well as for OAuth # Settings to configure IAP&#x27;s OAuth behavior.
462 # Credentials.
463 &quot;clientId&quot;: &quot;A String&quot;, # OAuth 2.0 client ID used in the OAuth flow to generate an access token. If
464 # this field is set, you can skip obtaining the OAuth credentials in this
465 # step:
466 # https://developers.google.com/identity/protocols/OAuth2?hl=en_US#1.-obtain-oauth-2.0-credentials-from-the-google-api-console.
467 # However, this could allow for client sharing. The risks of client sharing
468 # are outlined here:
469 # https://cloud.google.com/iap/docs/sharing-oauth-clients#risks.
470 &quot;loginHint&quot;: &quot;A String&quot;, # Domain hint to send as hd=? parameter in OAuth request flow. Enables
471 # redirect to primary IDP by skipping Google&#x27;s login screen.
472 # https://developers.google.com/identity/protocols/OpenIDConnect#hd-param
473 # Note: IAP does not verify that the id token&#x27;s hd claim matches this value
474 # since access behavior is managed by IAM policies.
475 },
Dan O'Mearadd494642020-05-01 07:42:23 -0700476 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700477 &quot;name&quot;: &quot;A String&quot;, # Required. The resource name of the IAP protected resource.
478 }</pre>
Dan O'Mearadd494642020-05-01 07:42:23 -0700479</div>
480
481<div class="method">
482 <code class="details" id="setIamPolicy">setIamPolicy(resource, body=None, x__xgafv=None)</code>
483 <pre>Sets the access control policy for an Identity-Aware Proxy protected
484resource. Replaces any existing policy.
485More information about managing access via IAP can be found at:
486https://cloud.google.com/iap/docs/managing-access#managing_access_via_the_api
487
488Args:
489 resource: string, REQUIRED: The resource for which the policy is being specified.
490See the operation documentation for the appropriate value for this field. (required)
491 body: object, The request body.
492 The object takes the form of:
493
494{ # Request message for `SetIamPolicy` method.
Bu Sun Kim65020912020-05-20 12:08:20 -0700495 &quot;policy&quot;: { # An Identity and Access Management (IAM) policy, which specifies access # REQUIRED: The complete policy to be applied to the `resource`. The size of
Dan O'Mearadd494642020-05-01 07:42:23 -0700496 # the policy is limited to a few 10s of KB. An empty policy is a
497 # valid policy but certain Cloud Platform services (such as Projects)
498 # might reject them.
499 # controls for Google Cloud resources.
500 #
501 #
502 # A `Policy` is a collection of `bindings`. A `binding` binds one or more
503 # `members` to a single `role`. Members can be user accounts, service accounts,
504 # Google groups, and domains (such as G Suite). A `role` is a named list of
505 # permissions; each `role` can be an IAM predefined role or a user-created
506 # custom role.
507 #
Bu Sun Kim65020912020-05-20 12:08:20 -0700508 # For some types of Google Cloud resources, a `binding` can also specify a
509 # `condition`, which is a logical expression that allows access to a resource
510 # only if the expression evaluates to `true`. A condition can add constraints
511 # based on attributes of the request, the resource, or both. To learn which
512 # resources support conditions in their IAM policies, see the
513 # [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
Dan O'Mearadd494642020-05-01 07:42:23 -0700514 #
515 # **JSON example:**
516 #
517 # {
Bu Sun Kim65020912020-05-20 12:08:20 -0700518 # &quot;bindings&quot;: [
Dan O'Mearadd494642020-05-01 07:42:23 -0700519 # {
Bu Sun Kim65020912020-05-20 12:08:20 -0700520 # &quot;role&quot;: &quot;roles/resourcemanager.organizationAdmin&quot;,
521 # &quot;members&quot;: [
522 # &quot;user:mike@example.com&quot;,
523 # &quot;group:admins@example.com&quot;,
524 # &quot;domain:google.com&quot;,
525 # &quot;serviceAccount:my-project-id@appspot.gserviceaccount.com&quot;
Dan O'Mearadd494642020-05-01 07:42:23 -0700526 # ]
527 # },
528 # {
Bu Sun Kim65020912020-05-20 12:08:20 -0700529 # &quot;role&quot;: &quot;roles/resourcemanager.organizationViewer&quot;,
530 # &quot;members&quot;: [
531 # &quot;user:eve@example.com&quot;
532 # ],
533 # &quot;condition&quot;: {
534 # &quot;title&quot;: &quot;expirable access&quot;,
535 # &quot;description&quot;: &quot;Does not grant access after Sep 2020&quot;,
536 # &quot;expression&quot;: &quot;request.time &lt; timestamp(&#x27;2020-10-01T00:00:00.000Z&#x27;)&quot;,
Dan O'Mearadd494642020-05-01 07:42:23 -0700537 # }
538 # }
539 # ],
Bu Sun Kim65020912020-05-20 12:08:20 -0700540 # &quot;etag&quot;: &quot;BwWWja0YfJA=&quot;,
541 # &quot;version&quot;: 3
Dan O'Mearadd494642020-05-01 07:42:23 -0700542 # }
543 #
544 # **YAML example:**
545 #
546 # bindings:
547 # - members:
548 # - user:mike@example.com
549 # - group:admins@example.com
550 # - domain:google.com
551 # - serviceAccount:my-project-id@appspot.gserviceaccount.com
552 # role: roles/resourcemanager.organizationAdmin
553 # - members:
554 # - user:eve@example.com
555 # role: roles/resourcemanager.organizationViewer
556 # condition:
557 # title: expirable access
558 # description: Does not grant access after Sep 2020
Bu Sun Kim65020912020-05-20 12:08:20 -0700559 # expression: request.time &lt; timestamp(&#x27;2020-10-01T00:00:00.000Z&#x27;)
Dan O'Mearadd494642020-05-01 07:42:23 -0700560 # - etag: BwWWja0YfJA=
561 # - version: 3
562 #
563 # For a description of IAM and its features, see the
564 # [IAM documentation](https://cloud.google.com/iam/docs/).
Bu Sun Kim65020912020-05-20 12:08:20 -0700565 &quot;etag&quot;: &quot;A String&quot;, # `etag` is used for optimistic concurrency control as a way to help
566 # prevent simultaneous updates of a policy from overwriting each other.
567 # It is strongly suggested that systems make use of the `etag` in the
568 # read-modify-write cycle to perform policy updates in order to avoid race
569 # conditions: An `etag` is returned in the response to `getIamPolicy`, and
570 # systems are expected to put that etag in the request to `setIamPolicy` to
571 # ensure that their change will be applied to the same version of the policy.
572 #
573 # **Important:** If you use IAM Conditions, you must include the `etag` field
574 # whenever you call `setIamPolicy`. If you omit this field, then IAM allows
575 # you to overwrite a version `3` policy with a version `1` policy, and all of
576 # the conditions in the version `3` policy are lost.
577 &quot;version&quot;: 42, # Specifies the format of the policy.
578 #
579 # Valid values are `0`, `1`, and `3`. Requests that specify an invalid value
580 # are rejected.
581 #
582 # Any operation that affects conditional role bindings must specify version
583 # `3`. This requirement applies to the following operations:
584 #
585 # * Getting a policy that includes a conditional role binding
586 # * Adding a conditional role binding to a policy
587 # * Changing a conditional role binding in a policy
588 # * Removing any role binding, with or without a condition, from a policy
589 # that includes conditions
590 #
591 # **Important:** If you use IAM Conditions, you must include the `etag` field
592 # whenever you call `setIamPolicy`. If you omit this field, then IAM allows
593 # you to overwrite a version `3` policy with a version `1` policy, and all of
594 # the conditions in the version `3` policy are lost.
595 #
596 # If a policy does not include any conditions, operations on that policy may
597 # specify any valid version or leave the field unset.
598 #
599 # To learn which resources support conditions in their IAM policies, see the
600 # [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
601 &quot;bindings&quot;: [ # Associates a list of `members` to a `role`. Optionally, may specify a
Dan O'Mearadd494642020-05-01 07:42:23 -0700602 # `condition` that determines how and when the `bindings` are applied. Each
603 # of the `bindings` must contain at least one member.
604 { # Associates `members` with a `role`.
Bu Sun Kim65020912020-05-20 12:08:20 -0700605 &quot;role&quot;: &quot;A String&quot;, # Role that is assigned to `members`.
Dan O'Mearadd494642020-05-01 07:42:23 -0700606 # For example, `roles/viewer`, `roles/editor`, or `roles/owner`.
Bu Sun Kim65020912020-05-20 12:08:20 -0700607 &quot;condition&quot;: { # Represents a textual expression in the Common Expression Language (CEL) # The condition that is associated with this binding.
608 #
609 # If the condition evaluates to `true`, then this binding applies to the
610 # current request.
611 #
612 # If the condition evaluates to `false`, then this binding does not apply to
613 # the current request. However, a different role binding might grant the same
614 # role to one or more of the members in this binding.
615 #
616 # To learn which resources support conditions in their IAM policies, see the
617 # [IAM
618 # documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
619 # syntax. CEL is a C-like expression language. The syntax and semantics of CEL
620 # are documented at https://github.com/google/cel-spec.
621 #
622 # Example (Comparison):
623 #
624 # title: &quot;Summary size limit&quot;
625 # description: &quot;Determines if a summary is less than 100 chars&quot;
626 # expression: &quot;document.summary.size() &lt; 100&quot;
627 #
628 # Example (Equality):
629 #
630 # title: &quot;Requestor is owner&quot;
631 # description: &quot;Determines if requestor is the document owner&quot;
632 # expression: &quot;document.owner == request.auth.claims.email&quot;
633 #
634 # Example (Logic):
635 #
636 # title: &quot;Public documents&quot;
637 # description: &quot;Determine whether the document should be publicly visible&quot;
638 # expression: &quot;document.type != &#x27;private&#x27; &amp;&amp; document.type != &#x27;internal&#x27;&quot;
639 #
640 # Example (Data Manipulation):
641 #
642 # title: &quot;Notification string&quot;
643 # description: &quot;Create a notification string with a timestamp.&quot;
644 # expression: &quot;&#x27;New message received at &#x27; + string(document.create_time)&quot;
645 #
646 # The exact variables and functions that may be referenced within an expression
647 # are determined by the service that evaluates it. See the service
648 # documentation for additional information.
649 &quot;expression&quot;: &quot;A String&quot;, # Textual representation of an expression in Common Expression Language
650 # syntax.
651 &quot;title&quot;: &quot;A String&quot;, # Optional. Title for the expression, i.e. a short string describing
652 # its purpose. This can be used e.g. in UIs which allow to enter the
653 # expression.
654 &quot;location&quot;: &quot;A String&quot;, # Optional. String indicating the location of the expression for error
655 # reporting, e.g. a file name and a position in the file.
656 &quot;description&quot;: &quot;A String&quot;, # Optional. Description of the expression. This is a longer text which
657 # describes the expression, e.g. when hovered over it in a UI.
658 },
659 &quot;members&quot;: [ # Specifies the identities requesting access for a Cloud Platform resource.
Dan O'Mearadd494642020-05-01 07:42:23 -0700660 # `members` can have the following values:
661 #
662 # * `allUsers`: A special identifier that represents anyone who is
663 # on the internet; with or without a Google account.
664 #
665 # * `allAuthenticatedUsers`: A special identifier that represents anyone
666 # who is authenticated with a Google account or a service account.
667 #
668 # * `user:{emailid}`: An email address that represents a specific Google
669 # account. For example, `alice@example.com` .
670 #
671 #
672 # * `serviceAccount:{emailid}`: An email address that represents a service
673 # account. For example, `my-other-app@appspot.gserviceaccount.com`.
674 #
675 # * `group:{emailid}`: An email address that represents a Google group.
676 # For example, `admins@example.com`.
677 #
678 # * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique
679 # identifier) representing a user that has been recently deleted. For
680 # example, `alice@example.com?uid=123456789012345678901`. If the user is
681 # recovered, this value reverts to `user:{emailid}` and the recovered user
682 # retains the role in the binding.
683 #
684 # * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus
685 # unique identifier) representing a service account that has been recently
686 # deleted. For example,
687 # `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`.
688 # If the service account is undeleted, this value reverts to
689 # `serviceAccount:{emailid}` and the undeleted service account retains the
690 # role in the binding.
691 #
692 # * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique
693 # identifier) representing a Google group that has been recently
694 # deleted. For example, `admins@example.com?uid=123456789012345678901`. If
695 # the group is recovered, this value reverts to `group:{emailid}` and the
696 # recovered group retains the role in the binding.
697 #
698 #
699 # * `domain:{domain}`: The G Suite domain (primary) that represents all the
700 # users of that domain. For example, `google.com` or `example.com`.
701 #
Bu Sun Kim65020912020-05-20 12:08:20 -0700702 &quot;A String&quot;,
Dan O'Mearadd494642020-05-01 07:42:23 -0700703 ],
Dan O'Mearadd494642020-05-01 07:42:23 -0700704 },
705 ],
Dan O'Mearadd494642020-05-01 07:42:23 -0700706 },
707 }
708
709 x__xgafv: string, V1 error format.
710 Allowed values
711 1 - v1 error format
712 2 - v2 error format
713
714Returns:
715 An object of the form:
716
717 { # An Identity and Access Management (IAM) policy, which specifies access
718 # controls for Google Cloud resources.
719 #
720 #
721 # A `Policy` is a collection of `bindings`. A `binding` binds one or more
722 # `members` to a single `role`. Members can be user accounts, service accounts,
723 # Google groups, and domains (such as G Suite). A `role` is a named list of
724 # permissions; each `role` can be an IAM predefined role or a user-created
725 # custom role.
726 #
Bu Sun Kim65020912020-05-20 12:08:20 -0700727 # For some types of Google Cloud resources, a `binding` can also specify a
728 # `condition`, which is a logical expression that allows access to a resource
729 # only if the expression evaluates to `true`. A condition can add constraints
730 # based on attributes of the request, the resource, or both. To learn which
731 # resources support conditions in their IAM policies, see the
732 # [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
Dan O'Mearadd494642020-05-01 07:42:23 -0700733 #
734 # **JSON example:**
735 #
736 # {
Bu Sun Kim65020912020-05-20 12:08:20 -0700737 # &quot;bindings&quot;: [
Dan O'Mearadd494642020-05-01 07:42:23 -0700738 # {
Bu Sun Kim65020912020-05-20 12:08:20 -0700739 # &quot;role&quot;: &quot;roles/resourcemanager.organizationAdmin&quot;,
740 # &quot;members&quot;: [
741 # &quot;user:mike@example.com&quot;,
742 # &quot;group:admins@example.com&quot;,
743 # &quot;domain:google.com&quot;,
744 # &quot;serviceAccount:my-project-id@appspot.gserviceaccount.com&quot;
Dan O'Mearadd494642020-05-01 07:42:23 -0700745 # ]
746 # },
747 # {
Bu Sun Kim65020912020-05-20 12:08:20 -0700748 # &quot;role&quot;: &quot;roles/resourcemanager.organizationViewer&quot;,
749 # &quot;members&quot;: [
750 # &quot;user:eve@example.com&quot;
751 # ],
752 # &quot;condition&quot;: {
753 # &quot;title&quot;: &quot;expirable access&quot;,
754 # &quot;description&quot;: &quot;Does not grant access after Sep 2020&quot;,
755 # &quot;expression&quot;: &quot;request.time &lt; timestamp(&#x27;2020-10-01T00:00:00.000Z&#x27;)&quot;,
Dan O'Mearadd494642020-05-01 07:42:23 -0700756 # }
757 # }
758 # ],
Bu Sun Kim65020912020-05-20 12:08:20 -0700759 # &quot;etag&quot;: &quot;BwWWja0YfJA=&quot;,
760 # &quot;version&quot;: 3
Dan O'Mearadd494642020-05-01 07:42:23 -0700761 # }
762 #
763 # **YAML example:**
764 #
765 # bindings:
766 # - members:
767 # - user:mike@example.com
768 # - group:admins@example.com
769 # - domain:google.com
770 # - serviceAccount:my-project-id@appspot.gserviceaccount.com
771 # role: roles/resourcemanager.organizationAdmin
772 # - members:
773 # - user:eve@example.com
774 # role: roles/resourcemanager.organizationViewer
775 # condition:
776 # title: expirable access
777 # description: Does not grant access after Sep 2020
Bu Sun Kim65020912020-05-20 12:08:20 -0700778 # expression: request.time &lt; timestamp(&#x27;2020-10-01T00:00:00.000Z&#x27;)
Dan O'Mearadd494642020-05-01 07:42:23 -0700779 # - etag: BwWWja0YfJA=
780 # - version: 3
781 #
782 # For a description of IAM and its features, see the
783 # [IAM documentation](https://cloud.google.com/iam/docs/).
Bu Sun Kim65020912020-05-20 12:08:20 -0700784 &quot;etag&quot;: &quot;A String&quot;, # `etag` is used for optimistic concurrency control as a way to help
785 # prevent simultaneous updates of a policy from overwriting each other.
786 # It is strongly suggested that systems make use of the `etag` in the
787 # read-modify-write cycle to perform policy updates in order to avoid race
788 # conditions: An `etag` is returned in the response to `getIamPolicy`, and
789 # systems are expected to put that etag in the request to `setIamPolicy` to
790 # ensure that their change will be applied to the same version of the policy.
791 #
792 # **Important:** If you use IAM Conditions, you must include the `etag` field
793 # whenever you call `setIamPolicy`. If you omit this field, then IAM allows
794 # you to overwrite a version `3` policy with a version `1` policy, and all of
795 # the conditions in the version `3` policy are lost.
796 &quot;version&quot;: 42, # Specifies the format of the policy.
797 #
798 # Valid values are `0`, `1`, and `3`. Requests that specify an invalid value
799 # are rejected.
800 #
801 # Any operation that affects conditional role bindings must specify version
802 # `3`. This requirement applies to the following operations:
803 #
804 # * Getting a policy that includes a conditional role binding
805 # * Adding a conditional role binding to a policy
806 # * Changing a conditional role binding in a policy
807 # * Removing any role binding, with or without a condition, from a policy
808 # that includes conditions
809 #
810 # **Important:** If you use IAM Conditions, you must include the `etag` field
811 # whenever you call `setIamPolicy`. If you omit this field, then IAM allows
812 # you to overwrite a version `3` policy with a version `1` policy, and all of
813 # the conditions in the version `3` policy are lost.
814 #
815 # If a policy does not include any conditions, operations on that policy may
816 # specify any valid version or leave the field unset.
817 #
818 # To learn which resources support conditions in their IAM policies, see the
819 # [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
820 &quot;bindings&quot;: [ # Associates a list of `members` to a `role`. Optionally, may specify a
Dan O'Mearadd494642020-05-01 07:42:23 -0700821 # `condition` that determines how and when the `bindings` are applied. Each
822 # of the `bindings` must contain at least one member.
823 { # Associates `members` with a `role`.
Bu Sun Kim65020912020-05-20 12:08:20 -0700824 &quot;role&quot;: &quot;A String&quot;, # Role that is assigned to `members`.
Dan O'Mearadd494642020-05-01 07:42:23 -0700825 # For example, `roles/viewer`, `roles/editor`, or `roles/owner`.
Bu Sun Kim65020912020-05-20 12:08:20 -0700826 &quot;condition&quot;: { # Represents a textual expression in the Common Expression Language (CEL) # The condition that is associated with this binding.
827 #
828 # If the condition evaluates to `true`, then this binding applies to the
829 # current request.
830 #
831 # If the condition evaluates to `false`, then this binding does not apply to
832 # the current request. However, a different role binding might grant the same
833 # role to one or more of the members in this binding.
834 #
835 # To learn which resources support conditions in their IAM policies, see the
836 # [IAM
837 # documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
838 # syntax. CEL is a C-like expression language. The syntax and semantics of CEL
839 # are documented at https://github.com/google/cel-spec.
840 #
841 # Example (Comparison):
842 #
843 # title: &quot;Summary size limit&quot;
844 # description: &quot;Determines if a summary is less than 100 chars&quot;
845 # expression: &quot;document.summary.size() &lt; 100&quot;
846 #
847 # Example (Equality):
848 #
849 # title: &quot;Requestor is owner&quot;
850 # description: &quot;Determines if requestor is the document owner&quot;
851 # expression: &quot;document.owner == request.auth.claims.email&quot;
852 #
853 # Example (Logic):
854 #
855 # title: &quot;Public documents&quot;
856 # description: &quot;Determine whether the document should be publicly visible&quot;
857 # expression: &quot;document.type != &#x27;private&#x27; &amp;&amp; document.type != &#x27;internal&#x27;&quot;
858 #
859 # Example (Data Manipulation):
860 #
861 # title: &quot;Notification string&quot;
862 # description: &quot;Create a notification string with a timestamp.&quot;
863 # expression: &quot;&#x27;New message received at &#x27; + string(document.create_time)&quot;
864 #
865 # The exact variables and functions that may be referenced within an expression
866 # are determined by the service that evaluates it. See the service
867 # documentation for additional information.
868 &quot;expression&quot;: &quot;A String&quot;, # Textual representation of an expression in Common Expression Language
869 # syntax.
870 &quot;title&quot;: &quot;A String&quot;, # Optional. Title for the expression, i.e. a short string describing
871 # its purpose. This can be used e.g. in UIs which allow to enter the
872 # expression.
873 &quot;location&quot;: &quot;A String&quot;, # Optional. String indicating the location of the expression for error
874 # reporting, e.g. a file name and a position in the file.
875 &quot;description&quot;: &quot;A String&quot;, # Optional. Description of the expression. This is a longer text which
876 # describes the expression, e.g. when hovered over it in a UI.
877 },
878 &quot;members&quot;: [ # Specifies the identities requesting access for a Cloud Platform resource.
Dan O'Mearadd494642020-05-01 07:42:23 -0700879 # `members` can have the following values:
880 #
881 # * `allUsers`: A special identifier that represents anyone who is
882 # on the internet; with or without a Google account.
883 #
884 # * `allAuthenticatedUsers`: A special identifier that represents anyone
885 # who is authenticated with a Google account or a service account.
886 #
887 # * `user:{emailid}`: An email address that represents a specific Google
888 # account. For example, `alice@example.com` .
889 #
890 #
891 # * `serviceAccount:{emailid}`: An email address that represents a service
892 # account. For example, `my-other-app@appspot.gserviceaccount.com`.
893 #
894 # * `group:{emailid}`: An email address that represents a Google group.
895 # For example, `admins@example.com`.
896 #
897 # * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique
898 # identifier) representing a user that has been recently deleted. For
899 # example, `alice@example.com?uid=123456789012345678901`. If the user is
900 # recovered, this value reverts to `user:{emailid}` and the recovered user
901 # retains the role in the binding.
902 #
903 # * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus
904 # unique identifier) representing a service account that has been recently
905 # deleted. For example,
906 # `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`.
907 # If the service account is undeleted, this value reverts to
908 # `serviceAccount:{emailid}` and the undeleted service account retains the
909 # role in the binding.
910 #
911 # * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique
912 # identifier) representing a Google group that has been recently
913 # deleted. For example, `admins@example.com?uid=123456789012345678901`. If
914 # the group is recovered, this value reverts to `group:{emailid}` and the
915 # recovered group retains the role in the binding.
916 #
917 #
918 # * `domain:{domain}`: The G Suite domain (primary) that represents all the
919 # users of that domain. For example, `google.com` or `example.com`.
920 #
Bu Sun Kim65020912020-05-20 12:08:20 -0700921 &quot;A String&quot;,
Dan O'Mearadd494642020-05-01 07:42:23 -0700922 ],
Dan O'Mearadd494642020-05-01 07:42:23 -0700923 },
924 ],
Dan O'Mearadd494642020-05-01 07:42:23 -0700925 }</pre>
926</div>
927
928<div class="method">
929 <code class="details" id="testIamPermissions">testIamPermissions(resource, body=None, x__xgafv=None)</code>
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700930 <pre>Returns permissions that a caller has on the Identity-Aware Proxy protected
931resource.
932More information about managing access via IAP can be found at:
933https://cloud.google.com/iap/docs/managing-access#managing_access_via_the_api
934
935Args:
936 resource: string, REQUIRED: The resource for which the policy detail is being requested.
937See the operation documentation for the appropriate value for this field. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700938 body: object, The request body.
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700939 The object takes the form of:
940
941{ # Request message for `TestIamPermissions` method.
Bu Sun Kim65020912020-05-20 12:08:20 -0700942 &quot;permissions&quot;: [ # The set of permissions to check for the `resource`. Permissions with
943 # wildcards (such as &#x27;*&#x27; or &#x27;storage.*&#x27;) are not allowed. For more
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700944 # information see
945 # [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions).
Bu Sun Kim65020912020-05-20 12:08:20 -0700946 &quot;A String&quot;,
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700947 ],
948 }
949
950 x__xgafv: string, V1 error format.
951 Allowed values
952 1 - v1 error format
953 2 - v2 error format
954
955Returns:
956 An object of the form:
957
958 { # Response message for `TestIamPermissions` method.
Bu Sun Kim65020912020-05-20 12:08:20 -0700959 &quot;permissions&quot;: [ # A subset of `TestPermissionsRequest.permissions` that the caller is
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700960 # allowed.
Bu Sun Kim65020912020-05-20 12:08:20 -0700961 &quot;A String&quot;,
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700962 ],
963 }</pre>
964</div>
965
Dan O'Mearadd494642020-05-01 07:42:23 -0700966<div class="method">
967 <code class="details" id="updateIapSettings">updateIapSettings(name, body=None, updateMask=None, x__xgafv=None)</code>
968 <pre>Updates the IAP settings on a particular IAP protected resource. It
969replaces all fields unless the `update_mask` is set.
970
971Args:
972 name: string, Required. The resource name of the IAP protected resource. (required)
973 body: object, The request body.
974 The object takes the form of:
975
976{ # The IAP configurable settings.
Bu Sun Kim65020912020-05-20 12:08:20 -0700977 &quot;applicationSettings&quot;: { # Wrapper over application specific settings for IAP. # Top level wrapper for all application related settings in IAP
978 &quot;csmSettings&quot;: { # Configuration for RCTokens generated for CSM workloads protected by IAP. # Settings to configure IAP&#x27;s behavior for a CSM mesh.
979 # RCTokens are IAP generated JWTs that can be verified at the application. The
980 # RCToken is primarily used for ISTIO deployments, and can be scoped to a
981 # single mesh by configuring the audience field accordingly
982 &quot;rctokenAud&quot;: &quot;A String&quot;, # Audience claim set in the generated RCToken. This value is not validated by
983 # IAP.
Dan O'Mearadd494642020-05-01 07:42:23 -0700984 },
Bu Sun Kim65020912020-05-20 12:08:20 -0700985 &quot;cookieDomain&quot;: &quot;A String&quot;, # The Domain value to set for cookies generated by IAP. This value is not
986 # validated by the API, but will be ignored at runtime if invalid.
987 &quot;accessDeniedPageSettings&quot;: { # Custom content configuration for access denied page. # Customization for Access Denied page.
988 # IAP allows customers to define a custom URI to use as the error page when
989 # access is denied to users. If IAP prevents access to this page, the default
990 # IAP error page will be displayed instead.
991 &quot;accessDeniedPageUri&quot;: &quot;A String&quot;, # The URI to be redirected to when access is denied.
992 },
993 },
994 &quot;accessSettings&quot;: { # Access related settings for IAP protected apps. # Top level wrapper for all access related setting in IAP
995 &quot;corsSettings&quot;: { # Allows customers to configure HTTP request paths that&#x27;ll allow HTTP OPTIONS # Configuration to allow cross-origin requests via IAP.
996 # call to bypass authentication and authorization.
997 &quot;allowHttpOptions&quot;: True or False, # Configuration to allow HTTP OPTIONS calls to skip authorization. If
998 # undefined, IAP will not apply any special logic to OPTIONS requests.
999 },
1000 &quot;gcipSettings&quot;: { # Allows customers to configure tenant_id for GCIP instance per-app. # GCIP claims and endpoint configurations for 3p identity providers.
1001 &quot;loginPageUri&quot;: &quot;A String&quot;, # Login page URI associated with the GCIP tenants.
1002 # Typically, all resources within the same project share the same login page,
1003 # though it could be overridden at the sub resource level.
1004 &quot;tenantIds&quot;: [ # GCIP tenant ids that are linked to the IAP resource.
1005 # tenant_ids could be a string beginning with a number character to indicate
1006 # authenticating with GCIP tenant flow, or in the format of _&lt;ProjectNumber&gt;
1007 # to indicate authenticating with GCIP agent flow.
1008 # If agent flow is used, tenant_ids should only contain one single element,
1009 # while for tenant flow, tenant_ids can contain multiple elements.
1010 &quot;A String&quot;,
1011 ],
1012 },
1013 &quot;policyDelegationSettings&quot;: { # PolicyDelegationConfig allows google-internal teams to use IAP for apps # Settings to configure Policy delegation for apps hosted in tenant projects.
1014 # INTERNAL_ONLY.
1015 # hosted in a tenant project. Using these settings, the app can delegate
1016 # permission check to happen against the linked customer project.
1017 # This is only ever supposed to be used by google internal teams, hence the
1018 # restriction on the proto.
1019 &quot;iamServiceName&quot;: &quot;A String&quot;, # The DNS name of the service (e.g. &quot;resourcemanager.googleapis.com&quot;).
1020 # This should be the domain name part of the full resource names (see
1021 # https://aip.dev/122#full-resource-names), which is usually
1022 # the same as IamServiceSpec.service of the service where the resource type
1023 # is defined.
1024 &quot;iamPermission&quot;: &quot;A String&quot;, # Permission to check in IAM.
1025 &quot;policyName&quot;: { # Policy name to be checked
1026 &quot;type&quot;: &quot;A String&quot;, # Valid values for type might be &#x27;gce&#x27;, &#x27;gcs&#x27;, &#x27;project&#x27;, &#x27;account&#x27; etc.
1027 &quot;id&quot;: &quot;A String&quot;,
1028 &quot;region&quot;: &quot;A String&quot;, # For Cloud IAM:
1029 # The location of the Policy.
1030 # Must be empty or &quot;global&quot; for Policies owned by global IAM. Must name a
1031 # region from prodspec/cloud-iam-cloudspec for Regional IAM Policies, see
1032 # go/iam-faq#where-is-iam-currently-deployed.
1033 #
1034 # For Local IAM:
1035 # This field should be set to &quot;local&quot;.
Dan O'Mearadd494642020-05-01 07:42:23 -07001036 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001037 &quot;resource&quot;: { # IAM resource to check permission on
1038 &quot;type&quot;: &quot;A String&quot;, # The public resource type name of the resource on which conditions will be
1039 # evaluated. It is configured using the official_name of the ResourceType as
1040 # defined in service configurations under //configs/cloud/resourcetypes.
1041 # For example, the official_name for GCP projects is set as
1042 # &#x27;cloudresourcemanager.googleapis.com/Project&#x27; according to
1043 # //configs/cloud/resourcetypes/google/cloud/resourcemanager/prod.yaml
1044 # For details see go/iam-conditions-integration-guide.
1045 &quot;labels&quot;: { # The service defined labels of the resource on which the conditions will be
1046 # evaluated. The semantics - including the key names - are vague to IAM.
1047 # If the effective condition has a reference to a `resource.labels[foo]`
1048 # construct, IAM consults with this map to retrieve the values associated
1049 # with `foo` key for Conditions evaluation. If the provided key is not found
1050 # in the labels map, the condition would evaluate to false.
1051 #
1052 # This field is in limited use. If your intended use case is not expected
1053 # to express resource.labels attribute in IAM Conditions, leave this field
1054 # empty. Before planning on using this attribute please:
1055 # * Read go/iam-conditions-labels-comm and ensure your service can meet the
1056 # data availability and management requirements.
1057 # * Talk to iam-conditions-eng@ about your use case.
1058 &quot;a_key&quot;: &quot;A String&quot;,
1059 },
1060 &quot;service&quot;: &quot;A String&quot;, # The name of the service this resource belongs to. It is configured using
1061 # the official_service_name of the Service as defined in service
1062 # configurations under //configs/cloud/resourcetypes.
1063 # For example, the official_service_name of cloud resource manager service
1064 # is set as &#x27;cloudresourcemanager.googleapis.com&#x27; according to
1065 # //configs/cloud/resourcetypes/google/cloud/resourcemanager/prod.yaml
1066 &quot;name&quot;: &quot;A String&quot;, # Name of the resource on which conditions will be evaluated.
1067 # Must use the Relative Resource Name of the resource, which is the URI
1068 # path of the resource without the leading &quot;/&quot;. Examples are
1069 # &quot;projects/_/buckets/[BUCKET-ID]&quot; for storage buckets or
1070 # &quot;projects/[PROJECT-ID]/global/firewalls/[FIREWALL-ID]&quot; for a firewall.
1071 #
1072 # This field is required for evaluating conditions with rules on resource
1073 # names. For a `list` permission check, the resource.name value must be set
1074 # to the parent resource. If the parent resource is a project, this field
1075 # should be left unset.
1076 },
Dan O'Mearadd494642020-05-01 07:42:23 -07001077 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001078 &quot;oauthSettings&quot;: { # Configuration for OAuth login&amp;consent flow behavior as well as for OAuth # Settings to configure IAP&#x27;s OAuth behavior.
1079 # Credentials.
1080 &quot;clientId&quot;: &quot;A String&quot;, # OAuth 2.0 client ID used in the OAuth flow to generate an access token. If
1081 # this field is set, you can skip obtaining the OAuth credentials in this
1082 # step:
1083 # https://developers.google.com/identity/protocols/OAuth2?hl=en_US#1.-obtain-oauth-2.0-credentials-from-the-google-api-console.
1084 # However, this could allow for client sharing. The risks of client sharing
1085 # are outlined here:
1086 # https://cloud.google.com/iap/docs/sharing-oauth-clients#risks.
1087 &quot;loginHint&quot;: &quot;A String&quot;, # Domain hint to send as hd=? parameter in OAuth request flow. Enables
1088 # redirect to primary IDP by skipping Google&#x27;s login screen.
1089 # https://developers.google.com/identity/protocols/OpenIDConnect#hd-param
1090 # Note: IAP does not verify that the id token&#x27;s hd claim matches this value
1091 # since access behavior is managed by IAM policies.
1092 },
Dan O'Mearadd494642020-05-01 07:42:23 -07001093 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001094 &quot;name&quot;: &quot;A String&quot;, # Required. The resource name of the IAP protected resource.
1095 }
Dan O'Mearadd494642020-05-01 07:42:23 -07001096
1097 updateMask: string, The field mask specifying which IAP settings should be updated.
1098If omitted, the all of the settings are updated. See
1099https://developers.google.com/protocol-buffers/docs/reference/google.protobuf#fieldmask
1100 x__xgafv: string, V1 error format.
1101 Allowed values
1102 1 - v1 error format
1103 2 - v2 error format
1104
1105Returns:
1106 An object of the form:
1107
1108 { # The IAP configurable settings.
Bu Sun Kim65020912020-05-20 12:08:20 -07001109 &quot;applicationSettings&quot;: { # Wrapper over application specific settings for IAP. # Top level wrapper for all application related settings in IAP
1110 &quot;csmSettings&quot;: { # Configuration for RCTokens generated for CSM workloads protected by IAP. # Settings to configure IAP&#x27;s behavior for a CSM mesh.
1111 # RCTokens are IAP generated JWTs that can be verified at the application. The
1112 # RCToken is primarily used for ISTIO deployments, and can be scoped to a
1113 # single mesh by configuring the audience field accordingly
1114 &quot;rctokenAud&quot;: &quot;A String&quot;, # Audience claim set in the generated RCToken. This value is not validated by
1115 # IAP.
Dan O'Mearadd494642020-05-01 07:42:23 -07001116 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001117 &quot;cookieDomain&quot;: &quot;A String&quot;, # The Domain value to set for cookies generated by IAP. This value is not
1118 # validated by the API, but will be ignored at runtime if invalid.
1119 &quot;accessDeniedPageSettings&quot;: { # Custom content configuration for access denied page. # Customization for Access Denied page.
1120 # IAP allows customers to define a custom URI to use as the error page when
1121 # access is denied to users. If IAP prevents access to this page, the default
1122 # IAP error page will be displayed instead.
1123 &quot;accessDeniedPageUri&quot;: &quot;A String&quot;, # The URI to be redirected to when access is denied.
1124 },
1125 },
1126 &quot;accessSettings&quot;: { # Access related settings for IAP protected apps. # Top level wrapper for all access related setting in IAP
1127 &quot;corsSettings&quot;: { # Allows customers to configure HTTP request paths that&#x27;ll allow HTTP OPTIONS # Configuration to allow cross-origin requests via IAP.
1128 # call to bypass authentication and authorization.
1129 &quot;allowHttpOptions&quot;: True or False, # Configuration to allow HTTP OPTIONS calls to skip authorization. If
1130 # undefined, IAP will not apply any special logic to OPTIONS requests.
1131 },
1132 &quot;gcipSettings&quot;: { # Allows customers to configure tenant_id for GCIP instance per-app. # GCIP claims and endpoint configurations for 3p identity providers.
1133 &quot;loginPageUri&quot;: &quot;A String&quot;, # Login page URI associated with the GCIP tenants.
1134 # Typically, all resources within the same project share the same login page,
1135 # though it could be overridden at the sub resource level.
1136 &quot;tenantIds&quot;: [ # GCIP tenant ids that are linked to the IAP resource.
1137 # tenant_ids could be a string beginning with a number character to indicate
1138 # authenticating with GCIP tenant flow, or in the format of _&lt;ProjectNumber&gt;
1139 # to indicate authenticating with GCIP agent flow.
1140 # If agent flow is used, tenant_ids should only contain one single element,
1141 # while for tenant flow, tenant_ids can contain multiple elements.
1142 &quot;A String&quot;,
1143 ],
1144 },
1145 &quot;policyDelegationSettings&quot;: { # PolicyDelegationConfig allows google-internal teams to use IAP for apps # Settings to configure Policy delegation for apps hosted in tenant projects.
1146 # INTERNAL_ONLY.
1147 # hosted in a tenant project. Using these settings, the app can delegate
1148 # permission check to happen against the linked customer project.
1149 # This is only ever supposed to be used by google internal teams, hence the
1150 # restriction on the proto.
1151 &quot;iamServiceName&quot;: &quot;A String&quot;, # The DNS name of the service (e.g. &quot;resourcemanager.googleapis.com&quot;).
1152 # This should be the domain name part of the full resource names (see
1153 # https://aip.dev/122#full-resource-names), which is usually
1154 # the same as IamServiceSpec.service of the service where the resource type
1155 # is defined.
1156 &quot;iamPermission&quot;: &quot;A String&quot;, # Permission to check in IAM.
1157 &quot;policyName&quot;: { # Policy name to be checked
1158 &quot;type&quot;: &quot;A String&quot;, # Valid values for type might be &#x27;gce&#x27;, &#x27;gcs&#x27;, &#x27;project&#x27;, &#x27;account&#x27; etc.
1159 &quot;id&quot;: &quot;A String&quot;,
1160 &quot;region&quot;: &quot;A String&quot;, # For Cloud IAM:
1161 # The location of the Policy.
1162 # Must be empty or &quot;global&quot; for Policies owned by global IAM. Must name a
1163 # region from prodspec/cloud-iam-cloudspec for Regional IAM Policies, see
1164 # go/iam-faq#where-is-iam-currently-deployed.
1165 #
1166 # For Local IAM:
1167 # This field should be set to &quot;local&quot;.
Dan O'Mearadd494642020-05-01 07:42:23 -07001168 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001169 &quot;resource&quot;: { # IAM resource to check permission on
1170 &quot;type&quot;: &quot;A String&quot;, # The public resource type name of the resource on which conditions will be
1171 # evaluated. It is configured using the official_name of the ResourceType as
1172 # defined in service configurations under //configs/cloud/resourcetypes.
1173 # For example, the official_name for GCP projects is set as
1174 # &#x27;cloudresourcemanager.googleapis.com/Project&#x27; according to
1175 # //configs/cloud/resourcetypes/google/cloud/resourcemanager/prod.yaml
1176 # For details see go/iam-conditions-integration-guide.
1177 &quot;labels&quot;: { # The service defined labels of the resource on which the conditions will be
1178 # evaluated. The semantics - including the key names - are vague to IAM.
1179 # If the effective condition has a reference to a `resource.labels[foo]`
1180 # construct, IAM consults with this map to retrieve the values associated
1181 # with `foo` key for Conditions evaluation. If the provided key is not found
1182 # in the labels map, the condition would evaluate to false.
1183 #
1184 # This field is in limited use. If your intended use case is not expected
1185 # to express resource.labels attribute in IAM Conditions, leave this field
1186 # empty. Before planning on using this attribute please:
1187 # * Read go/iam-conditions-labels-comm and ensure your service can meet the
1188 # data availability and management requirements.
1189 # * Talk to iam-conditions-eng@ about your use case.
1190 &quot;a_key&quot;: &quot;A String&quot;,
1191 },
1192 &quot;service&quot;: &quot;A String&quot;, # The name of the service this resource belongs to. It is configured using
1193 # the official_service_name of the Service as defined in service
1194 # configurations under //configs/cloud/resourcetypes.
1195 # For example, the official_service_name of cloud resource manager service
1196 # is set as &#x27;cloudresourcemanager.googleapis.com&#x27; according to
1197 # //configs/cloud/resourcetypes/google/cloud/resourcemanager/prod.yaml
1198 &quot;name&quot;: &quot;A String&quot;, # Name of the resource on which conditions will be evaluated.
1199 # Must use the Relative Resource Name of the resource, which is the URI
1200 # path of the resource without the leading &quot;/&quot;. Examples are
1201 # &quot;projects/_/buckets/[BUCKET-ID]&quot; for storage buckets or
1202 # &quot;projects/[PROJECT-ID]/global/firewalls/[FIREWALL-ID]&quot; for a firewall.
1203 #
1204 # This field is required for evaluating conditions with rules on resource
1205 # names. For a `list` permission check, the resource.name value must be set
1206 # to the parent resource. If the parent resource is a project, this field
1207 # should be left unset.
1208 },
Dan O'Mearadd494642020-05-01 07:42:23 -07001209 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001210 &quot;oauthSettings&quot;: { # Configuration for OAuth login&amp;consent flow behavior as well as for OAuth # Settings to configure IAP&#x27;s OAuth behavior.
1211 # Credentials.
1212 &quot;clientId&quot;: &quot;A String&quot;, # OAuth 2.0 client ID used in the OAuth flow to generate an access token. If
1213 # this field is set, you can skip obtaining the OAuth credentials in this
1214 # step:
1215 # https://developers.google.com/identity/protocols/OAuth2?hl=en_US#1.-obtain-oauth-2.0-credentials-from-the-google-api-console.
1216 # However, this could allow for client sharing. The risks of client sharing
1217 # are outlined here:
1218 # https://cloud.google.com/iap/docs/sharing-oauth-clients#risks.
1219 &quot;loginHint&quot;: &quot;A String&quot;, # Domain hint to send as hd=? parameter in OAuth request flow. Enables
1220 # redirect to primary IDP by skipping Google&#x27;s login screen.
1221 # https://developers.google.com/identity/protocols/OpenIDConnect#hd-param
1222 # Note: IAP does not verify that the id token&#x27;s hd claim matches this value
1223 # since access behavior is managed by IAM policies.
1224 },
Dan O'Mearadd494642020-05-01 07:42:23 -07001225 },
Bu Sun Kim65020912020-05-20 12:08:20 -07001226 &quot;name&quot;: &quot;A String&quot;, # Required. The resource name of the IAP protected resource.
1227 }</pre>
Dan O'Mearadd494642020-05-01 07:42:23 -07001228</div>
1229
Bu Sun Kim715bd7f2019-06-14 16:50:42 -07001230</body></html>