blob: 2d282dda2b65f2d2bb3480f6ec2164866c994837 [file] [log] [blame]
Craig Citroe633be12015-03-02 13:40:36 -08001<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
Bu Sun Kim715bd7f2019-06-14 16:50:42 -070075<h1><a href="pubsub_v1beta2.html">Cloud Pub/Sub API</a> . <a href="pubsub_v1beta2.projects.html">projects</a> . <a href="pubsub_v1beta2.projects.topics.html">topics</a></h1>
Craig Citroe633be12015-03-02 13:40:36 -080076<h2>Instance Methods</h2>
77<p class="toc_element">
78 <code><a href="pubsub_v1beta2.projects.topics.subscriptions.html">subscriptions()</a></code>
79</p>
80<p class="firstline">Returns the subscriptions Resource.</p>
81
82<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -070083 <code><a href="#create">create(name, body=None, x__xgafv=None)</a></code></p>
Craig Citroe633be12015-03-02 13:40:36 -080084<p class="firstline">Creates the given topic with the given name.</p>
85<p class="toc_element">
Nathaniel Manista4f877e52015-06-15 16:44:50 +000086 <code><a href="#delete">delete(topic, x__xgafv=None)</a></code></p>
Jon Wayne Parrott692617a2017-01-06 09:58:29 -080087<p class="firstline">Deletes the topic with the given name. Returns `NOT_FOUND` if the topic</p>
Craig Citroe633be12015-03-02 13:40:36 -080088<p class="toc_element">
Nathaniel Manista4f877e52015-06-15 16:44:50 +000089 <code><a href="#get">get(topic, x__xgafv=None)</a></code></p>
Craig Citroe633be12015-03-02 13:40:36 -080090<p class="firstline">Gets the configuration of a topic.</p>
91<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -070092 <code><a href="#getIamPolicy">getIamPolicy(resource, options_requestedPolicyVersion=None, x__xgafv=None)</a></code></p>
Jon Wayne Parrott692617a2017-01-06 09:58:29 -080093<p class="firstline">Gets the access control policy for a resource.</p>
Nathaniel Manista4f877e52015-06-15 16:44:50 +000094<p class="toc_element">
Bu Sun Kim65020912020-05-20 12:08:20 -070095 <code><a href="#list">list(project, pageToken=None, pageSize=None, x__xgafv=None)</a></code></p>
Craig Citroe633be12015-03-02 13:40:36 -080096<p class="firstline">Lists matching topics.</p>
97<p class="toc_element">
98 <code><a href="#list_next">list_next(previous_request, previous_response)</a></code></p>
99<p class="firstline">Retrieves the next page of results.</p>
100<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -0700101 <code><a href="#publish">publish(topic, body=None, x__xgafv=None)</a></code></p>
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800102<p class="firstline">Adds one or more messages to the topic. Returns `NOT_FOUND` if the topic</p>
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000103<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -0700104 <code><a href="#setIamPolicy">setIamPolicy(resource, body=None, x__xgafv=None)</a></code></p>
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800105<p class="firstline">Sets the access control policy on the specified resource. Replaces any</p>
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000106<p class="toc_element">
Dan O'Mearadd494642020-05-01 07:42:23 -0700107 <code><a href="#testIamPermissions">testIamPermissions(resource, body=None, x__xgafv=None)</a></code></p>
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000108<p class="firstline">Returns permissions that a caller has on the specified resource.</p>
Craig Citroe633be12015-03-02 13:40:36 -0800109<h3>Method Details</h3>
110<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -0700111 <code class="details" id="create">create(name, body=None, x__xgafv=None)</code>
Craig Citroe633be12015-03-02 13:40:36 -0800112 <pre>Creates the given topic with the given name.
113
114Args:
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800115 name: string, The name of the topic. It must have the format
Bu Sun Kim65020912020-05-20 12:08:20 -0700116`&quot;projects/{project}/topics/{topic}&quot;`. `{topic}` must start with a letter,
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800117and contain only letters (`[A-Za-z]`), numbers (`[0-9]`), dashes (`-`),
118underscores (`_`), periods (`.`), tildes (`~`), plus (`+`) or percent
119signs (`%`). It must be between 3 and 255 characters in length, and it
Bu Sun Kim65020912020-05-20 12:08:20 -0700120must not start with `&quot;goog&quot;`. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700121 body: object, The request body.
Craig Citroe633be12015-03-02 13:40:36 -0800122 The object takes the form of:
123
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000124{ # A topic resource.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700125 &quot;name&quot;: &quot;A String&quot;, # The name of the topic. It must have the format
126 # `&quot;projects/{project}/topics/{topic}&quot;`. `{topic}` must start with a letter,
127 # and contain only letters (`[A-Za-z]`), numbers (`[0-9]`), dashes (`-`),
128 # underscores (`_`), periods (`.`), tildes (`~`), plus (`+`) or percent
129 # signs (`%`). It must be between 3 and 255 characters in length, and it
130 # must not start with `&quot;goog&quot;`.
131 }
Craig Citroe633be12015-03-02 13:40:36 -0800132
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000133 x__xgafv: string, V1 error format.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800134 Allowed values
135 1 - v1 error format
136 2 - v2 error format
Craig Citroe633be12015-03-02 13:40:36 -0800137
138Returns:
139 An object of the form:
140
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000141 { # A topic resource.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700142 &quot;name&quot;: &quot;A String&quot;, # The name of the topic. It must have the format
143 # `&quot;projects/{project}/topics/{topic}&quot;`. `{topic}` must start with a letter,
144 # and contain only letters (`[A-Za-z]`), numbers (`[0-9]`), dashes (`-`),
145 # underscores (`_`), periods (`.`), tildes (`~`), plus (`+`) or percent
146 # signs (`%`). It must be between 3 and 255 characters in length, and it
147 # must not start with `&quot;goog&quot;`.
148 }</pre>
Craig Citroe633be12015-03-02 13:40:36 -0800149</div>
150
151<div class="method">
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000152 <code class="details" id="delete">delete(topic, x__xgafv=None)</code>
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800153 <pre>Deletes the topic with the given name. Returns `NOT_FOUND` if the topic
154does not exist. After a topic is deleted, a new topic may be created with
155the same name; this is an entirely new topic with none of the old
156configuration or subscriptions. Existing subscriptions to this topic are
157not deleted, but their `topic` field is set to `_deleted-topic_`.
Craig Citroe633be12015-03-02 13:40:36 -0800158
159Args:
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000160 topic: string, Name of the topic to delete. (required)
161 x__xgafv: string, V1 error format.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800162 Allowed values
163 1 - v1 error format
164 2 - v2 error format
Craig Citroe633be12015-03-02 13:40:36 -0800165
166Returns:
167 An object of the form:
168
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800169 { # A generic empty message that you can re-use to avoid defining duplicated
170 # empty messages in your APIs. A typical example is to use it as the request
171 # or the response type of an API method. For instance:
172 #
173 # service Foo {
174 # rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty);
175 # }
176 #
177 # The JSON representation for `Empty` is empty JSON object `{}`.
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000178 }</pre>
Craig Citroe633be12015-03-02 13:40:36 -0800179</div>
180
181<div class="method">
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000182 <code class="details" id="get">get(topic, x__xgafv=None)</code>
183 <pre>Gets the configuration of a topic.
Craig Citroe633be12015-03-02 13:40:36 -0800184
185Args:
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000186 topic: string, The name of the topic to get. (required)
187 x__xgafv: string, V1 error format.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800188 Allowed values
189 1 - v1 error format
190 2 - v2 error format
Craig Citroe633be12015-03-02 13:40:36 -0800191
192Returns:
193 An object of the form:
194
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000195 { # A topic resource.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700196 &quot;name&quot;: &quot;A String&quot;, # The name of the topic. It must have the format
197 # `&quot;projects/{project}/topics/{topic}&quot;`. `{topic}` must start with a letter,
198 # and contain only letters (`[A-Za-z]`), numbers (`[0-9]`), dashes (`-`),
199 # underscores (`_`), periods (`.`), tildes (`~`), plus (`+`) or percent
200 # signs (`%`). It must be between 3 and 255 characters in length, and it
201 # must not start with `&quot;goog&quot;`.
202 }</pre>
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000203</div>
204
205<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -0700206 <code class="details" id="getIamPolicy">getIamPolicy(resource, options_requestedPolicyVersion=None, x__xgafv=None)</code>
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800207 <pre>Gets the access control policy for a resource.
208Returns an empty policy if the resource exists and does not have a policy
209set.
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000210
211Args:
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800212 resource: string, REQUIRED: The resource for which the policy is being requested.
Sai Cheemalapatie833b792017-03-24 15:06:46 -0700213See the operation documentation for the appropriate value for this field. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700214 options_requestedPolicyVersion: integer, Optional. The policy format version to be returned.
215
216Valid values are 0, 1, and 3. Requests specifying an invalid value will be
217rejected.
218
219Requests for policies with any conditional bindings must specify version 3.
220Policies without any conditional bindings may specify any valid value or
221leave the field unset.
Bu Sun Kim65020912020-05-20 12:08:20 -0700222
223To learn which resources support conditions in their IAM policies, see the
224[IAM
225documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000226 x__xgafv: string, V1 error format.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800227 Allowed values
228 1 - v1 error format
229 2 - v2 error format
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000230
231Returns:
232 An object of the form:
233
Dan O'Mearadd494642020-05-01 07:42:23 -0700234 { # An Identity and Access Management (IAM) policy, which specifies access
235 # controls for Google Cloud resources.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800236 #
237 #
Dan O'Mearadd494642020-05-01 07:42:23 -0700238 # A `Policy` is a collection of `bindings`. A `binding` binds one or more
239 # `members` to a single `role`. Members can be user accounts, service accounts,
240 # Google groups, and domains (such as G Suite). A `role` is a named list of
241 # permissions; each `role` can be an IAM predefined role or a user-created
242 # custom role.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800243 #
Bu Sun Kim65020912020-05-20 12:08:20 -0700244 # For some types of Google Cloud resources, a `binding` can also specify a
245 # `condition`, which is a logical expression that allows access to a resource
246 # only if the expression evaluates to `true`. A condition can add constraints
247 # based on attributes of the request, the resource, or both. To learn which
248 # resources support conditions in their IAM policies, see the
249 # [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
Dan O'Mearadd494642020-05-01 07:42:23 -0700250 #
251 # **JSON example:**
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800252 #
253 # {
Bu Sun Kim65020912020-05-20 12:08:20 -0700254 # &quot;bindings&quot;: [
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800255 # {
Bu Sun Kim65020912020-05-20 12:08:20 -0700256 # &quot;role&quot;: &quot;roles/resourcemanager.organizationAdmin&quot;,
257 # &quot;members&quot;: [
258 # &quot;user:mike@example.com&quot;,
259 # &quot;group:admins@example.com&quot;,
260 # &quot;domain:google.com&quot;,
261 # &quot;serviceAccount:my-project-id@appspot.gserviceaccount.com&quot;
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800262 # ]
263 # },
264 # {
Bu Sun Kim65020912020-05-20 12:08:20 -0700265 # &quot;role&quot;: &quot;roles/resourcemanager.organizationViewer&quot;,
266 # &quot;members&quot;: [
267 # &quot;user:eve@example.com&quot;
268 # ],
269 # &quot;condition&quot;: {
270 # &quot;title&quot;: &quot;expirable access&quot;,
271 # &quot;description&quot;: &quot;Does not grant access after Sep 2020&quot;,
272 # &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 -0700273 # }
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800274 # }
Dan O'Mearadd494642020-05-01 07:42:23 -0700275 # ],
Bu Sun Kim65020912020-05-20 12:08:20 -0700276 # &quot;etag&quot;: &quot;BwWWja0YfJA=&quot;,
277 # &quot;version&quot;: 3
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800278 # }
279 #
Dan O'Mearadd494642020-05-01 07:42:23 -0700280 # **YAML example:**
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700281 #
282 # bindings:
283 # - members:
284 # - user:mike@example.com
285 # - group:admins@example.com
286 # - domain:google.com
Dan O'Mearadd494642020-05-01 07:42:23 -0700287 # - serviceAccount:my-project-id@appspot.gserviceaccount.com
288 # role: roles/resourcemanager.organizationAdmin
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700289 # - members:
Dan O'Mearadd494642020-05-01 07:42:23 -0700290 # - user:eve@example.com
291 # role: roles/resourcemanager.organizationViewer
292 # condition:
293 # title: expirable access
294 # description: Does not grant access after Sep 2020
Bu Sun Kim65020912020-05-20 12:08:20 -0700295 # expression: request.time &lt; timestamp(&#x27;2020-10-01T00:00:00.000Z&#x27;)
Dan O'Mearadd494642020-05-01 07:42:23 -0700296 # - etag: BwWWja0YfJA=
297 # - version: 3
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700298 #
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800299 # For a description of IAM and its features, see the
Dan O'Mearadd494642020-05-01 07:42:23 -0700300 # [IAM documentation](https://cloud.google.com/iam/docs/).
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700301 &quot;version&quot;: 42, # Specifies the format of the policy.
302 #
303 # Valid values are `0`, `1`, and `3`. Requests that specify an invalid value
304 # are rejected.
305 #
306 # Any operation that affects conditional role bindings must specify version
307 # `3`. This requirement applies to the following operations:
308 #
309 # * Getting a policy that includes a conditional role binding
310 # * Adding a conditional role binding to a policy
311 # * Changing a conditional role binding in a policy
312 # * Removing any role binding, with or without a condition, from a policy
313 # that includes conditions
314 #
315 # **Important:** If you use IAM Conditions, you must include the `etag` field
316 # whenever you call `setIamPolicy`. If you omit this field, then IAM allows
317 # you to overwrite a version `3` policy with a version `1` policy, and all of
318 # the conditions in the version `3` policy are lost.
319 #
320 # If a policy does not include any conditions, operations on that policy may
321 # specify any valid version or leave the field unset.
322 #
323 # To learn which resources support conditions in their IAM policies, see the
324 # [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700325 &quot;etag&quot;: &quot;A String&quot;, # `etag` is used for optimistic concurrency control as a way to help
326 # prevent simultaneous updates of a policy from overwriting each other.
327 # It is strongly suggested that systems make use of the `etag` in the
328 # read-modify-write cycle to perform policy updates in order to avoid race
329 # conditions: An `etag` is returned in the response to `getIamPolicy`, and
330 # systems are expected to put that etag in the request to `setIamPolicy` to
331 # ensure that their change will be applied to the same version of the policy.
332 #
333 # **Important:** If you use IAM Conditions, you must include the `etag` field
334 # whenever you call `setIamPolicy`. If you omit this field, then IAM allows
335 # you to overwrite a version `3` policy with a version `1` policy, and all of
336 # the conditions in the version `3` policy are lost.
Bu Sun Kim65020912020-05-20 12:08:20 -0700337 &quot;bindings&quot;: [ # Associates a list of `members` to a `role`. Optionally, may specify a
Dan O'Mearadd494642020-05-01 07:42:23 -0700338 # `condition` that determines how and when the `bindings` are applied. Each
339 # of the `bindings` must contain at least one member.
Sai Cheemalapatidf613972016-10-21 13:59:49 -0700340 { # Associates `members` with a `role`.
Bu Sun Kim65020912020-05-20 12:08:20 -0700341 &quot;role&quot;: &quot;A String&quot;, # Role that is assigned to `members`.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800342 # For example, `roles/viewer`, `roles/editor`, or `roles/owner`.
Bu Sun Kim65020912020-05-20 12:08:20 -0700343 &quot;condition&quot;: { # Represents a textual expression in the Common Expression Language (CEL) # The condition that is associated with this binding.
344 #
345 # If the condition evaluates to `true`, then this binding applies to the
346 # current request.
347 #
348 # If the condition evaluates to `false`, then this binding does not apply to
349 # the current request. However, a different role binding might grant the same
350 # role to one or more of the members in this binding.
351 #
352 # To learn which resources support conditions in their IAM policies, see the
353 # [IAM
354 # documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
355 # syntax. CEL is a C-like expression language. The syntax and semantics of CEL
356 # are documented at https://github.com/google/cel-spec.
357 #
358 # Example (Comparison):
359 #
360 # title: &quot;Summary size limit&quot;
361 # description: &quot;Determines if a summary is less than 100 chars&quot;
362 # expression: &quot;document.summary.size() &lt; 100&quot;
363 #
364 # Example (Equality):
365 #
366 # title: &quot;Requestor is owner&quot;
367 # description: &quot;Determines if requestor is the document owner&quot;
368 # expression: &quot;document.owner == request.auth.claims.email&quot;
369 #
370 # Example (Logic):
371 #
372 # title: &quot;Public documents&quot;
373 # description: &quot;Determine whether the document should be publicly visible&quot;
374 # expression: &quot;document.type != &#x27;private&#x27; &amp;&amp; document.type != &#x27;internal&#x27;&quot;
375 #
376 # Example (Data Manipulation):
377 #
378 # title: &quot;Notification string&quot;
379 # description: &quot;Create a notification string with a timestamp.&quot;
380 # expression: &quot;&#x27;New message received at &#x27; + string(document.create_time)&quot;
381 #
382 # The exact variables and functions that may be referenced within an expression
383 # are determined by the service that evaluates it. See the service
384 # documentation for additional information.
Bu Sun Kim65020912020-05-20 12:08:20 -0700385 &quot;title&quot;: &quot;A String&quot;, # Optional. Title for the expression, i.e. a short string describing
386 # its purpose. This can be used e.g. in UIs which allow to enter the
387 # expression.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700388 &quot;description&quot;: &quot;A String&quot;, # Optional. Description of the expression. This is a longer text which
389 # describes the expression, e.g. when hovered over it in a UI.
390 &quot;expression&quot;: &quot;A String&quot;, # Textual representation of an expression in Common Expression Language
391 # syntax.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700392 &quot;location&quot;: &quot;A String&quot;, # Optional. String indicating the location of the expression for error
393 # reporting, e.g. a file name and a position in the file.
Bu Sun Kim65020912020-05-20 12:08:20 -0700394 },
395 &quot;members&quot;: [ # Specifies the identities requesting access for a Cloud Platform resource.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800396 # `members` can have the following values:
397 #
398 # * `allUsers`: A special identifier that represents anyone who is
399 # on the internet; with or without a Google account.
400 #
401 # * `allAuthenticatedUsers`: A special identifier that represents anyone
402 # who is authenticated with a Google account or a service account.
403 #
404 # * `user:{emailid}`: An email address that represents a specific Google
Dan O'Mearadd494642020-05-01 07:42:23 -0700405 # account. For example, `alice@example.com` .
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800406 #
407 #
408 # * `serviceAccount:{emailid}`: An email address that represents a service
409 # account. For example, `my-other-app@appspot.gserviceaccount.com`.
410 #
411 # * `group:{emailid}`: An email address that represents a Google group.
412 # For example, `admins@example.com`.
413 #
Dan O'Mearadd494642020-05-01 07:42:23 -0700414 # * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique
415 # identifier) representing a user that has been recently deleted. For
416 # example, `alice@example.com?uid=123456789012345678901`. If the user is
417 # recovered, this value reverts to `user:{emailid}` and the recovered user
418 # retains the role in the binding.
419 #
420 # * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus
421 # unique identifier) representing a service account that has been recently
422 # deleted. For example,
423 # `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`.
424 # If the service account is undeleted, this value reverts to
425 # `serviceAccount:{emailid}` and the undeleted service account retains the
426 # role in the binding.
427 #
428 # * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique
429 # identifier) representing a Google group that has been recently
430 # deleted. For example, `admins@example.com?uid=123456789012345678901`. If
431 # the group is recovered, this value reverts to `group:{emailid}` and the
432 # recovered group retains the role in the binding.
433 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700434 #
435 # * `domain:{domain}`: The G Suite domain (primary) that represents all the
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800436 # users of that domain. For example, `google.com` or `example.com`.
437 #
Bu Sun Kim65020912020-05-20 12:08:20 -0700438 &quot;A String&quot;,
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000439 ],
440 },
441 ],
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000442 }</pre>
443</div>
444
445<div class="method">
Bu Sun Kim65020912020-05-20 12:08:20 -0700446 <code class="details" id="list">list(project, pageToken=None, pageSize=None, x__xgafv=None)</code>
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000447 <pre>Lists matching topics.
448
449Args:
450 project: string, The name of the cloud project that topics belong to. (required)
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800451 pageToken: string, The value returned by the last `ListTopicsResponse`; indicates that this is
452a continuation of a prior `ListTopics` call, and that the system should
453return the next page of data.
Bu Sun Kim65020912020-05-20 12:08:20 -0700454 pageSize: integer, Maximum number of topics to return.
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000455 x__xgafv: string, V1 error format.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800456 Allowed values
457 1 - v1 error format
458 2 - v2 error format
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000459
460Returns:
461 An object of the form:
462
Sai Cheemalapatidf613972016-10-21 13:59:49 -0700463 { # Response for the `ListTopics` method.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700464 &quot;nextPageToken&quot;: &quot;A String&quot;, # If not empty, indicates that there may be more topics that match the
465 # request; this value should be passed in a new `ListTopicsRequest`.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700466 &quot;topics&quot;: [ # The resulting topics.
467 { # A topic resource.
468 &quot;name&quot;: &quot;A String&quot;, # The name of the topic. It must have the format
469 # `&quot;projects/{project}/topics/{topic}&quot;`. `{topic}` must start with a letter,
470 # and contain only letters (`[A-Za-z]`), numbers (`[0-9]`), dashes (`-`),
471 # underscores (`_`), periods (`.`), tildes (`~`), plus (`+`) or percent
472 # signs (`%`). It must be between 3 and 255 characters in length, and it
473 # must not start with `&quot;goog&quot;`.
474 },
475 ],
Craig Citroe633be12015-03-02 13:40:36 -0800476 }</pre>
477</div>
478
479<div class="method">
480 <code class="details" id="list_next">list_next(previous_request, previous_response)</code>
481 <pre>Retrieves the next page of results.
482
483Args:
484 previous_request: The request for the previous page. (required)
485 previous_response: The response from the request for the previous page. (required)
486
487Returns:
Bu Sun Kim65020912020-05-20 12:08:20 -0700488 A request object that you can call &#x27;execute()&#x27; on to request the next
Craig Citroe633be12015-03-02 13:40:36 -0800489 page. Returns None if there are no more items in the collection.
490 </pre>
491</div>
492
493<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -0700494 <code class="details" id="publish">publish(topic, body=None, x__xgafv=None)</code>
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800495 <pre>Adds one or more messages to the topic. Returns `NOT_FOUND` if the topic
496does not exist. The message payload must not be empty; it must contain
497 either a non-empty data field, or at least one attribute.
Craig Citroe633be12015-03-02 13:40:36 -0800498
499Args:
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000500 topic: string, The messages in the request will be published on this topic. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700501 body: object, The request body.
Craig Citroe633be12015-03-02 13:40:36 -0800502 The object takes the form of:
503
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000504{ # Request for the Publish method.
Bu Sun Kim65020912020-05-20 12:08:20 -0700505 &quot;messages&quot;: [ # The messages to publish.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800506 { # A message data and its attributes. The message payload must not be empty;
507 # it must contain either a non-empty data field, or at least one attribute.
Bu Sun Kim65020912020-05-20 12:08:20 -0700508 &quot;messageId&quot;: &quot;A String&quot;, # ID of this message, assigned by the server when the message is published.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800509 # Guaranteed to be unique within the topic. This value may be read by a
510 # subscriber that receives a `PubsubMessage` via a `Pull` call or a push
511 # delivery. It must not be populated by the publisher in a `Publish` call.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700512 &quot;data&quot;: &quot;A String&quot;, # The message payload. For JSON requests, the value of this field must be
513 # [base64-encoded](https://tools.ietf.org/html/rfc4648).
Bu Sun Kim65020912020-05-20 12:08:20 -0700514 &quot;publishTime&quot;: &quot;A String&quot;, # The time at which the message was published, populated by the server when
515 # it receives the `Publish` call. It must not be populated by the
516 # publisher in a `Publish` call.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700517 &quot;attributes&quot;: { # Optional attributes for this message.
518 &quot;a_key&quot;: &quot;A String&quot;,
519 },
Craig Citroe633be12015-03-02 13:40:36 -0800520 },
521 ],
522 }
523
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000524 x__xgafv: string, V1 error format.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800525 Allowed values
526 1 - v1 error format
527 2 - v2 error format
Craig Citroe633be12015-03-02 13:40:36 -0800528
529Returns:
530 An object of the form:
531
Sai Cheemalapatidf613972016-10-21 13:59:49 -0700532 { # Response for the `Publish` method.
Bu Sun Kim65020912020-05-20 12:08:20 -0700533 &quot;messageIds&quot;: [ # The server-assigned ID of each published message, in the same order as
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800534 # the messages in the request. IDs are guaranteed to be unique within
535 # the topic.
Bu Sun Kim65020912020-05-20 12:08:20 -0700536 &quot;A String&quot;,
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000537 ],
538 }</pre>
539</div>
540
541<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -0700542 <code class="details" id="setIamPolicy">setIamPolicy(resource, body=None, x__xgafv=None)</code>
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800543 <pre>Sets the access control policy on the specified resource. Replaces any
544existing policy.
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000545
Bu Sun Kim65020912020-05-20 12:08:20 -0700546Can return `NOT_FOUND`, `INVALID_ARGUMENT`, and `PERMISSION_DENIED` errors.
Dan O'Mearadd494642020-05-01 07:42:23 -0700547
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000548Args:
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800549 resource: string, REQUIRED: The resource for which the policy is being specified.
Sai Cheemalapatie833b792017-03-24 15:06:46 -0700550See the operation documentation for the appropriate value for this field. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -0700551 body: object, The request body.
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000552 The object takes the form of:
553
554{ # Request message for `SetIamPolicy` method.
Bu Sun Kim65020912020-05-20 12:08:20 -0700555 &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
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800556 # the policy is limited to a few 10s of KB. An empty policy is a
557 # valid policy but certain Cloud Platform services (such as Projects)
558 # might reject them.
Dan O'Mearadd494642020-05-01 07:42:23 -0700559 # controls for Google Cloud resources.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800560 #
561 #
Dan O'Mearadd494642020-05-01 07:42:23 -0700562 # A `Policy` is a collection of `bindings`. A `binding` binds one or more
563 # `members` to a single `role`. Members can be user accounts, service accounts,
564 # Google groups, and domains (such as G Suite). A `role` is a named list of
565 # permissions; each `role` can be an IAM predefined role or a user-created
566 # custom role.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800567 #
Bu Sun Kim65020912020-05-20 12:08:20 -0700568 # For some types of Google Cloud resources, a `binding` can also specify a
569 # `condition`, which is a logical expression that allows access to a resource
570 # only if the expression evaluates to `true`. A condition can add constraints
571 # based on attributes of the request, the resource, or both. To learn which
572 # resources support conditions in their IAM policies, see the
573 # [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
Dan O'Mearadd494642020-05-01 07:42:23 -0700574 #
575 # **JSON example:**
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800576 #
577 # {
Bu Sun Kim65020912020-05-20 12:08:20 -0700578 # &quot;bindings&quot;: [
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800579 # {
Bu Sun Kim65020912020-05-20 12:08:20 -0700580 # &quot;role&quot;: &quot;roles/resourcemanager.organizationAdmin&quot;,
581 # &quot;members&quot;: [
582 # &quot;user:mike@example.com&quot;,
583 # &quot;group:admins@example.com&quot;,
584 # &quot;domain:google.com&quot;,
585 # &quot;serviceAccount:my-project-id@appspot.gserviceaccount.com&quot;
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800586 # ]
587 # },
588 # {
Bu Sun Kim65020912020-05-20 12:08:20 -0700589 # &quot;role&quot;: &quot;roles/resourcemanager.organizationViewer&quot;,
590 # &quot;members&quot;: [
591 # &quot;user:eve@example.com&quot;
592 # ],
593 # &quot;condition&quot;: {
594 # &quot;title&quot;: &quot;expirable access&quot;,
595 # &quot;description&quot;: &quot;Does not grant access after Sep 2020&quot;,
596 # &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 -0700597 # }
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800598 # }
Dan O'Mearadd494642020-05-01 07:42:23 -0700599 # ],
Bu Sun Kim65020912020-05-20 12:08:20 -0700600 # &quot;etag&quot;: &quot;BwWWja0YfJA=&quot;,
601 # &quot;version&quot;: 3
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800602 # }
603 #
Dan O'Mearadd494642020-05-01 07:42:23 -0700604 # **YAML example:**
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700605 #
606 # bindings:
607 # - members:
608 # - user:mike@example.com
609 # - group:admins@example.com
610 # - domain:google.com
Dan O'Mearadd494642020-05-01 07:42:23 -0700611 # - serviceAccount:my-project-id@appspot.gserviceaccount.com
612 # role: roles/resourcemanager.organizationAdmin
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700613 # - members:
Dan O'Mearadd494642020-05-01 07:42:23 -0700614 # - user:eve@example.com
615 # role: roles/resourcemanager.organizationViewer
616 # condition:
617 # title: expirable access
618 # description: Does not grant access after Sep 2020
Bu Sun Kim65020912020-05-20 12:08:20 -0700619 # expression: request.time &lt; timestamp(&#x27;2020-10-01T00:00:00.000Z&#x27;)
Dan O'Mearadd494642020-05-01 07:42:23 -0700620 # - etag: BwWWja0YfJA=
621 # - version: 3
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700622 #
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800623 # For a description of IAM and its features, see the
Dan O'Mearadd494642020-05-01 07:42:23 -0700624 # [IAM documentation](https://cloud.google.com/iam/docs/).
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700625 &quot;version&quot;: 42, # Specifies the format of the policy.
626 #
627 # Valid values are `0`, `1`, and `3`. Requests that specify an invalid value
628 # are rejected.
629 #
630 # Any operation that affects conditional role bindings must specify version
631 # `3`. This requirement applies to the following operations:
632 #
633 # * Getting a policy that includes a conditional role binding
634 # * Adding a conditional role binding to a policy
635 # * Changing a conditional role binding in a policy
636 # * Removing any role binding, with or without a condition, from a policy
637 # that includes conditions
638 #
639 # **Important:** If you use IAM Conditions, you must include the `etag` field
640 # whenever you call `setIamPolicy`. If you omit this field, then IAM allows
641 # you to overwrite a version `3` policy with a version `1` policy, and all of
642 # the conditions in the version `3` policy are lost.
643 #
644 # If a policy does not include any conditions, operations on that policy may
645 # specify any valid version or leave the field unset.
646 #
647 # To learn which resources support conditions in their IAM policies, see the
648 # [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700649 &quot;etag&quot;: &quot;A String&quot;, # `etag` is used for optimistic concurrency control as a way to help
650 # prevent simultaneous updates of a policy from overwriting each other.
651 # It is strongly suggested that systems make use of the `etag` in the
652 # read-modify-write cycle to perform policy updates in order to avoid race
653 # conditions: An `etag` is returned in the response to `getIamPolicy`, and
654 # systems are expected to put that etag in the request to `setIamPolicy` to
655 # ensure that their change will be applied to the same version of the policy.
656 #
657 # **Important:** If you use IAM Conditions, you must include the `etag` field
658 # whenever you call `setIamPolicy`. If you omit this field, then IAM allows
659 # you to overwrite a version `3` policy with a version `1` policy, and all of
660 # the conditions in the version `3` policy are lost.
Bu Sun Kim65020912020-05-20 12:08:20 -0700661 &quot;bindings&quot;: [ # Associates a list of `members` to a `role`. Optionally, may specify a
Dan O'Mearadd494642020-05-01 07:42:23 -0700662 # `condition` that determines how and when the `bindings` are applied. Each
663 # of the `bindings` must contain at least one member.
Sai Cheemalapatidf613972016-10-21 13:59:49 -0700664 { # Associates `members` with a `role`.
Bu Sun Kim65020912020-05-20 12:08:20 -0700665 &quot;role&quot;: &quot;A String&quot;, # Role that is assigned to `members`.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800666 # For example, `roles/viewer`, `roles/editor`, or `roles/owner`.
Bu Sun Kim65020912020-05-20 12:08:20 -0700667 &quot;condition&quot;: { # Represents a textual expression in the Common Expression Language (CEL) # The condition that is associated with this binding.
668 #
669 # If the condition evaluates to `true`, then this binding applies to the
670 # current request.
671 #
672 # If the condition evaluates to `false`, then this binding does not apply to
673 # the current request. However, a different role binding might grant the same
674 # role to one or more of the members in this binding.
675 #
676 # To learn which resources support conditions in their IAM policies, see the
677 # [IAM
678 # documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
679 # syntax. CEL is a C-like expression language. The syntax and semantics of CEL
680 # are documented at https://github.com/google/cel-spec.
681 #
682 # Example (Comparison):
683 #
684 # title: &quot;Summary size limit&quot;
685 # description: &quot;Determines if a summary is less than 100 chars&quot;
686 # expression: &quot;document.summary.size() &lt; 100&quot;
687 #
688 # Example (Equality):
689 #
690 # title: &quot;Requestor is owner&quot;
691 # description: &quot;Determines if requestor is the document owner&quot;
692 # expression: &quot;document.owner == request.auth.claims.email&quot;
693 #
694 # Example (Logic):
695 #
696 # title: &quot;Public documents&quot;
697 # description: &quot;Determine whether the document should be publicly visible&quot;
698 # expression: &quot;document.type != &#x27;private&#x27; &amp;&amp; document.type != &#x27;internal&#x27;&quot;
699 #
700 # Example (Data Manipulation):
701 #
702 # title: &quot;Notification string&quot;
703 # description: &quot;Create a notification string with a timestamp.&quot;
704 # expression: &quot;&#x27;New message received at &#x27; + string(document.create_time)&quot;
705 #
706 # The exact variables and functions that may be referenced within an expression
707 # are determined by the service that evaluates it. See the service
708 # documentation for additional information.
Bu Sun Kim65020912020-05-20 12:08:20 -0700709 &quot;title&quot;: &quot;A String&quot;, # Optional. Title for the expression, i.e. a short string describing
710 # its purpose. This can be used e.g. in UIs which allow to enter the
711 # expression.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700712 &quot;description&quot;: &quot;A String&quot;, # Optional. Description of the expression. This is a longer text which
713 # describes the expression, e.g. when hovered over it in a UI.
714 &quot;expression&quot;: &quot;A String&quot;, # Textual representation of an expression in Common Expression Language
715 # syntax.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700716 &quot;location&quot;: &quot;A String&quot;, # Optional. String indicating the location of the expression for error
717 # reporting, e.g. a file name and a position in the file.
Bu Sun Kim65020912020-05-20 12:08:20 -0700718 },
719 &quot;members&quot;: [ # Specifies the identities requesting access for a Cloud Platform resource.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800720 # `members` can have the following values:
721 #
722 # * `allUsers`: A special identifier that represents anyone who is
723 # on the internet; with or without a Google account.
724 #
725 # * `allAuthenticatedUsers`: A special identifier that represents anyone
726 # who is authenticated with a Google account or a service account.
727 #
728 # * `user:{emailid}`: An email address that represents a specific Google
Dan O'Mearadd494642020-05-01 07:42:23 -0700729 # account. For example, `alice@example.com` .
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800730 #
731 #
732 # * `serviceAccount:{emailid}`: An email address that represents a service
733 # account. For example, `my-other-app@appspot.gserviceaccount.com`.
734 #
735 # * `group:{emailid}`: An email address that represents a Google group.
736 # For example, `admins@example.com`.
737 #
Dan O'Mearadd494642020-05-01 07:42:23 -0700738 # * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique
739 # identifier) representing a user that has been recently deleted. For
740 # example, `alice@example.com?uid=123456789012345678901`. If the user is
741 # recovered, this value reverts to `user:{emailid}` and the recovered user
742 # retains the role in the binding.
743 #
744 # * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus
745 # unique identifier) representing a service account that has been recently
746 # deleted. For example,
747 # `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`.
748 # If the service account is undeleted, this value reverts to
749 # `serviceAccount:{emailid}` and the undeleted service account retains the
750 # role in the binding.
751 #
752 # * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique
753 # identifier) representing a Google group that has been recently
754 # deleted. For example, `admins@example.com?uid=123456789012345678901`. If
755 # the group is recovered, this value reverts to `group:{emailid}` and the
756 # recovered group retains the role in the binding.
757 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700758 #
759 # * `domain:{domain}`: The G Suite domain (primary) that represents all the
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800760 # users of that domain. For example, `google.com` or `example.com`.
761 #
Bu Sun Kim65020912020-05-20 12:08:20 -0700762 &quot;A String&quot;,
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000763 ],
764 },
765 ],
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000766 },
767 }
768
769 x__xgafv: string, V1 error format.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800770 Allowed values
771 1 - v1 error format
772 2 - v2 error format
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000773
774Returns:
775 An object of the form:
776
Dan O'Mearadd494642020-05-01 07:42:23 -0700777 { # An Identity and Access Management (IAM) policy, which specifies access
778 # controls for Google Cloud resources.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800779 #
780 #
Dan O'Mearadd494642020-05-01 07:42:23 -0700781 # A `Policy` is a collection of `bindings`. A `binding` binds one or more
782 # `members` to a single `role`. Members can be user accounts, service accounts,
783 # Google groups, and domains (such as G Suite). A `role` is a named list of
784 # permissions; each `role` can be an IAM predefined role or a user-created
785 # custom role.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800786 #
Bu Sun Kim65020912020-05-20 12:08:20 -0700787 # For some types of Google Cloud resources, a `binding` can also specify a
788 # `condition`, which is a logical expression that allows access to a resource
789 # only if the expression evaluates to `true`. A condition can add constraints
790 # based on attributes of the request, the resource, or both. To learn which
791 # resources support conditions in their IAM policies, see the
792 # [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
Dan O'Mearadd494642020-05-01 07:42:23 -0700793 #
794 # **JSON example:**
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800795 #
796 # {
Bu Sun Kim65020912020-05-20 12:08:20 -0700797 # &quot;bindings&quot;: [
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800798 # {
Bu Sun Kim65020912020-05-20 12:08:20 -0700799 # &quot;role&quot;: &quot;roles/resourcemanager.organizationAdmin&quot;,
800 # &quot;members&quot;: [
801 # &quot;user:mike@example.com&quot;,
802 # &quot;group:admins@example.com&quot;,
803 # &quot;domain:google.com&quot;,
804 # &quot;serviceAccount:my-project-id@appspot.gserviceaccount.com&quot;
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800805 # ]
806 # },
807 # {
Bu Sun Kim65020912020-05-20 12:08:20 -0700808 # &quot;role&quot;: &quot;roles/resourcemanager.organizationViewer&quot;,
809 # &quot;members&quot;: [
810 # &quot;user:eve@example.com&quot;
811 # ],
812 # &quot;condition&quot;: {
813 # &quot;title&quot;: &quot;expirable access&quot;,
814 # &quot;description&quot;: &quot;Does not grant access after Sep 2020&quot;,
815 # &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 -0700816 # }
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800817 # }
Dan O'Mearadd494642020-05-01 07:42:23 -0700818 # ],
Bu Sun Kim65020912020-05-20 12:08:20 -0700819 # &quot;etag&quot;: &quot;BwWWja0YfJA=&quot;,
820 # &quot;version&quot;: 3
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800821 # }
822 #
Dan O'Mearadd494642020-05-01 07:42:23 -0700823 # **YAML example:**
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700824 #
825 # bindings:
826 # - members:
827 # - user:mike@example.com
828 # - group:admins@example.com
829 # - domain:google.com
Dan O'Mearadd494642020-05-01 07:42:23 -0700830 # - serviceAccount:my-project-id@appspot.gserviceaccount.com
831 # role: roles/resourcemanager.organizationAdmin
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700832 # - members:
Dan O'Mearadd494642020-05-01 07:42:23 -0700833 # - user:eve@example.com
834 # role: roles/resourcemanager.organizationViewer
835 # condition:
836 # title: expirable access
837 # description: Does not grant access after Sep 2020
Bu Sun Kim65020912020-05-20 12:08:20 -0700838 # expression: request.time &lt; timestamp(&#x27;2020-10-01T00:00:00.000Z&#x27;)
Dan O'Mearadd494642020-05-01 07:42:23 -0700839 # - etag: BwWWja0YfJA=
840 # - version: 3
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700841 #
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800842 # For a description of IAM and its features, see the
Dan O'Mearadd494642020-05-01 07:42:23 -0700843 # [IAM documentation](https://cloud.google.com/iam/docs/).
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700844 &quot;version&quot;: 42, # Specifies the format of the policy.
845 #
846 # Valid values are `0`, `1`, and `3`. Requests that specify an invalid value
847 # are rejected.
848 #
849 # Any operation that affects conditional role bindings must specify version
850 # `3`. This requirement applies to the following operations:
851 #
852 # * Getting a policy that includes a conditional role binding
853 # * Adding a conditional role binding to a policy
854 # * Changing a conditional role binding in a policy
855 # * Removing any role binding, with or without a condition, from a policy
856 # that includes conditions
857 #
858 # **Important:** If you use IAM Conditions, you must include the `etag` field
859 # whenever you call `setIamPolicy`. If you omit this field, then IAM allows
860 # you to overwrite a version `3` policy with a version `1` policy, and all of
861 # the conditions in the version `3` policy are lost.
862 #
863 # If a policy does not include any conditions, operations on that policy may
864 # specify any valid version or leave the field unset.
865 #
866 # To learn which resources support conditions in their IAM policies, see the
867 # [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700868 &quot;etag&quot;: &quot;A String&quot;, # `etag` is used for optimistic concurrency control as a way to help
869 # prevent simultaneous updates of a policy from overwriting each other.
870 # It is strongly suggested that systems make use of the `etag` in the
871 # read-modify-write cycle to perform policy updates in order to avoid race
872 # conditions: An `etag` is returned in the response to `getIamPolicy`, and
873 # systems are expected to put that etag in the request to `setIamPolicy` to
874 # ensure that their change will be applied to the same version of the policy.
875 #
876 # **Important:** If you use IAM Conditions, you must include the `etag` field
877 # whenever you call `setIamPolicy`. If you omit this field, then IAM allows
878 # you to overwrite a version `3` policy with a version `1` policy, and all of
879 # the conditions in the version `3` policy are lost.
Bu Sun Kim65020912020-05-20 12:08:20 -0700880 &quot;bindings&quot;: [ # Associates a list of `members` to a `role`. Optionally, may specify a
Dan O'Mearadd494642020-05-01 07:42:23 -0700881 # `condition` that determines how and when the `bindings` are applied. Each
882 # of the `bindings` must contain at least one member.
Sai Cheemalapatidf613972016-10-21 13:59:49 -0700883 { # Associates `members` with a `role`.
Bu Sun Kim65020912020-05-20 12:08:20 -0700884 &quot;role&quot;: &quot;A String&quot;, # Role that is assigned to `members`.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800885 # For example, `roles/viewer`, `roles/editor`, or `roles/owner`.
Bu Sun Kim65020912020-05-20 12:08:20 -0700886 &quot;condition&quot;: { # Represents a textual expression in the Common Expression Language (CEL) # The condition that is associated with this binding.
887 #
888 # If the condition evaluates to `true`, then this binding applies to the
889 # current request.
890 #
891 # If the condition evaluates to `false`, then this binding does not apply to
892 # the current request. However, a different role binding might grant the same
893 # role to one or more of the members in this binding.
894 #
895 # To learn which resources support conditions in their IAM policies, see the
896 # [IAM
897 # documentation](https://cloud.google.com/iam/help/conditions/resource-policies).
898 # syntax. CEL is a C-like expression language. The syntax and semantics of CEL
899 # are documented at https://github.com/google/cel-spec.
900 #
901 # Example (Comparison):
902 #
903 # title: &quot;Summary size limit&quot;
904 # description: &quot;Determines if a summary is less than 100 chars&quot;
905 # expression: &quot;document.summary.size() &lt; 100&quot;
906 #
907 # Example (Equality):
908 #
909 # title: &quot;Requestor is owner&quot;
910 # description: &quot;Determines if requestor is the document owner&quot;
911 # expression: &quot;document.owner == request.auth.claims.email&quot;
912 #
913 # Example (Logic):
914 #
915 # title: &quot;Public documents&quot;
916 # description: &quot;Determine whether the document should be publicly visible&quot;
917 # expression: &quot;document.type != &#x27;private&#x27; &amp;&amp; document.type != &#x27;internal&#x27;&quot;
918 #
919 # Example (Data Manipulation):
920 #
921 # title: &quot;Notification string&quot;
922 # description: &quot;Create a notification string with a timestamp.&quot;
923 # expression: &quot;&#x27;New message received at &#x27; + string(document.create_time)&quot;
924 #
925 # The exact variables and functions that may be referenced within an expression
926 # are determined by the service that evaluates it. See the service
927 # documentation for additional information.
Bu Sun Kim65020912020-05-20 12:08:20 -0700928 &quot;title&quot;: &quot;A String&quot;, # Optional. Title for the expression, i.e. a short string describing
929 # its purpose. This can be used e.g. in UIs which allow to enter the
930 # expression.
Bu Sun Kim4ed7d3f2020-05-27 12:20:54 -0700931 &quot;description&quot;: &quot;A String&quot;, # Optional. Description of the expression. This is a longer text which
932 # describes the expression, e.g. when hovered over it in a UI.
933 &quot;expression&quot;: &quot;A String&quot;, # Textual representation of an expression in Common Expression Language
934 # syntax.
Bu Sun Kimd059ad82020-07-22 17:02:09 -0700935 &quot;location&quot;: &quot;A String&quot;, # Optional. String indicating the location of the expression for error
936 # reporting, e.g. a file name and a position in the file.
Bu Sun Kim65020912020-05-20 12:08:20 -0700937 },
938 &quot;members&quot;: [ # Specifies the identities requesting access for a Cloud Platform resource.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800939 # `members` can have the following values:
940 #
941 # * `allUsers`: A special identifier that represents anyone who is
942 # on the internet; with or without a Google account.
943 #
944 # * `allAuthenticatedUsers`: A special identifier that represents anyone
945 # who is authenticated with a Google account or a service account.
946 #
947 # * `user:{emailid}`: An email address that represents a specific Google
Dan O'Mearadd494642020-05-01 07:42:23 -0700948 # account. For example, `alice@example.com` .
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800949 #
950 #
951 # * `serviceAccount:{emailid}`: An email address that represents a service
952 # account. For example, `my-other-app@appspot.gserviceaccount.com`.
953 #
954 # * `group:{emailid}`: An email address that represents a Google group.
955 # For example, `admins@example.com`.
956 #
Dan O'Mearadd494642020-05-01 07:42:23 -0700957 # * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique
958 # identifier) representing a user that has been recently deleted. For
959 # example, `alice@example.com?uid=123456789012345678901`. If the user is
960 # recovered, this value reverts to `user:{emailid}` and the recovered user
961 # retains the role in the binding.
962 #
963 # * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus
964 # unique identifier) representing a service account that has been recently
965 # deleted. For example,
966 # `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`.
967 # If the service account is undeleted, this value reverts to
968 # `serviceAccount:{emailid}` and the undeleted service account retains the
969 # role in the binding.
970 #
971 # * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique
972 # identifier) representing a Google group that has been recently
973 # deleted. For example, `admins@example.com?uid=123456789012345678901`. If
974 # the group is recovered, this value reverts to `group:{emailid}` and the
975 # recovered group retains the role in the binding.
976 #
Bu Sun Kim715bd7f2019-06-14 16:50:42 -0700977 #
978 # * `domain:{domain}`: The G Suite domain (primary) that represents all the
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800979 # users of that domain. For example, `google.com` or `example.com`.
980 #
Bu Sun Kim65020912020-05-20 12:08:20 -0700981 &quot;A String&quot;,
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000982 ],
983 },
984 ],
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000985 }</pre>
986</div>
987
988<div class="method">
Dan O'Mearadd494642020-05-01 07:42:23 -0700989 <code class="details" id="testIamPermissions">testIamPermissions(resource, body=None, x__xgafv=None)</code>
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000990 <pre>Returns permissions that a caller has on the specified resource.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800991If the resource does not exist, this will return an empty set of
Bu Sun Kim65020912020-05-20 12:08:20 -0700992permissions, not a `NOT_FOUND` error.
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000993
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400994Note: This operation is designed to be used for building permission-aware
995UIs and command-line tools, not for authorization checking. This operation
Bu Sun Kim65020912020-05-20 12:08:20 -0700996may &quot;fail open&quot; without warning.
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400997
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000998Args:
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800999 resource: string, REQUIRED: The resource for which the policy detail is being requested.
Sai Cheemalapatie833b792017-03-24 15:06:46 -07001000See the operation documentation for the appropriate value for this field. (required)
Dan O'Mearadd494642020-05-01 07:42:23 -07001001 body: object, The request body.
Nathaniel Manista4f877e52015-06-15 16:44:50 +00001002 The object takes the form of:
1003
1004{ # Request message for `TestIamPermissions` method.
Bu Sun Kim65020912020-05-20 12:08:20 -07001005 &quot;permissions&quot;: [ # The set of permissions to check for the `resource`. Permissions with
1006 # wildcards (such as &#x27;*&#x27; or &#x27;storage.*&#x27;) are not allowed. For more
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08001007 # information see
1008 # [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions).
Bu Sun Kim65020912020-05-20 12:08:20 -07001009 &quot;A String&quot;,
Nathaniel Manista4f877e52015-06-15 16:44:50 +00001010 ],
1011 }
1012
1013 x__xgafv: string, V1 error format.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08001014 Allowed values
1015 1 - v1 error format
1016 2 - v2 error format
Nathaniel Manista4f877e52015-06-15 16:44:50 +00001017
1018Returns:
1019 An object of the form:
1020
1021 { # Response message for `TestIamPermissions` method.
Bu Sun Kim65020912020-05-20 12:08:20 -07001022 &quot;permissions&quot;: [ # A subset of `TestPermissionsRequest.permissions` that the caller is
Jon Wayne Parrott692617a2017-01-06 09:58:29 -08001023 # allowed.
Bu Sun Kim65020912020-05-20 12:08:20 -07001024 &quot;A String&quot;,
Craig Citroe633be12015-03-02 13:40:36 -08001025 ],
1026 }</pre>
1027</div>
1028
1029</body></html>