blob: 8d44e3f9f9da48877626a6b8a5bca1cd18952904 [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
75<h1><a href="pubsub_v1beta2.html">Google Cloud Pub/Sub API</a> . <a href="pubsub_v1beta2.projects.html">projects</a> . <a href="pubsub_v1beta2.projects.subscriptions.html">subscriptions</a></h1>
76<h2>Instance Methods</h2>
77<p class="toc_element">
Nathaniel Manista4f877e52015-06-15 16:44:50 +000078 <code><a href="#acknowledge">acknowledge(subscription, body, x__xgafv=None)</a></code></p>
Jon Wayne Parrott692617a2017-01-06 09:58:29 -080079<p class="firstline">Acknowledges the messages associated with the `ack_ids` in the</p>
Craig Citroe633be12015-03-02 13:40:36 -080080<p class="toc_element">
Thomas Coffee2f245372017-03-27 10:39:26 -070081 <code><a href="#create">create(name, body, x__xgafv=None)</a></code></p>
Jon Wayne Parrott692617a2017-01-06 09:58:29 -080082<p class="firstline">Creates a subscription to a given topic.</p>
Craig Citroe633be12015-03-02 13:40:36 -080083<p class="toc_element">
Nathaniel Manista4f877e52015-06-15 16:44:50 +000084 <code><a href="#delete">delete(subscription, x__xgafv=None)</a></code></p>
Jon Wayne Parrott692617a2017-01-06 09:58:29 -080085<p class="firstline">Deletes an existing subscription. All pending messages in the subscription</p>
Craig Citroe633be12015-03-02 13:40:36 -080086<p class="toc_element">
Nathaniel Manista4f877e52015-06-15 16:44:50 +000087 <code><a href="#get">get(subscription, x__xgafv=None)</a></code></p>
Craig Citroe633be12015-03-02 13:40:36 -080088<p class="firstline">Gets the configuration details of a subscription.</p>
89<p class="toc_element">
Thomas Coffee2f245372017-03-27 10:39:26 -070090 <code><a href="#getIamPolicy">getIamPolicy(resource, x__xgafv=None)</a></code></p>
Jon Wayne Parrott692617a2017-01-06 09:58:29 -080091<p class="firstline">Gets the access control policy for a resource.</p>
Nathaniel Manista4f877e52015-06-15 16:44:50 +000092<p class="toc_element">
93 <code><a href="#list">list(project, pageSize=None, pageToken=None, x__xgafv=None)</a></code></p>
Craig Citroe633be12015-03-02 13:40:36 -080094<p class="firstline">Lists matching subscriptions.</p>
95<p class="toc_element">
96 <code><a href="#list_next">list_next(previous_request, previous_response)</a></code></p>
97<p class="firstline">Retrieves the next page of results.</p>
98<p class="toc_element">
Nathaniel Manista4f877e52015-06-15 16:44:50 +000099 <code><a href="#modifyAckDeadline">modifyAckDeadline(subscription, body, x__xgafv=None)</a></code></p>
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800100<p class="firstline">Modifies the ack deadline for a specific message. This method is useful</p>
Craig Citroe633be12015-03-02 13:40:36 -0800101<p class="toc_element">
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000102 <code><a href="#modifyPushConfig">modifyPushConfig(subscription, body, x__xgafv=None)</a></code></p>
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800103<p class="firstline">Modifies the `PushConfig` for a specified subscription.</p>
Craig Citroe633be12015-03-02 13:40:36 -0800104<p class="toc_element">
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000105 <code><a href="#pull">pull(subscription, body, x__xgafv=None)</a></code></p>
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800106<p class="firstline">Pulls messages from the server. Returns an empty list if there are no</p>
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000107<p class="toc_element">
Thomas Coffee2f245372017-03-27 10:39:26 -0700108 <code><a href="#setIamPolicy">setIamPolicy(resource, body, x__xgafv=None)</a></code></p>
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800109<p class="firstline">Sets the access control policy on the specified resource. Replaces any</p>
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000110<p class="toc_element">
Thomas Coffee2f245372017-03-27 10:39:26 -0700111 <code><a href="#testIamPermissions">testIamPermissions(resource, body, x__xgafv=None)</a></code></p>
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000112<p class="firstline">Returns permissions that a caller has on the specified resource.</p>
Craig Citroe633be12015-03-02 13:40:36 -0800113<h3>Method Details</h3>
114<div class="method">
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000115 <code class="details" id="acknowledge">acknowledge(subscription, body, x__xgafv=None)</code>
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800116 <pre>Acknowledges the messages associated with the `ack_ids` in the
117`AcknowledgeRequest`. The Pub/Sub system can remove the relevant messages
118from the subscription.
119
120Acknowledging a message whose ack deadline has expired may succeed,
121but such a message may be redelivered later. Acknowledging a message more
122than once will not result in an error.
Craig Citroe633be12015-03-02 13:40:36 -0800123
124Args:
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000125 subscription: string, The subscription whose message is being acknowledged. (required)
Craig Citroe633be12015-03-02 13:40:36 -0800126 body: object, The request body. (required)
127 The object takes the form of:
128
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000129{ # Request for the Acknowledge method.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800130 "ackIds": [ # The acknowledgment ID for the messages being acknowledged that was returned
131 # by the Pub/Sub system in the `Pull` response. Must not be empty.
Craig Citroe633be12015-03-02 13:40:36 -0800132 "A String",
133 ],
134 }
135
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000136 x__xgafv: string, V1 error format.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800137 Allowed values
138 1 - v1 error format
139 2 - v2 error format
Craig Citroe633be12015-03-02 13:40:36 -0800140
141Returns:
142 An object of the form:
143
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800144 { # A generic empty message that you can re-use to avoid defining duplicated
145 # empty messages in your APIs. A typical example is to use it as the request
146 # or the response type of an API method. For instance:
147 #
148 # service Foo {
149 # rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty);
150 # }
151 #
152 # The JSON representation for `Empty` is empty JSON object `{}`.
Craig Citroe633be12015-03-02 13:40:36 -0800153 }</pre>
154</div>
155
156<div class="method">
Thomas Coffee2f245372017-03-27 10:39:26 -0700157 <code class="details" id="create">create(name, body, x__xgafv=None)</code>
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800158 <pre>Creates a subscription to a given topic.
159If the subscription already exists, returns `ALREADY_EXISTS`.
160If the corresponding topic doesn't exist, returns `NOT_FOUND`.
161
162If the name is not provided in the request, the server will assign a random
163name for this subscription on the same project as the topic. Note that
164for REST API requests, you must specify a name.
Craig Citroe633be12015-03-02 13:40:36 -0800165
166Args:
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800167 name: string, The name of the subscription. It must have the format
168`"projects/{project}/subscriptions/{subscription}"`. `{subscription}` must
169start with a letter, and contain only letters (`[A-Za-z]`), numbers
170(`[0-9]`), dashes (`-`), underscores (`_`), periods (`.`), tildes (`~`),
171plus (`+`) or percent signs (`%`). It must be between 3 and 255 characters
172in length, and it must not start with `"goog"`. (required)
Craig Citroe633be12015-03-02 13:40:36 -0800173 body: object, The request body. (required)
174 The object takes the form of:
175
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000176{ # A subscription resource.
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400177 "ackDeadlineSeconds": 42, # This value is the maximum time after a subscriber receives a message
178 # before the subscriber should acknowledge the message. After message
179 # delivery but before the ack deadline expires and before the message is
180 # acknowledged, it is an outstanding message and will not be delivered
181 # again during that time (on a best-effort basis).
182 #
183 # For pull subscriptions, this value is used as the initial value for the ack
184 # deadline. To override this value for a given message, call
185 # `ModifyAckDeadline` with the corresponding `ack_id` if using pull.
186 # The maximum custom deadline you can specify is 600 seconds (10 minutes).
187 #
188 # For push delivery, this value is also used to set the request timeout for
189 # the call to the push endpoint.
190 #
191 # If the subscriber never acknowledges the message, the Pub/Sub
192 # system will eventually redeliver the message.
193 #
194 # If this parameter is 0, a default value of 10 seconds is used.
195 "topic": "A String", # The name of the topic from which this subscription is receiving messages.
196 # The value of this field will be `_deleted-topic_` if the topic has been
197 # deleted.
198 "pushConfig": { # Configuration for a push delivery endpoint. # If push delivery is used with this subscription, this field is
199 # used to configure it. An empty `pushConfig` signifies that the subscriber
200 # will pull and ack messages using API methods.
201 "attributes": { # Endpoint configuration attributes.
202 #
203 # Every endpoint has a set of API supported attributes that can be used to
204 # control different aspects of the message delivery.
205 #
206 # The currently supported attribute is `x-goog-version`, which you can
207 # use to change the format of the push message. This attribute
208 # indicates the version of the data expected by the endpoint. This
209 # controls the shape of the envelope (i.e. its fields and metadata).
210 # The endpoint version is based on the version of the Pub/Sub
211 # API.
212 #
213 # If not present during the `CreateSubscription` call, it will default to
214 # the version of the API used to make such call. If not present during a
215 # `ModifyPushConfig` call, its value will not be changed. `GetSubscription`
216 # calls will always return a valid version, even if the subscription was
217 # created without this attribute.
218 #
219 # The possible values for this attribute are:
220 #
221 # * `v1beta1`: uses the push format defined in the v1beta1 Pub/Sub API.
222 # * `v1` or `v1beta2`: uses the push format defined in the v1 Pub/Sub API.
223 "a_key": "A String",
224 },
225 "pushEndpoint": "A String", # A URL locating the endpoint to which messages should be pushed.
226 # For example, a Webhook endpoint might use "https://example.com/push".
227 },
228 "name": "A String", # The name of the subscription. It must have the format
229 # `"projects/{project}/subscriptions/{subscription}"`. `{subscription}` must
230 # start with a letter, and contain only letters (`[A-Za-z]`), numbers
231 # (`[0-9]`), dashes (`-`), underscores (`_`), periods (`.`), tildes (`~`),
232 # plus (`+`) or percent signs (`%`). It must be between 3 and 255 characters
233 # in length, and it must not start with `"goog"`.
234}
235
236 x__xgafv: string, V1 error format.
237 Allowed values
238 1 - v1 error format
239 2 - v2 error format
240
241Returns:
242 An object of the form:
243
244 { # A subscription resource.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800245 "ackDeadlineSeconds": 42, # This value is the maximum time after a subscriber receives a message
246 # before the subscriber should acknowledge the message. After message
247 # delivery but before the ack deadline expires and before the message is
248 # acknowledged, it is an outstanding message and will not be delivered
249 # again during that time (on a best-effort basis).
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400250 #
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800251 # For pull subscriptions, this value is used as the initial value for the ack
252 # deadline. To override this value for a given message, call
253 # `ModifyAckDeadline` with the corresponding `ack_id` if using pull.
254 # The maximum custom deadline you can specify is 600 seconds (10 minutes).
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400255 #
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800256 # For push delivery, this value is also used to set the request timeout for
257 # the call to the push endpoint.
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400258 #
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800259 # If the subscriber never acknowledges the message, the Pub/Sub
260 # system will eventually redeliver the message.
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400261 #
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800262 # If this parameter is 0, a default value of 10 seconds is used.
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400263 "topic": "A String", # The name of the topic from which this subscription is receiving messages.
264 # The value of this field will be `_deleted-topic_` if the topic has been
265 # deleted.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800266 "pushConfig": { # Configuration for a push delivery endpoint. # If push delivery is used with this subscription, this field is
267 # used to configure it. An empty `pushConfig` signifies that the subscriber
268 # will pull and ack messages using API methods.
269 "attributes": { # Endpoint configuration attributes.
270 #
271 # Every endpoint has a set of API supported attributes that can be used to
272 # control different aspects of the message delivery.
273 #
274 # The currently supported attribute is `x-goog-version`, which you can
275 # use to change the format of the push message. This attribute
276 # indicates the version of the data expected by the endpoint. This
277 # controls the shape of the envelope (i.e. its fields and metadata).
278 # The endpoint version is based on the version of the Pub/Sub
279 # API.
280 #
281 # If not present during the `CreateSubscription` call, it will default to
282 # the version of the API used to make such call. If not present during a
283 # `ModifyPushConfig` call, its value will not be changed. `GetSubscription`
284 # calls will always return a valid version, even if the subscription was
285 # created without this attribute.
286 #
287 # The possible values for this attribute are:
288 #
289 # * `v1beta1`: uses the push format defined in the v1beta1 Pub/Sub API.
290 # * `v1` or `v1beta2`: uses the push format defined in the v1 Pub/Sub API.
Craig Citroe633be12015-03-02 13:40:36 -0800291 "a_key": "A String",
292 },
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800293 "pushEndpoint": "A String", # A URL locating the endpoint to which messages should be pushed.
294 # For example, a Webhook endpoint might use "https://example.com/push".
Craig Citroe633be12015-03-02 13:40:36 -0800295 },
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800296 "name": "A String", # The name of the subscription. It must have the format
297 # `"projects/{project}/subscriptions/{subscription}"`. `{subscription}` must
298 # start with a letter, and contain only letters (`[A-Za-z]`), numbers
299 # (`[0-9]`), dashes (`-`), underscores (`_`), periods (`.`), tildes (`~`),
300 # plus (`+`) or percent signs (`%`). It must be between 3 and 255 characters
301 # in length, and it must not start with `"goog"`.
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400302 }</pre>
Craig Citroe633be12015-03-02 13:40:36 -0800303</div>
304
305<div class="method">
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000306 <code class="details" id="delete">delete(subscription, x__xgafv=None)</code>
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800307 <pre>Deletes an existing subscription. All pending messages in the subscription
308are immediately dropped. Calls to `Pull` after deletion will return
309`NOT_FOUND`. After a subscription is deleted, a new one may be created with
310the same name, but the new one has no association with the old
311subscription, or its topic unless the same topic is specified.
Craig Citroe633be12015-03-02 13:40:36 -0800312
313Args:
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000314 subscription: string, The subscription to delete. (required)
315 x__xgafv: string, V1 error format.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800316 Allowed values
317 1 - v1 error format
318 2 - v2 error format
Craig Citroe633be12015-03-02 13:40:36 -0800319
320Returns:
321 An object of the form:
322
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800323 { # A generic empty message that you can re-use to avoid defining duplicated
324 # empty messages in your APIs. A typical example is to use it as the request
325 # or the response type of an API method. For instance:
326 #
327 # service Foo {
328 # rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty);
329 # }
330 #
331 # The JSON representation for `Empty` is empty JSON object `{}`.
Craig Citroe633be12015-03-02 13:40:36 -0800332 }</pre>
333</div>
334
335<div class="method">
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000336 <code class="details" id="get">get(subscription, x__xgafv=None)</code>
Craig Citroe633be12015-03-02 13:40:36 -0800337 <pre>Gets the configuration details of a subscription.
338
339Args:
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000340 subscription: string, The name of the subscription to get. (required)
341 x__xgafv: string, V1 error format.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800342 Allowed values
343 1 - v1 error format
344 2 - v2 error format
Craig Citroe633be12015-03-02 13:40:36 -0800345
346Returns:
347 An object of the form:
348
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000349 { # A subscription resource.
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400350 "ackDeadlineSeconds": 42, # This value is the maximum time after a subscriber receives a message
351 # before the subscriber should acknowledge the message. After message
352 # delivery but before the ack deadline expires and before the message is
353 # acknowledged, it is an outstanding message and will not be delivered
354 # again during that time (on a best-effort basis).
355 #
356 # For pull subscriptions, this value is used as the initial value for the ack
357 # deadline. To override this value for a given message, call
358 # `ModifyAckDeadline` with the corresponding `ack_id` if using pull.
359 # The maximum custom deadline you can specify is 600 seconds (10 minutes).
360 #
361 # For push delivery, this value is also used to set the request timeout for
362 # the call to the push endpoint.
363 #
364 # If the subscriber never acknowledges the message, the Pub/Sub
365 # system will eventually redeliver the message.
366 #
367 # If this parameter is 0, a default value of 10 seconds is used.
368 "topic": "A String", # The name of the topic from which this subscription is receiving messages.
369 # The value of this field will be `_deleted-topic_` if the topic has been
370 # deleted.
371 "pushConfig": { # Configuration for a push delivery endpoint. # If push delivery is used with this subscription, this field is
372 # used to configure it. An empty `pushConfig` signifies that the subscriber
373 # will pull and ack messages using API methods.
374 "attributes": { # Endpoint configuration attributes.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800375 #
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400376 # Every endpoint has a set of API supported attributes that can be used to
377 # control different aspects of the message delivery.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800378 #
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400379 # The currently supported attribute is `x-goog-version`, which you can
380 # use to change the format of the push message. This attribute
381 # indicates the version of the data expected by the endpoint. This
382 # controls the shape of the envelope (i.e. its fields and metadata).
383 # The endpoint version is based on the version of the Pub/Sub
384 # API.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800385 #
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400386 # If not present during the `CreateSubscription` call, it will default to
387 # the version of the API used to make such call. If not present during a
388 # `ModifyPushConfig` call, its value will not be changed. `GetSubscription`
389 # calls will always return a valid version, even if the subscription was
390 # created without this attribute.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800391 #
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400392 # The possible values for this attribute are:
393 #
394 # * `v1beta1`: uses the push format defined in the v1beta1 Pub/Sub API.
395 # * `v1` or `v1beta2`: uses the push format defined in the v1 Pub/Sub API.
396 "a_key": "A String",
Craig Citroe633be12015-03-02 13:40:36 -0800397 },
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400398 "pushEndpoint": "A String", # A URL locating the endpoint to which messages should be pushed.
399 # For example, a Webhook endpoint might use "https://example.com/push".
400 },
401 "name": "A String", # The name of the subscription. It must have the format
402 # `"projects/{project}/subscriptions/{subscription}"`. `{subscription}` must
403 # start with a letter, and contain only letters (`[A-Za-z]`), numbers
404 # (`[0-9]`), dashes (`-`), underscores (`_`), periods (`.`), tildes (`~`),
405 # plus (`+`) or percent signs (`%`). It must be between 3 and 255 characters
406 # in length, and it must not start with `"goog"`.
407 }</pre>
Craig Citroe633be12015-03-02 13:40:36 -0800408</div>
409
410<div class="method">
Thomas Coffee2f245372017-03-27 10:39:26 -0700411 <code class="details" id="getIamPolicy">getIamPolicy(resource, x__xgafv=None)</code>
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800412 <pre>Gets the access control policy for a resource.
413Returns an empty policy if the resource exists and does not have a policy
414set.
Craig Citroe633be12015-03-02 13:40:36 -0800415
416Args:
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800417 resource: string, REQUIRED: The resource for which the policy is being requested.
Sai Cheemalapatie833b792017-03-24 15:06:46 -0700418See the operation documentation for the appropriate value for this field. (required)
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000419 x__xgafv: string, V1 error format.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800420 Allowed values
421 1 - v1 error format
422 2 - v2 error format
Craig Citroe633be12015-03-02 13:40:36 -0800423
424Returns:
425 An object of the form:
426
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800427 { # Defines an Identity and Access Management (IAM) policy. It is used to
428 # specify access control policies for Cloud Platform resources.
429 #
430 #
431 # A `Policy` consists of a list of `bindings`. A `Binding` binds a list of
432 # `members` to a `role`, where the members can be user accounts, Google groups,
433 # Google domains, and service accounts. A `role` is a named list of permissions
434 # defined by IAM.
435 #
436 # **Example**
437 #
438 # {
439 # "bindings": [
440 # {
441 # "role": "roles/owner",
442 # "members": [
443 # "user:mike@example.com",
444 # "group:admins@example.com",
445 # "domain:google.com",
446 # "serviceAccount:my-other-app@appspot.gserviceaccount.com",
447 # ]
448 # },
449 # {
450 # "role": "roles/viewer",
451 # "members": ["user:sean@example.com"]
452 # }
453 # ]
454 # }
455 #
456 # For a description of IAM and its features, see the
457 # [IAM developer's guide](https://cloud.google.com/iam).
458 "bindings": [ # Associates a list of `members` to a `role`.
459 # Multiple `bindings` must not be specified for the same `role`.
460 # `bindings` with no members will result in an error.
Sai Cheemalapatidf613972016-10-21 13:59:49 -0700461 { # Associates `members` with a `role`.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800462 "role": "A String", # Role that is assigned to `members`.
463 # For example, `roles/viewer`, `roles/editor`, or `roles/owner`.
464 # Required
465 "members": [ # Specifies the identities requesting access for a Cloud Platform resource.
466 # `members` can have the following values:
467 #
468 # * `allUsers`: A special identifier that represents anyone who is
469 # on the internet; with or without a Google account.
470 #
471 # * `allAuthenticatedUsers`: A special identifier that represents anyone
472 # who is authenticated with a Google account or a service account.
473 #
474 # * `user:{emailid}`: An email address that represents a specific Google
475 # account. For example, `alice@gmail.com` or `joe@example.com`.
476 #
477 #
478 # * `serviceAccount:{emailid}`: An email address that represents a service
479 # account. For example, `my-other-app@appspot.gserviceaccount.com`.
480 #
481 # * `group:{emailid}`: An email address that represents a Google group.
482 # For example, `admins@example.com`.
483 #
484 # * `domain:{domain}`: A Google Apps domain name that represents all the
485 # users of that domain. For example, `google.com` or `example.com`.
486 #
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000487 "A String",
488 ],
489 },
490 ],
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800491 "etag": "A String", # `etag` is used for optimistic concurrency control as a way to help
492 # prevent simultaneous updates of a policy from overwriting each other.
493 # It is strongly suggested that systems make use of the `etag` in the
494 # read-modify-write cycle to perform policy updates in order to avoid race
495 # conditions: An `etag` is returned in the response to `getIamPolicy`, and
496 # systems are expected to put that etag in the request to `setIamPolicy` to
497 # ensure that their change will be applied to the same version of the policy.
498 #
499 # If no `etag` is provided in the call to `setIamPolicy`, then the existing
500 # policy is overwritten blindly.
Sai Cheemalapatidf613972016-10-21 13:59:49 -0700501 "version": 42, # Version of the `Policy`. The default version is 0.
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000502 }</pre>
503</div>
504
505<div class="method">
506 <code class="details" id="list">list(project, pageSize=None, pageToken=None, x__xgafv=None)</code>
507 <pre>Lists matching subscriptions.
508
509Args:
510 project: string, The name of the cloud project that subscriptions belong to. (required)
511 pageSize: integer, Maximum number of subscriptions to return.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800512 pageToken: string, The value returned by the last `ListSubscriptionsResponse`; indicates that
513this is a continuation of a prior `ListSubscriptions` call, and that the
514system should return the next page of data.
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000515 x__xgafv: string, V1 error format.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800516 Allowed values
517 1 - v1 error format
518 2 - v2 error format
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000519
520Returns:
521 An object of the form:
522
Sai Cheemalapatidf613972016-10-21 13:59:49 -0700523 { # Response for the `ListSubscriptions` method.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800524 "nextPageToken": "A String", # If not empty, indicates that there may be more subscriptions that match
525 # the request; this value should be passed in a new
526 # `ListSubscriptionsRequest` to get more subscriptions.
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000527 "subscriptions": [ # The subscriptions that match the request.
528 { # A subscription resource.
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400529 "ackDeadlineSeconds": 42, # This value is the maximum time after a subscriber receives a message
530 # before the subscriber should acknowledge the message. After message
531 # delivery but before the ack deadline expires and before the message is
532 # acknowledged, it is an outstanding message and will not be delivered
533 # again during that time (on a best-effort basis).
534 #
535 # For pull subscriptions, this value is used as the initial value for the ack
536 # deadline. To override this value for a given message, call
537 # `ModifyAckDeadline` with the corresponding `ack_id` if using pull.
538 # The maximum custom deadline you can specify is 600 seconds (10 minutes).
539 #
540 # For push delivery, this value is also used to set the request timeout for
541 # the call to the push endpoint.
542 #
543 # If the subscriber never acknowledges the message, the Pub/Sub
544 # system will eventually redeliver the message.
545 #
546 # If this parameter is 0, a default value of 10 seconds is used.
547 "topic": "A String", # The name of the topic from which this subscription is receiving messages.
548 # The value of this field will be `_deleted-topic_` if the topic has been
549 # deleted.
550 "pushConfig": { # Configuration for a push delivery endpoint. # If push delivery is used with this subscription, this field is
551 # used to configure it. An empty `pushConfig` signifies that the subscriber
552 # will pull and ack messages using API methods.
553 "attributes": { # Endpoint configuration attributes.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800554 #
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400555 # Every endpoint has a set of API supported attributes that can be used to
556 # control different aspects of the message delivery.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800557 #
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400558 # The currently supported attribute is `x-goog-version`, which you can
559 # use to change the format of the push message. This attribute
560 # indicates the version of the data expected by the endpoint. This
561 # controls the shape of the envelope (i.e. its fields and metadata).
562 # The endpoint version is based on the version of the Pub/Sub
563 # API.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800564 #
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400565 # If not present during the `CreateSubscription` call, it will default to
566 # the version of the API used to make such call. If not present during a
567 # `ModifyPushConfig` call, its value will not be changed. `GetSubscription`
568 # calls will always return a valid version, even if the subscription was
569 # created without this attribute.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800570 #
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400571 # The possible values for this attribute are:
572 #
573 # * `v1beta1`: uses the push format defined in the v1beta1 Pub/Sub API.
574 # * `v1` or `v1beta2`: uses the push format defined in the v1 Pub/Sub API.
575 "a_key": "A String",
Craig Citroe633be12015-03-02 13:40:36 -0800576 },
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400577 "pushEndpoint": "A String", # A URL locating the endpoint to which messages should be pushed.
578 # For example, a Webhook endpoint might use "https://example.com/push".
Craig Citroe633be12015-03-02 13:40:36 -0800579 },
Sai Cheemalapati4ba8c232017-06-06 18:46:08 -0400580 "name": "A String", # The name of the subscription. It must have the format
581 # `"projects/{project}/subscriptions/{subscription}"`. `{subscription}` must
582 # start with a letter, and contain only letters (`[A-Za-z]`), numbers
583 # (`[0-9]`), dashes (`-`), underscores (`_`), periods (`.`), tildes (`~`),
584 # plus (`+`) or percent signs (`%`). It must be between 3 and 255 characters
585 # in length, and it must not start with `"goog"`.
586 },
Craig Citroe633be12015-03-02 13:40:36 -0800587 ],
588 }</pre>
589</div>
590
591<div class="method">
592 <code class="details" id="list_next">list_next(previous_request, previous_response)</code>
593 <pre>Retrieves the next page of results.
594
595Args:
596 previous_request: The request for the previous page. (required)
597 previous_response: The response from the request for the previous page. (required)
598
599Returns:
600 A request object that you can call 'execute()' on to request the next
601 page. Returns None if there are no more items in the collection.
602 </pre>
603</div>
604
605<div class="method">
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000606 <code class="details" id="modifyAckDeadline">modifyAckDeadline(subscription, body, x__xgafv=None)</code>
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800607 <pre>Modifies the ack deadline for a specific message. This method is useful
608to indicate that more time is needed to process a message by the
609subscriber, or to make the message available for redelivery if the
610processing was interrupted. Note that this does not modify the
611subscription-level `ackDeadlineSeconds` used for subsequent messages.
Craig Citroe633be12015-03-02 13:40:36 -0800612
613Args:
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000614 subscription: string, The name of the subscription. (required)
Craig Citroe633be12015-03-02 13:40:36 -0800615 body: object, The request body. (required)
616 The object takes the form of:
617
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000618{ # Request for the ModifyAckDeadline method.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800619 "ackDeadlineSeconds": 42, # The new ack deadline with respect to the time this request was sent to
620 # the Pub/Sub system. Must be >= 0. For example, if the value is 10, the new
621 # ack deadline will expire 10 seconds after the `ModifyAckDeadline` call
622 # was made. Specifying zero may immediately make the message available for
623 # another pull request.
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000624 "ackIds": [ # List of acknowledgment IDs.
625 "A String",
626 ],
Thomas Coffee2f245372017-03-27 10:39:26 -0700627 "ackId": "A String", # The acknowledgment ID. Either this or ack_ids must be populated, but not
628 # both.
Craig Citroe633be12015-03-02 13:40:36 -0800629 }
630
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000631 x__xgafv: string, V1 error format.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800632 Allowed values
633 1 - v1 error format
634 2 - v2 error format
Craig Citroe633be12015-03-02 13:40:36 -0800635
636Returns:
637 An object of the form:
638
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800639 { # A generic empty message that you can re-use to avoid defining duplicated
640 # empty messages in your APIs. A typical example is to use it as the request
641 # or the response type of an API method. For instance:
642 #
643 # service Foo {
644 # rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty);
645 # }
646 #
647 # The JSON representation for `Empty` is empty JSON object `{}`.
Craig Citroe633be12015-03-02 13:40:36 -0800648 }</pre>
649</div>
650
651<div class="method">
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000652 <code class="details" id="modifyPushConfig">modifyPushConfig(subscription, body, x__xgafv=None)</code>
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800653 <pre>Modifies the `PushConfig` for a specified subscription.
654
655This may be used to change a push subscription to a pull one (signified by
656an empty `PushConfig`) or vice versa, or change the endpoint URL and other
657attributes of a push subscription. Messages will accumulate for delivery
658continuously through the call regardless of changes to the `PushConfig`.
Craig Citroe633be12015-03-02 13:40:36 -0800659
660Args:
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000661 subscription: string, The name of the subscription. (required)
Craig Citroe633be12015-03-02 13:40:36 -0800662 body: object, The request body. (required)
663 The object takes the form of:
664
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000665{ # Request for the ModifyPushConfig method.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800666 "pushConfig": { # Configuration for a push delivery endpoint. # The push configuration for future deliveries.
667 #
668 # An empty `pushConfig` indicates that the Pub/Sub system should
669 # stop pushing messages from the given subscription and allow
670 # messages to be pulled and acknowledged - effectively pausing
671 # the subscription if `Pull` is not called.
672 "attributes": { # Endpoint configuration attributes.
673 #
674 # Every endpoint has a set of API supported attributes that can be used to
675 # control different aspects of the message delivery.
676 #
677 # The currently supported attribute is `x-goog-version`, which you can
678 # use to change the format of the push message. This attribute
679 # indicates the version of the data expected by the endpoint. This
680 # controls the shape of the envelope (i.e. its fields and metadata).
681 # The endpoint version is based on the version of the Pub/Sub
682 # API.
683 #
684 # If not present during the `CreateSubscription` call, it will default to
685 # the version of the API used to make such call. If not present during a
686 # `ModifyPushConfig` call, its value will not be changed. `GetSubscription`
687 # calls will always return a valid version, even if the subscription was
688 # created without this attribute.
689 #
690 # The possible values for this attribute are:
691 #
692 # * `v1beta1`: uses the push format defined in the v1beta1 Pub/Sub API.
693 # * `v1` or `v1beta2`: uses the push format defined in the v1 Pub/Sub API.
Craig Citroe633be12015-03-02 13:40:36 -0800694 "a_key": "A String",
695 },
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800696 "pushEndpoint": "A String", # A URL locating the endpoint to which messages should be pushed.
697 # For example, a Webhook endpoint might use "https://example.com/push".
Craig Citroe633be12015-03-02 13:40:36 -0800698 },
699 }
700
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000701 x__xgafv: string, V1 error format.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800702 Allowed values
703 1 - v1 error format
704 2 - v2 error format
Craig Citroe633be12015-03-02 13:40:36 -0800705
706Returns:
707 An object of the form:
708
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800709 { # A generic empty message that you can re-use to avoid defining duplicated
710 # empty messages in your APIs. A typical example is to use it as the request
711 # or the response type of an API method. For instance:
712 #
713 # service Foo {
714 # rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty);
715 # }
716 #
717 # The JSON representation for `Empty` is empty JSON object `{}`.
Craig Citroe633be12015-03-02 13:40:36 -0800718 }</pre>
719</div>
720
721<div class="method">
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000722 <code class="details" id="pull">pull(subscription, body, x__xgafv=None)</code>
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800723 <pre>Pulls messages from the server. Returns an empty list if there are no
724messages available in the backlog. The server may return `UNAVAILABLE` if
725there are too many concurrent pull requests pending for the given
726subscription.
Craig Citroe633be12015-03-02 13:40:36 -0800727
728Args:
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000729 subscription: string, The subscription from which messages should be pulled. (required)
Craig Citroe633be12015-03-02 13:40:36 -0800730 body: object, The request body. (required)
731 The object takes the form of:
732
Sai Cheemalapatidf613972016-10-21 13:59:49 -0700733{ # Request for the `Pull` method.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800734 "returnImmediately": True or False, # If this is specified as true the system will respond immediately even if
735 # it is not able to return a message in the `Pull` response. Otherwise the
736 # system is allowed to wait until at least one message is available rather
737 # than returning no messages. The client may cancel the request if it does
738 # not wish to wait any longer for the response.
739 "maxMessages": 42, # The maximum number of messages returned for this request. The Pub/Sub
740 # system may return fewer than the number specified.
Craig Citroe633be12015-03-02 13:40:36 -0800741 }
742
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000743 x__xgafv: string, V1 error format.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800744 Allowed values
745 1 - v1 error format
746 2 - v2 error format
Craig Citroe633be12015-03-02 13:40:36 -0800747
748Returns:
749 An object of the form:
750
Sai Cheemalapatidf613972016-10-21 13:59:49 -0700751 { # Response for the `Pull` method.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800752 "receivedMessages": [ # Received Pub/Sub messages. The Pub/Sub system will return zero messages if
753 # there are no more available in the backlog. The Pub/Sub system may return
754 # fewer than the `maxMessages` requested even if there are more messages
755 # available in the backlog.
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000756 { # A message and its corresponding acknowledgment ID.
757 "ackId": "A String", # This ID can be used to acknowledge the received message.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800758 "message": { # A message data and its attributes. The message payload must not be empty; # The message.
759 # it must contain either a non-empty data field, or at least one attribute.
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000760 "attributes": { # Optional attributes for this message.
Craig Citroe633be12015-03-02 13:40:36 -0800761 "a_key": "A String",
762 },
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800763 "data": "A String", # The message payload. For JSON requests, the value of this field must be
764 # [base64-encoded](https://tools.ietf.org/html/rfc4648).
765 "publishTime": "A String", # The time at which the message was published, populated by the server when
766 # it receives the `Publish` call. It must not be populated by the
767 # publisher in a `Publish` call.
768 "messageId": "A String", # ID of this message, assigned by the server when the message is published.
769 # Guaranteed to be unique within the topic. This value may be read by a
770 # subscriber that receives a `PubsubMessage` via a `Pull` call or a push
771 # delivery. It must not be populated by the publisher in a `Publish` call.
Craig Citroe633be12015-03-02 13:40:36 -0800772 },
773 },
774 ],
775 }</pre>
776</div>
777
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000778<div class="method">
Thomas Coffee2f245372017-03-27 10:39:26 -0700779 <code class="details" id="setIamPolicy">setIamPolicy(resource, body, x__xgafv=None)</code>
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800780 <pre>Sets the access control policy on the specified resource. Replaces any
781existing policy.
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000782
783Args:
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800784 resource: string, REQUIRED: The resource for which the policy is being specified.
Sai Cheemalapatie833b792017-03-24 15:06:46 -0700785See the operation documentation for the appropriate value for this field. (required)
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000786 body: object, The request body. (required)
787 The object takes the form of:
788
789{ # Request message for `SetIamPolicy` method.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800790 "policy": { # Defines an Identity and Access Management (IAM) policy. It is used to # REQUIRED: The complete policy to be applied to the `resource`. The size of
791 # the policy is limited to a few 10s of KB. An empty policy is a
792 # valid policy but certain Cloud Platform services (such as Projects)
793 # might reject them.
794 # specify access control policies for Cloud Platform resources.
795 #
796 #
797 # A `Policy` consists of a list of `bindings`. A `Binding` binds a list of
798 # `members` to a `role`, where the members can be user accounts, Google groups,
799 # Google domains, and service accounts. A `role` is a named list of permissions
800 # defined by IAM.
801 #
802 # **Example**
803 #
804 # {
805 # "bindings": [
806 # {
807 # "role": "roles/owner",
808 # "members": [
809 # "user:mike@example.com",
810 # "group:admins@example.com",
811 # "domain:google.com",
812 # "serviceAccount:my-other-app@appspot.gserviceaccount.com",
813 # ]
814 # },
815 # {
816 # "role": "roles/viewer",
817 # "members": ["user:sean@example.com"]
818 # }
819 # ]
820 # }
821 #
822 # For a description of IAM and its features, see the
823 # [IAM developer's guide](https://cloud.google.com/iam).
824 "bindings": [ # Associates a list of `members` to a `role`.
825 # Multiple `bindings` must not be specified for the same `role`.
826 # `bindings` with no members will result in an error.
Sai Cheemalapatidf613972016-10-21 13:59:49 -0700827 { # Associates `members` with a `role`.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800828 "role": "A String", # Role that is assigned to `members`.
829 # For example, `roles/viewer`, `roles/editor`, or `roles/owner`.
830 # Required
831 "members": [ # Specifies the identities requesting access for a Cloud Platform resource.
832 # `members` can have the following values:
833 #
834 # * `allUsers`: A special identifier that represents anyone who is
835 # on the internet; with or without a Google account.
836 #
837 # * `allAuthenticatedUsers`: A special identifier that represents anyone
838 # who is authenticated with a Google account or a service account.
839 #
840 # * `user:{emailid}`: An email address that represents a specific Google
841 # account. For example, `alice@gmail.com` or `joe@example.com`.
842 #
843 #
844 # * `serviceAccount:{emailid}`: An email address that represents a service
845 # account. For example, `my-other-app@appspot.gserviceaccount.com`.
846 #
847 # * `group:{emailid}`: An email address that represents a Google group.
848 # For example, `admins@example.com`.
849 #
850 # * `domain:{domain}`: A Google Apps domain name that represents all the
851 # users of that domain. For example, `google.com` or `example.com`.
852 #
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000853 "A String",
854 ],
855 },
856 ],
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800857 "etag": "A String", # `etag` is used for optimistic concurrency control as a way to help
858 # prevent simultaneous updates of a policy from overwriting each other.
859 # It is strongly suggested that systems make use of the `etag` in the
860 # read-modify-write cycle to perform policy updates in order to avoid race
861 # conditions: An `etag` is returned in the response to `getIamPolicy`, and
862 # systems are expected to put that etag in the request to `setIamPolicy` to
863 # ensure that their change will be applied to the same version of the policy.
864 #
865 # If no `etag` is provided in the call to `setIamPolicy`, then the existing
866 # policy is overwritten blindly.
Sai Cheemalapatidf613972016-10-21 13:59:49 -0700867 "version": 42, # Version of the `Policy`. The default version is 0.
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000868 },
869 }
870
871 x__xgafv: string, V1 error format.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800872 Allowed values
873 1 - v1 error format
874 2 - v2 error format
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000875
876Returns:
877 An object of the form:
878
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800879 { # Defines an Identity and Access Management (IAM) policy. It is used to
880 # specify access control policies for Cloud Platform resources.
881 #
882 #
883 # A `Policy` consists of a list of `bindings`. A `Binding` binds a list of
884 # `members` to a `role`, where the members can be user accounts, Google groups,
885 # Google domains, and service accounts. A `role` is a named list of permissions
886 # defined by IAM.
887 #
888 # **Example**
889 #
890 # {
891 # "bindings": [
892 # {
893 # "role": "roles/owner",
894 # "members": [
895 # "user:mike@example.com",
896 # "group:admins@example.com",
897 # "domain:google.com",
898 # "serviceAccount:my-other-app@appspot.gserviceaccount.com",
899 # ]
900 # },
901 # {
902 # "role": "roles/viewer",
903 # "members": ["user:sean@example.com"]
904 # }
905 # ]
906 # }
907 #
908 # For a description of IAM and its features, see the
909 # [IAM developer's guide](https://cloud.google.com/iam).
910 "bindings": [ # Associates a list of `members` to a `role`.
911 # Multiple `bindings` must not be specified for the same `role`.
912 # `bindings` with no members will result in an error.
Sai Cheemalapatidf613972016-10-21 13:59:49 -0700913 { # Associates `members` with a `role`.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800914 "role": "A String", # Role that is assigned to `members`.
915 # For example, `roles/viewer`, `roles/editor`, or `roles/owner`.
916 # Required
917 "members": [ # Specifies the identities requesting access for a Cloud Platform resource.
918 # `members` can have the following values:
919 #
920 # * `allUsers`: A special identifier that represents anyone who is
921 # on the internet; with or without a Google account.
922 #
923 # * `allAuthenticatedUsers`: A special identifier that represents anyone
924 # who is authenticated with a Google account or a service account.
925 #
926 # * `user:{emailid}`: An email address that represents a specific Google
927 # account. For example, `alice@gmail.com` or `joe@example.com`.
928 #
929 #
930 # * `serviceAccount:{emailid}`: An email address that represents a service
931 # account. For example, `my-other-app@appspot.gserviceaccount.com`.
932 #
933 # * `group:{emailid}`: An email address that represents a Google group.
934 # For example, `admins@example.com`.
935 #
936 # * `domain:{domain}`: A Google Apps domain name that represents all the
937 # users of that domain. For example, `google.com` or `example.com`.
938 #
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000939 "A String",
940 ],
941 },
942 ],
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800943 "etag": "A String", # `etag` is used for optimistic concurrency control as a way to help
944 # prevent simultaneous updates of a policy from overwriting each other.
945 # It is strongly suggested that systems make use of the `etag` in the
946 # read-modify-write cycle to perform policy updates in order to avoid race
947 # conditions: An `etag` is returned in the response to `getIamPolicy`, and
948 # systems are expected to put that etag in the request to `setIamPolicy` to
949 # ensure that their change will be applied to the same version of the policy.
950 #
951 # If no `etag` is provided in the call to `setIamPolicy`, then the existing
952 # policy is overwritten blindly.
Sai Cheemalapatidf613972016-10-21 13:59:49 -0700953 "version": 42, # Version of the `Policy`. The default version is 0.
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000954 }</pre>
955</div>
956
957<div class="method">
Thomas Coffee2f245372017-03-27 10:39:26 -0700958 <code class="details" id="testIamPermissions">testIamPermissions(resource, body, x__xgafv=None)</code>
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000959 <pre>Returns permissions that a caller has on the specified resource.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800960If the resource does not exist, this will return an empty set of
961permissions, not a NOT_FOUND error.
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000962
Sai Cheemalapatic30d2b52017-03-13 12:12:03 -0400963Note: This operation is designed to be used for building permission-aware
964UIs and command-line tools, not for authorization checking. This operation
965may "fail open" without warning.
966
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000967Args:
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800968 resource: string, REQUIRED: The resource for which the policy detail is being requested.
Sai Cheemalapatie833b792017-03-24 15:06:46 -0700969See the operation documentation for the appropriate value for this field. (required)
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000970 body: object, The request body. (required)
971 The object takes the form of:
972
973{ # Request message for `TestIamPermissions` method.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800974 "permissions": [ # The set of permissions to check for the `resource`. Permissions with
975 # wildcards (such as '*' or 'storage.*') are not allowed. For more
976 # information see
977 # [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions).
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000978 "A String",
979 ],
980 }
981
982 x__xgafv: string, V1 error format.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800983 Allowed values
984 1 - v1 error format
985 2 - v2 error format
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000986
987Returns:
988 An object of the form:
989
990 { # Response message for `TestIamPermissions` method.
Jon Wayne Parrott692617a2017-01-06 09:58:29 -0800991 "permissions": [ # A subset of `TestPermissionsRequest.permissions` that the caller is
992 # allowed.
Nathaniel Manista4f877e52015-06-15 16:44:50 +0000993 "A String",
994 ],
995 }</pre>
996</div>
997
Craig Citroe633be12015-03-02 13:40:36 -0800998</body></html>