Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [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="cloudresourcemanager_v1beta1.html">Cloud Resource Manager API</a> . <a href="cloudresourcemanager_v1beta1.projects.html">projects</a></h1> |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 76 | <h2>Instance Methods</h2> |
| 77 | <p class="toc_element"> |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 78 | <code><a href="#create">create(body=None, useLegacyStack=None, x__xgafv=None)</a></code></p> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 79 | <p class="firstline">Creates a Project resource.</p> |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 80 | <p class="toc_element"> |
Thomas Coffee | 2f24537 | 2017-03-27 10:39:26 -0700 | [diff] [blame] | 81 | <code><a href="#delete">delete(projectId, x__xgafv=None)</a></code></p> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 82 | <p class="firstline">Marks the Project identified by the specified</p> |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 83 | <p class="toc_element"> |
Thomas Coffee | 2f24537 | 2017-03-27 10:39:26 -0700 | [diff] [blame] | 84 | <code><a href="#get">get(projectId, x__xgafv=None)</a></code></p> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 85 | <p class="firstline">Retrieves the Project identified by the specified</p> |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 86 | <p class="toc_element"> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 87 | <code><a href="#getAncestry">getAncestry(projectId, body=None, x__xgafv=None)</a></code></p> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 88 | <p class="firstline">Gets a list of ancestors in the resource hierarchy for the Project</p> |
Sai Cheemalapati | df61397 | 2016-10-21 13:59:49 -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="#getIamPolicy">getIamPolicy(resource, body=None, x__xgafv=None)</a></code></p> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 91 | <p class="firstline">Returns the IAM access control policy for the specified Project.</p> |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 92 | <p class="toc_element"> |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 93 | <code><a href="#list">list(filter=None, pageToken=None, pageSize=None, x__xgafv=None)</a></code></p> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 94 | <p class="firstline">Lists Projects that the caller has the `resourcemanager.projects.get`</p> |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 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"> |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 99 | <code><a href="#setIamPolicy">setIamPolicy(resource, body=None, x__xgafv=None)</a></code></p> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 100 | <p class="firstline">Sets the IAM access control policy for the specified Project. Overwrites</p> |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 101 | <p class="toc_element"> |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 102 | <code><a href="#testIamPermissions">testIamPermissions(resource, body=None, x__xgafv=None)</a></code></p> |
Jon Wayne Parrott | 36e41bc | 2016-02-19 16:02:29 -0800 | [diff] [blame] | 103 | <p class="firstline">Returns permissions that a caller has on the specified Project.</p> |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 104 | <p class="toc_element"> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 105 | <code><a href="#undelete">undelete(projectId, body=None, x__xgafv=None)</a></code></p> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 106 | <p class="firstline">Restores the Project identified by the specified</p> |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 107 | <p class="toc_element"> |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 108 | <code><a href="#update">update(projectId, body=None, x__xgafv=None)</a></code></p> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 109 | <p class="firstline">Updates the attributes of the Project identified by the specified</p> |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 110 | <h3>Method Details</h3> |
| 111 | <div class="method"> |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 112 | <code class="details" id="create">create(body=None, useLegacyStack=None, x__xgafv=None)</code> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 113 | <pre>Creates a Project resource. |
| 114 | |
| 115 | Initially, the Project resource is owned by its creator exclusively. |
| 116 | The creator can later grant permission to others to read or update the |
| 117 | Project. |
| 118 | |
| 119 | Several APIs are activated automatically for the Project, including |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 120 | Google Cloud Storage. The parent is identified by a specified |
| 121 | ResourceId, which must include both an ID and a type, such as |
| 122 | project, folder, or organization. |
| 123 | |
| 124 | This method does not associate the new project with a billing account. |
| 125 | You can set or update the billing account associated with a project using |
| 126 | the [`projects.updateBillingInfo`] |
| 127 | (/billing/reference/rest/v1/projects/updateBillingInfo) method. |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 128 | |
| 129 | Args: |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 130 | body: object, The request body. |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 131 | The object takes the form of: |
| 132 | |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 133 | { # A Project is a high-level Google Cloud Platform entity. It is a |
Sai Cheemalapati | c30d2b5 | 2017-03-13 12:12:03 -0400 | [diff] [blame] | 134 | # container for ACLs, APIs, App Engine Apps, VMs, and other |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 135 | # Google Cloud Platform resources. |
Bu Sun Kim | 4ed7d3f | 2020-05-27 12:20:54 -0700 | [diff] [blame] | 136 | "name": "A String", # The optional user-assigned display name of the Project. |
| 137 | # When present it must be between 4 to 30 characters. |
| 138 | # Allowed characters are: lowercase and uppercase letters, numbers, |
| 139 | # hyphen, single-quote, double-quote, space, and exclamation point. |
| 140 | # |
| 141 | # Example: <code>My Project</code> |
| 142 | # Read-write. |
| 143 | "projectId": "A String", # The unique, user-assigned ID of the Project. |
| 144 | # It must be 6 to 30 lowercase letters, digits, or hyphens. |
| 145 | # It must start with a letter. |
| 146 | # Trailing hyphens are prohibited. |
| 147 | # |
| 148 | # Example: <code>tokyo-rain-123</code> |
| 149 | # Read-only after creation. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 150 | "lifecycleState": "A String", # The Project lifecycle state. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 151 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 152 | # Read-only. |
| 153 | "projectNumber": "A String", # The number uniquely identifying the project. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 154 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 155 | # Example: <code>415104041262</code> |
| 156 | # Read-only. |
| 157 | "parent": { # A container to reference an id for any resource type. A `resource` in Google # An optional reference to a parent Resource. |
| 158 | # |
| 159 | # Supported parent types include "organization" and "folder". Once set, the |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 160 | # parent cannot be cleared. The `parent` can be set on creation or using the |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 161 | # `UpdateProject` method; the end user must have the |
| 162 | # `resourcemanager.projects.create` permission on the parent. |
| 163 | # |
| 164 | # Read-write. |
| 165 | # Cloud Platform is a generic term for something you (a developer) may want to |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 166 | # interact with through one of our API's. Some examples are an App Engine app, |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 167 | # a Compute Engine instance, a Cloud SQL database, and so on. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 168 | "type": "A String", # Required field representing the resource type this id is for. |
| 169 | # At present, the valid types are "project", "folder", and "organization". |
| 170 | "id": "A String", # Required field for the type-specific id. This should correspond to the id |
| 171 | # used in the type-specific API's. |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 172 | }, |
Bu Sun Kim | 4ed7d3f | 2020-05-27 12:20:54 -0700 | [diff] [blame] | 173 | "createTime": "A String", # Creation time. |
| 174 | # |
| 175 | # Read-only. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 176 | "labels": { # The labels associated with this Project. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 177 | # |
| 178 | # Label keys must be between 1 and 63 characters long and must conform |
| 179 | # to the following regular expression: \[a-z\](\[-a-z0-9\]*\[a-z0-9\])?. |
| 180 | # |
| 181 | # Label values must be between 0 and 63 characters long and must conform |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 182 | # to the regular expression (\[a-z\](\[-a-z0-9\]*\[a-z0-9\])?)?. A label |
| 183 | # value can be empty. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 184 | # |
| 185 | # No more than 256 labels can be associated with a given resource. |
| 186 | # |
| 187 | # Clients should store labels in a representation such as JSON that does not |
| 188 | # depend on specific characters being disallowed. |
| 189 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 190 | # Example: <code>"environment" : "dev"</code> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 191 | # Read-write. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 192 | "a_key": "A String", |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 193 | }, |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 194 | } |
| 195 | |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 196 | useLegacyStack: boolean, A now unused experiment opt-out option. |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 197 | x__xgafv: string, V1 error format. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 198 | Allowed values |
| 199 | 1 - v1 error format |
| 200 | 2 - v2 error format |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 201 | |
| 202 | Returns: |
| 203 | An object of the form: |
| 204 | |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 205 | { # A Project is a high-level Google Cloud Platform entity. It is a |
Sai Cheemalapati | c30d2b5 | 2017-03-13 12:12:03 -0400 | [diff] [blame] | 206 | # container for ACLs, APIs, App Engine Apps, VMs, and other |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 207 | # Google Cloud Platform resources. |
Bu Sun Kim | 4ed7d3f | 2020-05-27 12:20:54 -0700 | [diff] [blame] | 208 | "name": "A String", # The optional user-assigned display name of the Project. |
| 209 | # When present it must be between 4 to 30 characters. |
| 210 | # Allowed characters are: lowercase and uppercase letters, numbers, |
| 211 | # hyphen, single-quote, double-quote, space, and exclamation point. |
| 212 | # |
| 213 | # Example: <code>My Project</code> |
| 214 | # Read-write. |
| 215 | "projectId": "A String", # The unique, user-assigned ID of the Project. |
| 216 | # It must be 6 to 30 lowercase letters, digits, or hyphens. |
| 217 | # It must start with a letter. |
| 218 | # Trailing hyphens are prohibited. |
| 219 | # |
| 220 | # Example: <code>tokyo-rain-123</code> |
| 221 | # Read-only after creation. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 222 | "lifecycleState": "A String", # The Project lifecycle state. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 223 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 224 | # Read-only. |
| 225 | "projectNumber": "A String", # The number uniquely identifying the project. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 226 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 227 | # Example: <code>415104041262</code> |
| 228 | # Read-only. |
| 229 | "parent": { # A container to reference an id for any resource type. A `resource` in Google # An optional reference to a parent Resource. |
| 230 | # |
| 231 | # Supported parent types include "organization" and "folder". Once set, the |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 232 | # parent cannot be cleared. The `parent` can be set on creation or using the |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 233 | # `UpdateProject` method; the end user must have the |
| 234 | # `resourcemanager.projects.create` permission on the parent. |
| 235 | # |
| 236 | # Read-write. |
| 237 | # Cloud Platform is a generic term for something you (a developer) may want to |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 238 | # interact with through one of our API's. Some examples are an App Engine app, |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 239 | # a Compute Engine instance, a Cloud SQL database, and so on. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 240 | "type": "A String", # Required field representing the resource type this id is for. |
| 241 | # At present, the valid types are "project", "folder", and "organization". |
| 242 | "id": "A String", # Required field for the type-specific id. This should correspond to the id |
| 243 | # used in the type-specific API's. |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 244 | }, |
Bu Sun Kim | 4ed7d3f | 2020-05-27 12:20:54 -0700 | [diff] [blame] | 245 | "createTime": "A String", # Creation time. |
| 246 | # |
| 247 | # Read-only. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 248 | "labels": { # The labels associated with this Project. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 249 | # |
| 250 | # Label keys must be between 1 and 63 characters long and must conform |
| 251 | # to the following regular expression: \[a-z\](\[-a-z0-9\]*\[a-z0-9\])?. |
| 252 | # |
| 253 | # Label values must be between 0 and 63 characters long and must conform |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 254 | # to the regular expression (\[a-z\](\[-a-z0-9\]*\[a-z0-9\])?)?. A label |
| 255 | # value can be empty. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 256 | # |
| 257 | # No more than 256 labels can be associated with a given resource. |
| 258 | # |
| 259 | # Clients should store labels in a representation such as JSON that does not |
| 260 | # depend on specific characters being disallowed. |
| 261 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 262 | # Example: <code>"environment" : "dev"</code> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 263 | # Read-write. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 264 | "a_key": "A String", |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 265 | }, |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 266 | }</pre> |
| 267 | </div> |
| 268 | |
| 269 | <div class="method"> |
Thomas Coffee | 2f24537 | 2017-03-27 10:39:26 -0700 | [diff] [blame] | 270 | <code class="details" id="delete">delete(projectId, x__xgafv=None)</code> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 271 | <pre>Marks the Project identified by the specified |
| 272 | `project_id` (for example, `my-project-123`) for deletion. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 273 | This method will only affect the Project if it has a lifecycle state of |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 274 | ACTIVE. |
| 275 | |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 276 | This method changes the Project's lifecycle state from |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 277 | ACTIVE |
| 278 | to DELETE_REQUESTED. |
| 279 | The deletion starts at an unspecified time, at which point the project is |
| 280 | no longer accessible. |
| 281 | |
| 282 | Until the deletion completes, you can check the lifecycle state |
| 283 | checked by retrieving the Project with GetProject, |
| 284 | and the Project remains visible to ListProjects. |
| 285 | However, you cannot update the project. |
| 286 | |
| 287 | After the deletion completes, the Project is not retrievable by |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 288 | the GetProject |
| 289 | and ListProjects |
| 290 | methods. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 291 | |
| 292 | The caller must have modify permissions for this Project. |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 293 | |
| 294 | Args: |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 295 | projectId: string, The Project ID (for example, `foo-bar-123`). |
| 296 | |
| 297 | Required. (required) |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 298 | x__xgafv: string, V1 error format. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 299 | Allowed values |
| 300 | 1 - v1 error format |
| 301 | 2 - v2 error format |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 302 | |
| 303 | Returns: |
| 304 | An object of the form: |
| 305 | |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 306 | { # A generic empty message that you can re-use to avoid defining duplicated |
| 307 | # empty messages in your APIs. A typical example is to use it as the request |
| 308 | # or the response type of an API method. For instance: |
| 309 | # |
| 310 | # service Foo { |
| 311 | # rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); |
| 312 | # } |
| 313 | # |
| 314 | # The JSON representation for `Empty` is empty JSON object `{}`. |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 315 | }</pre> |
| 316 | </div> |
| 317 | |
| 318 | <div class="method"> |
Thomas Coffee | 2f24537 | 2017-03-27 10:39:26 -0700 | [diff] [blame] | 319 | <code class="details" id="get">get(projectId, x__xgafv=None)</code> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 320 | <pre>Retrieves the Project identified by the specified |
| 321 | `project_id` (for example, `my-project-123`). |
| 322 | |
| 323 | The caller must have read permissions for this Project. |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 324 | |
| 325 | Args: |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 326 | projectId: string, The Project ID (for example, `my-project-123`). |
| 327 | |
| 328 | Required. (required) |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 329 | x__xgafv: string, V1 error format. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 330 | Allowed values |
| 331 | 1 - v1 error format |
| 332 | 2 - v2 error format |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 333 | |
| 334 | Returns: |
| 335 | An object of the form: |
| 336 | |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 337 | { # A Project is a high-level Google Cloud Platform entity. It is a |
Sai Cheemalapati | c30d2b5 | 2017-03-13 12:12:03 -0400 | [diff] [blame] | 338 | # container for ACLs, APIs, App Engine Apps, VMs, and other |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 339 | # Google Cloud Platform resources. |
Bu Sun Kim | 4ed7d3f | 2020-05-27 12:20:54 -0700 | [diff] [blame] | 340 | "name": "A String", # The optional user-assigned display name of the Project. |
| 341 | # When present it must be between 4 to 30 characters. |
| 342 | # Allowed characters are: lowercase and uppercase letters, numbers, |
| 343 | # hyphen, single-quote, double-quote, space, and exclamation point. |
| 344 | # |
| 345 | # Example: <code>My Project</code> |
| 346 | # Read-write. |
| 347 | "projectId": "A String", # The unique, user-assigned ID of the Project. |
| 348 | # It must be 6 to 30 lowercase letters, digits, or hyphens. |
| 349 | # It must start with a letter. |
| 350 | # Trailing hyphens are prohibited. |
| 351 | # |
| 352 | # Example: <code>tokyo-rain-123</code> |
| 353 | # Read-only after creation. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 354 | "lifecycleState": "A String", # The Project lifecycle state. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 355 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 356 | # Read-only. |
| 357 | "projectNumber": "A String", # The number uniquely identifying the project. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 358 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 359 | # Example: <code>415104041262</code> |
| 360 | # Read-only. |
| 361 | "parent": { # A container to reference an id for any resource type. A `resource` in Google # An optional reference to a parent Resource. |
| 362 | # |
| 363 | # Supported parent types include "organization" and "folder". Once set, the |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 364 | # parent cannot be cleared. The `parent` can be set on creation or using the |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 365 | # `UpdateProject` method; the end user must have the |
| 366 | # `resourcemanager.projects.create` permission on the parent. |
| 367 | # |
| 368 | # Read-write. |
| 369 | # Cloud Platform is a generic term for something you (a developer) may want to |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 370 | # interact with through one of our API's. Some examples are an App Engine app, |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 371 | # a Compute Engine instance, a Cloud SQL database, and so on. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 372 | "type": "A String", # Required field representing the resource type this id is for. |
| 373 | # At present, the valid types are "project", "folder", and "organization". |
| 374 | "id": "A String", # Required field for the type-specific id. This should correspond to the id |
| 375 | # used in the type-specific API's. |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 376 | }, |
Bu Sun Kim | 4ed7d3f | 2020-05-27 12:20:54 -0700 | [diff] [blame] | 377 | "createTime": "A String", # Creation time. |
| 378 | # |
| 379 | # Read-only. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 380 | "labels": { # The labels associated with this Project. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 381 | # |
| 382 | # Label keys must be between 1 and 63 characters long and must conform |
| 383 | # to the following regular expression: \[a-z\](\[-a-z0-9\]*\[a-z0-9\])?. |
| 384 | # |
| 385 | # Label values must be between 0 and 63 characters long and must conform |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 386 | # to the regular expression (\[a-z\](\[-a-z0-9\]*\[a-z0-9\])?)?. A label |
| 387 | # value can be empty. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 388 | # |
| 389 | # No more than 256 labels can be associated with a given resource. |
| 390 | # |
| 391 | # Clients should store labels in a representation such as JSON that does not |
| 392 | # depend on specific characters being disallowed. |
| 393 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 394 | # Example: <code>"environment" : "dev"</code> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 395 | # Read-write. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 396 | "a_key": "A String", |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 397 | }, |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 398 | }</pre> |
| 399 | </div> |
| 400 | |
| 401 | <div class="method"> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 402 | <code class="details" id="getAncestry">getAncestry(projectId, body=None, x__xgafv=None)</code> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 403 | <pre>Gets a list of ancestors in the resource hierarchy for the Project |
| 404 | identified by the specified `project_id` (for example, `my-project-123`). |
| 405 | |
| 406 | The caller must have read permissions for this Project. |
Sai Cheemalapati | df61397 | 2016-10-21 13:59:49 -0700 | [diff] [blame] | 407 | |
| 408 | Args: |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 409 | projectId: string, The Project ID (for example, `my-project-123`). |
| 410 | |
| 411 | Required. (required) |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 412 | body: object, The request body. |
Sai Cheemalapati | df61397 | 2016-10-21 13:59:49 -0700 | [diff] [blame] | 413 | The object takes the form of: |
| 414 | |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 415 | { # The request sent to the |
| 416 | # GetAncestry |
| 417 | # method. |
Sai Cheemalapati | df61397 | 2016-10-21 13:59:49 -0700 | [diff] [blame] | 418 | } |
| 419 | |
| 420 | x__xgafv: string, V1 error format. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 421 | Allowed values |
| 422 | 1 - v1 error format |
| 423 | 2 - v2 error format |
Sai Cheemalapati | df61397 | 2016-10-21 13:59:49 -0700 | [diff] [blame] | 424 | |
| 425 | Returns: |
| 426 | An object of the form: |
| 427 | |
| 428 | { # Response from the GetAncestry method. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 429 | "ancestor": [ # Ancestors are ordered from bottom to top of the resource hierarchy. The |
| 430 | # first ancestor is the project itself, followed by the project's parent, |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 431 | # etc. |
Sai Cheemalapati | df61397 | 2016-10-21 13:59:49 -0700 | [diff] [blame] | 432 | { # Identifying information for a single ancestor of a project. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 433 | "resourceId": { # A container to reference an id for any resource type. A `resource` in Google # Resource id of the ancestor. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 434 | # Cloud Platform is a generic term for something you (a developer) may want to |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 435 | # interact with through one of our API's. Some examples are an App Engine app, |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 436 | # a Compute Engine instance, a Cloud SQL database, and so on. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 437 | "type": "A String", # Required field representing the resource type this id is for. |
| 438 | # At present, the valid types are "project", "folder", and "organization". |
| 439 | "id": "A String", # Required field for the type-specific id. This should correspond to the id |
| 440 | # used in the type-specific API's. |
Sai Cheemalapati | df61397 | 2016-10-21 13:59:49 -0700 | [diff] [blame] | 441 | }, |
| 442 | }, |
| 443 | ], |
| 444 | }</pre> |
| 445 | </div> |
| 446 | |
| 447 | <div class="method"> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 448 | <code class="details" id="getIamPolicy">getIamPolicy(resource, body=None, x__xgafv=None)</code> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 449 | <pre>Returns the IAM access control policy for the specified Project. |
| 450 | Permission is denied if the policy or the resource does not exist. |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 451 | |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 452 | For additional information about resource structure and identification, |
| 453 | see [Resource Names](/apis/design/resource_names). |
| 454 | |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 455 | Args: |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 456 | resource: string, REQUIRED: The resource for which the policy is being requested. |
Sai Cheemalapati | c30d2b5 | 2017-03-13 12:12:03 -0400 | [diff] [blame] | 457 | See the operation documentation for the appropriate value for this field. (required) |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 458 | body: object, The request body. |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 459 | The object takes the form of: |
| 460 | |
| 461 | { # Request message for `GetIamPolicy` method. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 462 | "options": { # Encapsulates settings provided to GetIamPolicy. # OPTIONAL: A `GetPolicyOptions` object for specifying options to |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 463 | # `GetIamPolicy`. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 464 | "requestedPolicyVersion": 42, # Optional. The policy format version to be returned. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 465 | # |
| 466 | # Valid values are 0, 1, and 3. Requests specifying an invalid value will be |
| 467 | # rejected. |
| 468 | # |
| 469 | # Requests for policies with any conditional bindings must specify version 3. |
| 470 | # Policies without any conditional bindings may specify any valid value or |
| 471 | # leave the field unset. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 472 | # |
| 473 | # To learn which resources support conditions in their IAM policies, see the |
| 474 | # [IAM |
| 475 | # documentation](https://cloud.google.com/iam/help/conditions/resource-policies). |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 476 | }, |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 477 | } |
| 478 | |
| 479 | x__xgafv: string, V1 error format. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 480 | Allowed values |
| 481 | 1 - v1 error format |
| 482 | 2 - v2 error format |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 483 | |
| 484 | Returns: |
| 485 | An object of the form: |
| 486 | |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 487 | { # An Identity and Access Management (IAM) policy, which specifies access |
| 488 | # controls for Google Cloud resources. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 489 | # |
| 490 | # |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 491 | # A `Policy` is a collection of `bindings`. A `binding` binds one or more |
| 492 | # `members` to a single `role`. Members can be user accounts, service accounts, |
| 493 | # Google groups, and domains (such as G Suite). A `role` is a named list of |
| 494 | # permissions; each `role` can be an IAM predefined role or a user-created |
| 495 | # custom role. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 496 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 497 | # For some types of Google Cloud resources, a `binding` can also specify a |
| 498 | # `condition`, which is a logical expression that allows access to a resource |
| 499 | # only if the expression evaluates to `true`. A condition can add constraints |
| 500 | # based on attributes of the request, the resource, or both. To learn which |
| 501 | # resources support conditions in their IAM policies, see the |
| 502 | # [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies). |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 503 | # |
| 504 | # **JSON example:** |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 505 | # |
| 506 | # { |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 507 | # "bindings": [ |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 508 | # { |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 509 | # "role": "roles/resourcemanager.organizationAdmin", |
| 510 | # "members": [ |
| 511 | # "user:mike@example.com", |
| 512 | # "group:admins@example.com", |
| 513 | # "domain:google.com", |
| 514 | # "serviceAccount:my-project-id@appspot.gserviceaccount.com" |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 515 | # ] |
| 516 | # }, |
| 517 | # { |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 518 | # "role": "roles/resourcemanager.organizationViewer", |
| 519 | # "members": [ |
| 520 | # "user:eve@example.com" |
| 521 | # ], |
| 522 | # "condition": { |
| 523 | # "title": "expirable access", |
| 524 | # "description": "Does not grant access after Sep 2020", |
| 525 | # "expression": "request.time < timestamp('2020-10-01T00:00:00.000Z')", |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 526 | # } |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 527 | # } |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 528 | # ], |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 529 | # "etag": "BwWWja0YfJA=", |
| 530 | # "version": 3 |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 531 | # } |
| 532 | # |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 533 | # **YAML example:** |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 534 | # |
| 535 | # bindings: |
| 536 | # - members: |
| 537 | # - user:mike@example.com |
| 538 | # - group:admins@example.com |
| 539 | # - domain:google.com |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 540 | # - serviceAccount:my-project-id@appspot.gserviceaccount.com |
| 541 | # role: roles/resourcemanager.organizationAdmin |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 542 | # - members: |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 543 | # - user:eve@example.com |
| 544 | # role: roles/resourcemanager.organizationViewer |
| 545 | # condition: |
| 546 | # title: expirable access |
| 547 | # description: Does not grant access after Sep 2020 |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 548 | # expression: request.time < timestamp('2020-10-01T00:00:00.000Z') |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 549 | # - etag: BwWWja0YfJA= |
| 550 | # - version: 3 |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 551 | # |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 552 | # For a description of IAM and its features, see the |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 553 | # [IAM documentation](https://cloud.google.com/iam/docs/). |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 554 | "bindings": [ # Associates a list of `members` to a `role`. Optionally, may specify a |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 555 | # `condition` that determines how and when the `bindings` are applied. Each |
| 556 | # of the `bindings` must contain at least one member. |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 557 | { # Associates `members` with a `role`. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 558 | "role": "A String", # Role that is assigned to `members`. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 559 | # For example, `roles/viewer`, `roles/editor`, or `roles/owner`. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 560 | "condition": { # Represents a textual expression in the Common Expression Language (CEL) # The condition that is associated with this binding. |
| 561 | # |
| 562 | # If the condition evaluates to `true`, then this binding applies to the |
| 563 | # current request. |
| 564 | # |
| 565 | # If the condition evaluates to `false`, then this binding does not apply to |
| 566 | # the current request. However, a different role binding might grant the same |
| 567 | # role to one or more of the members in this binding. |
| 568 | # |
| 569 | # To learn which resources support conditions in their IAM policies, see the |
| 570 | # [IAM |
| 571 | # documentation](https://cloud.google.com/iam/help/conditions/resource-policies). |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 572 | # syntax. CEL is a C-like expression language. The syntax and semantics of CEL |
| 573 | # are documented at https://github.com/google/cel-spec. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 574 | # |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 575 | # Example (Comparison): |
| 576 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 577 | # title: "Summary size limit" |
| 578 | # description: "Determines if a summary is less than 100 chars" |
| 579 | # expression: "document.summary.size() < 100" |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 580 | # |
| 581 | # Example (Equality): |
| 582 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 583 | # title: "Requestor is owner" |
| 584 | # description: "Determines if requestor is the document owner" |
| 585 | # expression: "document.owner == request.auth.claims.email" |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 586 | # |
| 587 | # Example (Logic): |
| 588 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 589 | # title: "Public documents" |
| 590 | # description: "Determine whether the document should be publicly visible" |
| 591 | # expression: "document.type != 'private' && document.type != 'internal'" |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 592 | # |
| 593 | # Example (Data Manipulation): |
| 594 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 595 | # title: "Notification string" |
| 596 | # description: "Create a notification string with a timestamp." |
| 597 | # expression: "'New message received at ' + string(document.create_time)" |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 598 | # |
| 599 | # The exact variables and functions that may be referenced within an expression |
| 600 | # are determined by the service that evaluates it. See the service |
| 601 | # documentation for additional information. |
Bu Sun Kim | 4ed7d3f | 2020-05-27 12:20:54 -0700 | [diff] [blame] | 602 | "expression": "A String", # Textual representation of an expression in Common Expression Language |
| 603 | # syntax. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 604 | "title": "A String", # Optional. Title for the expression, i.e. a short string describing |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 605 | # its purpose. This can be used e.g. in UIs which allow to enter the |
| 606 | # expression. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 607 | "location": "A String", # Optional. String indicating the location of the expression for error |
| 608 | # reporting, e.g. a file name and a position in the file. |
| 609 | "description": "A String", # Optional. Description of the expression. This is a longer text which |
| 610 | # describes the expression, e.g. when hovered over it in a UI. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 611 | }, |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 612 | "members": [ # Specifies the identities requesting access for a Cloud Platform resource. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 613 | # `members` can have the following values: |
| 614 | # |
| 615 | # * `allUsers`: A special identifier that represents anyone who is |
| 616 | # on the internet; with or without a Google account. |
| 617 | # |
| 618 | # * `allAuthenticatedUsers`: A special identifier that represents anyone |
| 619 | # who is authenticated with a Google account or a service account. |
| 620 | # |
| 621 | # * `user:{emailid}`: An email address that represents a specific Google |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 622 | # account. For example, `alice@example.com` . |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 623 | # |
| 624 | # |
| 625 | # * `serviceAccount:{emailid}`: An email address that represents a service |
| 626 | # account. For example, `my-other-app@appspot.gserviceaccount.com`. |
| 627 | # |
| 628 | # * `group:{emailid}`: An email address that represents a Google group. |
| 629 | # For example, `admins@example.com`. |
| 630 | # |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 631 | # * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique |
| 632 | # identifier) representing a user that has been recently deleted. For |
| 633 | # example, `alice@example.com?uid=123456789012345678901`. If the user is |
| 634 | # recovered, this value reverts to `user:{emailid}` and the recovered user |
| 635 | # retains the role in the binding. |
| 636 | # |
| 637 | # * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus |
| 638 | # unique identifier) representing a service account that has been recently |
| 639 | # deleted. For example, |
| 640 | # `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`. |
| 641 | # If the service account is undeleted, this value reverts to |
| 642 | # `serviceAccount:{emailid}` and the undeleted service account retains the |
| 643 | # role in the binding. |
| 644 | # |
| 645 | # * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique |
| 646 | # identifier) representing a Google group that has been recently |
| 647 | # deleted. For example, `admins@example.com?uid=123456789012345678901`. If |
| 648 | # the group is recovered, this value reverts to `group:{emailid}` and the |
| 649 | # recovered group retains the role in the binding. |
| 650 | # |
Sai Cheemalapati | 4ba8c23 | 2017-06-06 18:46:08 -0400 | [diff] [blame] | 651 | # |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 652 | # * `domain:{domain}`: The G Suite domain (primary) that represents all the |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 653 | # users of that domain. For example, `google.com` or `example.com`. |
| 654 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 655 | "A String", |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 656 | ], |
| 657 | }, |
| 658 | ], |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 659 | "etag": "A String", # `etag` is used for optimistic concurrency control as a way to help |
Sai Cheemalapati | 4ba8c23 | 2017-06-06 18:46:08 -0400 | [diff] [blame] | 660 | # prevent simultaneous updates of a policy from overwriting each other. |
| 661 | # It is strongly suggested that systems make use of the `etag` in the |
| 662 | # read-modify-write cycle to perform policy updates in order to avoid race |
| 663 | # conditions: An `etag` is returned in the response to `getIamPolicy`, and |
| 664 | # systems are expected to put that etag in the request to `setIamPolicy` to |
| 665 | # ensure that their change will be applied to the same version of the policy. |
| 666 | # |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 667 | # **Important:** If you use IAM Conditions, you must include the `etag` field |
| 668 | # whenever you call `setIamPolicy`. If you omit this field, then IAM allows |
| 669 | # you to overwrite a version `3` policy with a version `1` policy, and all of |
| 670 | # the conditions in the version `3` policy are lost. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 671 | "version": 42, # Specifies the format of the policy. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 672 | # |
| 673 | # Valid values are `0`, `1`, and `3`. Requests that specify an invalid value |
| 674 | # are rejected. |
| 675 | # |
| 676 | # Any operation that affects conditional role bindings must specify version |
| 677 | # `3`. This requirement applies to the following operations: |
| 678 | # |
| 679 | # * Getting a policy that includes a conditional role binding |
| 680 | # * Adding a conditional role binding to a policy |
| 681 | # * Changing a conditional role binding in a policy |
| 682 | # * Removing any role binding, with or without a condition, from a policy |
| 683 | # that includes conditions |
| 684 | # |
| 685 | # **Important:** If you use IAM Conditions, you must include the `etag` field |
| 686 | # whenever you call `setIamPolicy`. If you omit this field, then IAM allows |
| 687 | # you to overwrite a version `3` policy with a version `1` policy, and all of |
| 688 | # the conditions in the version `3` policy are lost. |
| 689 | # |
| 690 | # If a policy does not include any conditions, operations on that policy may |
| 691 | # specify any valid version or leave the field unset. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 692 | # |
| 693 | # To learn which resources support conditions in their IAM policies, see the |
| 694 | # [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies). |
Bu Sun Kim | 4ed7d3f | 2020-05-27 12:20:54 -0700 | [diff] [blame] | 695 | "auditConfigs": [ # Specifies cloud audit logging configuration for this policy. |
| 696 | { # Specifies the audit configuration for a service. |
| 697 | # The configuration determines which permission types are logged, and what |
| 698 | # identities, if any, are exempted from logging. |
| 699 | # An AuditConfig must have one or more AuditLogConfigs. |
| 700 | # |
| 701 | # If there are AuditConfigs for both `allServices` and a specific service, |
| 702 | # the union of the two AuditConfigs is used for that service: the log_types |
| 703 | # specified in each AuditConfig are enabled, and the exempted_members in each |
| 704 | # AuditLogConfig are exempted. |
| 705 | # |
| 706 | # Example Policy with multiple AuditConfigs: |
| 707 | # |
| 708 | # { |
| 709 | # "audit_configs": [ |
| 710 | # { |
| 711 | # "service": "allServices" |
| 712 | # "audit_log_configs": [ |
| 713 | # { |
| 714 | # "log_type": "DATA_READ", |
| 715 | # "exempted_members": [ |
| 716 | # "user:jose@example.com" |
| 717 | # ] |
| 718 | # }, |
| 719 | # { |
| 720 | # "log_type": "DATA_WRITE", |
| 721 | # }, |
| 722 | # { |
| 723 | # "log_type": "ADMIN_READ", |
| 724 | # } |
| 725 | # ] |
| 726 | # }, |
| 727 | # { |
| 728 | # "service": "sampleservice.googleapis.com" |
| 729 | # "audit_log_configs": [ |
| 730 | # { |
| 731 | # "log_type": "DATA_READ", |
| 732 | # }, |
| 733 | # { |
| 734 | # "log_type": "DATA_WRITE", |
| 735 | # "exempted_members": [ |
| 736 | # "user:aliya@example.com" |
| 737 | # ] |
| 738 | # } |
| 739 | # ] |
| 740 | # } |
| 741 | # ] |
| 742 | # } |
| 743 | # |
| 744 | # For sampleservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ |
| 745 | # logging. It also exempts jose@example.com from DATA_READ logging, and |
| 746 | # aliya@example.com from DATA_WRITE logging. |
| 747 | "auditLogConfigs": [ # The configuration for logging of each type of permission. |
| 748 | { # Provides the configuration for logging a type of permissions. |
| 749 | # Example: |
| 750 | # |
| 751 | # { |
| 752 | # "audit_log_configs": [ |
| 753 | # { |
| 754 | # "log_type": "DATA_READ", |
| 755 | # "exempted_members": [ |
| 756 | # "user:jose@example.com" |
| 757 | # ] |
| 758 | # }, |
| 759 | # { |
| 760 | # "log_type": "DATA_WRITE", |
| 761 | # } |
| 762 | # ] |
| 763 | # } |
| 764 | # |
| 765 | # This enables 'DATA_READ' and 'DATA_WRITE' logging, while exempting |
| 766 | # jose@example.com from DATA_READ logging. |
| 767 | "exemptedMembers": [ # Specifies the identities that do not cause logging for this type of |
| 768 | # permission. |
| 769 | # Follows the same format of Binding.members. |
| 770 | "A String", |
| 771 | ], |
| 772 | "logType": "A String", # The log type that this config enables. |
| 773 | }, |
| 774 | ], |
| 775 | "service": "A String", # Specifies a service that will be enabled for audit logging. |
| 776 | # For example, `storage.googleapis.com`, `cloudsql.googleapis.com`. |
| 777 | # `allServices` is a special value that covers all services. |
| 778 | }, |
| 779 | ], |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 780 | }</pre> |
| 781 | </div> |
| 782 | |
| 783 | <div class="method"> |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 784 | <code class="details" id="list">list(filter=None, pageToken=None, pageSize=None, x__xgafv=None)</code> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 785 | <pre>Lists Projects that the caller has the `resourcemanager.projects.get` |
| 786 | permission on and satisfy the specified filter. |
| 787 | |
| 788 | This method returns Projects in an unspecified order. |
| 789 | This method is eventually consistent with project mutations; this means |
| 790 | that a newly created project may not appear in the results or recent |
| 791 | updates to an existing project may not be reflected in the results. To |
| 792 | retrieve the latest state of a project, use the |
| 793 | GetProject method. |
| 794 | |
| 795 | NOTE: If the request filter contains a `parent.type` and `parent.id` and |
| 796 | the caller has the `resourcemanager.projects.list` permission on the |
| 797 | parent, the results will be drawn from an alternate index which provides |
| 798 | more consistent results. In future versions of this API, this List method |
| 799 | will be split into List and Search to properly capture the behavorial |
| 800 | difference. |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 801 | |
| 802 | Args: |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 803 | filter: string, An expression for filtering the results of the request. Filter rules are |
| 804 | case insensitive. The fields eligible for filtering are: |
| 805 | |
| 806 | + `name` |
| 807 | + `id` |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 808 | + `labels.<key>` (where *key* is the name of a label) |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 809 | + `parent.type` |
| 810 | + `parent.id` |
| 811 | |
| 812 | Some examples of using labels as filters: |
| 813 | |
| 814 | | Filter | Description | |
| 815 | |------------------|-----------------------------------------------------| |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 816 | | name:how* | The project's name starts with "how". | |
| 817 | | name:Howl | The project's name is `Howl` or `howl`. | |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 818 | | name:HOWL | Equivalent to above. | |
| 819 | | NAME:howl | Equivalent to above. | |
| 820 | | labels.color:* | The project has the label `color`. | |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 821 | | labels.color:red | The project's label `color` has the value `red`. | |
| 822 | | labels.color:red&nbsp;labels.size:big |The project's label `color` has |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 823 | the value `red` and its label `size` has the value `big`. | |
| 824 | |
| 825 | If no filter is specified, the call will return projects for which the user |
| 826 | has the `resourcemanager.projects.get` permission. |
| 827 | |
| 828 | NOTE: To perform a by-parent query (eg., what projects are directly in a |
| 829 | Folder), the caller must have the `resourcemanager.projects.list` |
| 830 | permission on the parent and the filter must contain both a `parent.type` |
| 831 | and a `parent.id` restriction |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 832 | (example: "parent.type:folder parent.id:123"). In this case an alternate |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 833 | search index is used which provides more consistent results. |
| 834 | |
| 835 | Optional. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 836 | pageToken: string, A pagination token returned from a previous call to ListProjects |
| 837 | that indicates from where listing should continue. |
| 838 | |
| 839 | Optional. |
| 840 | pageSize: integer, The maximum number of Projects to return in the response. |
| 841 | The server can return fewer Projects than requested. |
| 842 | If unspecified, server picks an appropriate default. |
| 843 | |
| 844 | Optional. |
| 845 | x__xgafv: string, V1 error format. |
| 846 | Allowed values |
| 847 | 1 - v1 error format |
| 848 | 2 - v2 error format |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 849 | |
| 850 | Returns: |
| 851 | An object of the form: |
| 852 | |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 853 | { # A page of the response received from the |
| 854 | # ListProjects |
| 855 | # method. |
| 856 | # |
| 857 | # A paginated response where more pages are available has |
| 858 | # `next_page_token` set. This token can be used in a subsequent request to |
| 859 | # retrieve the next request page. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 860 | "projects": [ # The list of Projects that matched the list filter. This list can |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 861 | # be paginated. |
| 862 | { # A Project is a high-level Google Cloud Platform entity. It is a |
Sai Cheemalapati | c30d2b5 | 2017-03-13 12:12:03 -0400 | [diff] [blame] | 863 | # container for ACLs, APIs, App Engine Apps, VMs, and other |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 864 | # Google Cloud Platform resources. |
Bu Sun Kim | 4ed7d3f | 2020-05-27 12:20:54 -0700 | [diff] [blame] | 865 | "name": "A String", # The optional user-assigned display name of the Project. |
| 866 | # When present it must be between 4 to 30 characters. |
| 867 | # Allowed characters are: lowercase and uppercase letters, numbers, |
| 868 | # hyphen, single-quote, double-quote, space, and exclamation point. |
| 869 | # |
| 870 | # Example: <code>My Project</code> |
| 871 | # Read-write. |
| 872 | "projectId": "A String", # The unique, user-assigned ID of the Project. |
| 873 | # It must be 6 to 30 lowercase letters, digits, or hyphens. |
| 874 | # It must start with a letter. |
| 875 | # Trailing hyphens are prohibited. |
| 876 | # |
| 877 | # Example: <code>tokyo-rain-123</code> |
| 878 | # Read-only after creation. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 879 | "lifecycleState": "A String", # The Project lifecycle state. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 880 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 881 | # Read-only. |
| 882 | "projectNumber": "A String", # The number uniquely identifying the project. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 883 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 884 | # Example: <code>415104041262</code> |
| 885 | # Read-only. |
| 886 | "parent": { # A container to reference an id for any resource type. A `resource` in Google # An optional reference to a parent Resource. |
| 887 | # |
| 888 | # Supported parent types include "organization" and "folder". Once set, the |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 889 | # parent cannot be cleared. The `parent` can be set on creation or using the |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 890 | # `UpdateProject` method; the end user must have the |
| 891 | # `resourcemanager.projects.create` permission on the parent. |
| 892 | # |
| 893 | # Read-write. |
| 894 | # Cloud Platform is a generic term for something you (a developer) may want to |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 895 | # interact with through one of our API's. Some examples are an App Engine app, |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 896 | # a Compute Engine instance, a Cloud SQL database, and so on. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 897 | "type": "A String", # Required field representing the resource type this id is for. |
| 898 | # At present, the valid types are "project", "folder", and "organization". |
| 899 | "id": "A String", # Required field for the type-specific id. This should correspond to the id |
| 900 | # used in the type-specific API's. |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 901 | }, |
Bu Sun Kim | 4ed7d3f | 2020-05-27 12:20:54 -0700 | [diff] [blame] | 902 | "createTime": "A String", # Creation time. |
| 903 | # |
| 904 | # Read-only. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 905 | "labels": { # The labels associated with this Project. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 906 | # |
| 907 | # Label keys must be between 1 and 63 characters long and must conform |
| 908 | # to the following regular expression: \[a-z\](\[-a-z0-9\]*\[a-z0-9\])?. |
| 909 | # |
| 910 | # Label values must be between 0 and 63 characters long and must conform |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 911 | # to the regular expression (\[a-z\](\[-a-z0-9\]*\[a-z0-9\])?)?. A label |
| 912 | # value can be empty. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 913 | # |
| 914 | # No more than 256 labels can be associated with a given resource. |
| 915 | # |
| 916 | # Clients should store labels in a representation such as JSON that does not |
| 917 | # depend on specific characters being disallowed. |
| 918 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 919 | # Example: <code>"environment" : "dev"</code> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 920 | # Read-write. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 921 | "a_key": "A String", |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 922 | }, |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 923 | }, |
| 924 | ], |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 925 | "nextPageToken": "A String", # Pagination token. |
| 926 | # |
| 927 | # If the result set is too large to fit in a single response, this token |
| 928 | # is returned. It encodes the position of the current result cursor. |
| 929 | # Feeding this value into a new list request with the `page_token` parameter |
| 930 | # gives the next page of the results. |
| 931 | # |
| 932 | # When `next_page_token` is not filled in, there is no next page and |
| 933 | # the list returned is the last page in the result set. |
| 934 | # |
| 935 | # Pagination tokens have a limited lifetime. |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 936 | }</pre> |
| 937 | </div> |
| 938 | |
| 939 | <div class="method"> |
| 940 | <code class="details" id="list_next">list_next(previous_request, previous_response)</code> |
| 941 | <pre>Retrieves the next page of results. |
| 942 | |
| 943 | Args: |
| 944 | previous_request: The request for the previous page. (required) |
| 945 | previous_response: The response from the request for the previous page. (required) |
| 946 | |
| 947 | Returns: |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 948 | A request object that you can call 'execute()' on to request the next |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 949 | page. Returns None if there are no more items in the collection. |
| 950 | </pre> |
| 951 | </div> |
| 952 | |
| 953 | <div class="method"> |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 954 | <code class="details" id="setIamPolicy">setIamPolicy(resource, body=None, x__xgafv=None)</code> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 955 | <pre>Sets the IAM access control policy for the specified Project. Overwrites |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 956 | any existing policy. |
| 957 | |
| 958 | The following constraints apply when using `setIamPolicy()`: |
| 959 | |
| 960 | + Project does not support `allUsers` and `allAuthenticatedUsers` as |
| 961 | `members` in a `Binding` of a `Policy`. |
| 962 | |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 963 | + The owner role can be granted to a `user`, `serviceAccount`, or a group |
| 964 | that is part of an organization. For example, |
| 965 | group@myownpersonaldomain.com could be added as an owner to a project in |
| 966 | the myownpersonaldomain.com organization, but not the examplepetstore.com |
| 967 | organization. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 968 | |
| 969 | + Service accounts can be made owners of a project directly |
| 970 | without any restrictions. However, to be added as an owner, a user must be |
| 971 | invited via Cloud Platform console and must accept the invitation. |
| 972 | |
| 973 | + A user cannot be granted the owner role using `setIamPolicy()`. The user |
| 974 | must be granted the owner role using the Cloud Platform Console and must |
| 975 | explicitly accept the invitation. |
| 976 | |
Sai Cheemalapati | e833b79 | 2017-03-24 15:06:46 -0700 | [diff] [blame] | 977 | + Invitations to grant the owner role cannot be sent using |
| 978 | `setIamPolicy()`; they must be sent only using the Cloud Platform Console. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 979 | |
| 980 | + Membership changes that leave the project without any owners that have |
| 981 | accepted the Terms of Service (ToS) will be rejected. |
| 982 | |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 983 | + If the project is not part of an organization, there must be at least |
| 984 | one owner who has accepted the Terms of Service (ToS) agreement in the |
| 985 | policy. Calling `setIamPolicy()` to remove the last ToS-accepted owner |
| 986 | from the policy will fail. This restriction also applies to legacy |
| 987 | projects that no longer have owners who have accepted the ToS. Edits to |
| 988 | IAM policies will be rejected until the lack of a ToS-accepting owner is |
| 989 | rectified. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 990 | |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 991 | + This method will replace the existing policy, and cannot be used to |
| 992 | append additional IAM settings. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 993 | |
| 994 | Note: Removing service accounts from policies or changing their roles |
| 995 | can render services completely inoperable. It is important to understand |
Sai Cheemalapati | e833b79 | 2017-03-24 15:06:46 -0700 | [diff] [blame] | 996 | how the service account is being used before removing or updating its |
| 997 | roles. |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 998 | |
| 999 | Args: |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1000 | resource: string, REQUIRED: The resource for which the policy is being specified. |
Sai Cheemalapati | c30d2b5 | 2017-03-13 12:12:03 -0400 | [diff] [blame] | 1001 | See the operation documentation for the appropriate value for this field. (required) |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1002 | body: object, The request body. |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 1003 | The object takes the form of: |
| 1004 | |
| 1005 | { # Request message for `SetIamPolicy` method. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1006 | "policy": { # An Identity and Access Management (IAM) policy, which specifies access # REQUIRED: The complete policy to be applied to the `resource`. The size of |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1007 | # the policy is limited to a few 10s of KB. An empty policy is a |
| 1008 | # valid policy but certain Cloud Platform services (such as Projects) |
| 1009 | # might reject them. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1010 | # controls for Google Cloud resources. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1011 | # |
| 1012 | # |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1013 | # A `Policy` is a collection of `bindings`. A `binding` binds one or more |
| 1014 | # `members` to a single `role`. Members can be user accounts, service accounts, |
| 1015 | # Google groups, and domains (such as G Suite). A `role` is a named list of |
| 1016 | # permissions; each `role` can be an IAM predefined role or a user-created |
| 1017 | # custom role. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1018 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1019 | # For some types of Google Cloud resources, a `binding` can also specify a |
| 1020 | # `condition`, which is a logical expression that allows access to a resource |
| 1021 | # only if the expression evaluates to `true`. A condition can add constraints |
| 1022 | # based on attributes of the request, the resource, or both. To learn which |
| 1023 | # resources support conditions in their IAM policies, see the |
| 1024 | # [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies). |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1025 | # |
| 1026 | # **JSON example:** |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1027 | # |
| 1028 | # { |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1029 | # "bindings": [ |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1030 | # { |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1031 | # "role": "roles/resourcemanager.organizationAdmin", |
| 1032 | # "members": [ |
| 1033 | # "user:mike@example.com", |
| 1034 | # "group:admins@example.com", |
| 1035 | # "domain:google.com", |
| 1036 | # "serviceAccount:my-project-id@appspot.gserviceaccount.com" |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1037 | # ] |
| 1038 | # }, |
| 1039 | # { |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1040 | # "role": "roles/resourcemanager.organizationViewer", |
| 1041 | # "members": [ |
| 1042 | # "user:eve@example.com" |
| 1043 | # ], |
| 1044 | # "condition": { |
| 1045 | # "title": "expirable access", |
| 1046 | # "description": "Does not grant access after Sep 2020", |
| 1047 | # "expression": "request.time < timestamp('2020-10-01T00:00:00.000Z')", |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1048 | # } |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1049 | # } |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1050 | # ], |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1051 | # "etag": "BwWWja0YfJA=", |
| 1052 | # "version": 3 |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1053 | # } |
| 1054 | # |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1055 | # **YAML example:** |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1056 | # |
| 1057 | # bindings: |
| 1058 | # - members: |
| 1059 | # - user:mike@example.com |
| 1060 | # - group:admins@example.com |
| 1061 | # - domain:google.com |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1062 | # - serviceAccount:my-project-id@appspot.gserviceaccount.com |
| 1063 | # role: roles/resourcemanager.organizationAdmin |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1064 | # - members: |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1065 | # - user:eve@example.com |
| 1066 | # role: roles/resourcemanager.organizationViewer |
| 1067 | # condition: |
| 1068 | # title: expirable access |
| 1069 | # description: Does not grant access after Sep 2020 |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1070 | # expression: request.time < timestamp('2020-10-01T00:00:00.000Z') |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1071 | # - etag: BwWWja0YfJA= |
| 1072 | # - version: 3 |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1073 | # |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1074 | # For a description of IAM and its features, see the |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1075 | # [IAM documentation](https://cloud.google.com/iam/docs/). |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1076 | "bindings": [ # Associates a list of `members` to a `role`. Optionally, may specify a |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1077 | # `condition` that determines how and when the `bindings` are applied. Each |
| 1078 | # of the `bindings` must contain at least one member. |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 1079 | { # Associates `members` with a `role`. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1080 | "role": "A String", # Role that is assigned to `members`. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1081 | # For example, `roles/viewer`, `roles/editor`, or `roles/owner`. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1082 | "condition": { # Represents a textual expression in the Common Expression Language (CEL) # The condition that is associated with this binding. |
| 1083 | # |
| 1084 | # If the condition evaluates to `true`, then this binding applies to the |
| 1085 | # current request. |
| 1086 | # |
| 1087 | # If the condition evaluates to `false`, then this binding does not apply to |
| 1088 | # the current request. However, a different role binding might grant the same |
| 1089 | # role to one or more of the members in this binding. |
| 1090 | # |
| 1091 | # To learn which resources support conditions in their IAM policies, see the |
| 1092 | # [IAM |
| 1093 | # documentation](https://cloud.google.com/iam/help/conditions/resource-policies). |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1094 | # syntax. CEL is a C-like expression language. The syntax and semantics of CEL |
| 1095 | # are documented at https://github.com/google/cel-spec. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1096 | # |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1097 | # Example (Comparison): |
| 1098 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1099 | # title: "Summary size limit" |
| 1100 | # description: "Determines if a summary is less than 100 chars" |
| 1101 | # expression: "document.summary.size() < 100" |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1102 | # |
| 1103 | # Example (Equality): |
| 1104 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1105 | # title: "Requestor is owner" |
| 1106 | # description: "Determines if requestor is the document owner" |
| 1107 | # expression: "document.owner == request.auth.claims.email" |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1108 | # |
| 1109 | # Example (Logic): |
| 1110 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1111 | # title: "Public documents" |
| 1112 | # description: "Determine whether the document should be publicly visible" |
| 1113 | # expression: "document.type != 'private' && document.type != 'internal'" |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1114 | # |
| 1115 | # Example (Data Manipulation): |
| 1116 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1117 | # title: "Notification string" |
| 1118 | # description: "Create a notification string with a timestamp." |
| 1119 | # expression: "'New message received at ' + string(document.create_time)" |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1120 | # |
| 1121 | # The exact variables and functions that may be referenced within an expression |
| 1122 | # are determined by the service that evaluates it. See the service |
| 1123 | # documentation for additional information. |
Bu Sun Kim | 4ed7d3f | 2020-05-27 12:20:54 -0700 | [diff] [blame] | 1124 | "expression": "A String", # Textual representation of an expression in Common Expression Language |
| 1125 | # syntax. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1126 | "title": "A String", # Optional. Title for the expression, i.e. a short string describing |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1127 | # its purpose. This can be used e.g. in UIs which allow to enter the |
| 1128 | # expression. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1129 | "location": "A String", # Optional. String indicating the location of the expression for error |
| 1130 | # reporting, e.g. a file name and a position in the file. |
| 1131 | "description": "A String", # Optional. Description of the expression. This is a longer text which |
| 1132 | # describes the expression, e.g. when hovered over it in a UI. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1133 | }, |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1134 | "members": [ # Specifies the identities requesting access for a Cloud Platform resource. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1135 | # `members` can have the following values: |
| 1136 | # |
| 1137 | # * `allUsers`: A special identifier that represents anyone who is |
| 1138 | # on the internet; with or without a Google account. |
| 1139 | # |
| 1140 | # * `allAuthenticatedUsers`: A special identifier that represents anyone |
| 1141 | # who is authenticated with a Google account or a service account. |
| 1142 | # |
| 1143 | # * `user:{emailid}`: An email address that represents a specific Google |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1144 | # account. For example, `alice@example.com` . |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1145 | # |
| 1146 | # |
| 1147 | # * `serviceAccount:{emailid}`: An email address that represents a service |
| 1148 | # account. For example, `my-other-app@appspot.gserviceaccount.com`. |
| 1149 | # |
| 1150 | # * `group:{emailid}`: An email address that represents a Google group. |
| 1151 | # For example, `admins@example.com`. |
| 1152 | # |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1153 | # * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique |
| 1154 | # identifier) representing a user that has been recently deleted. For |
| 1155 | # example, `alice@example.com?uid=123456789012345678901`. If the user is |
| 1156 | # recovered, this value reverts to `user:{emailid}` and the recovered user |
| 1157 | # retains the role in the binding. |
| 1158 | # |
| 1159 | # * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus |
| 1160 | # unique identifier) representing a service account that has been recently |
| 1161 | # deleted. For example, |
| 1162 | # `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`. |
| 1163 | # If the service account is undeleted, this value reverts to |
| 1164 | # `serviceAccount:{emailid}` and the undeleted service account retains the |
| 1165 | # role in the binding. |
| 1166 | # |
| 1167 | # * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique |
| 1168 | # identifier) representing a Google group that has been recently |
| 1169 | # deleted. For example, `admins@example.com?uid=123456789012345678901`. If |
| 1170 | # the group is recovered, this value reverts to `group:{emailid}` and the |
| 1171 | # recovered group retains the role in the binding. |
| 1172 | # |
Sai Cheemalapati | 4ba8c23 | 2017-06-06 18:46:08 -0400 | [diff] [blame] | 1173 | # |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1174 | # * `domain:{domain}`: The G Suite domain (primary) that represents all the |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1175 | # users of that domain. For example, `google.com` or `example.com`. |
| 1176 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1177 | "A String", |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 1178 | ], |
| 1179 | }, |
| 1180 | ], |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1181 | "etag": "A String", # `etag` is used for optimistic concurrency control as a way to help |
Sai Cheemalapati | 4ba8c23 | 2017-06-06 18:46:08 -0400 | [diff] [blame] | 1182 | # prevent simultaneous updates of a policy from overwriting each other. |
| 1183 | # It is strongly suggested that systems make use of the `etag` in the |
| 1184 | # read-modify-write cycle to perform policy updates in order to avoid race |
| 1185 | # conditions: An `etag` is returned in the response to `getIamPolicy`, and |
| 1186 | # systems are expected to put that etag in the request to `setIamPolicy` to |
| 1187 | # ensure that their change will be applied to the same version of the policy. |
| 1188 | # |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1189 | # **Important:** If you use IAM Conditions, you must include the `etag` field |
| 1190 | # whenever you call `setIamPolicy`. If you omit this field, then IAM allows |
| 1191 | # you to overwrite a version `3` policy with a version `1` policy, and all of |
| 1192 | # the conditions in the version `3` policy are lost. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1193 | "version": 42, # Specifies the format of the policy. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1194 | # |
| 1195 | # Valid values are `0`, `1`, and `3`. Requests that specify an invalid value |
| 1196 | # are rejected. |
| 1197 | # |
| 1198 | # Any operation that affects conditional role bindings must specify version |
| 1199 | # `3`. This requirement applies to the following operations: |
| 1200 | # |
| 1201 | # * Getting a policy that includes a conditional role binding |
| 1202 | # * Adding a conditional role binding to a policy |
| 1203 | # * Changing a conditional role binding in a policy |
| 1204 | # * Removing any role binding, with or without a condition, from a policy |
| 1205 | # that includes conditions |
| 1206 | # |
| 1207 | # **Important:** If you use IAM Conditions, you must include the `etag` field |
| 1208 | # whenever you call `setIamPolicy`. If you omit this field, then IAM allows |
| 1209 | # you to overwrite a version `3` policy with a version `1` policy, and all of |
| 1210 | # the conditions in the version `3` policy are lost. |
| 1211 | # |
| 1212 | # If a policy does not include any conditions, operations on that policy may |
| 1213 | # specify any valid version or leave the field unset. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1214 | # |
| 1215 | # To learn which resources support conditions in their IAM policies, see the |
| 1216 | # [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies). |
Bu Sun Kim | 4ed7d3f | 2020-05-27 12:20:54 -0700 | [diff] [blame] | 1217 | "auditConfigs": [ # Specifies cloud audit logging configuration for this policy. |
| 1218 | { # Specifies the audit configuration for a service. |
| 1219 | # The configuration determines which permission types are logged, and what |
| 1220 | # identities, if any, are exempted from logging. |
| 1221 | # An AuditConfig must have one or more AuditLogConfigs. |
| 1222 | # |
| 1223 | # If there are AuditConfigs for both `allServices` and a specific service, |
| 1224 | # the union of the two AuditConfigs is used for that service: the log_types |
| 1225 | # specified in each AuditConfig are enabled, and the exempted_members in each |
| 1226 | # AuditLogConfig are exempted. |
| 1227 | # |
| 1228 | # Example Policy with multiple AuditConfigs: |
| 1229 | # |
| 1230 | # { |
| 1231 | # "audit_configs": [ |
| 1232 | # { |
| 1233 | # "service": "allServices" |
| 1234 | # "audit_log_configs": [ |
| 1235 | # { |
| 1236 | # "log_type": "DATA_READ", |
| 1237 | # "exempted_members": [ |
| 1238 | # "user:jose@example.com" |
| 1239 | # ] |
| 1240 | # }, |
| 1241 | # { |
| 1242 | # "log_type": "DATA_WRITE", |
| 1243 | # }, |
| 1244 | # { |
| 1245 | # "log_type": "ADMIN_READ", |
| 1246 | # } |
| 1247 | # ] |
| 1248 | # }, |
| 1249 | # { |
| 1250 | # "service": "sampleservice.googleapis.com" |
| 1251 | # "audit_log_configs": [ |
| 1252 | # { |
| 1253 | # "log_type": "DATA_READ", |
| 1254 | # }, |
| 1255 | # { |
| 1256 | # "log_type": "DATA_WRITE", |
| 1257 | # "exempted_members": [ |
| 1258 | # "user:aliya@example.com" |
| 1259 | # ] |
| 1260 | # } |
| 1261 | # ] |
| 1262 | # } |
| 1263 | # ] |
| 1264 | # } |
| 1265 | # |
| 1266 | # For sampleservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ |
| 1267 | # logging. It also exempts jose@example.com from DATA_READ logging, and |
| 1268 | # aliya@example.com from DATA_WRITE logging. |
| 1269 | "auditLogConfigs": [ # The configuration for logging of each type of permission. |
| 1270 | { # Provides the configuration for logging a type of permissions. |
| 1271 | # Example: |
| 1272 | # |
| 1273 | # { |
| 1274 | # "audit_log_configs": [ |
| 1275 | # { |
| 1276 | # "log_type": "DATA_READ", |
| 1277 | # "exempted_members": [ |
| 1278 | # "user:jose@example.com" |
| 1279 | # ] |
| 1280 | # }, |
| 1281 | # { |
| 1282 | # "log_type": "DATA_WRITE", |
| 1283 | # } |
| 1284 | # ] |
| 1285 | # } |
| 1286 | # |
| 1287 | # This enables 'DATA_READ' and 'DATA_WRITE' logging, while exempting |
| 1288 | # jose@example.com from DATA_READ logging. |
| 1289 | "exemptedMembers": [ # Specifies the identities that do not cause logging for this type of |
| 1290 | # permission. |
| 1291 | # Follows the same format of Binding.members. |
| 1292 | "A String", |
| 1293 | ], |
| 1294 | "logType": "A String", # The log type that this config enables. |
| 1295 | }, |
| 1296 | ], |
| 1297 | "service": "A String", # Specifies a service that will be enabled for audit logging. |
| 1298 | # For example, `storage.googleapis.com`, `cloudsql.googleapis.com`. |
| 1299 | # `allServices` is a special value that covers all services. |
| 1300 | }, |
| 1301 | ], |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 1302 | }, |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1303 | "updateMask": "A String", # OPTIONAL: A FieldMask specifying which fields of the policy to modify. Only |
Sai Cheemalapati | e833b79 | 2017-03-24 15:06:46 -0700 | [diff] [blame] | 1304 | # the fields in the mask will be modified. If no mask is provided, the |
| 1305 | # following default mask is used: |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1306 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1307 | # `paths: "bindings, etag"` |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 1308 | } |
| 1309 | |
| 1310 | x__xgafv: string, V1 error format. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1311 | Allowed values |
| 1312 | 1 - v1 error format |
| 1313 | 2 - v2 error format |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 1314 | |
| 1315 | Returns: |
| 1316 | An object of the form: |
| 1317 | |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1318 | { # An Identity and Access Management (IAM) policy, which specifies access |
| 1319 | # controls for Google Cloud resources. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1320 | # |
| 1321 | # |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1322 | # A `Policy` is a collection of `bindings`. A `binding` binds one or more |
| 1323 | # `members` to a single `role`. Members can be user accounts, service accounts, |
| 1324 | # Google groups, and domains (such as G Suite). A `role` is a named list of |
| 1325 | # permissions; each `role` can be an IAM predefined role or a user-created |
| 1326 | # custom role. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1327 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1328 | # For some types of Google Cloud resources, a `binding` can also specify a |
| 1329 | # `condition`, which is a logical expression that allows access to a resource |
| 1330 | # only if the expression evaluates to `true`. A condition can add constraints |
| 1331 | # based on attributes of the request, the resource, or both. To learn which |
| 1332 | # resources support conditions in their IAM policies, see the |
| 1333 | # [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies). |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1334 | # |
| 1335 | # **JSON example:** |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1336 | # |
| 1337 | # { |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1338 | # "bindings": [ |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1339 | # { |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1340 | # "role": "roles/resourcemanager.organizationAdmin", |
| 1341 | # "members": [ |
| 1342 | # "user:mike@example.com", |
| 1343 | # "group:admins@example.com", |
| 1344 | # "domain:google.com", |
| 1345 | # "serviceAccount:my-project-id@appspot.gserviceaccount.com" |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1346 | # ] |
| 1347 | # }, |
| 1348 | # { |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1349 | # "role": "roles/resourcemanager.organizationViewer", |
| 1350 | # "members": [ |
| 1351 | # "user:eve@example.com" |
| 1352 | # ], |
| 1353 | # "condition": { |
| 1354 | # "title": "expirable access", |
| 1355 | # "description": "Does not grant access after Sep 2020", |
| 1356 | # "expression": "request.time < timestamp('2020-10-01T00:00:00.000Z')", |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1357 | # } |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1358 | # } |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1359 | # ], |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1360 | # "etag": "BwWWja0YfJA=", |
| 1361 | # "version": 3 |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1362 | # } |
| 1363 | # |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1364 | # **YAML example:** |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1365 | # |
| 1366 | # bindings: |
| 1367 | # - members: |
| 1368 | # - user:mike@example.com |
| 1369 | # - group:admins@example.com |
| 1370 | # - domain:google.com |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1371 | # - serviceAccount:my-project-id@appspot.gserviceaccount.com |
| 1372 | # role: roles/resourcemanager.organizationAdmin |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1373 | # - members: |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1374 | # - user:eve@example.com |
| 1375 | # role: roles/resourcemanager.organizationViewer |
| 1376 | # condition: |
| 1377 | # title: expirable access |
| 1378 | # description: Does not grant access after Sep 2020 |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1379 | # expression: request.time < timestamp('2020-10-01T00:00:00.000Z') |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1380 | # - etag: BwWWja0YfJA= |
| 1381 | # - version: 3 |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1382 | # |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1383 | # For a description of IAM and its features, see the |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1384 | # [IAM documentation](https://cloud.google.com/iam/docs/). |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1385 | "bindings": [ # Associates a list of `members` to a `role`. Optionally, may specify a |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1386 | # `condition` that determines how and when the `bindings` are applied. Each |
| 1387 | # of the `bindings` must contain at least one member. |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 1388 | { # Associates `members` with a `role`. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1389 | "role": "A String", # Role that is assigned to `members`. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1390 | # For example, `roles/viewer`, `roles/editor`, or `roles/owner`. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1391 | "condition": { # Represents a textual expression in the Common Expression Language (CEL) # The condition that is associated with this binding. |
| 1392 | # |
| 1393 | # If the condition evaluates to `true`, then this binding applies to the |
| 1394 | # current request. |
| 1395 | # |
| 1396 | # If the condition evaluates to `false`, then this binding does not apply to |
| 1397 | # the current request. However, a different role binding might grant the same |
| 1398 | # role to one or more of the members in this binding. |
| 1399 | # |
| 1400 | # To learn which resources support conditions in their IAM policies, see the |
| 1401 | # [IAM |
| 1402 | # documentation](https://cloud.google.com/iam/help/conditions/resource-policies). |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1403 | # syntax. CEL is a C-like expression language. The syntax and semantics of CEL |
| 1404 | # are documented at https://github.com/google/cel-spec. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1405 | # |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1406 | # Example (Comparison): |
| 1407 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1408 | # title: "Summary size limit" |
| 1409 | # description: "Determines if a summary is less than 100 chars" |
| 1410 | # expression: "document.summary.size() < 100" |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1411 | # |
| 1412 | # Example (Equality): |
| 1413 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1414 | # title: "Requestor is owner" |
| 1415 | # description: "Determines if requestor is the document owner" |
| 1416 | # expression: "document.owner == request.auth.claims.email" |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1417 | # |
| 1418 | # Example (Logic): |
| 1419 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1420 | # title: "Public documents" |
| 1421 | # description: "Determine whether the document should be publicly visible" |
| 1422 | # expression: "document.type != 'private' && document.type != 'internal'" |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1423 | # |
| 1424 | # Example (Data Manipulation): |
| 1425 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1426 | # title: "Notification string" |
| 1427 | # description: "Create a notification string with a timestamp." |
| 1428 | # expression: "'New message received at ' + string(document.create_time)" |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1429 | # |
| 1430 | # The exact variables and functions that may be referenced within an expression |
| 1431 | # are determined by the service that evaluates it. See the service |
| 1432 | # documentation for additional information. |
Bu Sun Kim | 4ed7d3f | 2020-05-27 12:20:54 -0700 | [diff] [blame] | 1433 | "expression": "A String", # Textual representation of an expression in Common Expression Language |
| 1434 | # syntax. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1435 | "title": "A String", # Optional. Title for the expression, i.e. a short string describing |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1436 | # its purpose. This can be used e.g. in UIs which allow to enter the |
| 1437 | # expression. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1438 | "location": "A String", # Optional. String indicating the location of the expression for error |
| 1439 | # reporting, e.g. a file name and a position in the file. |
| 1440 | "description": "A String", # Optional. Description of the expression. This is a longer text which |
| 1441 | # describes the expression, e.g. when hovered over it in a UI. |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1442 | }, |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1443 | "members": [ # Specifies the identities requesting access for a Cloud Platform resource. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1444 | # `members` can have the following values: |
| 1445 | # |
| 1446 | # * `allUsers`: A special identifier that represents anyone who is |
| 1447 | # on the internet; with or without a Google account. |
| 1448 | # |
| 1449 | # * `allAuthenticatedUsers`: A special identifier that represents anyone |
| 1450 | # who is authenticated with a Google account or a service account. |
| 1451 | # |
| 1452 | # * `user:{emailid}`: An email address that represents a specific Google |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1453 | # account. For example, `alice@example.com` . |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1454 | # |
| 1455 | # |
| 1456 | # * `serviceAccount:{emailid}`: An email address that represents a service |
| 1457 | # account. For example, `my-other-app@appspot.gserviceaccount.com`. |
| 1458 | # |
| 1459 | # * `group:{emailid}`: An email address that represents a Google group. |
| 1460 | # For example, `admins@example.com`. |
| 1461 | # |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1462 | # * `deleted:user:{emailid}?uid={uniqueid}`: An email address (plus unique |
| 1463 | # identifier) representing a user that has been recently deleted. For |
| 1464 | # example, `alice@example.com?uid=123456789012345678901`. If the user is |
| 1465 | # recovered, this value reverts to `user:{emailid}` and the recovered user |
| 1466 | # retains the role in the binding. |
| 1467 | # |
| 1468 | # * `deleted:serviceAccount:{emailid}?uid={uniqueid}`: An email address (plus |
| 1469 | # unique identifier) representing a service account that has been recently |
| 1470 | # deleted. For example, |
| 1471 | # `my-other-app@appspot.gserviceaccount.com?uid=123456789012345678901`. |
| 1472 | # If the service account is undeleted, this value reverts to |
| 1473 | # `serviceAccount:{emailid}` and the undeleted service account retains the |
| 1474 | # role in the binding. |
| 1475 | # |
| 1476 | # * `deleted:group:{emailid}?uid={uniqueid}`: An email address (plus unique |
| 1477 | # identifier) representing a Google group that has been recently |
| 1478 | # deleted. For example, `admins@example.com?uid=123456789012345678901`. If |
| 1479 | # the group is recovered, this value reverts to `group:{emailid}` and the |
| 1480 | # recovered group retains the role in the binding. |
| 1481 | # |
Sai Cheemalapati | 4ba8c23 | 2017-06-06 18:46:08 -0400 | [diff] [blame] | 1482 | # |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1483 | # * `domain:{domain}`: The G Suite domain (primary) that represents all the |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1484 | # users of that domain. For example, `google.com` or `example.com`. |
| 1485 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1486 | "A String", |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 1487 | ], |
| 1488 | }, |
| 1489 | ], |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1490 | "etag": "A String", # `etag` is used for optimistic concurrency control as a way to help |
Sai Cheemalapati | 4ba8c23 | 2017-06-06 18:46:08 -0400 | [diff] [blame] | 1491 | # prevent simultaneous updates of a policy from overwriting each other. |
| 1492 | # It is strongly suggested that systems make use of the `etag` in the |
| 1493 | # read-modify-write cycle to perform policy updates in order to avoid race |
| 1494 | # conditions: An `etag` is returned in the response to `getIamPolicy`, and |
| 1495 | # systems are expected to put that etag in the request to `setIamPolicy` to |
| 1496 | # ensure that their change will be applied to the same version of the policy. |
| 1497 | # |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1498 | # **Important:** If you use IAM Conditions, you must include the `etag` field |
| 1499 | # whenever you call `setIamPolicy`. If you omit this field, then IAM allows |
| 1500 | # you to overwrite a version `3` policy with a version `1` policy, and all of |
| 1501 | # the conditions in the version `3` policy are lost. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1502 | "version": 42, # Specifies the format of the policy. |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1503 | # |
| 1504 | # Valid values are `0`, `1`, and `3`. Requests that specify an invalid value |
| 1505 | # are rejected. |
| 1506 | # |
| 1507 | # Any operation that affects conditional role bindings must specify version |
| 1508 | # `3`. This requirement applies to the following operations: |
| 1509 | # |
| 1510 | # * Getting a policy that includes a conditional role binding |
| 1511 | # * Adding a conditional role binding to a policy |
| 1512 | # * Changing a conditional role binding in a policy |
| 1513 | # * Removing any role binding, with or without a condition, from a policy |
| 1514 | # that includes conditions |
| 1515 | # |
| 1516 | # **Important:** If you use IAM Conditions, you must include the `etag` field |
| 1517 | # whenever you call `setIamPolicy`. If you omit this field, then IAM allows |
| 1518 | # you to overwrite a version `3` policy with a version `1` policy, and all of |
| 1519 | # the conditions in the version `3` policy are lost. |
| 1520 | # |
| 1521 | # If a policy does not include any conditions, operations on that policy may |
| 1522 | # specify any valid version or leave the field unset. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1523 | # |
| 1524 | # To learn which resources support conditions in their IAM policies, see the |
| 1525 | # [IAM documentation](https://cloud.google.com/iam/help/conditions/resource-policies). |
Bu Sun Kim | 4ed7d3f | 2020-05-27 12:20:54 -0700 | [diff] [blame] | 1526 | "auditConfigs": [ # Specifies cloud audit logging configuration for this policy. |
| 1527 | { # Specifies the audit configuration for a service. |
| 1528 | # The configuration determines which permission types are logged, and what |
| 1529 | # identities, if any, are exempted from logging. |
| 1530 | # An AuditConfig must have one or more AuditLogConfigs. |
| 1531 | # |
| 1532 | # If there are AuditConfigs for both `allServices` and a specific service, |
| 1533 | # the union of the two AuditConfigs is used for that service: the log_types |
| 1534 | # specified in each AuditConfig are enabled, and the exempted_members in each |
| 1535 | # AuditLogConfig are exempted. |
| 1536 | # |
| 1537 | # Example Policy with multiple AuditConfigs: |
| 1538 | # |
| 1539 | # { |
| 1540 | # "audit_configs": [ |
| 1541 | # { |
| 1542 | # "service": "allServices" |
| 1543 | # "audit_log_configs": [ |
| 1544 | # { |
| 1545 | # "log_type": "DATA_READ", |
| 1546 | # "exempted_members": [ |
| 1547 | # "user:jose@example.com" |
| 1548 | # ] |
| 1549 | # }, |
| 1550 | # { |
| 1551 | # "log_type": "DATA_WRITE", |
| 1552 | # }, |
| 1553 | # { |
| 1554 | # "log_type": "ADMIN_READ", |
| 1555 | # } |
| 1556 | # ] |
| 1557 | # }, |
| 1558 | # { |
| 1559 | # "service": "sampleservice.googleapis.com" |
| 1560 | # "audit_log_configs": [ |
| 1561 | # { |
| 1562 | # "log_type": "DATA_READ", |
| 1563 | # }, |
| 1564 | # { |
| 1565 | # "log_type": "DATA_WRITE", |
| 1566 | # "exempted_members": [ |
| 1567 | # "user:aliya@example.com" |
| 1568 | # ] |
| 1569 | # } |
| 1570 | # ] |
| 1571 | # } |
| 1572 | # ] |
| 1573 | # } |
| 1574 | # |
| 1575 | # For sampleservice, this policy enables DATA_READ, DATA_WRITE and ADMIN_READ |
| 1576 | # logging. It also exempts jose@example.com from DATA_READ logging, and |
| 1577 | # aliya@example.com from DATA_WRITE logging. |
| 1578 | "auditLogConfigs": [ # The configuration for logging of each type of permission. |
| 1579 | { # Provides the configuration for logging a type of permissions. |
| 1580 | # Example: |
| 1581 | # |
| 1582 | # { |
| 1583 | # "audit_log_configs": [ |
| 1584 | # { |
| 1585 | # "log_type": "DATA_READ", |
| 1586 | # "exempted_members": [ |
| 1587 | # "user:jose@example.com" |
| 1588 | # ] |
| 1589 | # }, |
| 1590 | # { |
| 1591 | # "log_type": "DATA_WRITE", |
| 1592 | # } |
| 1593 | # ] |
| 1594 | # } |
| 1595 | # |
| 1596 | # This enables 'DATA_READ' and 'DATA_WRITE' logging, while exempting |
| 1597 | # jose@example.com from DATA_READ logging. |
| 1598 | "exemptedMembers": [ # Specifies the identities that do not cause logging for this type of |
| 1599 | # permission. |
| 1600 | # Follows the same format of Binding.members. |
| 1601 | "A String", |
| 1602 | ], |
| 1603 | "logType": "A String", # The log type that this config enables. |
| 1604 | }, |
| 1605 | ], |
| 1606 | "service": "A String", # Specifies a service that will be enabled for audit logging. |
| 1607 | # For example, `storage.googleapis.com`, `cloudsql.googleapis.com`. |
| 1608 | # `allServices` is a special value that covers all services. |
| 1609 | }, |
| 1610 | ], |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 1611 | }</pre> |
| 1612 | </div> |
| 1613 | |
| 1614 | <div class="method"> |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1615 | <code class="details" id="testIamPermissions">testIamPermissions(resource, body=None, x__xgafv=None)</code> |
Jon Wayne Parrott | 36e41bc | 2016-02-19 16:02:29 -0800 | [diff] [blame] | 1616 | <pre>Returns permissions that a caller has on the specified Project. |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 1617 | |
| 1618 | Args: |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1619 | resource: string, REQUIRED: The resource for which the policy detail is being requested. |
Sai Cheemalapati | c30d2b5 | 2017-03-13 12:12:03 -0400 | [diff] [blame] | 1620 | See the operation documentation for the appropriate value for this field. (required) |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1621 | body: object, The request body. |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 1622 | The object takes the form of: |
| 1623 | |
| 1624 | { # Request message for `TestIamPermissions` method. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1625 | "permissions": [ # The set of permissions to check for the `resource`. Permissions with |
| 1626 | # wildcards (such as '*' or 'storage.*') are not allowed. For more |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1627 | # information see |
| 1628 | # [IAM Overview](https://cloud.google.com/iam/docs/overview#permissions). |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1629 | "A String", |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 1630 | ], |
| 1631 | } |
| 1632 | |
| 1633 | x__xgafv: string, V1 error format. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1634 | Allowed values |
| 1635 | 1 - v1 error format |
| 1636 | 2 - v2 error format |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 1637 | |
| 1638 | Returns: |
| 1639 | An object of the form: |
| 1640 | |
| 1641 | { # Response message for `TestIamPermissions` method. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1642 | "permissions": [ # A subset of `TestPermissionsRequest.permissions` that the caller is |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1643 | # allowed. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1644 | "A String", |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 1645 | ], |
| 1646 | }</pre> |
| 1647 | </div> |
| 1648 | |
| 1649 | <div class="method"> |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1650 | <code class="details" id="undelete">undelete(projectId, body=None, x__xgafv=None)</code> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1651 | <pre>Restores the Project identified by the specified |
| 1652 | `project_id` (for example, `my-project-123`). |
| 1653 | You can only use this method for a Project that has a lifecycle state of |
| 1654 | DELETE_REQUESTED. |
| 1655 | After deletion starts, the Project cannot be restored. |
| 1656 | |
| 1657 | The caller must have modify permissions for this Project. |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 1658 | |
| 1659 | Args: |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1660 | projectId: string, The project ID (for example, `foo-bar-123`). |
| 1661 | |
| 1662 | Required. (required) |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1663 | body: object, The request body. |
Sai Cheemalapati | df61397 | 2016-10-21 13:59:49 -0700 | [diff] [blame] | 1664 | The object takes the form of: |
| 1665 | |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1666 | { # The request sent to the UndeleteProject |
| 1667 | # method. |
Sai Cheemalapati | df61397 | 2016-10-21 13:59:49 -0700 | [diff] [blame] | 1668 | } |
| 1669 | |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 1670 | x__xgafv: string, V1 error format. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1671 | Allowed values |
| 1672 | 1 - v1 error format |
| 1673 | 2 - v2 error format |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 1674 | |
| 1675 | Returns: |
| 1676 | An object of the form: |
| 1677 | |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1678 | { # A generic empty message that you can re-use to avoid defining duplicated |
| 1679 | # empty messages in your APIs. A typical example is to use it as the request |
| 1680 | # or the response type of an API method. For instance: |
| 1681 | # |
| 1682 | # service Foo { |
| 1683 | # rpc Bar(google.protobuf.Empty) returns (google.protobuf.Empty); |
| 1684 | # } |
| 1685 | # |
| 1686 | # The JSON representation for `Empty` is empty JSON object `{}`. |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 1687 | }</pre> |
| 1688 | </div> |
| 1689 | |
| 1690 | <div class="method"> |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1691 | <code class="details" id="update">update(projectId, body=None, x__xgafv=None)</code> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1692 | <pre>Updates the attributes of the Project identified by the specified |
| 1693 | `project_id` (for example, `my-project-123`). |
| 1694 | |
| 1695 | The caller must have modify permissions for this Project. |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 1696 | |
| 1697 | Args: |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1698 | projectId: string, The project ID (for example, `my-project-123`). |
| 1699 | |
| 1700 | Required. (required) |
Dan O'Meara | dd49464 | 2020-05-01 07:42:23 -0700 | [diff] [blame] | 1701 | body: object, The request body. |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 1702 | The object takes the form of: |
| 1703 | |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1704 | { # A Project is a high-level Google Cloud Platform entity. It is a |
Sai Cheemalapati | c30d2b5 | 2017-03-13 12:12:03 -0400 | [diff] [blame] | 1705 | # container for ACLs, APIs, App Engine Apps, VMs, and other |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1706 | # Google Cloud Platform resources. |
Bu Sun Kim | 4ed7d3f | 2020-05-27 12:20:54 -0700 | [diff] [blame] | 1707 | "name": "A String", # The optional user-assigned display name of the Project. |
| 1708 | # When present it must be between 4 to 30 characters. |
| 1709 | # Allowed characters are: lowercase and uppercase letters, numbers, |
| 1710 | # hyphen, single-quote, double-quote, space, and exclamation point. |
| 1711 | # |
| 1712 | # Example: <code>My Project</code> |
| 1713 | # Read-write. |
| 1714 | "projectId": "A String", # The unique, user-assigned ID of the Project. |
| 1715 | # It must be 6 to 30 lowercase letters, digits, or hyphens. |
| 1716 | # It must start with a letter. |
| 1717 | # Trailing hyphens are prohibited. |
| 1718 | # |
| 1719 | # Example: <code>tokyo-rain-123</code> |
| 1720 | # Read-only after creation. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1721 | "lifecycleState": "A String", # The Project lifecycle state. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1722 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1723 | # Read-only. |
| 1724 | "projectNumber": "A String", # The number uniquely identifying the project. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1725 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1726 | # Example: <code>415104041262</code> |
| 1727 | # Read-only. |
| 1728 | "parent": { # A container to reference an id for any resource type. A `resource` in Google # An optional reference to a parent Resource. |
| 1729 | # |
| 1730 | # Supported parent types include "organization" and "folder". Once set, the |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1731 | # parent cannot be cleared. The `parent` can be set on creation or using the |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1732 | # `UpdateProject` method; the end user must have the |
| 1733 | # `resourcemanager.projects.create` permission on the parent. |
| 1734 | # |
| 1735 | # Read-write. |
| 1736 | # Cloud Platform is a generic term for something you (a developer) may want to |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1737 | # interact with through one of our API's. Some examples are an App Engine app, |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1738 | # a Compute Engine instance, a Cloud SQL database, and so on. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1739 | "type": "A String", # Required field representing the resource type this id is for. |
| 1740 | # At present, the valid types are "project", "folder", and "organization". |
| 1741 | "id": "A String", # Required field for the type-specific id. This should correspond to the id |
| 1742 | # used in the type-specific API's. |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 1743 | }, |
Bu Sun Kim | 4ed7d3f | 2020-05-27 12:20:54 -0700 | [diff] [blame] | 1744 | "createTime": "A String", # Creation time. |
| 1745 | # |
| 1746 | # Read-only. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1747 | "labels": { # The labels associated with this Project. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1748 | # |
| 1749 | # Label keys must be between 1 and 63 characters long and must conform |
| 1750 | # to the following regular expression: \[a-z\](\[-a-z0-9\]*\[a-z0-9\])?. |
| 1751 | # |
| 1752 | # Label values must be between 0 and 63 characters long and must conform |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1753 | # to the regular expression (\[a-z\](\[-a-z0-9\]*\[a-z0-9\])?)?. A label |
| 1754 | # value can be empty. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1755 | # |
| 1756 | # No more than 256 labels can be associated with a given resource. |
| 1757 | # |
| 1758 | # Clients should store labels in a representation such as JSON that does not |
| 1759 | # depend on specific characters being disallowed. |
| 1760 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1761 | # Example: <code>"environment" : "dev"</code> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1762 | # Read-write. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1763 | "a_key": "A String", |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 1764 | }, |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 1765 | } |
| 1766 | |
| 1767 | x__xgafv: string, V1 error format. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1768 | Allowed values |
| 1769 | 1 - v1 error format |
| 1770 | 2 - v2 error format |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 1771 | |
| 1772 | Returns: |
| 1773 | An object of the form: |
| 1774 | |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1775 | { # A Project is a high-level Google Cloud Platform entity. It is a |
Sai Cheemalapati | c30d2b5 | 2017-03-13 12:12:03 -0400 | [diff] [blame] | 1776 | # container for ACLs, APIs, App Engine Apps, VMs, and other |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1777 | # Google Cloud Platform resources. |
Bu Sun Kim | 4ed7d3f | 2020-05-27 12:20:54 -0700 | [diff] [blame] | 1778 | "name": "A String", # The optional user-assigned display name of the Project. |
| 1779 | # When present it must be between 4 to 30 characters. |
| 1780 | # Allowed characters are: lowercase and uppercase letters, numbers, |
| 1781 | # hyphen, single-quote, double-quote, space, and exclamation point. |
| 1782 | # |
| 1783 | # Example: <code>My Project</code> |
| 1784 | # Read-write. |
| 1785 | "projectId": "A String", # The unique, user-assigned ID of the Project. |
| 1786 | # It must be 6 to 30 lowercase letters, digits, or hyphens. |
| 1787 | # It must start with a letter. |
| 1788 | # Trailing hyphens are prohibited. |
| 1789 | # |
| 1790 | # Example: <code>tokyo-rain-123</code> |
| 1791 | # Read-only after creation. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1792 | "lifecycleState": "A String", # The Project lifecycle state. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1793 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1794 | # Read-only. |
| 1795 | "projectNumber": "A String", # The number uniquely identifying the project. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1796 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1797 | # Example: <code>415104041262</code> |
| 1798 | # Read-only. |
| 1799 | "parent": { # A container to reference an id for any resource type. A `resource` in Google # An optional reference to a parent Resource. |
| 1800 | # |
| 1801 | # Supported parent types include "organization" and "folder". Once set, the |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1802 | # parent cannot be cleared. The `parent` can be set on creation or using the |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1803 | # `UpdateProject` method; the end user must have the |
| 1804 | # `resourcemanager.projects.create` permission on the parent. |
| 1805 | # |
| 1806 | # Read-write. |
| 1807 | # Cloud Platform is a generic term for something you (a developer) may want to |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1808 | # interact with through one of our API's. Some examples are an App Engine app, |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1809 | # a Compute Engine instance, a Cloud SQL database, and so on. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1810 | "type": "A String", # Required field representing the resource type this id is for. |
| 1811 | # At present, the valid types are "project", "folder", and "organization". |
| 1812 | "id": "A String", # Required field for the type-specific id. This should correspond to the id |
| 1813 | # used in the type-specific API's. |
Takashi Matsuo | 0669410 | 2015-09-11 13:55:40 -0700 | [diff] [blame] | 1814 | }, |
Bu Sun Kim | 4ed7d3f | 2020-05-27 12:20:54 -0700 | [diff] [blame] | 1815 | "createTime": "A String", # Creation time. |
| 1816 | # |
| 1817 | # Read-only. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1818 | "labels": { # The labels associated with this Project. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1819 | # |
| 1820 | # Label keys must be between 1 and 63 characters long and must conform |
| 1821 | # to the following regular expression: \[a-z\](\[-a-z0-9\]*\[a-z0-9\])?. |
| 1822 | # |
| 1823 | # Label values must be between 0 and 63 characters long and must conform |
Bu Sun Kim | 715bd7f | 2019-06-14 16:50:42 -0700 | [diff] [blame] | 1824 | # to the regular expression (\[a-z\](\[-a-z0-9\]*\[a-z0-9\])?)?. A label |
| 1825 | # value can be empty. |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1826 | # |
| 1827 | # No more than 256 labels can be associated with a given resource. |
| 1828 | # |
| 1829 | # Clients should store labels in a representation such as JSON that does not |
| 1830 | # depend on specific characters being disallowed. |
| 1831 | # |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1832 | # Example: <code>"environment" : "dev"</code> |
Jon Wayne Parrott | 692617a | 2017-01-06 09:58:29 -0800 | [diff] [blame] | 1833 | # Read-write. |
Bu Sun Kim | 6502091 | 2020-05-20 12:08:20 -0700 | [diff] [blame] | 1834 | "a_key": "A String", |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 1835 | }, |
Nathaniel Manista | 4f877e5 | 2015-06-15 16:44:50 +0000 | [diff] [blame] | 1836 | }</pre> |
| 1837 | </div> |
| 1838 | |
| 1839 | </body></html> |