Sai Cheemalapati | ea3a5e1 | 2016-10-12 14:05:53 -0700 | [diff] [blame] | 1 | <html><body> |
| 2 | <style> |
| 3 | |
| 4 | body, 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 | |
| 15 | body { |
| 16 | font-size: 13px; |
| 17 | padding: 1em; |
| 18 | } |
| 19 | |
| 20 | h1 { |
| 21 | font-size: 26px; |
| 22 | margin-bottom: 1em; |
| 23 | } |
| 24 | |
| 25 | h2 { |
| 26 | font-size: 24px; |
| 27 | margin-bottom: 1em; |
| 28 | } |
| 29 | |
| 30 | h3 { |
| 31 | font-size: 20px; |
| 32 | margin-bottom: 1em; |
| 33 | margin-top: 1em; |
| 34 | } |
| 35 | |
| 36 | pre, code { |
| 37 | line-height: 1.5; |
| 38 | font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace; |
| 39 | } |
| 40 | |
| 41 | pre { |
| 42 | margin-top: 0.5em; |
| 43 | } |
| 44 | |
| 45 | h1, h2, h3, p { |
| 46 | font-family: Arial, sans serif; |
| 47 | } |
| 48 | |
| 49 | h1, 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 Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame^] | 75 | <h1><a href="pubsub_v1.html">Cloud Pub/Sub API</a> . <a href="pubsub_v1.projects.html">projects</a> . <a href="pubsub_v1.projects.snapshots.html">snapshots</a></h1> |
Sai Cheemalapati | ea3a5e1 | 2016-10-12 14:05:53 -0700 | [diff] [blame] | 76 | <h2>Instance Methods</h2> |
| 77 | <p class="toc_element"> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame^] | 78 | <code><a href="#create">create(name, body, x__xgafv=None)</a></code></p> |
| 79 | <p class="firstline">Creates a snapshot from the requested subscription. Snapshots are used in</p> |
| 80 | <p class="toc_element"> |
| 81 | <code><a href="#delete">delete(snapshot, x__xgafv=None)</a></code></p> |
| 82 | <p class="firstline">Removes an existing snapshot. Snapshots are used in</p> |
| 83 | <p class="toc_element"> |
| 84 | <code><a href="#get">get(snapshot, x__xgafv=None)</a></code></p> |
| 85 | <p class="firstline">Gets the configuration details of a snapshot. Snapshots are used in</p> |
| 86 | <p class="toc_element"> |
Thomas Coffee | 2f24537 | 2017-03-27 10:39:26 -0700 | [diff] [blame] | 87 | <code><a href="#getIamPolicy">getIamPolicy(resource, x__xgafv=None)</a></code></p> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 88 | <p class="firstline">Gets the access control policy for a resource.</p> |
Sai Cheemalapati | ea3a5e1 | 2016-10-12 14:05:53 -0700 | [diff] [blame] | 89 | <p class="toc_element"> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame^] | 90 | <code><a href="#list">list(project, pageSize=None, pageToken=None, x__xgafv=None)</a></code></p> |
| 91 | <p class="firstline">Lists the existing snapshots. Snapshots are used in</p> |
| 92 | <p class="toc_element"> |
| 93 | <code><a href="#list_next">list_next(previous_request, previous_response)</a></code></p> |
| 94 | <p class="firstline">Retrieves the next page of results.</p> |
| 95 | <p class="toc_element"> |
| 96 | <code><a href="#patch">patch(name, body, x__xgafv=None)</a></code></p> |
| 97 | <p class="firstline">Updates an existing snapshot. Snapshots are used in</p> |
| 98 | <p class="toc_element"> |
Thomas Coffee | 2f24537 | 2017-03-27 10:39:26 -0700 | [diff] [blame] | 99 | <code><a href="#setIamPolicy">setIamPolicy(resource, body, x__xgafv=None)</a></code></p> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 100 | <p class="firstline">Sets the access control policy on the specified resource. Replaces any</p> |
Sai Cheemalapati | ea3a5e1 | 2016-10-12 14:05:53 -0700 | [diff] [blame] | 101 | <p class="toc_element"> |
Thomas Coffee | 2f24537 | 2017-03-27 10:39:26 -0700 | [diff] [blame] | 102 | <code><a href="#testIamPermissions">testIamPermissions(resource, body, x__xgafv=None)</a></code></p> |
Sai Cheemalapati | ea3a5e1 | 2016-10-12 14:05:53 -0700 | [diff] [blame] | 103 | <p class="firstline">Returns permissions that a caller has on the specified resource.</p> |
| 104 | <h3>Method Details</h3> |
| 105 | <div class="method"> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame^] | 106 | <code class="details" id="create">create(name, body, x__xgafv=None)</code> |
| 107 | <pre>Creates a snapshot from the requested subscription. Snapshots are used in |
| 108 | <a href="https://cloud.google.com/pubsub/docs/replay-overview">Seek</a> |
| 109 | operations, which allow |
| 110 | you to manage message acknowledgments in bulk. That is, you can set the |
| 111 | acknowledgment state of messages in an existing subscription to the state |
| 112 | captured by a snapshot. |
| 113 | <br><br>If the snapshot already exists, returns `ALREADY_EXISTS`. |
| 114 | If the requested subscription doesn't exist, returns `NOT_FOUND`. |
| 115 | If the backlog in the subscription is too old -- and the resulting snapshot |
| 116 | would expire in less than 1 hour -- then `FAILED_PRECONDITION` is returned. |
| 117 | See also the `Snapshot.expire_time` field. If the name is not provided in |
| 118 | the request, the server will assign a random |
| 119 | name for this snapshot on the same project as the subscription, conforming |
| 120 | to the |
| 121 | [resource name |
| 122 | format](https://cloud.google.com/pubsub/docs/admin#resource_names). The |
| 123 | generated name is populated in the returned Snapshot object. Note that for |
| 124 | REST API requests, you must specify a name in the request. |
| 125 | |
| 126 | Args: |
| 127 | name: string, Optional user-provided name for this snapshot. |
| 128 | If the name is not provided in the request, the server will assign a random |
| 129 | name for this snapshot on the same project as the subscription. |
| 130 | Note that for REST API requests, you must specify a name. See the |
| 131 | <a href="https://cloud.google.com/pubsub/docs/admin#resource_names"> |
| 132 | resource name rules</a>. |
| 133 | Format is `projects/{project}/snapshots/{snap}`. (required) |
| 134 | body: object, The request body. (required) |
| 135 | The object takes the form of: |
| 136 | |
| 137 | { # Request for the `CreateSnapshot` method. |
| 138 | "labels": { # See <a href="https://cloud.google.com/pubsub/docs/labels"> Creating and |
| 139 | # managing labels</a>. |
| 140 | "a_key": "A String", |
| 141 | }, |
| 142 | "subscription": "A String", # The subscription whose backlog the snapshot retains. |
| 143 | # Specifically, the created snapshot is guaranteed to retain: |
| 144 | # (a) The existing backlog on the subscription. More precisely, this is |
| 145 | # defined as the messages in the subscription's backlog that are |
| 146 | # unacknowledged upon the successful completion of the |
| 147 | # `CreateSnapshot` request; as well as: |
| 148 | # (b) Any messages published to the subscription's topic following the |
| 149 | # successful completion of the CreateSnapshot request. |
| 150 | # Format is `projects/{project}/subscriptions/{sub}`. |
| 151 | } |
| 152 | |
| 153 | x__xgafv: string, V1 error format. |
| 154 | Allowed values |
| 155 | 1 - v1 error format |
| 156 | 2 - v2 error format |
| 157 | |
| 158 | Returns: |
| 159 | An object of the form: |
| 160 | |
| 161 | { # A snapshot resource. Snapshots are used in |
| 162 | # <a href="https://cloud.google.com/pubsub/docs/replay-overview">Seek</a> |
| 163 | # operations, which allow |
| 164 | # you to manage message acknowledgments in bulk. That is, you can set the |
| 165 | # acknowledgment state of messages in an existing subscription to the state |
| 166 | # captured by a snapshot. |
| 167 | "topic": "A String", # The name of the topic from which this snapshot is retaining messages. |
| 168 | "expireTime": "A String", # The snapshot is guaranteed to exist up until this time. |
| 169 | # A newly-created snapshot expires no later than 7 days from the time of its |
| 170 | # creation. Its exact lifetime is determined at creation by the existing |
| 171 | # backlog in the source subscription. Specifically, the lifetime of the |
| 172 | # snapshot is `7 days - (age of oldest unacked message in the subscription)`. |
| 173 | # For example, consider a subscription whose oldest unacked message is 3 days |
| 174 | # old. If a snapshot is created from this subscription, the snapshot -- which |
| 175 | # will always capture this 3-day-old backlog as long as the snapshot |
| 176 | # exists -- will expire in 4 days. The service will refuse to create a |
| 177 | # snapshot that would expire in less than 1 hour after creation. |
| 178 | "labels": { # See <a href="https://cloud.google.com/pubsub/docs/labels"> Creating and |
| 179 | # managing labels</a>. |
| 180 | "a_key": "A String", |
| 181 | }, |
| 182 | "name": "A String", # The name of the snapshot. |
| 183 | }</pre> |
| 184 | </div> |
| 185 | |
| 186 | <div class="method"> |
| 187 | <code class="details" id="delete">delete(snapshot, x__xgafv=None)</code> |
| 188 | <pre>Removes an existing snapshot. Snapshots are used in |
| 189 | <a href="https://cloud.google.com/pubsub/docs/replay-overview">Seek</a> |
| 190 | operations, which allow |
| 191 | you to manage message acknowledgments in bulk. That is, you can set the |
| 192 | acknowledgment state of messages in an existing subscription to the state |
| 193 | captured by a snapshot.<br><br> |
| 194 | When the snapshot is deleted, all messages retained in the snapshot |
| 195 | are immediately dropped. After a snapshot is deleted, a new one may be |
| 196 | created with the same name, but the new one has no association with the old |
| 197 | snapshot or its subscription, unless the same subscription is specified. |
| 198 | |
| 199 | Args: |
| 200 | snapshot: string, The name of the snapshot to delete. |
| 201 | Format is `projects/{project}/snapshots/{snap}`. (required) |
| 202 | x__xgafv: string, V1 error format. |
| 203 | Allowed values |
| 204 | 1 - v1 error format |
| 205 | 2 - v2 error format |
| 206 | |
| 207 | Returns: |
| 208 | An object of the form: |
| 209 | |
| 210 | { # A generic empty message that you can re-use to avoid defining duplicated |
| 211 | # empty messages in your APIs. A typical example is to use it as the request |
| 212 | # or the response type of an API method. For instance: |
| 213 | # |
| 214 | # service Foo { |
| 215 | # rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); |
| 216 | # } |
| 217 | # |
| 218 | # The JSON representation for `Empty` is empty JSON object `{}`. |
| 219 | }</pre> |
| 220 | </div> |
| 221 | |
| 222 | <div class="method"> |
| 223 | <code class="details" id="get">get(snapshot, x__xgafv=None)</code> |
| 224 | <pre>Gets the configuration details of a snapshot. Snapshots are used in |
| 225 | <a href="https://cloud.google.com/pubsub/docs/replay-overview">Seek</a> |
| 226 | operations, which allow you to manage message acknowledgments in bulk. That |
| 227 | is, you can set the acknowledgment state of messages in an existing |
| 228 | subscription to the state captured by a snapshot. |
| 229 | |
| 230 | Args: |
| 231 | snapshot: string, The name of the snapshot to get. |
| 232 | Format is `projects/{project}/snapshots/{snap}`. (required) |
| 233 | x__xgafv: string, V1 error format. |
| 234 | Allowed values |
| 235 | 1 - v1 error format |
| 236 | 2 - v2 error format |
| 237 | |
| 238 | Returns: |
| 239 | An object of the form: |
| 240 | |
| 241 | { # A snapshot resource. Snapshots are used in |
| 242 | # <a href="https://cloud.google.com/pubsub/docs/replay-overview">Seek</a> |
| 243 | # operations, which allow |
| 244 | # you to manage message acknowledgments in bulk. That is, you can set the |
| 245 | # acknowledgment state of messages in an existing subscription to the state |
| 246 | # captured by a snapshot. |
| 247 | "topic": "A String", # The name of the topic from which this snapshot is retaining messages. |
| 248 | "expireTime": "A String", # The snapshot is guaranteed to exist up until this time. |
| 249 | # A newly-created snapshot expires no later than 7 days from the time of its |
| 250 | # creation. Its exact lifetime is determined at creation by the existing |
| 251 | # backlog in the source subscription. Specifically, the lifetime of the |
| 252 | # snapshot is `7 days - (age of oldest unacked message in the subscription)`. |
| 253 | # For example, consider a subscription whose oldest unacked message is 3 days |
| 254 | # old. If a snapshot is created from this subscription, the snapshot -- which |
| 255 | # will always capture this 3-day-old backlog as long as the snapshot |
| 256 | # exists -- will expire in 4 days. The service will refuse to create a |
| 257 | # snapshot that would expire in less than 1 hour after creation. |
| 258 | "labels": { # See <a href="https://cloud.google.com/pubsub/docs/labels"> Creating and |
| 259 | # managing labels</a>. |
| 260 | "a_key": "A String", |
| 261 | }, |
| 262 | "name": "A String", # The name of the snapshot. |
| 263 | }</pre> |
| 264 | </div> |
| 265 | |
| 266 | <div class="method"> |
Thomas Coffee | 2f24537 | 2017-03-27 10:39:26 -0700 | [diff] [blame] | 267 | <code class="details" id="getIamPolicy">getIamPolicy(resource, x__xgafv=None)</code> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 268 | <pre>Gets the access control policy for a resource. |
| 269 | Returns an empty policy if the resource exists and does not have a policy |
| 270 | set. |
Sai Cheemalapati | ea3a5e1 | 2016-10-12 14:05:53 -0700 | [diff] [blame] | 271 | |
| 272 | Args: |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 273 | resource: string, REQUIRED: The resource for which the policy is being requested. |
Sai Cheemalapati | e833b79 | 2017-03-24 15:06:46 -0700 | [diff] [blame] | 274 | See the operation documentation for the appropriate value for this field. (required) |
Sai Cheemalapati | ea3a5e1 | 2016-10-12 14:05:53 -0700 | [diff] [blame] | 275 | x__xgafv: string, V1 error format. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 276 | Allowed values |
| 277 | 1 - v1 error format |
| 278 | 2 - v2 error format |
Sai Cheemalapati | ea3a5e1 | 2016-10-12 14:05:53 -0700 | [diff] [blame] | 279 | |
| 280 | Returns: |
| 281 | An object of the form: |
| 282 | |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 283 | { # Defines an Identity and Access Management (IAM) policy. It is used to |
| 284 | # specify access control policies for Cloud Platform resources. |
| 285 | # |
| 286 | # |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame^] | 287 | # A `Policy` consists of a list of `bindings`. A `binding` binds a list of |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 288 | # `members` to a `role`, where the members can be user accounts, Google groups, |
| 289 | # Google domains, and service accounts. A `role` is a named list of permissions |
| 290 | # defined by IAM. |
| 291 | # |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame^] | 292 | # **JSON Example** |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 293 | # |
| 294 | # { |
| 295 | # "bindings": [ |
| 296 | # { |
| 297 | # "role": "roles/owner", |
| 298 | # "members": [ |
| 299 | # "user:mike@example.com", |
| 300 | # "group:admins@example.com", |
| 301 | # "domain:google.com", |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame^] | 302 | # "serviceAccount:my-other-app@appspot.gserviceaccount.com" |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 303 | # ] |
| 304 | # }, |
| 305 | # { |
| 306 | # "role": "roles/viewer", |
| 307 | # "members": ["user:sean@example.com"] |
| 308 | # } |
| 309 | # ] |
| 310 | # } |
| 311 | # |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame^] | 312 | # **YAML Example** |
| 313 | # |
| 314 | # bindings: |
| 315 | # - members: |
| 316 | # - user:mike@example.com |
| 317 | # - group:admins@example.com |
| 318 | # - domain:google.com |
| 319 | # - serviceAccount:my-other-app@appspot.gserviceaccount.com |
| 320 | # role: roles/owner |
| 321 | # - members: |
| 322 | # - user:sean@example.com |
| 323 | # role: roles/viewer |
| 324 | # |
| 325 | # |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 326 | # For a description of IAM and its features, see the |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame^] | 327 | # [IAM developer's guide](https://cloud.google.com/iam/docs). |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 328 | "bindings": [ # Associates a list of `members` to a `role`. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 329 | # `bindings` with no members will result in an error. |
Sai Cheemalapati | ea3a5e1 | 2016-10-12 14:05:53 -0700 | [diff] [blame] | 330 | { # Associates `members` with a `role`. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 331 | "role": "A String", # Role that is assigned to `members`. |
| 332 | # For example, `roles/viewer`, `roles/editor`, or `roles/owner`. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 333 | "members": [ # Specifies the identities requesting access for a Cloud Platform resource. |
| 334 | # `members` can have the following values: |
| 335 | # |
| 336 | # * `allUsers`: A special identifier that represents anyone who is |
| 337 | # on the internet; with or without a Google account. |
| 338 | # |
| 339 | # * `allAuthenticatedUsers`: A special identifier that represents anyone |
| 340 | # who is authenticated with a Google account or a service account. |
| 341 | # |
| 342 | # * `user:{emailid}`: An email address that represents a specific Google |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame^] | 343 | # account. For example, `alice@gmail.com` . |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 344 | # |
| 345 | # |
| 346 | # * `serviceAccount:{emailid}`: An email address that represents a service |
| 347 | # account. For example, `my-other-app@appspot.gserviceaccount.com`. |
| 348 | # |
| 349 | # * `group:{emailid}`: An email address that represents a Google group. |
| 350 | # For example, `admins@example.com`. |
| 351 | # |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame^] | 352 | # |
| 353 | # * `domain:{domain}`: The G Suite domain (primary) that represents all the |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 354 | # users of that domain. For example, `google.com` or `example.com`. |
| 355 | # |
Sai Cheemalapati | ea3a5e1 | 2016-10-12 14:05:53 -0700 | [diff] [blame] | 356 | "A String", |
| 357 | ], |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame^] | 358 | "condition": { # Represents an expression text. Example: # The condition that is associated with this binding. |
| 359 | # NOTE: An unsatisfied condition will not allow user access via current |
| 360 | # binding. Different bindings, including their conditions, are examined |
| 361 | # independently. |
| 362 | # |
| 363 | # title: "User account presence" |
| 364 | # description: "Determines whether the request has a user account" |
| 365 | # expression: "size(request.user) > 0" |
| 366 | "location": "A String", # An optional string indicating the location of the expression for error |
| 367 | # reporting, e.g. a file name and a position in the file. |
| 368 | "expression": "A String", # Textual representation of an expression in |
| 369 | # Common Expression Language syntax. |
| 370 | # |
| 371 | # The application context of the containing message determines which |
| 372 | # well-known feature set of CEL is supported. |
| 373 | "description": "A String", # An optional description of the expression. This is a longer text which |
| 374 | # describes the expression, e.g. when hovered over it in a UI. |
| 375 | "title": "A String", # An optional title for the expression, i.e. a short string describing |
| 376 | # its purpose. This can be used e.g. in UIs which allow to enter the |
| 377 | # expression. |
| 378 | }, |
Sai Cheemalapati | ea3a5e1 | 2016-10-12 14:05:53 -0700 | [diff] [blame] | 379 | }, |
| 380 | ], |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame^] | 381 | "version": 42, # Deprecated. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 382 | "etag": "A String", # `etag` is used for optimistic concurrency control as a way to help |
| 383 | # prevent simultaneous updates of a policy from overwriting each other. |
| 384 | # It is strongly suggested that systems make use of the `etag` in the |
| 385 | # read-modify-write cycle to perform policy updates in order to avoid race |
| 386 | # conditions: An `etag` is returned in the response to `getIamPolicy`, and |
| 387 | # systems are expected to put that etag in the request to `setIamPolicy` to |
| 388 | # ensure that their change will be applied to the same version of the policy. |
| 389 | # |
| 390 | # If no `etag` is provided in the call to `setIamPolicy`, then the existing |
| 391 | # policy is overwritten blindly. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame^] | 392 | }</pre> |
| 393 | </div> |
| 394 | |
| 395 | <div class="method"> |
| 396 | <code class="details" id="list">list(project, pageSize=None, pageToken=None, x__xgafv=None)</code> |
| 397 | <pre>Lists the existing snapshots. Snapshots are used in |
| 398 | <a href="https://cloud.google.com/pubsub/docs/replay-overview">Seek</a> |
| 399 | operations, which allow |
| 400 | you to manage message acknowledgments in bulk. That is, you can set the |
| 401 | acknowledgment state of messages in an existing subscription to the state |
| 402 | captured by a snapshot. |
| 403 | |
| 404 | Args: |
| 405 | project: string, The name of the project in which to list snapshots. |
| 406 | Format is `projects/{project-id}`. (required) |
| 407 | pageSize: integer, Maximum number of snapshots to return. |
| 408 | pageToken: string, The value returned by the last `ListSnapshotsResponse`; indicates that this |
| 409 | is a continuation of a prior `ListSnapshots` call, and that the system |
| 410 | should return the next page of data. |
| 411 | x__xgafv: string, V1 error format. |
| 412 | Allowed values |
| 413 | 1 - v1 error format |
| 414 | 2 - v2 error format |
| 415 | |
| 416 | Returns: |
| 417 | An object of the form: |
| 418 | |
| 419 | { # Response for the `ListSnapshots` method. |
| 420 | "nextPageToken": "A String", # If not empty, indicates that there may be more snapshot that match the |
| 421 | # request; this value should be passed in a new `ListSnapshotsRequest`. |
| 422 | "snapshots": [ # The resulting snapshots. |
| 423 | { # A snapshot resource. Snapshots are used in |
| 424 | # <a href="https://cloud.google.com/pubsub/docs/replay-overview">Seek</a> |
| 425 | # operations, which allow |
| 426 | # you to manage message acknowledgments in bulk. That is, you can set the |
| 427 | # acknowledgment state of messages in an existing subscription to the state |
| 428 | # captured by a snapshot. |
| 429 | "topic": "A String", # The name of the topic from which this snapshot is retaining messages. |
| 430 | "expireTime": "A String", # The snapshot is guaranteed to exist up until this time. |
| 431 | # A newly-created snapshot expires no later than 7 days from the time of its |
| 432 | # creation. Its exact lifetime is determined at creation by the existing |
| 433 | # backlog in the source subscription. Specifically, the lifetime of the |
| 434 | # snapshot is `7 days - (age of oldest unacked message in the subscription)`. |
| 435 | # For example, consider a subscription whose oldest unacked message is 3 days |
| 436 | # old. If a snapshot is created from this subscription, the snapshot -- which |
| 437 | # will always capture this 3-day-old backlog as long as the snapshot |
| 438 | # exists -- will expire in 4 days. The service will refuse to create a |
| 439 | # snapshot that would expire in less than 1 hour after creation. |
| 440 | "labels": { # See <a href="https://cloud.google.com/pubsub/docs/labels"> Creating and |
| 441 | # managing labels</a>. |
| 442 | "a_key": "A String", |
| 443 | }, |
| 444 | "name": "A String", # The name of the snapshot. |
| 445 | }, |
| 446 | ], |
| 447 | }</pre> |
| 448 | </div> |
| 449 | |
| 450 | <div class="method"> |
| 451 | <code class="details" id="list_next">list_next(previous_request, previous_response)</code> |
| 452 | <pre>Retrieves the next page of results. |
| 453 | |
| 454 | Args: |
| 455 | previous_request: The request for the previous page. (required) |
| 456 | previous_response: The response from the request for the previous page. (required) |
| 457 | |
| 458 | Returns: |
| 459 | A request object that you can call 'execute()' on to request the next |
| 460 | page. Returns None if there are no more items in the collection. |
| 461 | </pre> |
| 462 | </div> |
| 463 | |
| 464 | <div class="method"> |
| 465 | <code class="details" id="patch">patch(name, body, x__xgafv=None)</code> |
| 466 | <pre>Updates an existing snapshot. Snapshots are used in |
| 467 | <a href="https://cloud.google.com/pubsub/docs/replay-overview">Seek</a> |
| 468 | operations, which allow |
| 469 | you to manage message acknowledgments in bulk. That is, you can set the |
| 470 | acknowledgment state of messages in an existing subscription to the state |
| 471 | captured by a snapshot. |
| 472 | |
| 473 | Args: |
| 474 | name: string, The name of the snapshot. (required) |
| 475 | body: object, The request body. (required) |
| 476 | The object takes the form of: |
| 477 | |
| 478 | { # Request for the UpdateSnapshot method. |
| 479 | "snapshot": { # A snapshot resource. Snapshots are used in # The updated snapshot object. |
| 480 | # <a href="https://cloud.google.com/pubsub/docs/replay-overview">Seek</a> |
| 481 | # operations, which allow |
| 482 | # you to manage message acknowledgments in bulk. That is, you can set the |
| 483 | # acknowledgment state of messages in an existing subscription to the state |
| 484 | # captured by a snapshot. |
| 485 | "topic": "A String", # The name of the topic from which this snapshot is retaining messages. |
| 486 | "expireTime": "A String", # The snapshot is guaranteed to exist up until this time. |
| 487 | # A newly-created snapshot expires no later than 7 days from the time of its |
| 488 | # creation. Its exact lifetime is determined at creation by the existing |
| 489 | # backlog in the source subscription. Specifically, the lifetime of the |
| 490 | # snapshot is `7 days - (age of oldest unacked message in the subscription)`. |
| 491 | # For example, consider a subscription whose oldest unacked message is 3 days |
| 492 | # old. If a snapshot is created from this subscription, the snapshot -- which |
| 493 | # will always capture this 3-day-old backlog as long as the snapshot |
| 494 | # exists -- will expire in 4 days. The service will refuse to create a |
| 495 | # snapshot that would expire in less than 1 hour after creation. |
| 496 | "labels": { # See <a href="https://cloud.google.com/pubsub/docs/labels"> Creating and |
| 497 | # managing labels</a>. |
| 498 | "a_key": "A String", |
| 499 | }, |
| 500 | "name": "A String", # The name of the snapshot. |
| 501 | }, |
| 502 | "updateMask": "A String", # Indicates which fields in the provided snapshot to update. |
| 503 | # Must be specified and non-empty. |
| 504 | } |
| 505 | |
| 506 | x__xgafv: string, V1 error format. |
| 507 | Allowed values |
| 508 | 1 - v1 error format |
| 509 | 2 - v2 error format |
| 510 | |
| 511 | Returns: |
| 512 | An object of the form: |
| 513 | |
| 514 | { # A snapshot resource. Snapshots are used in |
| 515 | # <a href="https://cloud.google.com/pubsub/docs/replay-overview">Seek</a> |
| 516 | # operations, which allow |
| 517 | # you to manage message acknowledgments in bulk. That is, you can set the |
| 518 | # acknowledgment state of messages in an existing subscription to the state |
| 519 | # captured by a snapshot. |
| 520 | "topic": "A String", # The name of the topic from which this snapshot is retaining messages. |
| 521 | "expireTime": "A String", # The snapshot is guaranteed to exist up until this time. |
| 522 | # A newly-created snapshot expires no later than 7 days from the time of its |
| 523 | # creation. Its exact lifetime is determined at creation by the existing |
| 524 | # backlog in the source subscription. Specifically, the lifetime of the |
| 525 | # snapshot is `7 days - (age of oldest unacked message in the subscription)`. |
| 526 | # For example, consider a subscription whose oldest unacked message is 3 days |
| 527 | # old. If a snapshot is created from this subscription, the snapshot -- which |
| 528 | # will always capture this 3-day-old backlog as long as the snapshot |
| 529 | # exists -- will expire in 4 days. The service will refuse to create a |
| 530 | # snapshot that would expire in less than 1 hour after creation. |
| 531 | "labels": { # See <a href="https://cloud.google.com/pubsub/docs/labels"> Creating and |
| 532 | # managing labels</a>. |
| 533 | "a_key": "A String", |
| 534 | }, |
| 535 | "name": "A String", # The name of the snapshot. |
Sai Cheemalapati | ea3a5e1 | 2016-10-12 14:05:53 -0700 | [diff] [blame] | 536 | }</pre> |
| 537 | </div> |
| 538 | |
| 539 | <div class="method"> |
Thomas Coffee | 2f24537 | 2017-03-27 10:39:26 -0700 | [diff] [blame] | 540 | <code class="details" id="setIamPolicy">setIamPolicy(resource, body, x__xgafv=None)</code> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 541 | <pre>Sets the access control policy on the specified resource. Replaces any |
| 542 | existing policy. |
Sai Cheemalapati | ea3a5e1 | 2016-10-12 14:05:53 -0700 | [diff] [blame] | 543 | |
| 544 | Args: |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 545 | resource: string, REQUIRED: The resource for which the policy is being specified. |
Sai Cheemalapati | e833b79 | 2017-03-24 15:06:46 -0700 | [diff] [blame] | 546 | See the operation documentation for the appropriate value for this field. (required) |
Sai Cheemalapati | ea3a5e1 | 2016-10-12 14:05:53 -0700 | [diff] [blame] | 547 | body: object, The request body. (required) |
| 548 | The object takes the form of: |
| 549 | |
| 550 | { # Request message for `SetIamPolicy` method. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 551 | "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 |
| 552 | # the policy is limited to a few 10s of KB. An empty policy is a |
| 553 | # valid policy but certain Cloud Platform services (such as Projects) |
| 554 | # might reject them. |
| 555 | # specify access control policies for Cloud Platform resources. |
| 556 | # |
| 557 | # |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame^] | 558 | # A `Policy` consists of a list of `bindings`. A `binding` binds a list of |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 559 | # `members` to a `role`, where the members can be user accounts, Google groups, |
| 560 | # Google domains, and service accounts. A `role` is a named list of permissions |
| 561 | # defined by IAM. |
| 562 | # |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame^] | 563 | # **JSON Example** |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 564 | # |
| 565 | # { |
| 566 | # "bindings": [ |
| 567 | # { |
| 568 | # "role": "roles/owner", |
| 569 | # "members": [ |
| 570 | # "user:mike@example.com", |
| 571 | # "group:admins@example.com", |
| 572 | # "domain:google.com", |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame^] | 573 | # "serviceAccount:my-other-app@appspot.gserviceaccount.com" |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 574 | # ] |
| 575 | # }, |
| 576 | # { |
| 577 | # "role": "roles/viewer", |
| 578 | # "members": ["user:sean@example.com"] |
| 579 | # } |
| 580 | # ] |
| 581 | # } |
| 582 | # |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame^] | 583 | # **YAML Example** |
| 584 | # |
| 585 | # bindings: |
| 586 | # - members: |
| 587 | # - user:mike@example.com |
| 588 | # - group:admins@example.com |
| 589 | # - domain:google.com |
| 590 | # - serviceAccount:my-other-app@appspot.gserviceaccount.com |
| 591 | # role: roles/owner |
| 592 | # - members: |
| 593 | # - user:sean@example.com |
| 594 | # role: roles/viewer |
| 595 | # |
| 596 | # |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 597 | # For a description of IAM and its features, see the |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame^] | 598 | # [IAM developer's guide](https://cloud.google.com/iam/docs). |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 599 | "bindings": [ # Associates a list of `members` to a `role`. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 600 | # `bindings` with no members will result in an error. |
Sai Cheemalapati | ea3a5e1 | 2016-10-12 14:05:53 -0700 | [diff] [blame] | 601 | { # Associates `members` with a `role`. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 602 | "role": "A String", # Role that is assigned to `members`. |
| 603 | # For example, `roles/viewer`, `roles/editor`, or `roles/owner`. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 604 | "members": [ # Specifies the identities requesting access for a Cloud Platform resource. |
| 605 | # `members` can have the following values: |
| 606 | # |
| 607 | # * `allUsers`: A special identifier that represents anyone who is |
| 608 | # on the internet; with or without a Google account. |
| 609 | # |
| 610 | # * `allAuthenticatedUsers`: A special identifier that represents anyone |
| 611 | # who is authenticated with a Google account or a service account. |
| 612 | # |
| 613 | # * `user:{emailid}`: An email address that represents a specific Google |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame^] | 614 | # account. For example, `alice@gmail.com` . |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 615 | # |
| 616 | # |
| 617 | # * `serviceAccount:{emailid}`: An email address that represents a service |
| 618 | # account. For example, `my-other-app@appspot.gserviceaccount.com`. |
| 619 | # |
| 620 | # * `group:{emailid}`: An email address that represents a Google group. |
| 621 | # For example, `admins@example.com`. |
| 622 | # |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame^] | 623 | # |
| 624 | # * `domain:{domain}`: The G Suite domain (primary) that represents all the |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 625 | # users of that domain. For example, `google.com` or `example.com`. |
| 626 | # |
Sai Cheemalapati | ea3a5e1 | 2016-10-12 14:05:53 -0700 | [diff] [blame] | 627 | "A String", |
| 628 | ], |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame^] | 629 | "condition": { # Represents an expression text. Example: # The condition that is associated with this binding. |
| 630 | # NOTE: An unsatisfied condition will not allow user access via current |
| 631 | # binding. Different bindings, including their conditions, are examined |
| 632 | # independently. |
| 633 | # |
| 634 | # title: "User account presence" |
| 635 | # description: "Determines whether the request has a user account" |
| 636 | # expression: "size(request.user) > 0" |
| 637 | "location": "A String", # An optional string indicating the location of the expression for error |
| 638 | # reporting, e.g. a file name and a position in the file. |
| 639 | "expression": "A String", # Textual representation of an expression in |
| 640 | # Common Expression Language syntax. |
| 641 | # |
| 642 | # The application context of the containing message determines which |
| 643 | # well-known feature set of CEL is supported. |
| 644 | "description": "A String", # An optional description of the expression. This is a longer text which |
| 645 | # describes the expression, e.g. when hovered over it in a UI. |
| 646 | "title": "A String", # An optional title for the expression, i.e. a short string describing |
| 647 | # its purpose. This can be used e.g. in UIs which allow to enter the |
| 648 | # expression. |
| 649 | }, |
Sai Cheemalapati | ea3a5e1 | 2016-10-12 14:05:53 -0700 | [diff] [blame] | 650 | }, |
| 651 | ], |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame^] | 652 | "version": 42, # Deprecated. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 653 | "etag": "A String", # `etag` is used for optimistic concurrency control as a way to help |
| 654 | # prevent simultaneous updates of a policy from overwriting each other. |
| 655 | # It is strongly suggested that systems make use of the `etag` in the |
| 656 | # read-modify-write cycle to perform policy updates in order to avoid race |
| 657 | # conditions: An `etag` is returned in the response to `getIamPolicy`, and |
| 658 | # systems are expected to put that etag in the request to `setIamPolicy` to |
| 659 | # ensure that their change will be applied to the same version of the policy. |
| 660 | # |
| 661 | # If no `etag` is provided in the call to `setIamPolicy`, then the existing |
| 662 | # policy is overwritten blindly. |
Sai Cheemalapati | ea3a5e1 | 2016-10-12 14:05:53 -0700 | [diff] [blame] | 663 | }, |
| 664 | } |
| 665 | |
| 666 | x__xgafv: string, V1 error format. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 667 | Allowed values |
| 668 | 1 - v1 error format |
| 669 | 2 - v2 error format |
Sai Cheemalapati | ea3a5e1 | 2016-10-12 14:05:53 -0700 | [diff] [blame] | 670 | |
| 671 | Returns: |
| 672 | An object of the form: |
| 673 | |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 674 | { # Defines an Identity and Access Management (IAM) policy. It is used to |
| 675 | # specify access control policies for Cloud Platform resources. |
| 676 | # |
| 677 | # |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame^] | 678 | # A `Policy` consists of a list of `bindings`. A `binding` binds a list of |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 679 | # `members` to a `role`, where the members can be user accounts, Google groups, |
| 680 | # Google domains, and service accounts. A `role` is a named list of permissions |
| 681 | # defined by IAM. |
| 682 | # |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame^] | 683 | # **JSON Example** |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 684 | # |
| 685 | # { |
| 686 | # "bindings": [ |
| 687 | # { |
| 688 | # "role": "roles/owner", |
| 689 | # "members": [ |
| 690 | # "user:mike@example.com", |
| 691 | # "group:admins@example.com", |
| 692 | # "domain:google.com", |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame^] | 693 | # "serviceAccount:my-other-app@appspot.gserviceaccount.com" |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 694 | # ] |
| 695 | # }, |
| 696 | # { |
| 697 | # "role": "roles/viewer", |
| 698 | # "members": ["user:sean@example.com"] |
| 699 | # } |
| 700 | # ] |
| 701 | # } |
| 702 | # |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame^] | 703 | # **YAML Example** |
| 704 | # |
| 705 | # bindings: |
| 706 | # - members: |
| 707 | # - user:mike@example.com |
| 708 | # - group:admins@example.com |
| 709 | # - domain:google.com |
| 710 | # - serviceAccount:my-other-app@appspot.gserviceaccount.com |
| 711 | # role: roles/owner |
| 712 | # - members: |
| 713 | # - user:sean@example.com |
| 714 | # role: roles/viewer |
| 715 | # |
| 716 | # |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 717 | # For a description of IAM and its features, see the |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame^] | 718 | # [IAM developer's guide](https://cloud.google.com/iam/docs). |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 719 | "bindings": [ # Associates a list of `members` to a `role`. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 720 | # `bindings` with no members will result in an error. |
Sai Cheemalapati | ea3a5e1 | 2016-10-12 14:05:53 -0700 | [diff] [blame] | 721 | { # Associates `members` with a `role`. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 722 | "role": "A String", # Role that is assigned to `members`. |
| 723 | # For example, `roles/viewer`, `roles/editor`, or `roles/owner`. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 724 | "members": [ # Specifies the identities requesting access for a Cloud Platform resource. |
| 725 | # `members` can have the following values: |
| 726 | # |
| 727 | # * `allUsers`: A special identifier that represents anyone who is |
| 728 | # on the internet; with or without a Google account. |
| 729 | # |
| 730 | # * `allAuthenticatedUsers`: A special identifier that represents anyone |
| 731 | # who is authenticated with a Google account or a service account. |
| 732 | # |
| 733 | # * `user:{emailid}`: An email address that represents a specific Google |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame^] | 734 | # account. For example, `alice@gmail.com` . |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 735 | # |
| 736 | # |
| 737 | # * `serviceAccount:{emailid}`: An email address that represents a service |
| 738 | # account. For example, `my-other-app@appspot.gserviceaccount.com`. |
| 739 | # |
| 740 | # * `group:{emailid}`: An email address that represents a Google group. |
| 741 | # For example, `admins@example.com`. |
| 742 | # |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame^] | 743 | # |
| 744 | # * `domain:{domain}`: The G Suite domain (primary) that represents all the |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 745 | # users of that domain. For example, `google.com` or `example.com`. |
| 746 | # |
Sai Cheemalapati | ea3a5e1 | 2016-10-12 14:05:53 -0700 | [diff] [blame] | 747 | "A String", |
| 748 | ], |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame^] | 749 | "condition": { # Represents an expression text. Example: # The condition that is associated with this binding. |
| 750 | # NOTE: An unsatisfied condition will not allow user access via current |
| 751 | # binding. Different bindings, including their conditions, are examined |
| 752 | # independently. |
| 753 | # |
| 754 | # title: "User account presence" |
| 755 | # description: "Determines whether the request has a user account" |
| 756 | # expression: "size(request.user) > 0" |
| 757 | "location": "A String", # An optional string indicating the location of the expression for error |
| 758 | # reporting, e.g. a file name and a position in the file. |
| 759 | "expression": "A String", # Textual representation of an expression in |
| 760 | # Common Expression Language syntax. |
| 761 | # |
| 762 | # The application context of the containing message determines which |
| 763 | # well-known feature set of CEL is supported. |
| 764 | "description": "A String", # An optional description of the expression. This is a longer text which |
| 765 | # describes the expression, e.g. when hovered over it in a UI. |
| 766 | "title": "A String", # An optional title for the expression, i.e. a short string describing |
| 767 | # its purpose. This can be used e.g. in UIs which allow to enter the |
| 768 | # expression. |
| 769 | }, |
Sai Cheemalapati | ea3a5e1 | 2016-10-12 14:05:53 -0700 | [diff] [blame] | 770 | }, |
| 771 | ], |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame^] | 772 | "version": 42, # Deprecated. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 773 | "etag": "A String", # `etag` is used for optimistic concurrency control as a way to help |
| 774 | # prevent simultaneous updates of a policy from overwriting each other. |
| 775 | # It is strongly suggested that systems make use of the `etag` in the |
| 776 | # read-modify-write cycle to perform policy updates in order to avoid race |
| 777 | # conditions: An `etag` is returned in the response to `getIamPolicy`, and |
| 778 | # systems are expected to put that etag in the request to `setIamPolicy` to |
| 779 | # ensure that their change will be applied to the same version of the policy. |
| 780 | # |
| 781 | # If no `etag` is provided in the call to `setIamPolicy`, then the existing |
| 782 | # policy is overwritten blindly. |
Sai Cheemalapati | ea3a5e1 | 2016-10-12 14:05:53 -0700 | [diff] [blame] | 783 | }</pre> |
| 784 | </div> |
| 785 | |
| 786 | <div class="method"> |
Thomas Coffee | 2f24537 | 2017-03-27 10:39:26 -0700 | [diff] [blame] | 787 | <code class="details" id="testIamPermissions">testIamPermissions(resource, body, x__xgafv=None)</code> |
Sai Cheemalapati | ea3a5e1 | 2016-10-12 14:05:53 -0700 | [diff] [blame] | 788 | <pre>Returns permissions that a caller has on the specified resource. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 789 | If the resource does not exist, this will return an empty set of |
| 790 | permissions, not a NOT_FOUND error. |
Sai Cheemalapati | ea3a5e1 | 2016-10-12 14:05:53 -0700 | [diff] [blame] | 791 | |
Sai Cheemalapati | c30d2b5 | 2017-03-13 12:12:03 -0400 | [diff] [blame] | 792 | Note: This operation is designed to be used for building permission-aware |
| 793 | UIs and command-line tools, not for authorization checking. This operation |
| 794 | may "fail open" without warning. |
| 795 | |
Sai Cheemalapati | ea3a5e1 | 2016-10-12 14:05:53 -0700 | [diff] [blame] | 796 | Args: |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 797 | resource: string, REQUIRED: The resource for which the policy detail is being requested. |
Sai Cheemalapati | e833b79 | 2017-03-24 15:06:46 -0700 | [diff] [blame] | 798 | See the operation documentation for the appropriate value for this field. (required) |
Sai Cheemalapati | ea3a5e1 | 2016-10-12 14:05:53 -0700 | [diff] [blame] | 799 | body: object, The request body. (required) |
| 800 | The object takes the form of: |
| 801 | |
| 802 | { # Request message for `TestIamPermissions` method. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 803 | "permissions": [ # The set of permissions to check for the `resource`. Permissions with |
| 804 | # wildcards (such as '*' or 'storage.*') are not allowed. For more |
| 805 | # information see |
| 806 | # [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). |
Sai Cheemalapati | ea3a5e1 | 2016-10-12 14:05:53 -0700 | [diff] [blame] | 807 | "A String", |
| 808 | ], |
| 809 | } |
| 810 | |
| 811 | x__xgafv: string, V1 error format. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 812 | Allowed values |
| 813 | 1 - v1 error format |
| 814 | 2 - v2 error format |
Sai Cheemalapati | ea3a5e1 | 2016-10-12 14:05:53 -0700 | [diff] [blame] | 815 | |
| 816 | Returns: |
| 817 | An object of the form: |
| 818 | |
| 819 | { # Response message for `TestIamPermissions` method. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 820 | "permissions": [ # A subset of `TestPermissionsRequest.permissions` that the caller is |
| 821 | # allowed. |
Sai Cheemalapati | ea3a5e1 | 2016-10-12 14:05:53 -0700 | [diff] [blame] | 822 | "A String", |
| 823 | ], |
| 824 | }</pre> |
| 825 | </div> |
| 826 | |
| 827 | </body></html> |