Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -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 | |
| 75 | <h1><a href="pubsub_v1.html">Google Cloud Pub/Sub API</a> . <a href="pubsub_v1.projects.html">projects</a> . <a href="pubsub_v1.projects.topics.html">topics</a></h1> |
| 76 | <h2>Instance Methods</h2> |
| 77 | <p class="toc_element"> |
| 78 | <code><a href="pubsub_v1.projects.topics.subscriptions.html">subscriptions()</a></code> |
| 79 | </p> |
| 80 | <p class="firstline">Returns the subscriptions Resource.</p> |
| 81 | |
| 82 | <p class="toc_element"> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 83 | <code><a href="#create">create(name=None, body, x__xgafv=None)</a></code></p> |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 84 | <p class="firstline">Creates the given topic with the given name.</p> |
| 85 | <p class="toc_element"> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 86 | <code><a href="#delete">delete(topic=None, x__xgafv=None)</a></code></p> |
| 87 | <p class="firstline">Deletes the topic with the given name. Returns `NOT_FOUND` if the topic</p> |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 88 | <p class="toc_element"> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 89 | <code><a href="#get">get(topic=None, x__xgafv=None)</a></code></p> |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 90 | <p class="firstline">Gets the configuration of a topic.</p> |
| 91 | <p class="toc_element"> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 92 | <code><a href="#getIamPolicy">getIamPolicy(resource=None, x__xgafv=None)</a></code></p> |
| 93 | <p class="firstline">Gets the access control policy for a resource.</p> |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 94 | <p class="toc_element"> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 95 | <code><a href="#list">list(project=None, pageSize=None, pageToken=None, x__xgafv=None)</a></code></p> |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 96 | <p class="firstline">Lists matching topics.</p> |
| 97 | <p class="toc_element"> |
| 98 | <code><a href="#list_next">list_next(previous_request, previous_response)</a></code></p> |
| 99 | <p class="firstline">Retrieves the next page of results.</p> |
| 100 | <p class="toc_element"> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 101 | <code><a href="#publish">publish(topic=None, body, x__xgafv=None)</a></code></p> |
| 102 | <p class="firstline">Adds one or more messages to the topic. Returns `NOT_FOUND` if the topic</p> |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 103 | <p class="toc_element"> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 104 | <code><a href="#setIamPolicy">setIamPolicy(resource=None, body, x__xgafv=None)</a></code></p> |
| 105 | <p class="firstline">Sets the access control policy on the specified resource. Replaces any</p> |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 106 | <p class="toc_element"> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 107 | <code><a href="#testIamPermissions">testIamPermissions(resource=None, body, x__xgafv=None)</a></code></p> |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 108 | <p class="firstline">Returns permissions that a caller has on the specified resource.</p> |
| 109 | <h3>Method Details</h3> |
| 110 | <div class="method"> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 111 | <code class="details" id="create">create(name=None, body, x__xgafv=None)</code> |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 112 | <pre>Creates the given topic with the given name. |
| 113 | |
| 114 | Args: |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 115 | name: string, The name of the topic. It must have the format |
| 116 | `"projects/{project}/topics/{topic}"`. `{topic}` must start with a letter, |
| 117 | and contain only letters (`[A-Za-z]`), numbers (`[0-9]`), dashes (`-`), |
| 118 | underscores (`_`), periods (`.`), tildes (`~`), plus (`+`) or percent |
| 119 | signs (`%`). It must be between 3 and 255 characters in length, and it |
| 120 | must not start with `"goog"`. (required) |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 121 | body: object, The request body. (required) |
| 122 | The object takes the form of: |
| 123 | |
| 124 | { # A topic resource. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 125 | "name": "A String", # The name of the topic. It must have the format |
| 126 | # `"projects/{project}/topics/{topic}"`. `{topic}` must start with a letter, |
| 127 | # and contain only letters (`[A-Za-z]`), numbers (`[0-9]`), dashes (`-`), |
| 128 | # underscores (`_`), periods (`.`), tildes (`~`), plus (`+`) or percent |
| 129 | # signs (`%`). It must be between 3 and 255 characters in length, and it |
| 130 | # must not start with `"goog"`. |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 131 | } |
| 132 | |
| 133 | x__xgafv: string, V1 error format. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 134 | Allowed values |
| 135 | 1 - v1 error format |
| 136 | 2 - v2 error format |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 137 | |
| 138 | Returns: |
| 139 | An object of the form: |
| 140 | |
| 141 | { # A topic resource. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 142 | "name": "A String", # The name of the topic. It must have the format |
| 143 | # `"projects/{project}/topics/{topic}"`. `{topic}` must start with a letter, |
| 144 | # and contain only letters (`[A-Za-z]`), numbers (`[0-9]`), dashes (`-`), |
| 145 | # underscores (`_`), periods (`.`), tildes (`~`), plus (`+`) or percent |
| 146 | # signs (`%`). It must be between 3 and 255 characters in length, and it |
| 147 | # must not start with `"goog"`. |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 148 | }</pre> |
| 149 | </div> |
| 150 | |
| 151 | <div class="method"> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 152 | <code class="details" id="delete">delete(topic=None, x__xgafv=None)</code> |
| 153 | <pre>Deletes the topic with the given name. Returns `NOT_FOUND` if the topic |
| 154 | does not exist. After a topic is deleted, a new topic may be created with |
| 155 | the same name; this is an entirely new topic with none of the old |
| 156 | configuration or subscriptions. Existing subscriptions to this topic are |
| 157 | not deleted, but their `topic` field is set to `_deleted-topic_`. |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 158 | |
| 159 | Args: |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 160 | topic: string, Name of the topic to delete. |
| 161 | Format is `projects/{project}/topics/{topic}`. (required) |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 162 | x__xgafv: string, V1 error format. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 163 | Allowed values |
| 164 | 1 - v1 error format |
| 165 | 2 - v2 error format |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 166 | |
| 167 | Returns: |
| 168 | An object of the form: |
| 169 | |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 170 | { # A generic empty message that you can re-use to avoid defining duplicated |
| 171 | # empty messages in your APIs. A typical example is to use it as the request |
| 172 | # or the response type of an API method. For instance: |
| 173 | # |
| 174 | # service Foo { |
| 175 | # rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); |
| 176 | # } |
| 177 | # |
| 178 | # The JSON representation for `Empty` is empty JSON object `{}`. |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 179 | }</pre> |
| 180 | </div> |
| 181 | |
| 182 | <div class="method"> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 183 | <code class="details" id="get">get(topic=None, x__xgafv=None)</code> |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 184 | <pre>Gets the configuration of a topic. |
| 185 | |
| 186 | Args: |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 187 | topic: string, The name of the topic to get. |
| 188 | Format is `projects/{project}/topics/{topic}`. (required) |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 189 | x__xgafv: string, V1 error format. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 190 | Allowed values |
| 191 | 1 - v1 error format |
| 192 | 2 - v2 error format |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 193 | |
| 194 | Returns: |
| 195 | An object of the form: |
| 196 | |
| 197 | { # A topic resource. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 198 | "name": "A String", # The name of the topic. It must have the format |
| 199 | # `"projects/{project}/topics/{topic}"`. `{topic}` must start with a letter, |
| 200 | # and contain only letters (`[A-Za-z]`), numbers (`[0-9]`), dashes (`-`), |
| 201 | # underscores (`_`), periods (`.`), tildes (`~`), plus (`+`) or percent |
| 202 | # signs (`%`). It must be between 3 and 255 characters in length, and it |
| 203 | # must not start with `"goog"`. |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 204 | }</pre> |
| 205 | </div> |
| 206 | |
| 207 | <div class="method"> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 208 | <code class="details" id="getIamPolicy">getIamPolicy(resource=None, x__xgafv=None)</code> |
| 209 | <pre>Gets the access control policy for a resource. |
| 210 | Returns an empty policy if the resource exists and does not have a policy |
| 211 | set. |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 212 | |
| 213 | Args: |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 214 | resource: string, REQUIRED: The resource for which the policy is being requested. |
| 215 | `resource` is usually specified as a path. For example, a Project |
| 216 | resource is specified as `projects/{project}`. (required) |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 217 | x__xgafv: string, V1 error format. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 218 | Allowed values |
| 219 | 1 - v1 error format |
| 220 | 2 - v2 error format |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 221 | |
| 222 | Returns: |
| 223 | An object of the form: |
| 224 | |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 225 | { # Defines an Identity and Access Management (IAM) policy. It is used to |
| 226 | # specify access control policies for Cloud Platform resources. |
| 227 | # |
| 228 | # |
| 229 | # A `Policy` consists of a list of `bindings`. A `Binding` binds a list of |
| 230 | # `members` to a `role`, where the members can be user accounts, Google groups, |
| 231 | # Google domains, and service accounts. A `role` is a named list of permissions |
| 232 | # defined by IAM. |
| 233 | # |
| 234 | # **Example** |
| 235 | # |
| 236 | # { |
| 237 | # "bindings": [ |
| 238 | # { |
| 239 | # "role": "roles/owner", |
| 240 | # "members": [ |
| 241 | # "user:mike@example.com", |
| 242 | # "group:admins@example.com", |
| 243 | # "domain:google.com", |
| 244 | # "serviceAccount:my-other-app@appspot.gserviceaccount.com", |
| 245 | # ] |
| 246 | # }, |
| 247 | # { |
| 248 | # "role": "roles/viewer", |
| 249 | # "members": ["user:sean@example.com"] |
| 250 | # } |
| 251 | # ] |
| 252 | # } |
| 253 | # |
| 254 | # For a description of IAM and its features, see the |
| 255 | # [IAM developer's guide](https://cloud.google.com/iam). |
| 256 | "bindings": [ # Associates a list of `members` to a `role`. |
| 257 | # Multiple `bindings` must not be specified for the same `role`. |
| 258 | # `bindings` with no members will result in an error. |
Jon Wayne Parrott | 36e41bc | 2016-02-19 16:02:29 -0800 | [diff] [blame] | 259 | { # Associates `members` with a `role`. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 260 | "role": "A String", # Role that is assigned to `members`. |
| 261 | # For example, `roles/viewer`, `roles/editor`, or `roles/owner`. |
| 262 | # Required |
| 263 | "members": [ # Specifies the identities requesting access for a Cloud Platform resource. |
| 264 | # `members` can have the following values: |
| 265 | # |
| 266 | # * `allUsers`: A special identifier that represents anyone who is |
| 267 | # on the internet; with or without a Google account. |
| 268 | # |
| 269 | # * `allAuthenticatedUsers`: A special identifier that represents anyone |
| 270 | # who is authenticated with a Google account or a service account. |
| 271 | # |
| 272 | # * `user:{emailid}`: An email address that represents a specific Google |
| 273 | # account. For example, `alice@gmail.com` or `joe@example.com`. |
| 274 | # |
| 275 | # |
| 276 | # * `serviceAccount:{emailid}`: An email address that represents a service |
| 277 | # account. For example, `my-other-app@appspot.gserviceaccount.com`. |
| 278 | # |
| 279 | # * `group:{emailid}`: An email address that represents a Google group. |
| 280 | # For example, `admins@example.com`. |
| 281 | # |
| 282 | # * `domain:{domain}`: A Google Apps domain name that represents all the |
| 283 | # users of that domain. For example, `google.com` or `example.com`. |
| 284 | # |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 285 | "A String", |
| 286 | ], |
| 287 | }, |
| 288 | ], |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 289 | "etag": "A String", # `etag` is used for optimistic concurrency control as a way to help |
| 290 | # prevent simultaneous updates of a policy from overwriting each other. |
| 291 | # It is strongly suggested that systems make use of the `etag` in the |
| 292 | # read-modify-write cycle to perform policy updates in order to avoid race |
| 293 | # conditions: An `etag` is returned in the response to `getIamPolicy`, and |
| 294 | # systems are expected to put that etag in the request to `setIamPolicy` to |
| 295 | # ensure that their change will be applied to the same version of the policy. |
| 296 | # |
| 297 | # If no `etag` is provided in the call to `setIamPolicy`, then the existing |
| 298 | # policy is overwritten blindly. |
Jon Wayne Parrott | 36e41bc | 2016-02-19 16:02:29 -0800 | [diff] [blame] | 299 | "version": 42, # Version of the `Policy`. The default version is 0. |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 300 | }</pre> |
| 301 | </div> |
| 302 | |
| 303 | <div class="method"> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 304 | <code class="details" id="list">list(project=None, pageSize=None, pageToken=None, x__xgafv=None)</code> |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 305 | <pre>Lists matching topics. |
| 306 | |
| 307 | Args: |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 308 | project: string, The name of the cloud project that topics belong to. |
| 309 | Format is `projects/{project}`. (required) |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 310 | pageSize: integer, Maximum number of topics to return. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 311 | pageToken: string, The value returned by the last `ListTopicsResponse`; indicates that this is |
| 312 | a continuation of a prior `ListTopics` call, and that the system should |
| 313 | return the next page of data. |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 314 | x__xgafv: string, V1 error format. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 315 | Allowed values |
| 316 | 1 - v1 error format |
| 317 | 2 - v2 error format |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 318 | |
| 319 | Returns: |
| 320 | An object of the form: |
| 321 | |
Jon Wayne Parrott | 36e41bc | 2016-02-19 16:02:29 -0800 | [diff] [blame] | 322 | { # Response for the `ListTopics` method. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 323 | "nextPageToken": "A String", # If not empty, indicates that there may be more topics that match the |
| 324 | # request; this value should be passed in a new `ListTopicsRequest`. |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 325 | "topics": [ # The resulting topics. |
| 326 | { # A topic resource. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 327 | "name": "A String", # The name of the topic. It must have the format |
| 328 | # `"projects/{project}/topics/{topic}"`. `{topic}` must start with a letter, |
| 329 | # and contain only letters (`[A-Za-z]`), numbers (`[0-9]`), dashes (`-`), |
| 330 | # underscores (`_`), periods (`.`), tildes (`~`), plus (`+`) or percent |
| 331 | # signs (`%`). It must be between 3 and 255 characters in length, and it |
| 332 | # must not start with `"goog"`. |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 333 | }, |
| 334 | ], |
| 335 | }</pre> |
| 336 | </div> |
| 337 | |
| 338 | <div class="method"> |
| 339 | <code class="details" id="list_next">list_next(previous_request, previous_response)</code> |
| 340 | <pre>Retrieves the next page of results. |
| 341 | |
| 342 | Args: |
| 343 | previous_request: The request for the previous page. (required) |
| 344 | previous_response: The response from the request for the previous page. (required) |
| 345 | |
| 346 | Returns: |
| 347 | A request object that you can call 'execute()' on to request the next |
| 348 | page. Returns None if there are no more items in the collection. |
| 349 | </pre> |
| 350 | </div> |
| 351 | |
| 352 | <div class="method"> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 353 | <code class="details" id="publish">publish(topic=None, body, x__xgafv=None)</code> |
| 354 | <pre>Adds one or more messages to the topic. Returns `NOT_FOUND` if the topic |
| 355 | does not exist. The message payload must not be empty; it must contain |
| 356 | either a non-empty data field, or at least one attribute. |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 357 | |
| 358 | Args: |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 359 | topic: string, The messages in the request will be published on this topic. |
| 360 | Format is `projects/{project}/topics/{topic}`. (required) |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 361 | body: object, The request body. (required) |
| 362 | The object takes the form of: |
| 363 | |
| 364 | { # Request for the Publish method. |
| 365 | "messages": [ # The messages to publish. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 366 | { # A message data and its attributes. The message payload must not be empty; |
| 367 | # it must contain either a non-empty data field, or at least one attribute. |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 368 | "attributes": { # Optional attributes for this message. |
| 369 | "a_key": "A String", |
| 370 | }, |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 371 | "data": "A String", # The message payload. |
| 372 | "publishTime": "A String", # The time at which the message was published, populated by the server when |
| 373 | # it receives the `Publish` call. It must not be populated by the |
| 374 | # publisher in a `Publish` call. |
| 375 | "messageId": "A String", # ID of this message, assigned by the server when the message is published. |
| 376 | # Guaranteed to be unique within the topic. This value may be read by a |
| 377 | # subscriber that receives a `PubsubMessage` via a `Pull` call or a push |
| 378 | # delivery. It must not be populated by the publisher in a `Publish` call. |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 379 | }, |
| 380 | ], |
| 381 | } |
| 382 | |
| 383 | x__xgafv: string, V1 error format. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 384 | Allowed values |
| 385 | 1 - v1 error format |
| 386 | 2 - v2 error format |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 387 | |
| 388 | Returns: |
| 389 | An object of the form: |
| 390 | |
Jon Wayne Parrott | 36e41bc | 2016-02-19 16:02:29 -0800 | [diff] [blame] | 391 | { # Response for the `Publish` method. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 392 | "messageIds": [ # The server-assigned ID of each published message, in the same order as |
| 393 | # the messages in the request. IDs are guaranteed to be unique within |
| 394 | # the topic. |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 395 | "A String", |
| 396 | ], |
| 397 | }</pre> |
| 398 | </div> |
| 399 | |
| 400 | <div class="method"> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 401 | <code class="details" id="setIamPolicy">setIamPolicy(resource=None, body, x__xgafv=None)</code> |
| 402 | <pre>Sets the access control policy on the specified resource. Replaces any |
| 403 | existing policy. |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 404 | |
| 405 | Args: |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 406 | resource: string, REQUIRED: The resource for which the policy is being specified. |
| 407 | `resource` is usually specified as a path. For example, a Project |
| 408 | resource is specified as `projects/{project}`. (required) |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 409 | body: object, The request body. (required) |
| 410 | The object takes the form of: |
| 411 | |
| 412 | { # Request message for `SetIamPolicy` method. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 413 | "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 |
| 414 | # the policy is limited to a few 10s of KB. An empty policy is a |
| 415 | # valid policy but certain Cloud Platform services (such as Projects) |
| 416 | # might reject them. |
| 417 | # specify access control policies for Cloud Platform resources. |
| 418 | # |
| 419 | # |
| 420 | # A `Policy` consists of a list of `bindings`. A `Binding` binds a list of |
| 421 | # `members` to a `role`, where the members can be user accounts, Google groups, |
| 422 | # Google domains, and service accounts. A `role` is a named list of permissions |
| 423 | # defined by IAM. |
| 424 | # |
| 425 | # **Example** |
| 426 | # |
| 427 | # { |
| 428 | # "bindings": [ |
| 429 | # { |
| 430 | # "role": "roles/owner", |
| 431 | # "members": [ |
| 432 | # "user:mike@example.com", |
| 433 | # "group:admins@example.com", |
| 434 | # "domain:google.com", |
| 435 | # "serviceAccount:my-other-app@appspot.gserviceaccount.com", |
| 436 | # ] |
| 437 | # }, |
| 438 | # { |
| 439 | # "role": "roles/viewer", |
| 440 | # "members": ["user:sean@example.com"] |
| 441 | # } |
| 442 | # ] |
| 443 | # } |
| 444 | # |
| 445 | # For a description of IAM and its features, see the |
| 446 | # [IAM developer's guide](https://cloud.google.com/iam). |
| 447 | "bindings": [ # Associates a list of `members` to a `role`. |
| 448 | # Multiple `bindings` must not be specified for the same `role`. |
| 449 | # `bindings` with no members will result in an error. |
Jon Wayne Parrott | 36e41bc | 2016-02-19 16:02:29 -0800 | [diff] [blame] | 450 | { # Associates `members` with a `role`. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 451 | "role": "A String", # Role that is assigned to `members`. |
| 452 | # For example, `roles/viewer`, `roles/editor`, or `roles/owner`. |
| 453 | # Required |
| 454 | "members": [ # Specifies the identities requesting access for a Cloud Platform resource. |
| 455 | # `members` can have the following values: |
| 456 | # |
| 457 | # * `allUsers`: A special identifier that represents anyone who is |
| 458 | # on the internet; with or without a Google account. |
| 459 | # |
| 460 | # * `allAuthenticatedUsers`: A special identifier that represents anyone |
| 461 | # who is authenticated with a Google account or a service account. |
| 462 | # |
| 463 | # * `user:{emailid}`: An email address that represents a specific Google |
| 464 | # account. For example, `alice@gmail.com` or `joe@example.com`. |
| 465 | # |
| 466 | # |
| 467 | # * `serviceAccount:{emailid}`: An email address that represents a service |
| 468 | # account. For example, `my-other-app@appspot.gserviceaccount.com`. |
| 469 | # |
| 470 | # * `group:{emailid}`: An email address that represents a Google group. |
| 471 | # For example, `admins@example.com`. |
| 472 | # |
| 473 | # * `domain:{domain}`: A Google Apps domain name that represents all the |
| 474 | # users of that domain. For example, `google.com` or `example.com`. |
| 475 | # |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 476 | "A String", |
| 477 | ], |
| 478 | }, |
| 479 | ], |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 480 | "etag": "A String", # `etag` is used for optimistic concurrency control as a way to help |
| 481 | # prevent simultaneous updates of a policy from overwriting each other. |
| 482 | # It is strongly suggested that systems make use of the `etag` in the |
| 483 | # read-modify-write cycle to perform policy updates in order to avoid race |
| 484 | # conditions: An `etag` is returned in the response to `getIamPolicy`, and |
| 485 | # systems are expected to put that etag in the request to `setIamPolicy` to |
| 486 | # ensure that their change will be applied to the same version of the policy. |
| 487 | # |
| 488 | # If no `etag` is provided in the call to `setIamPolicy`, then the existing |
| 489 | # policy is overwritten blindly. |
Jon Wayne Parrott | 36e41bc | 2016-02-19 16:02:29 -0800 | [diff] [blame] | 490 | "version": 42, # Version of the `Policy`. The default version is 0. |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 491 | }, |
| 492 | } |
| 493 | |
| 494 | x__xgafv: string, V1 error format. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 495 | Allowed values |
| 496 | 1 - v1 error format |
| 497 | 2 - v2 error format |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 498 | |
| 499 | Returns: |
| 500 | An object of the form: |
| 501 | |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 502 | { # Defines an Identity and Access Management (IAM) policy. It is used to |
| 503 | # specify access control policies for Cloud Platform resources. |
| 504 | # |
| 505 | # |
| 506 | # A `Policy` consists of a list of `bindings`. A `Binding` binds a list of |
| 507 | # `members` to a `role`, where the members can be user accounts, Google groups, |
| 508 | # Google domains, and service accounts. A `role` is a named list of permissions |
| 509 | # defined by IAM. |
| 510 | # |
| 511 | # **Example** |
| 512 | # |
| 513 | # { |
| 514 | # "bindings": [ |
| 515 | # { |
| 516 | # "role": "roles/owner", |
| 517 | # "members": [ |
| 518 | # "user:mike@example.com", |
| 519 | # "group:admins@example.com", |
| 520 | # "domain:google.com", |
| 521 | # "serviceAccount:my-other-app@appspot.gserviceaccount.com", |
| 522 | # ] |
| 523 | # }, |
| 524 | # { |
| 525 | # "role": "roles/viewer", |
| 526 | # "members": ["user:sean@example.com"] |
| 527 | # } |
| 528 | # ] |
| 529 | # } |
| 530 | # |
| 531 | # For a description of IAM and its features, see the |
| 532 | # [IAM developer's guide](https://cloud.google.com/iam). |
| 533 | "bindings": [ # Associates a list of `members` to a `role`. |
| 534 | # Multiple `bindings` must not be specified for the same `role`. |
| 535 | # `bindings` with no members will result in an error. |
Jon Wayne Parrott | 36e41bc | 2016-02-19 16:02:29 -0800 | [diff] [blame] | 536 | { # Associates `members` with a `role`. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 537 | "role": "A String", # Role that is assigned to `members`. |
| 538 | # For example, `roles/viewer`, `roles/editor`, or `roles/owner`. |
| 539 | # Required |
| 540 | "members": [ # Specifies the identities requesting access for a Cloud Platform resource. |
| 541 | # `members` can have the following values: |
| 542 | # |
| 543 | # * `allUsers`: A special identifier that represents anyone who is |
| 544 | # on the internet; with or without a Google account. |
| 545 | # |
| 546 | # * `allAuthenticatedUsers`: A special identifier that represents anyone |
| 547 | # who is authenticated with a Google account or a service account. |
| 548 | # |
| 549 | # * `user:{emailid}`: An email address that represents a specific Google |
| 550 | # account. For example, `alice@gmail.com` or `joe@example.com`. |
| 551 | # |
| 552 | # |
| 553 | # * `serviceAccount:{emailid}`: An email address that represents a service |
| 554 | # account. For example, `my-other-app@appspot.gserviceaccount.com`. |
| 555 | # |
| 556 | # * `group:{emailid}`: An email address that represents a Google group. |
| 557 | # For example, `admins@example.com`. |
| 558 | # |
| 559 | # * `domain:{domain}`: A Google Apps domain name that represents all the |
| 560 | # users of that domain. For example, `google.com` or `example.com`. |
| 561 | # |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 562 | "A String", |
| 563 | ], |
| 564 | }, |
| 565 | ], |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 566 | "etag": "A String", # `etag` is used for optimistic concurrency control as a way to help |
| 567 | # prevent simultaneous updates of a policy from overwriting each other. |
| 568 | # It is strongly suggested that systems make use of the `etag` in the |
| 569 | # read-modify-write cycle to perform policy updates in order to avoid race |
| 570 | # conditions: An `etag` is returned in the response to `getIamPolicy`, and |
| 571 | # systems are expected to put that etag in the request to `setIamPolicy` to |
| 572 | # ensure that their change will be applied to the same version of the policy. |
| 573 | # |
| 574 | # If no `etag` is provided in the call to `setIamPolicy`, then the existing |
| 575 | # policy is overwritten blindly. |
Jon Wayne Parrott | 36e41bc | 2016-02-19 16:02:29 -0800 | [diff] [blame] | 576 | "version": 42, # Version of the `Policy`. The default version is 0. |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 577 | }</pre> |
| 578 | </div> |
| 579 | |
| 580 | <div class="method"> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 581 | <code class="details" id="testIamPermissions">testIamPermissions(resource=None, body, x__xgafv=None)</code> |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 582 | <pre>Returns permissions that a caller has on the specified resource. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 583 | If the resource does not exist, this will return an empty set of |
| 584 | permissions, not a NOT_FOUND error. |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 585 | |
| 586 | Args: |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 587 | resource: string, REQUIRED: The resource for which the policy detail is being requested. |
| 588 | `resource` is usually specified as a path. For example, a Project |
| 589 | resource is specified as `projects/{project}`. (required) |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 590 | body: object, The request body. (required) |
| 591 | The object takes the form of: |
| 592 | |
| 593 | { # Request message for `TestIamPermissions` method. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 594 | "permissions": [ # The set of permissions to check for the `resource`. Permissions with |
| 595 | # wildcards (such as '*' or 'storage.*') are not allowed. For more |
| 596 | # information see |
| 597 | # [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 598 | "A String", |
| 599 | ], |
| 600 | } |
| 601 | |
| 602 | x__xgafv: string, V1 error format. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 603 | Allowed values |
| 604 | 1 - v1 error format |
| 605 | 2 - v2 error format |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 606 | |
| 607 | Returns: |
| 608 | An object of the form: |
| 609 | |
| 610 | { # Response message for `TestIamPermissions` method. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 611 | "permissions": [ # A subset of `TestPermissionsRequest.permissions` that the caller is |
| 612 | # allowed. |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 613 | "A String", |
| 614 | ], |
| 615 | }</pre> |
| 616 | </div> |
| 617 | |
| 618 | </body></html> |