1<html><body> 2<style> 3 4body, h1, h2, h3, div, span, p, pre, a { 5 margin: 0; 6 padding: 0; 7 border: 0; 8 font-weight: inherit; 9 font-style: inherit; 10 font-size: 100%; 11 font-family: inherit; 12 vertical-align: baseline; 13} 14 15body { 16 font-size: 13px; 17 padding: 1em; 18} 19 20h1 { 21 font-size: 26px; 22 margin-bottom: 1em; 23} 24 25h2 { 26 font-size: 24px; 27 margin-bottom: 1em; 28} 29 30h3 { 31 font-size: 20px; 32 margin-bottom: 1em; 33 margin-top: 1em; 34} 35 36pre, code { 37 line-height: 1.5; 38 font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace; 39} 40 41pre { 42 margin-top: 0.5em; 43} 44 45h1, h2, h3, p { 46 font-family: Arial, sans serif; 47} 48 49h1, h2, h3 { 50 border-bottom: solid #CCC 1px; 51} 52 53.toc_element { 54 margin-top: 0.5em; 55} 56 57.firstline { 58 margin-left: 2 em; 59} 60 61.method { 62 margin-top: 1em; 63 border: solid 1px #CCC; 64 padding: 1em; 65 background: #EEE; 66} 67 68.details { 69 font-weight: bold; 70 font-size: 14px; 71} 72 73</style> 74 75<h1><a href="storage_v1.html">Cloud Storage JSON API</a> . <a href="storage_v1.buckets.html">buckets</a></h1> 76<h2>Instance Methods</h2> 77<p class="toc_element"> 78 <code><a href="#delete">delete(bucket, ifMetagenerationMatch=None, userProject=None, ifMetagenerationNotMatch=None)</a></code></p> 79<p class="firstline">Permanently deletes an empty bucket.</p> 80<p class="toc_element"> 81 <code><a href="#get">get(bucket, projection=None, ifMetagenerationMatch=None, userProject=None, ifMetagenerationNotMatch=None)</a></code></p> 82<p class="firstline">Returns metadata for the specified bucket.</p> 83<p class="toc_element"> 84 <code><a href="#getIamPolicy">getIamPolicy(bucket, userProject=None)</a></code></p> 85<p class="firstline">Returns an IAM policy for the specified bucket.</p> 86<p class="toc_element"> 87 <code><a href="#insert">insert(project, body, projection=None, predefinedDefaultObjectAcl=None, predefinedAcl=None)</a></code></p> 88<p class="firstline">Creates a new bucket.</p> 89<p class="toc_element"> 90 <code><a href="#list">list(project, projection=None, pageToken=None, prefix=None, maxResults=None)</a></code></p> 91<p class="firstline">Retrieves a list of buckets for a given project.</p> 92<p class="toc_element"> 93 <code><a href="#list_next">list_next(previous_request, previous_response)</a></code></p> 94<p class="firstline">Retrieves the next page of results.</p> 95<p class="toc_element"> 96 <code><a href="#patch">patch(bucket, body, projection=None, ifMetagenerationMatch=None, userProject=None, predefinedDefaultObjectAcl=None, predefinedAcl=None, ifMetagenerationNotMatch=None)</a></code></p> 97<p class="firstline">Updates a bucket. Changes to the bucket will be readable immediately after writing, but configuration changes may take time to propagate. This method supports patch semantics.</p> 98<p class="toc_element"> 99 <code><a href="#setIamPolicy">setIamPolicy(bucket, body, userProject=None)</a></code></p> 100<p class="firstline">Updates an IAM policy for the specified bucket.</p> 101<p class="toc_element"> 102 <code><a href="#testIamPermissions">testIamPermissions(bucket, permissions, userProject=None)</a></code></p> 103<p class="firstline">Tests a set of permissions on the given bucket to see which, if any, are held by the caller.</p> 104<p class="toc_element"> 105 <code><a href="#update">update(bucket, body, projection=None, ifMetagenerationMatch=None, userProject=None, predefinedDefaultObjectAcl=None, predefinedAcl=None, ifMetagenerationNotMatch=None)</a></code></p> 106<p class="firstline">Updates a bucket. Changes to the bucket will be readable immediately after writing, but configuration changes may take time to propagate.</p> 107<h3>Method Details</h3> 108<div class="method"> 109 <code class="details" id="delete">delete(bucket, ifMetagenerationMatch=None, userProject=None, ifMetagenerationNotMatch=None)</code> 110 <pre>Permanently deletes an empty bucket. 111 112Args: 113 bucket: string, Name of a bucket. (required) 114 ifMetagenerationMatch: string, If set, only deletes the bucket if its metageneration matches this value. 115 userProject: string, The project number to be billed for this request, for Requester Pays buckets. 116 ifMetagenerationNotMatch: string, If set, only deletes the bucket if its metageneration does not match this value. 117</pre> 118</div> 119 120<div class="method"> 121 <code class="details" id="get">get(bucket, projection=None, ifMetagenerationMatch=None, userProject=None, ifMetagenerationNotMatch=None)</code> 122 <pre>Returns metadata for the specified bucket. 123 124Args: 125 bucket: string, Name of a bucket. (required) 126 projection: string, Set of properties to return. Defaults to noAcl. 127 Allowed values 128 full - Include all properties. 129 noAcl - Omit owner, acl and defaultObjectAcl properties. 130 ifMetagenerationMatch: string, Makes the return of the bucket metadata conditional on whether the bucket's current metageneration matches the given value. 131 userProject: string, The project number to be billed for this request, for Requester Pays buckets. 132 ifMetagenerationNotMatch: string, Makes the return of the bucket metadata conditional on whether the bucket's current metageneration does not match the given value. 133 134Returns: 135 An object of the form: 136 137 { # A bucket. 138 "website": { # The bucket's website configuration, controlling how the service behaves when accessing bucket contents as a web site. See the Static Website Examples for more information. 139 "notFoundPage": "A String", # If the requested object path is missing, and any mainPageSuffix object is missing, if applicable, the service will return the named object from this bucket as the content for a 404 Not Found result. 140 "mainPageSuffix": "A String", # If the requested object path is missing, the service will ensure the path has a trailing '/', append this suffix, and attempt to retrieve the resulting object. This allows the creation of index.html objects to represent directory pages. 141 }, 142 "metageneration": "A String", # The metadata generation of this bucket. 143 "kind": "storage#bucket", # The kind of item this is. For buckets, this is always storage#bucket. 144 "logging": { # The bucket's logging configuration, which defines the destination bucket and optional name prefix for the current bucket's logs. 145 "logObjectPrefix": "A String", # A prefix for log object names. 146 "logBucket": "A String", # The destination bucket where the current bucket's logs should be placed. 147 }, 148 "name": "A String", # The name of the bucket. 149 "billing": { # The bucket's billing configuration. 150 "requesterPays": True or False, # When set to true, bucket is requester pays. 151 }, 152 "timeCreated": "A String", # The creation time of the bucket in RFC 3339 format. 153 "labels": { # User-provided labels, in key/value pairs. 154 "a_key": "A String", # An individual label entry. 155 }, 156 "updated": "A String", # The modification time of the bucket in RFC 3339 format. 157 "versioning": { # The bucket's versioning configuration. 158 "enabled": True or False, # While set to true, versioning is fully enabled for this bucket. 159 }, 160 "acl": [ # Access controls on the bucket. 161 { # An access-control entry. 162 "domain": "A String", # The domain associated with the entity, if any. 163 "bucket": "A String", # The name of the bucket. 164 "kind": "storage#bucketAccessControl", # The kind of item this is. For bucket access control entries, this is always storage#bucketAccessControl. 165 "entity": "A String", # The entity holding the permission, in one of the following forms: 166 # - user-userId 167 # - user-email 168 # - group-groupId 169 # - group-email 170 # - domain-domain 171 # - project-team-projectId 172 # - allUsers 173 # - allAuthenticatedUsers Examples: 174 # - The user liz@example.com would be user-liz@example.com. 175 # - The group example@googlegroups.com would be group-example@googlegroups.com. 176 # - To refer to all members of the Google Apps for Business domain example.com, the entity would be domain-example.com. 177 "etag": "A String", # HTTP 1.1 Entity tag for the access-control entry. 178 "role": "A String", # The access permission for the entity. 179 "id": "A String", # The ID of the access-control entry. 180 "entityId": "A String", # The ID for the entity, if any. 181 "projectTeam": { # The project team associated with the entity, if any. 182 "projectNumber": "A String", # The project number. 183 "team": "A String", # The team. 184 }, 185 "email": "A String", # The email address associated with the entity, if any. 186 "selfLink": "A String", # The link to this access-control entry. 187 }, 188 ], 189 "defaultObjectAcl": [ # Default access controls to apply to new objects when no ACL is provided. 190 { # An access-control entry. 191 "domain": "A String", # The domain associated with the entity, if any. 192 "generation": "A String", # The content generation of the object, if applied to an object. 193 "object": "A String", # The name of the object, if applied to an object. 194 "bucket": "A String", # The name of the bucket. 195 "kind": "storage#objectAccessControl", # The kind of item this is. For object access control entries, this is always storage#objectAccessControl. 196 "entity": "A String", # The entity holding the permission, in one of the following forms: 197 # - user-userId 198 # - user-email 199 # - group-groupId 200 # - group-email 201 # - domain-domain 202 # - project-team-projectId 203 # - allUsers 204 # - allAuthenticatedUsers Examples: 205 # - The user liz@example.com would be user-liz@example.com. 206 # - The group example@googlegroups.com would be group-example@googlegroups.com. 207 # - To refer to all members of the Google Apps for Business domain example.com, the entity would be domain-example.com. 208 "etag": "A String", # HTTP 1.1 Entity tag for the access-control entry. 209 "role": "A String", # The access permission for the entity. 210 "id": "A String", # The ID of the access-control entry. 211 "entityId": "A String", # The ID for the entity, if any. 212 "projectTeam": { # The project team associated with the entity, if any. 213 "projectNumber": "A String", # The project number. 214 "team": "A String", # The team. 215 }, 216 "email": "A String", # The email address associated with the entity, if any. 217 "selfLink": "A String", # The link to this access-control entry. 218 }, 219 ], 220 "etag": "A String", # HTTP 1.1 Entity tag for the bucket. 221 "location": "A String", # The location of the bucket. Object data for objects in the bucket resides in physical storage within this region. Defaults to US. See the developer's guide for the authoritative list. 222 "cors": [ # The bucket's Cross-Origin Resource Sharing (CORS) configuration. 223 { 224 "origin": [ # The list of Origins eligible to receive CORS response headers. Note: "*" is permitted in the list of origins, and means "any Origin". 225 "A String", 226 ], 227 "responseHeader": [ # The list of HTTP headers other than the simple response headers to give permission for the user-agent to share across domains. 228 "A String", 229 ], 230 "method": [ # The list of HTTP methods on which to include CORS response headers, (GET, OPTIONS, POST, etc) Note: "*" is permitted in the list of methods, and means "any method". 231 "A String", 232 ], 233 "maxAgeSeconds": 42, # The value, in seconds, to return in the Access-Control-Max-Age header used in preflight responses. 234 }, 235 ], 236 "owner": { # The owner of the bucket. This is always the project team's owner group. 237 "entityId": "A String", # The ID for the entity. 238 "entity": "A String", # The entity, in the form project-owner-projectId. 239 }, 240 "lifecycle": { # The bucket's lifecycle configuration. See lifecycle management for more information. 241 "rule": [ # A lifecycle management rule, which is made of an action to take and the condition(s) under which the action will be taken. 242 { 243 "action": { # The action to take. 244 "type": "A String", # Type of the action. Currently, only Delete and SetStorageClass are supported. 245 "storageClass": "A String", # Target storage class. Required iff the type of the action is SetStorageClass. 246 }, 247 "condition": { # The condition(s) under which the action will be taken. 248 "isLive": True or False, # Relevant only for versioned objects. If the value is true, this condition matches live objects; if the value is false, it matches archived objects. 249 "matchesStorageClass": [ # Objects having any of the storage classes specified by this condition will be matched. Values include MULTI_REGIONAL, REGIONAL, NEARLINE, COLDLINE, STANDARD, and DURABLE_REDUCED_AVAILABILITY. 250 "A String", 251 ], 252 "age": 42, # Age of an object (in days). This condition is satisfied when an object reaches the specified age. 253 "numNewerVersions": 42, # Relevant only for versioned objects. If the value is N, this condition is satisfied when there are at least N versions (including the live version) newer than this version of the object. 254 "createdBefore": "A String", # A date in RFC 3339 format with only the date part (for instance, "2013-01-15"). This condition is satisfied when an object is created before midnight of the specified date in UTC. 255 }, 256 }, 257 ], 258 }, 259 "selfLink": "A String", # The URI of this bucket. 260 "id": "A String", # The ID of the bucket. For buckets, the id and name properities are the same. 261 "projectNumber": "A String", # The project number of the project the bucket belongs to. 262 "storageClass": "A String", # The bucket's default storage class, used whenever no storageClass is specified for a newly-created object. This defines how objects in the bucket are stored and determines the SLA and the cost of storage. Values include MULTI_REGIONAL, REGIONAL, STANDARD, NEARLINE, COLDLINE, and DURABLE_REDUCED_AVAILABILITY. If this value is not specified when the bucket is created, it will default to STANDARD. For more information, see storage classes. 263 }</pre> 264</div> 265 266<div class="method"> 267 <code class="details" id="getIamPolicy">getIamPolicy(bucket, userProject=None)</code> 268 <pre>Returns an IAM policy for the specified bucket. 269 270Args: 271 bucket: string, Name of a bucket. (required) 272 userProject: string, The project number to be billed for this request, for Requester Pays buckets. 273 274Returns: 275 An object of the form: 276 277 { # A bucket/object IAM policy. 278 "resourceId": "A String", # The ID of the resource to which this policy belongs. Will be of the form buckets/bucket for buckets, and buckets/bucket/objects/object for objects. A specific generation may be specified by appending #generationNumber to the end of the object name, e.g. buckets/my-bucket/objects/data.txt#17. The current generation can be denoted with #0. This field is ignored on input. 279 "bindings": [ # An association between a role, which comes with a set of permissions, and members who may assume that role. 280 { 281 "role": "A String", # The role to which members belong. Two types of roles are supported: new IAM roles, which grant permissions that do not map directly to those provided by ACLs, and legacy IAM roles, which do map directly to ACL permissions. All roles are of the format roles/storage.specificRole. 282 # The new IAM roles are: 283 # - roles/storage.admin — Full control of Google Cloud Storage resources. 284 # - roles/storage.objectViewer — Read-Only access to Google Cloud Storage objects. 285 # - roles/storage.objectCreator — Access to create objects in Google Cloud Storage. 286 # - roles/storage.objectAdmin — Full control of Google Cloud Storage objects. The legacy IAM roles are: 287 # - roles/storage.legacyObjectReader — Read-only access to objects without listing. Equivalent to an ACL entry on an object with the READER role. 288 # - roles/storage.legacyObjectOwner — Read/write access to existing objects without listing. Equivalent to an ACL entry on an object with the OWNER role. 289 # - roles/storage.legacyBucketReader — Read access to buckets with object listing. Equivalent to an ACL entry on a bucket with the READER role. 290 # - roles/storage.legacyBucketWriter — Read access to buckets with object listing/creation/deletion. Equivalent to an ACL entry on a bucket with the WRITER role. 291 # - roles/storage.legacyBucketOwner — Read and write access to existing buckets with object listing/creation/deletion. Equivalent to an ACL entry on a bucket with the OWNER role. 292 "members": [ # A collection of identifiers for members who may assume the provided role. Recognized identifiers are as follows: 293 # - allUsers — A special identifier that represents anyone on the internet; with or without a Google account. 294 # - allAuthenticatedUsers — A special identifier that represents anyone who is authenticated with a Google account or a service account. 295 # - user:emailid — An email address that represents a specific account. For example, user:alice@gmail.com or user:joe@example.com. 296 # - serviceAccount:emailid — An email address that represents a service account. For example, serviceAccount:my-other-app@appspot.gserviceaccount.com . 297 # - group:emailid — An email address that represents a Google group. For example, group:admins@example.com. 298 # - domain:domain — A Google Apps domain name that represents all the users of that domain. For example, domain:google.com or domain:example.com. 299 # - projectOwner:projectid — Owners of the given project. For example, projectOwner:my-example-project 300 # - projectEditor:projectid — Editors of the given project. For example, projectEditor:my-example-project 301 # - projectViewer:projectid — Viewers of the given project. For example, projectViewer:my-example-project 302 "A String", 303 ], 304 }, 305 ], 306 "etag": "A String", # HTTP 1.1 Entity tag for the policy. 307 "kind": "storage#policy", # The kind of item this is. For policies, this is always storage#policy. This field is ignored on input. 308 }</pre> 309</div> 310 311<div class="method"> 312 <code class="details" id="insert">insert(project, body, projection=None, predefinedDefaultObjectAcl=None, predefinedAcl=None)</code> 313 <pre>Creates a new bucket. 314 315Args: 316 project: string, A valid API project identifier. (required) 317 body: object, The request body. (required) 318 The object takes the form of: 319 320{ # A bucket. 321 "website": { # The bucket's website configuration, controlling how the service behaves when accessing bucket contents as a web site. See the Static Website Examples for more information. 322 "notFoundPage": "A String", # If the requested object path is missing, and any mainPageSuffix object is missing, if applicable, the service will return the named object from this bucket as the content for a 404 Not Found result. 323 "mainPageSuffix": "A String", # If the requested object path is missing, the service will ensure the path has a trailing '/', append this suffix, and attempt to retrieve the resulting object. This allows the creation of index.html objects to represent directory pages. 324 }, 325 "metageneration": "A String", # The metadata generation of this bucket. 326 "kind": "storage#bucket", # The kind of item this is. For buckets, this is always storage#bucket. 327 "logging": { # The bucket's logging configuration, which defines the destination bucket and optional name prefix for the current bucket's logs. 328 "logObjectPrefix": "A String", # A prefix for log object names. 329 "logBucket": "A String", # The destination bucket where the current bucket's logs should be placed. 330 }, 331 "name": "A String", # The name of the bucket. 332 "billing": { # The bucket's billing configuration. 333 "requesterPays": True or False, # When set to true, bucket is requester pays. 334 }, 335 "timeCreated": "A String", # The creation time of the bucket in RFC 3339 format. 336 "labels": { # User-provided labels, in key/value pairs. 337 "a_key": "A String", # An individual label entry. 338 }, 339 "updated": "A String", # The modification time of the bucket in RFC 3339 format. 340 "versioning": { # The bucket's versioning configuration. 341 "enabled": True or False, # While set to true, versioning is fully enabled for this bucket. 342 }, 343 "acl": [ # Access controls on the bucket. 344 { # An access-control entry. 345 "domain": "A String", # The domain associated with the entity, if any. 346 "bucket": "A String", # The name of the bucket. 347 "kind": "storage#bucketAccessControl", # The kind of item this is. For bucket access control entries, this is always storage#bucketAccessControl. 348 "entity": "A String", # The entity holding the permission, in one of the following forms: 349 # - user-userId 350 # - user-email 351 # - group-groupId 352 # - group-email 353 # - domain-domain 354 # - project-team-projectId 355 # - allUsers 356 # - allAuthenticatedUsers Examples: 357 # - The user liz@example.com would be user-liz@example.com. 358 # - The group example@googlegroups.com would be group-example@googlegroups.com. 359 # - To refer to all members of the Google Apps for Business domain example.com, the entity would be domain-example.com. 360 "etag": "A String", # HTTP 1.1 Entity tag for the access-control entry. 361 "role": "A String", # The access permission for the entity. 362 "id": "A String", # The ID of the access-control entry. 363 "entityId": "A String", # The ID for the entity, if any. 364 "projectTeam": { # The project team associated with the entity, if any. 365 "projectNumber": "A String", # The project number. 366 "team": "A String", # The team. 367 }, 368 "email": "A String", # The email address associated with the entity, if any. 369 "selfLink": "A String", # The link to this access-control entry. 370 }, 371 ], 372 "defaultObjectAcl": [ # Default access controls to apply to new objects when no ACL is provided. 373 { # An access-control entry. 374 "domain": "A String", # The domain associated with the entity, if any. 375 "generation": "A String", # The content generation of the object, if applied to an object. 376 "object": "A String", # The name of the object, if applied to an object. 377 "bucket": "A String", # The name of the bucket. 378 "kind": "storage#objectAccessControl", # The kind of item this is. For object access control entries, this is always storage#objectAccessControl. 379 "entity": "A String", # The entity holding the permission, in one of the following forms: 380 # - user-userId 381 # - user-email 382 # - group-groupId 383 # - group-email 384 # - domain-domain 385 # - project-team-projectId 386 # - allUsers 387 # - allAuthenticatedUsers Examples: 388 # - The user liz@example.com would be user-liz@example.com. 389 # - The group example@googlegroups.com would be group-example@googlegroups.com. 390 # - To refer to all members of the Google Apps for Business domain example.com, the entity would be domain-example.com. 391 "etag": "A String", # HTTP 1.1 Entity tag for the access-control entry. 392 "role": "A String", # The access permission for the entity. 393 "id": "A String", # The ID of the access-control entry. 394 "entityId": "A String", # The ID for the entity, if any. 395 "projectTeam": { # The project team associated with the entity, if any. 396 "projectNumber": "A String", # The project number. 397 "team": "A String", # The team. 398 }, 399 "email": "A String", # The email address associated with the entity, if any. 400 "selfLink": "A String", # The link to this access-control entry. 401 }, 402 ], 403 "etag": "A String", # HTTP 1.1 Entity tag for the bucket. 404 "location": "A String", # The location of the bucket. Object data for objects in the bucket resides in physical storage within this region. Defaults to US. See the developer's guide for the authoritative list. 405 "cors": [ # The bucket's Cross-Origin Resource Sharing (CORS) configuration. 406 { 407 "origin": [ # The list of Origins eligible to receive CORS response headers. Note: "*" is permitted in the list of origins, and means "any Origin". 408 "A String", 409 ], 410 "responseHeader": [ # The list of HTTP headers other than the simple response headers to give permission for the user-agent to share across domains. 411 "A String", 412 ], 413 "method": [ # The list of HTTP methods on which to include CORS response headers, (GET, OPTIONS, POST, etc) Note: "*" is permitted in the list of methods, and means "any method". 414 "A String", 415 ], 416 "maxAgeSeconds": 42, # The value, in seconds, to return in the Access-Control-Max-Age header used in preflight responses. 417 }, 418 ], 419 "owner": { # The owner of the bucket. This is always the project team's owner group. 420 "entityId": "A String", # The ID for the entity. 421 "entity": "A String", # The entity, in the form project-owner-projectId. 422 }, 423 "lifecycle": { # The bucket's lifecycle configuration. See lifecycle management for more information. 424 "rule": [ # A lifecycle management rule, which is made of an action to take and the condition(s) under which the action will be taken. 425 { 426 "action": { # The action to take. 427 "type": "A String", # Type of the action. Currently, only Delete and SetStorageClass are supported. 428 "storageClass": "A String", # Target storage class. Required iff the type of the action is SetStorageClass. 429 }, 430 "condition": { # The condition(s) under which the action will be taken. 431 "isLive": True or False, # Relevant only for versioned objects. If the value is true, this condition matches live objects; if the value is false, it matches archived objects. 432 "matchesStorageClass": [ # Objects having any of the storage classes specified by this condition will be matched. Values include MULTI_REGIONAL, REGIONAL, NEARLINE, COLDLINE, STANDARD, and DURABLE_REDUCED_AVAILABILITY. 433 "A String", 434 ], 435 "age": 42, # Age of an object (in days). This condition is satisfied when an object reaches the specified age. 436 "numNewerVersions": 42, # Relevant only for versioned objects. If the value is N, this condition is satisfied when there are at least N versions (including the live version) newer than this version of the object. 437 "createdBefore": "A String", # A date in RFC 3339 format with only the date part (for instance, "2013-01-15"). This condition is satisfied when an object is created before midnight of the specified date in UTC. 438 }, 439 }, 440 ], 441 }, 442 "selfLink": "A String", # The URI of this bucket. 443 "id": "A String", # The ID of the bucket. For buckets, the id and name properities are the same. 444 "projectNumber": "A String", # The project number of the project the bucket belongs to. 445 "storageClass": "A String", # The bucket's default storage class, used whenever no storageClass is specified for a newly-created object. This defines how objects in the bucket are stored and determines the SLA and the cost of storage. Values include MULTI_REGIONAL, REGIONAL, STANDARD, NEARLINE, COLDLINE, and DURABLE_REDUCED_AVAILABILITY. If this value is not specified when the bucket is created, it will default to STANDARD. For more information, see storage classes. 446 } 447 448 projection: string, Set of properties to return. Defaults to noAcl, unless the bucket resource specifies acl or defaultObjectAcl properties, when it defaults to full. 449 Allowed values 450 full - Include all properties. 451 noAcl - Omit owner, acl and defaultObjectAcl properties. 452 predefinedDefaultObjectAcl: string, Apply a predefined set of default object access controls to this bucket. 453 Allowed values 454 authenticatedRead - Object owner gets OWNER access, and allAuthenticatedUsers get READER access. 455 bucketOwnerFullControl - Object owner gets OWNER access, and project team owners get OWNER access. 456 bucketOwnerRead - Object owner gets OWNER access, and project team owners get READER access. 457 private - Object owner gets OWNER access. 458 projectPrivate - Object owner gets OWNER access, and project team members get access according to their roles. 459 publicRead - Object owner gets OWNER access, and allUsers get READER access. 460 predefinedAcl: string, Apply a predefined set of access controls to this bucket. 461 Allowed values 462 authenticatedRead - Project team owners get OWNER access, and allAuthenticatedUsers get READER access. 463 private - Project team owners get OWNER access. 464 projectPrivate - Project team members get access according to their roles. 465 publicRead - Project team owners get OWNER access, and allUsers get READER access. 466 publicReadWrite - Project team owners get OWNER access, and allUsers get WRITER access. 467 468Returns: 469 An object of the form: 470 471 { # A bucket. 472 "website": { # The bucket's website configuration, controlling how the service behaves when accessing bucket contents as a web site. See the Static Website Examples for more information. 473 "notFoundPage": "A String", # If the requested object path is missing, and any mainPageSuffix object is missing, if applicable, the service will return the named object from this bucket as the content for a 404 Not Found result. 474 "mainPageSuffix": "A String", # If the requested object path is missing, the service will ensure the path has a trailing '/', append this suffix, and attempt to retrieve the resulting object. This allows the creation of index.html objects to represent directory pages. 475 }, 476 "metageneration": "A String", # The metadata generation of this bucket. 477 "kind": "storage#bucket", # The kind of item this is. For buckets, this is always storage#bucket. 478 "logging": { # The bucket's logging configuration, which defines the destination bucket and optional name prefix for the current bucket's logs. 479 "logObjectPrefix": "A String", # A prefix for log object names. 480 "logBucket": "A String", # The destination bucket where the current bucket's logs should be placed. 481 }, 482 "name": "A String", # The name of the bucket. 483 "billing": { # The bucket's billing configuration. 484 "requesterPays": True or False, # When set to true, bucket is requester pays. 485 }, 486 "timeCreated": "A String", # The creation time of the bucket in RFC 3339 format. 487 "labels": { # User-provided labels, in key/value pairs. 488 "a_key": "A String", # An individual label entry. 489 }, 490 "updated": "A String", # The modification time of the bucket in RFC 3339 format. 491 "versioning": { # The bucket's versioning configuration. 492 "enabled": True or False, # While set to true, versioning is fully enabled for this bucket. 493 }, 494 "acl": [ # Access controls on the bucket. 495 { # An access-control entry. 496 "domain": "A String", # The domain associated with the entity, if any. 497 "bucket": "A String", # The name of the bucket. 498 "kind": "storage#bucketAccessControl", # The kind of item this is. For bucket access control entries, this is always storage#bucketAccessControl. 499 "entity": "A String", # The entity holding the permission, in one of the following forms: 500 # - user-userId 501 # - user-email 502 # - group-groupId 503 # - group-email 504 # - domain-domain 505 # - project-team-projectId 506 # - allUsers 507 # - allAuthenticatedUsers Examples: 508 # - The user liz@example.com would be user-liz@example.com. 509 # - The group example@googlegroups.com would be group-example@googlegroups.com. 510 # - To refer to all members of the Google Apps for Business domain example.com, the entity would be domain-example.com. 511 "etag": "A String", # HTTP 1.1 Entity tag for the access-control entry. 512 "role": "A String", # The access permission for the entity. 513 "id": "A String", # The ID of the access-control entry. 514 "entityId": "A String", # The ID for the entity, if any. 515 "projectTeam": { # The project team associated with the entity, if any. 516 "projectNumber": "A String", # The project number. 517 "team": "A String", # The team. 518 }, 519 "email": "A String", # The email address associated with the entity, if any. 520 "selfLink": "A String", # The link to this access-control entry. 521 }, 522 ], 523 "defaultObjectAcl": [ # Default access controls to apply to new objects when no ACL is provided. 524 { # An access-control entry. 525 "domain": "A String", # The domain associated with the entity, if any. 526 "generation": "A String", # The content generation of the object, if applied to an object. 527 "object": "A String", # The name of the object, if applied to an object. 528 "bucket": "A String", # The name of the bucket. 529 "kind": "storage#objectAccessControl", # The kind of item this is. For object access control entries, this is always storage#objectAccessControl. 530 "entity": "A String", # The entity holding the permission, in one of the following forms: 531 # - user-userId 532 # - user-email 533 # - group-groupId 534 # - group-email 535 # - domain-domain 536 # - project-team-projectId 537 # - allUsers 538 # - allAuthenticatedUsers Examples: 539 # - The user liz@example.com would be user-liz@example.com. 540 # - The group example@googlegroups.com would be group-example@googlegroups.com. 541 # - To refer to all members of the Google Apps for Business domain example.com, the entity would be domain-example.com. 542 "etag": "A String", # HTTP 1.1 Entity tag for the access-control entry. 543 "role": "A String", # The access permission for the entity. 544 "id": "A String", # The ID of the access-control entry. 545 "entityId": "A String", # The ID for the entity, if any. 546 "projectTeam": { # The project team associated with the entity, if any. 547 "projectNumber": "A String", # The project number. 548 "team": "A String", # The team. 549 }, 550 "email": "A String", # The email address associated with the entity, if any. 551 "selfLink": "A String", # The link to this access-control entry. 552 }, 553 ], 554 "etag": "A String", # HTTP 1.1 Entity tag for the bucket. 555 "location": "A String", # The location of the bucket. Object data for objects in the bucket resides in physical storage within this region. Defaults to US. See the developer's guide for the authoritative list. 556 "cors": [ # The bucket's Cross-Origin Resource Sharing (CORS) configuration. 557 { 558 "origin": [ # The list of Origins eligible to receive CORS response headers. Note: "*" is permitted in the list of origins, and means "any Origin". 559 "A String", 560 ], 561 "responseHeader": [ # The list of HTTP headers other than the simple response headers to give permission for the user-agent to share across domains. 562 "A String", 563 ], 564 "method": [ # The list of HTTP methods on which to include CORS response headers, (GET, OPTIONS, POST, etc) Note: "*" is permitted in the list of methods, and means "any method". 565 "A String", 566 ], 567 "maxAgeSeconds": 42, # The value, in seconds, to return in the Access-Control-Max-Age header used in preflight responses. 568 }, 569 ], 570 "owner": { # The owner of the bucket. This is always the project team's owner group. 571 "entityId": "A String", # The ID for the entity. 572 "entity": "A String", # The entity, in the form project-owner-projectId. 573 }, 574 "lifecycle": { # The bucket's lifecycle configuration. See lifecycle management for more information. 575 "rule": [ # A lifecycle management rule, which is made of an action to take and the condition(s) under which the action will be taken. 576 { 577 "action": { # The action to take. 578 "type": "A String", # Type of the action. Currently, only Delete and SetStorageClass are supported. 579 "storageClass": "A String", # Target storage class. Required iff the type of the action is SetStorageClass. 580 }, 581 "condition": { # The condition(s) under which the action will be taken. 582 "isLive": True or False, # Relevant only for versioned objects. If the value is true, this condition matches live objects; if the value is false, it matches archived objects. 583 "matchesStorageClass": [ # Objects having any of the storage classes specified by this condition will be matched. Values include MULTI_REGIONAL, REGIONAL, NEARLINE, COLDLINE, STANDARD, and DURABLE_REDUCED_AVAILABILITY. 584 "A String", 585 ], 586 "age": 42, # Age of an object (in days). This condition is satisfied when an object reaches the specified age. 587 "numNewerVersions": 42, # Relevant only for versioned objects. If the value is N, this condition is satisfied when there are at least N versions (including the live version) newer than this version of the object. 588 "createdBefore": "A String", # A date in RFC 3339 format with only the date part (for instance, "2013-01-15"). This condition is satisfied when an object is created before midnight of the specified date in UTC. 589 }, 590 }, 591 ], 592 }, 593 "selfLink": "A String", # The URI of this bucket. 594 "id": "A String", # The ID of the bucket. For buckets, the id and name properities are the same. 595 "projectNumber": "A String", # The project number of the project the bucket belongs to. 596 "storageClass": "A String", # The bucket's default storage class, used whenever no storageClass is specified for a newly-created object. This defines how objects in the bucket are stored and determines the SLA and the cost of storage. Values include MULTI_REGIONAL, REGIONAL, STANDARD, NEARLINE, COLDLINE, and DURABLE_REDUCED_AVAILABILITY. If this value is not specified when the bucket is created, it will default to STANDARD. For more information, see storage classes. 597 }</pre> 598</div> 599 600<div class="method"> 601 <code class="details" id="list">list(project, projection=None, pageToken=None, prefix=None, maxResults=None)</code> 602 <pre>Retrieves a list of buckets for a given project. 603 604Args: 605 project: string, A valid API project identifier. (required) 606 projection: string, Set of properties to return. Defaults to noAcl. 607 Allowed values 608 full - Include all properties. 609 noAcl - Omit owner, acl and defaultObjectAcl properties. 610 pageToken: string, A previously-returned page token representing part of the larger set of results to view. 611 prefix: string, Filter results to buckets whose names begin with this prefix. 612 maxResults: integer, Maximum number of buckets to return in a single response. The service will use this parameter or 1,000 items, whichever is smaller. 613 614Returns: 615 An object of the form: 616 617 { # A list of buckets. 618 "nextPageToken": "A String", # The continuation token, used to page through large result sets. Provide this value in a subsequent request to return the next page of results. 619 "items": [ # The list of items. 620 { # A bucket. 621 "website": { # The bucket's website configuration, controlling how the service behaves when accessing bucket contents as a web site. See the Static Website Examples for more information. 622 "notFoundPage": "A String", # If the requested object path is missing, and any mainPageSuffix object is missing, if applicable, the service will return the named object from this bucket as the content for a 404 Not Found result. 623 "mainPageSuffix": "A String", # If the requested object path is missing, the service will ensure the path has a trailing '/', append this suffix, and attempt to retrieve the resulting object. This allows the creation of index.html objects to represent directory pages. 624 }, 625 "metageneration": "A String", # The metadata generation of this bucket. 626 "kind": "storage#bucket", # The kind of item this is. For buckets, this is always storage#bucket. 627 "logging": { # The bucket's logging configuration, which defines the destination bucket and optional name prefix for the current bucket's logs. 628 "logObjectPrefix": "A String", # A prefix for log object names. 629 "logBucket": "A String", # The destination bucket where the current bucket's logs should be placed. 630 }, 631 "name": "A String", # The name of the bucket. 632 "billing": { # The bucket's billing configuration. 633 "requesterPays": True or False, # When set to true, bucket is requester pays. 634 }, 635 "timeCreated": "A String", # The creation time of the bucket in RFC 3339 format. 636 "labels": { # User-provided labels, in key/value pairs. 637 "a_key": "A String", # An individual label entry. 638 }, 639 "updated": "A String", # The modification time of the bucket in RFC 3339 format. 640 "versioning": { # The bucket's versioning configuration. 641 "enabled": True or False, # While set to true, versioning is fully enabled for this bucket. 642 }, 643 "acl": [ # Access controls on the bucket. 644 { # An access-control entry. 645 "domain": "A String", # The domain associated with the entity, if any. 646 "bucket": "A String", # The name of the bucket. 647 "kind": "storage#bucketAccessControl", # The kind of item this is. For bucket access control entries, this is always storage#bucketAccessControl. 648 "entity": "A String", # The entity holding the permission, in one of the following forms: 649 # - user-userId 650 # - user-email 651 # - group-groupId 652 # - group-email 653 # - domain-domain 654 # - project-team-projectId 655 # - allUsers 656 # - allAuthenticatedUsers Examples: 657 # - The user liz@example.com would be user-liz@example.com. 658 # - The group example@googlegroups.com would be group-example@googlegroups.com. 659 # - To refer to all members of the Google Apps for Business domain example.com, the entity would be domain-example.com. 660 "etag": "A String", # HTTP 1.1 Entity tag for the access-control entry. 661 "role": "A String", # The access permission for the entity. 662 "id": "A String", # The ID of the access-control entry. 663 "entityId": "A String", # The ID for the entity, if any. 664 "projectTeam": { # The project team associated with the entity, if any. 665 "projectNumber": "A String", # The project number. 666 "team": "A String", # The team. 667 }, 668 "email": "A String", # The email address associated with the entity, if any. 669 "selfLink": "A String", # The link to this access-control entry. 670 }, 671 ], 672 "defaultObjectAcl": [ # Default access controls to apply to new objects when no ACL is provided. 673 { # An access-control entry. 674 "domain": "A String", # The domain associated with the entity, if any. 675 "generation": "A String", # The content generation of the object, if applied to an object. 676 "object": "A String", # The name of the object, if applied to an object. 677 "bucket": "A String", # The name of the bucket. 678 "kind": "storage#objectAccessControl", # The kind of item this is. For object access control entries, this is always storage#objectAccessControl. 679 "entity": "A String", # The entity holding the permission, in one of the following forms: 680 # - user-userId 681 # - user-email 682 # - group-groupId 683 # - group-email 684 # - domain-domain 685 # - project-team-projectId 686 # - allUsers 687 # - allAuthenticatedUsers Examples: 688 # - The user liz@example.com would be user-liz@example.com. 689 # - The group example@googlegroups.com would be group-example@googlegroups.com. 690 # - To refer to all members of the Google Apps for Business domain example.com, the entity would be domain-example.com. 691 "etag": "A String", # HTTP 1.1 Entity tag for the access-control entry. 692 "role": "A String", # The access permission for the entity. 693 "id": "A String", # The ID of the access-control entry. 694 "entityId": "A String", # The ID for the entity, if any. 695 "projectTeam": { # The project team associated with the entity, if any. 696 "projectNumber": "A String", # The project number. 697 "team": "A String", # The team. 698 }, 699 "email": "A String", # The email address associated with the entity, if any. 700 "selfLink": "A String", # The link to this access-control entry. 701 }, 702 ], 703 "etag": "A String", # HTTP 1.1 Entity tag for the bucket. 704 "location": "A String", # The location of the bucket. Object data for objects in the bucket resides in physical storage within this region. Defaults to US. See the developer's guide for the authoritative list. 705 "cors": [ # The bucket's Cross-Origin Resource Sharing (CORS) configuration. 706 { 707 "origin": [ # The list of Origins eligible to receive CORS response headers. Note: "*" is permitted in the list of origins, and means "any Origin". 708 "A String", 709 ], 710 "responseHeader": [ # The list of HTTP headers other than the simple response headers to give permission for the user-agent to share across domains. 711 "A String", 712 ], 713 "method": [ # The list of HTTP methods on which to include CORS response headers, (GET, OPTIONS, POST, etc) Note: "*" is permitted in the list of methods, and means "any method". 714 "A String", 715 ], 716 "maxAgeSeconds": 42, # The value, in seconds, to return in the Access-Control-Max-Age header used in preflight responses. 717 }, 718 ], 719 "owner": { # The owner of the bucket. This is always the project team's owner group. 720 "entityId": "A String", # The ID for the entity. 721 "entity": "A String", # The entity, in the form project-owner-projectId. 722 }, 723 "lifecycle": { # The bucket's lifecycle configuration. See lifecycle management for more information. 724 "rule": [ # A lifecycle management rule, which is made of an action to take and the condition(s) under which the action will be taken. 725 { 726 "action": { # The action to take. 727 "type": "A String", # Type of the action. Currently, only Delete and SetStorageClass are supported. 728 "storageClass": "A String", # Target storage class. Required iff the type of the action is SetStorageClass. 729 }, 730 "condition": { # The condition(s) under which the action will be taken. 731 "isLive": True or False, # Relevant only for versioned objects. If the value is true, this condition matches live objects; if the value is false, it matches archived objects. 732 "matchesStorageClass": [ # Objects having any of the storage classes specified by this condition will be matched. Values include MULTI_REGIONAL, REGIONAL, NEARLINE, COLDLINE, STANDARD, and DURABLE_REDUCED_AVAILABILITY. 733 "A String", 734 ], 735 "age": 42, # Age of an object (in days). This condition is satisfied when an object reaches the specified age. 736 "numNewerVersions": 42, # Relevant only for versioned objects. If the value is N, this condition is satisfied when there are at least N versions (including the live version) newer than this version of the object. 737 "createdBefore": "A String", # A date in RFC 3339 format with only the date part (for instance, "2013-01-15"). This condition is satisfied when an object is created before midnight of the specified date in UTC. 738 }, 739 }, 740 ], 741 }, 742 "selfLink": "A String", # The URI of this bucket. 743 "id": "A String", # The ID of the bucket. For buckets, the id and name properities are the same. 744 "projectNumber": "A String", # The project number of the project the bucket belongs to. 745 "storageClass": "A String", # The bucket's default storage class, used whenever no storageClass is specified for a newly-created object. This defines how objects in the bucket are stored and determines the SLA and the cost of storage. Values include MULTI_REGIONAL, REGIONAL, STANDARD, NEARLINE, COLDLINE, and DURABLE_REDUCED_AVAILABILITY. If this value is not specified when the bucket is created, it will default to STANDARD. For more information, see storage classes. 746 }, 747 ], 748 "kind": "storage#buckets", # The kind of item this is. For lists of buckets, this is always storage#buckets. 749 }</pre> 750</div> 751 752<div class="method"> 753 <code class="details" id="list_next">list_next(previous_request, previous_response)</code> 754 <pre>Retrieves the next page of results. 755 756Args: 757 previous_request: The request for the previous page. (required) 758 previous_response: The response from the request for the previous page. (required) 759 760Returns: 761 A request object that you can call 'execute()' on to request the next 762 page. Returns None if there are no more items in the collection. 763 </pre> 764</div> 765 766<div class="method"> 767 <code class="details" id="patch">patch(bucket, body, projection=None, ifMetagenerationMatch=None, userProject=None, predefinedDefaultObjectAcl=None, predefinedAcl=None, ifMetagenerationNotMatch=None)</code> 768 <pre>Updates a bucket. Changes to the bucket will be readable immediately after writing, but configuration changes may take time to propagate. This method supports patch semantics. 769 770Args: 771 bucket: string, Name of a bucket. (required) 772 body: object, The request body. (required) 773 The object takes the form of: 774 775{ # A bucket. 776 "website": { # The bucket's website configuration, controlling how the service behaves when accessing bucket contents as a web site. See the Static Website Examples for more information. 777 "notFoundPage": "A String", # If the requested object path is missing, and any mainPageSuffix object is missing, if applicable, the service will return the named object from this bucket as the content for a 404 Not Found result. 778 "mainPageSuffix": "A String", # If the requested object path is missing, the service will ensure the path has a trailing '/', append this suffix, and attempt to retrieve the resulting object. This allows the creation of index.html objects to represent directory pages. 779 }, 780 "metageneration": "A String", # The metadata generation of this bucket. 781 "kind": "storage#bucket", # The kind of item this is. For buckets, this is always storage#bucket. 782 "logging": { # The bucket's logging configuration, which defines the destination bucket and optional name prefix for the current bucket's logs. 783 "logObjectPrefix": "A String", # A prefix for log object names. 784 "logBucket": "A String", # The destination bucket where the current bucket's logs should be placed. 785 }, 786 "name": "A String", # The name of the bucket. 787 "billing": { # The bucket's billing configuration. 788 "requesterPays": True or False, # When set to true, bucket is requester pays. 789 }, 790 "timeCreated": "A String", # The creation time of the bucket in RFC 3339 format. 791 "labels": { # User-provided labels, in key/value pairs. 792 "a_key": "A String", # An individual label entry. 793 }, 794 "updated": "A String", # The modification time of the bucket in RFC 3339 format. 795 "versioning": { # The bucket's versioning configuration. 796 "enabled": True or False, # While set to true, versioning is fully enabled for this bucket. 797 }, 798 "acl": [ # Access controls on the bucket. 799 { # An access-control entry. 800 "domain": "A String", # The domain associated with the entity, if any. 801 "bucket": "A String", # The name of the bucket. 802 "kind": "storage#bucketAccessControl", # The kind of item this is. For bucket access control entries, this is always storage#bucketAccessControl. 803 "entity": "A String", # The entity holding the permission, in one of the following forms: 804 # - user-userId 805 # - user-email 806 # - group-groupId 807 # - group-email 808 # - domain-domain 809 # - project-team-projectId 810 # - allUsers 811 # - allAuthenticatedUsers Examples: 812 # - The user liz@example.com would be user-liz@example.com. 813 # - The group example@googlegroups.com would be group-example@googlegroups.com. 814 # - To refer to all members of the Google Apps for Business domain example.com, the entity would be domain-example.com. 815 "etag": "A String", # HTTP 1.1 Entity tag for the access-control entry. 816 "role": "A String", # The access permission for the entity. 817 "id": "A String", # The ID of the access-control entry. 818 "entityId": "A String", # The ID for the entity, if any. 819 "projectTeam": { # The project team associated with the entity, if any. 820 "projectNumber": "A String", # The project number. 821 "team": "A String", # The team. 822 }, 823 "email": "A String", # The email address associated with the entity, if any. 824 "selfLink": "A String", # The link to this access-control entry. 825 }, 826 ], 827 "defaultObjectAcl": [ # Default access controls to apply to new objects when no ACL is provided. 828 { # An access-control entry. 829 "domain": "A String", # The domain associated with the entity, if any. 830 "generation": "A String", # The content generation of the object, if applied to an object. 831 "object": "A String", # The name of the object, if applied to an object. 832 "bucket": "A String", # The name of the bucket. 833 "kind": "storage#objectAccessControl", # The kind of item this is. For object access control entries, this is always storage#objectAccessControl. 834 "entity": "A String", # The entity holding the permission, in one of the following forms: 835 # - user-userId 836 # - user-email 837 # - group-groupId 838 # - group-email 839 # - domain-domain 840 # - project-team-projectId 841 # - allUsers 842 # - allAuthenticatedUsers Examples: 843 # - The user liz@example.com would be user-liz@example.com. 844 # - The group example@googlegroups.com would be group-example@googlegroups.com. 845 # - To refer to all members of the Google Apps for Business domain example.com, the entity would be domain-example.com. 846 "etag": "A String", # HTTP 1.1 Entity tag for the access-control entry. 847 "role": "A String", # The access permission for the entity. 848 "id": "A String", # The ID of the access-control entry. 849 "entityId": "A String", # The ID for the entity, if any. 850 "projectTeam": { # The project team associated with the entity, if any. 851 "projectNumber": "A String", # The project number. 852 "team": "A String", # The team. 853 }, 854 "email": "A String", # The email address associated with the entity, if any. 855 "selfLink": "A String", # The link to this access-control entry. 856 }, 857 ], 858 "etag": "A String", # HTTP 1.1 Entity tag for the bucket. 859 "location": "A String", # The location of the bucket. Object data for objects in the bucket resides in physical storage within this region. Defaults to US. See the developer's guide for the authoritative list. 860 "cors": [ # The bucket's Cross-Origin Resource Sharing (CORS) configuration. 861 { 862 "origin": [ # The list of Origins eligible to receive CORS response headers. Note: "*" is permitted in the list of origins, and means "any Origin". 863 "A String", 864 ], 865 "responseHeader": [ # The list of HTTP headers other than the simple response headers to give permission for the user-agent to share across domains. 866 "A String", 867 ], 868 "method": [ # The list of HTTP methods on which to include CORS response headers, (GET, OPTIONS, POST, etc) Note: "*" is permitted in the list of methods, and means "any method". 869 "A String", 870 ], 871 "maxAgeSeconds": 42, # The value, in seconds, to return in the Access-Control-Max-Age header used in preflight responses. 872 }, 873 ], 874 "owner": { # The owner of the bucket. This is always the project team's owner group. 875 "entityId": "A String", # The ID for the entity. 876 "entity": "A String", # The entity, in the form project-owner-projectId. 877 }, 878 "lifecycle": { # The bucket's lifecycle configuration. See lifecycle management for more information. 879 "rule": [ # A lifecycle management rule, which is made of an action to take and the condition(s) under which the action will be taken. 880 { 881 "action": { # The action to take. 882 "type": "A String", # Type of the action. Currently, only Delete and SetStorageClass are supported. 883 "storageClass": "A String", # Target storage class. Required iff the type of the action is SetStorageClass. 884 }, 885 "condition": { # The condition(s) under which the action will be taken. 886 "isLive": True or False, # Relevant only for versioned objects. If the value is true, this condition matches live objects; if the value is false, it matches archived objects. 887 "matchesStorageClass": [ # Objects having any of the storage classes specified by this condition will be matched. Values include MULTI_REGIONAL, REGIONAL, NEARLINE, COLDLINE, STANDARD, and DURABLE_REDUCED_AVAILABILITY. 888 "A String", 889 ], 890 "age": 42, # Age of an object (in days). This condition is satisfied when an object reaches the specified age. 891 "numNewerVersions": 42, # Relevant only for versioned objects. If the value is N, this condition is satisfied when there are at least N versions (including the live version) newer than this version of the object. 892 "createdBefore": "A String", # A date in RFC 3339 format with only the date part (for instance, "2013-01-15"). This condition is satisfied when an object is created before midnight of the specified date in UTC. 893 }, 894 }, 895 ], 896 }, 897 "selfLink": "A String", # The URI of this bucket. 898 "id": "A String", # The ID of the bucket. For buckets, the id and name properities are the same. 899 "projectNumber": "A String", # The project number of the project the bucket belongs to. 900 "storageClass": "A String", # The bucket's default storage class, used whenever no storageClass is specified for a newly-created object. This defines how objects in the bucket are stored and determines the SLA and the cost of storage. Values include MULTI_REGIONAL, REGIONAL, STANDARD, NEARLINE, COLDLINE, and DURABLE_REDUCED_AVAILABILITY. If this value is not specified when the bucket is created, it will default to STANDARD. For more information, see storage classes. 901 } 902 903 projection: string, Set of properties to return. Defaults to full. 904 Allowed values 905 full - Include all properties. 906 noAcl - Omit owner, acl and defaultObjectAcl properties. 907 ifMetagenerationMatch: string, Makes the return of the bucket metadata conditional on whether the bucket's current metageneration matches the given value. 908 userProject: string, The project number to be billed for this request, for Requester Pays buckets. 909 predefinedDefaultObjectAcl: string, Apply a predefined set of default object access controls to this bucket. 910 Allowed values 911 authenticatedRead - Object owner gets OWNER access, and allAuthenticatedUsers get READER access. 912 bucketOwnerFullControl - Object owner gets OWNER access, and project team owners get OWNER access. 913 bucketOwnerRead - Object owner gets OWNER access, and project team owners get READER access. 914 private - Object owner gets OWNER access. 915 projectPrivate - Object owner gets OWNER access, and project team members get access according to their roles. 916 publicRead - Object owner gets OWNER access, and allUsers get READER access. 917 predefinedAcl: string, Apply a predefined set of access controls to this bucket. 918 Allowed values 919 authenticatedRead - Project team owners get OWNER access, and allAuthenticatedUsers get READER access. 920 private - Project team owners get OWNER access. 921 projectPrivate - Project team members get access according to their roles. 922 publicRead - Project team owners get OWNER access, and allUsers get READER access. 923 publicReadWrite - Project team owners get OWNER access, and allUsers get WRITER access. 924 ifMetagenerationNotMatch: string, Makes the return of the bucket metadata conditional on whether the bucket's current metageneration does not match the given value. 925 926Returns: 927 An object of the form: 928 929 { # A bucket. 930 "website": { # The bucket's website configuration, controlling how the service behaves when accessing bucket contents as a web site. See the Static Website Examples for more information. 931 "notFoundPage": "A String", # If the requested object path is missing, and any mainPageSuffix object is missing, if applicable, the service will return the named object from this bucket as the content for a 404 Not Found result. 932 "mainPageSuffix": "A String", # If the requested object path is missing, the service will ensure the path has a trailing '/', append this suffix, and attempt to retrieve the resulting object. This allows the creation of index.html objects to represent directory pages. 933 }, 934 "metageneration": "A String", # The metadata generation of this bucket. 935 "kind": "storage#bucket", # The kind of item this is. For buckets, this is always storage#bucket. 936 "logging": { # The bucket's logging configuration, which defines the destination bucket and optional name prefix for the current bucket's logs. 937 "logObjectPrefix": "A String", # A prefix for log object names. 938 "logBucket": "A String", # The destination bucket where the current bucket's logs should be placed. 939 }, 940 "name": "A String", # The name of the bucket. 941 "billing": { # The bucket's billing configuration. 942 "requesterPays": True or False, # When set to true, bucket is requester pays. 943 }, 944 "timeCreated": "A String", # The creation time of the bucket in RFC 3339 format. 945 "labels": { # User-provided labels, in key/value pairs. 946 "a_key": "A String", # An individual label entry. 947 }, 948 "updated": "A String", # The modification time of the bucket in RFC 3339 format. 949 "versioning": { # The bucket's versioning configuration. 950 "enabled": True or False, # While set to true, versioning is fully enabled for this bucket. 951 }, 952 "acl": [ # Access controls on the bucket. 953 { # An access-control entry. 954 "domain": "A String", # The domain associated with the entity, if any. 955 "bucket": "A String", # The name of the bucket. 956 "kind": "storage#bucketAccessControl", # The kind of item this is. For bucket access control entries, this is always storage#bucketAccessControl. 957 "entity": "A String", # The entity holding the permission, in one of the following forms: 958 # - user-userId 959 # - user-email 960 # - group-groupId 961 # - group-email 962 # - domain-domain 963 # - project-team-projectId 964 # - allUsers 965 # - allAuthenticatedUsers Examples: 966 # - The user liz@example.com would be user-liz@example.com. 967 # - The group example@googlegroups.com would be group-example@googlegroups.com. 968 # - To refer to all members of the Google Apps for Business domain example.com, the entity would be domain-example.com. 969 "etag": "A String", # HTTP 1.1 Entity tag for the access-control entry. 970 "role": "A String", # The access permission for the entity. 971 "id": "A String", # The ID of the access-control entry. 972 "entityId": "A String", # The ID for the entity, if any. 973 "projectTeam": { # The project team associated with the entity, if any. 974 "projectNumber": "A String", # The project number. 975 "team": "A String", # The team. 976 }, 977 "email": "A String", # The email address associated with the entity, if any. 978 "selfLink": "A String", # The link to this access-control entry. 979 }, 980 ], 981 "defaultObjectAcl": [ # Default access controls to apply to new objects when no ACL is provided. 982 { # An access-control entry. 983 "domain": "A String", # The domain associated with the entity, if any. 984 "generation": "A String", # The content generation of the object, if applied to an object. 985 "object": "A String", # The name of the object, if applied to an object. 986 "bucket": "A String", # The name of the bucket. 987 "kind": "storage#objectAccessControl", # The kind of item this is. For object access control entries, this is always storage#objectAccessControl. 988 "entity": "A String", # The entity holding the permission, in one of the following forms: 989 # - user-userId 990 # - user-email 991 # - group-groupId 992 # - group-email 993 # - domain-domain 994 # - project-team-projectId 995 # - allUsers 996 # - allAuthenticatedUsers Examples: 997 # - The user liz@example.com would be user-liz@example.com. 998 # - The group example@googlegroups.com would be group-example@googlegroups.com. 999 # - To refer to all members of the Google Apps for Business domain example.com, the entity would be domain-example.com. 1000 "etag": "A String", # HTTP 1.1 Entity tag for the access-control entry. 1001 "role": "A String", # The access permission for the entity. 1002 "id": "A String", # The ID of the access-control entry. 1003 "entityId": "A String", # The ID for the entity, if any. 1004 "projectTeam": { # The project team associated with the entity, if any. 1005 "projectNumber": "A String", # The project number. 1006 "team": "A String", # The team. 1007 }, 1008 "email": "A String", # The email address associated with the entity, if any. 1009 "selfLink": "A String", # The link to this access-control entry. 1010 }, 1011 ], 1012 "etag": "A String", # HTTP 1.1 Entity tag for the bucket. 1013 "location": "A String", # The location of the bucket. Object data for objects in the bucket resides in physical storage within this region. Defaults to US. See the developer's guide for the authoritative list. 1014 "cors": [ # The bucket's Cross-Origin Resource Sharing (CORS) configuration. 1015 { 1016 "origin": [ # The list of Origins eligible to receive CORS response headers. Note: "*" is permitted in the list of origins, and means "any Origin". 1017 "A String", 1018 ], 1019 "responseHeader": [ # The list of HTTP headers other than the simple response headers to give permission for the user-agent to share across domains. 1020 "A String", 1021 ], 1022 "method": [ # The list of HTTP methods on which to include CORS response headers, (GET, OPTIONS, POST, etc) Note: "*" is permitted in the list of methods, and means "any method". 1023 "A String", 1024 ], 1025 "maxAgeSeconds": 42, # The value, in seconds, to return in the Access-Control-Max-Age header used in preflight responses. 1026 }, 1027 ], 1028 "owner": { # The owner of the bucket. This is always the project team's owner group. 1029 "entityId": "A String", # The ID for the entity. 1030 "entity": "A String", # The entity, in the form project-owner-projectId. 1031 }, 1032 "lifecycle": { # The bucket's lifecycle configuration. See lifecycle management for more information. 1033 "rule": [ # A lifecycle management rule, which is made of an action to take and the condition(s) under which the action will be taken. 1034 { 1035 "action": { # The action to take. 1036 "type": "A String", # Type of the action. Currently, only Delete and SetStorageClass are supported. 1037 "storageClass": "A String", # Target storage class. Required iff the type of the action is SetStorageClass. 1038 }, 1039 "condition": { # The condition(s) under which the action will be taken. 1040 "isLive": True or False, # Relevant only for versioned objects. If the value is true, this condition matches live objects; if the value is false, it matches archived objects. 1041 "matchesStorageClass": [ # Objects having any of the storage classes specified by this condition will be matched. Values include MULTI_REGIONAL, REGIONAL, NEARLINE, COLDLINE, STANDARD, and DURABLE_REDUCED_AVAILABILITY. 1042 "A String", 1043 ], 1044 "age": 42, # Age of an object (in days). This condition is satisfied when an object reaches the specified age. 1045 "numNewerVersions": 42, # Relevant only for versioned objects. If the value is N, this condition is satisfied when there are at least N versions (including the live version) newer than this version of the object. 1046 "createdBefore": "A String", # A date in RFC 3339 format with only the date part (for instance, "2013-01-15"). This condition is satisfied when an object is created before midnight of the specified date in UTC. 1047 }, 1048 }, 1049 ], 1050 }, 1051 "selfLink": "A String", # The URI of this bucket. 1052 "id": "A String", # The ID of the bucket. For buckets, the id and name properities are the same. 1053 "projectNumber": "A String", # The project number of the project the bucket belongs to. 1054 "storageClass": "A String", # The bucket's default storage class, used whenever no storageClass is specified for a newly-created object. This defines how objects in the bucket are stored and determines the SLA and the cost of storage. Values include MULTI_REGIONAL, REGIONAL, STANDARD, NEARLINE, COLDLINE, and DURABLE_REDUCED_AVAILABILITY. If this value is not specified when the bucket is created, it will default to STANDARD. For more information, see storage classes. 1055 }</pre> 1056</div> 1057 1058<div class="method"> 1059 <code class="details" id="setIamPolicy">setIamPolicy(bucket, body, userProject=None)</code> 1060 <pre>Updates an IAM policy for the specified bucket. 1061 1062Args: 1063 bucket: string, Name of a bucket. (required) 1064 body: object, The request body. (required) 1065 The object takes the form of: 1066 1067{ # A bucket/object IAM policy. 1068 "resourceId": "A String", # The ID of the resource to which this policy belongs. Will be of the form buckets/bucket for buckets, and buckets/bucket/objects/object for objects. A specific generation may be specified by appending #generationNumber to the end of the object name, e.g. buckets/my-bucket/objects/data.txt#17. The current generation can be denoted with #0. This field is ignored on input. 1069 "bindings": [ # An association between a role, which comes with a set of permissions, and members who may assume that role. 1070 { 1071 "role": "A String", # The role to which members belong. Two types of roles are supported: new IAM roles, which grant permissions that do not map directly to those provided by ACLs, and legacy IAM roles, which do map directly to ACL permissions. All roles are of the format roles/storage.specificRole. 1072 # The new IAM roles are: 1073 # - roles/storage.admin — Full control of Google Cloud Storage resources. 1074 # - roles/storage.objectViewer — Read-Only access to Google Cloud Storage objects. 1075 # - roles/storage.objectCreator — Access to create objects in Google Cloud Storage. 1076 # - roles/storage.objectAdmin — Full control of Google Cloud Storage objects. The legacy IAM roles are: 1077 # - roles/storage.legacyObjectReader — Read-only access to objects without listing. Equivalent to an ACL entry on an object with the READER role. 1078 # - roles/storage.legacyObjectOwner — Read/write access to existing objects without listing. Equivalent to an ACL entry on an object with the OWNER role. 1079 # - roles/storage.legacyBucketReader — Read access to buckets with object listing. Equivalent to an ACL entry on a bucket with the READER role. 1080 # - roles/storage.legacyBucketWriter — Read access to buckets with object listing/creation/deletion. Equivalent to an ACL entry on a bucket with the WRITER role. 1081 # - roles/storage.legacyBucketOwner — Read and write access to existing buckets with object listing/creation/deletion. Equivalent to an ACL entry on a bucket with the OWNER role. 1082 "members": [ # A collection of identifiers for members who may assume the provided role. Recognized identifiers are as follows: 1083 # - allUsers — A special identifier that represents anyone on the internet; with or without a Google account. 1084 # - allAuthenticatedUsers — A special identifier that represents anyone who is authenticated with a Google account or a service account. 1085 # - user:emailid — An email address that represents a specific account. For example, user:alice@gmail.com or user:joe@example.com. 1086 # - serviceAccount:emailid — An email address that represents a service account. For example, serviceAccount:my-other-app@appspot.gserviceaccount.com . 1087 # - group:emailid — An email address that represents a Google group. For example, group:admins@example.com. 1088 # - domain:domain — A Google Apps domain name that represents all the users of that domain. For example, domain:google.com or domain:example.com. 1089 # - projectOwner:projectid — Owners of the given project. For example, projectOwner:my-example-project 1090 # - projectEditor:projectid — Editors of the given project. For example, projectEditor:my-example-project 1091 # - projectViewer:projectid — Viewers of the given project. For example, projectViewer:my-example-project 1092 "A String", 1093 ], 1094 }, 1095 ], 1096 "etag": "A String", # HTTP 1.1 Entity tag for the policy. 1097 "kind": "storage#policy", # The kind of item this is. For policies, this is always storage#policy. This field is ignored on input. 1098} 1099 1100 userProject: string, The project number to be billed for this request, for Requester Pays buckets. 1101 1102Returns: 1103 An object of the form: 1104 1105 { # A bucket/object IAM policy. 1106 "resourceId": "A String", # The ID of the resource to which this policy belongs. Will be of the form buckets/bucket for buckets, and buckets/bucket/objects/object for objects. A specific generation may be specified by appending #generationNumber to the end of the object name, e.g. buckets/my-bucket/objects/data.txt#17. The current generation can be denoted with #0. This field is ignored on input. 1107 "bindings": [ # An association between a role, which comes with a set of permissions, and members who may assume that role. 1108 { 1109 "role": "A String", # The role to which members belong. Two types of roles are supported: new IAM roles, which grant permissions that do not map directly to those provided by ACLs, and legacy IAM roles, which do map directly to ACL permissions. All roles are of the format roles/storage.specificRole. 1110 # The new IAM roles are: 1111 # - roles/storage.admin — Full control of Google Cloud Storage resources. 1112 # - roles/storage.objectViewer — Read-Only access to Google Cloud Storage objects. 1113 # - roles/storage.objectCreator — Access to create objects in Google Cloud Storage. 1114 # - roles/storage.objectAdmin — Full control of Google Cloud Storage objects. The legacy IAM roles are: 1115 # - roles/storage.legacyObjectReader — Read-only access to objects without listing. Equivalent to an ACL entry on an object with the READER role. 1116 # - roles/storage.legacyObjectOwner — Read/write access to existing objects without listing. Equivalent to an ACL entry on an object with the OWNER role. 1117 # - roles/storage.legacyBucketReader — Read access to buckets with object listing. Equivalent to an ACL entry on a bucket with the READER role. 1118 # - roles/storage.legacyBucketWriter — Read access to buckets with object listing/creation/deletion. Equivalent to an ACL entry on a bucket with the WRITER role. 1119 # - roles/storage.legacyBucketOwner — Read and write access to existing buckets with object listing/creation/deletion. Equivalent to an ACL entry on a bucket with the OWNER role. 1120 "members": [ # A collection of identifiers for members who may assume the provided role. Recognized identifiers are as follows: 1121 # - allUsers — A special identifier that represents anyone on the internet; with or without a Google account. 1122 # - allAuthenticatedUsers — A special identifier that represents anyone who is authenticated with a Google account or a service account. 1123 # - user:emailid — An email address that represents a specific account. For example, user:alice@gmail.com or user:joe@example.com. 1124 # - serviceAccount:emailid — An email address that represents a service account. For example, serviceAccount:my-other-app@appspot.gserviceaccount.com . 1125 # - group:emailid — An email address that represents a Google group. For example, group:admins@example.com. 1126 # - domain:domain — A Google Apps domain name that represents all the users of that domain. For example, domain:google.com or domain:example.com. 1127 # - projectOwner:projectid — Owners of the given project. For example, projectOwner:my-example-project 1128 # - projectEditor:projectid — Editors of the given project. For example, projectEditor:my-example-project 1129 # - projectViewer:projectid — Viewers of the given project. For example, projectViewer:my-example-project 1130 "A String", 1131 ], 1132 }, 1133 ], 1134 "etag": "A String", # HTTP 1.1 Entity tag for the policy. 1135 "kind": "storage#policy", # The kind of item this is. For policies, this is always storage#policy. This field is ignored on input. 1136 }</pre> 1137</div> 1138 1139<div class="method"> 1140 <code class="details" id="testIamPermissions">testIamPermissions(bucket, permissions, userProject=None)</code> 1141 <pre>Tests a set of permissions on the given bucket to see which, if any, are held by the caller. 1142 1143Args: 1144 bucket: string, Name of a bucket. (required) 1145 permissions: string, Permissions to test. (required) (repeated) 1146 userProject: string, The project number to be billed for this request, for Requester Pays buckets. 1147 1148Returns: 1149 An object of the form: 1150 1151 { # A storage.(buckets|objects).testIamPermissions response. 1152 "kind": "storage#testIamPermissionsResponse", # The kind of item this is. 1153 "permissions": [ # The permissions held by the caller. Permissions are always of the format storage.resource.capability, where resource is one of buckets or objects. The supported permissions are as follows: 1154 # - storage.buckets.delete — Delete bucket. 1155 # - storage.buckets.get — Read bucket metadata. 1156 # - storage.buckets.getIamPolicy — Read bucket IAM policy. 1157 # - storage.buckets.create — Create bucket. 1158 # - storage.buckets.list — List buckets. 1159 # - storage.buckets.setIamPolicy — Update bucket IAM policy. 1160 # - storage.buckets.update — Update bucket metadata. 1161 # - storage.objects.delete — Delete object. 1162 # - storage.objects.get — Read object data and metadata. 1163 # - storage.objects.getIamPolicy — Read object IAM policy. 1164 # - storage.objects.create — Create object. 1165 # - storage.objects.list — List objects. 1166 # - storage.objects.setIamPolicy — Update object IAM policy. 1167 # - storage.objects.update — Update object metadata. 1168 "A String", 1169 ], 1170 }</pre> 1171</div> 1172 1173<div class="method"> 1174 <code class="details" id="update">update(bucket, body, projection=None, ifMetagenerationMatch=None, userProject=None, predefinedDefaultObjectAcl=None, predefinedAcl=None, ifMetagenerationNotMatch=None)</code> 1175 <pre>Updates a bucket. Changes to the bucket will be readable immediately after writing, but configuration changes may take time to propagate. 1176 1177Args: 1178 bucket: string, Name of a bucket. (required) 1179 body: object, The request body. (required) 1180 The object takes the form of: 1181 1182{ # A bucket. 1183 "website": { # The bucket's website configuration, controlling how the service behaves when accessing bucket contents as a web site. See the Static Website Examples for more information. 1184 "notFoundPage": "A String", # If the requested object path is missing, and any mainPageSuffix object is missing, if applicable, the service will return the named object from this bucket as the content for a 404 Not Found result. 1185 "mainPageSuffix": "A String", # If the requested object path is missing, the service will ensure the path has a trailing '/', append this suffix, and attempt to retrieve the resulting object. This allows the creation of index.html objects to represent directory pages. 1186 }, 1187 "metageneration": "A String", # The metadata generation of this bucket. 1188 "kind": "storage#bucket", # The kind of item this is. For buckets, this is always storage#bucket. 1189 "logging": { # The bucket's logging configuration, which defines the destination bucket and optional name prefix for the current bucket's logs. 1190 "logObjectPrefix": "A String", # A prefix for log object names. 1191 "logBucket": "A String", # The destination bucket where the current bucket's logs should be placed. 1192 }, 1193 "name": "A String", # The name of the bucket. 1194 "billing": { # The bucket's billing configuration. 1195 "requesterPays": True or False, # When set to true, bucket is requester pays. 1196 }, 1197 "timeCreated": "A String", # The creation time of the bucket in RFC 3339 format. 1198 "labels": { # User-provided labels, in key/value pairs. 1199 "a_key": "A String", # An individual label entry. 1200 }, 1201 "updated": "A String", # The modification time of the bucket in RFC 3339 format. 1202 "versioning": { # The bucket's versioning configuration. 1203 "enabled": True or False, # While set to true, versioning is fully enabled for this bucket. 1204 }, 1205 "acl": [ # Access controls on the bucket. 1206 { # An access-control entry. 1207 "domain": "A String", # The domain associated with the entity, if any. 1208 "bucket": "A String", # The name of the bucket. 1209 "kind": "storage#bucketAccessControl", # The kind of item this is. For bucket access control entries, this is always storage#bucketAccessControl. 1210 "entity": "A String", # The entity holding the permission, in one of the following forms: 1211 # - user-userId 1212 # - user-email 1213 # - group-groupId 1214 # - group-email 1215 # - domain-domain 1216 # - project-team-projectId 1217 # - allUsers 1218 # - allAuthenticatedUsers Examples: 1219 # - The user liz@example.com would be user-liz@example.com. 1220 # - The group example@googlegroups.com would be group-example@googlegroups.com. 1221 # - To refer to all members of the Google Apps for Business domain example.com, the entity would be domain-example.com. 1222 "etag": "A String", # HTTP 1.1 Entity tag for the access-control entry. 1223 "role": "A String", # The access permission for the entity. 1224 "id": "A String", # The ID of the access-control entry. 1225 "entityId": "A String", # The ID for the entity, if any. 1226 "projectTeam": { # The project team associated with the entity, if any. 1227 "projectNumber": "A String", # The project number. 1228 "team": "A String", # The team. 1229 }, 1230 "email": "A String", # The email address associated with the entity, if any. 1231 "selfLink": "A String", # The link to this access-control entry. 1232 }, 1233 ], 1234 "defaultObjectAcl": [ # Default access controls to apply to new objects when no ACL is provided. 1235 { # An access-control entry. 1236 "domain": "A String", # The domain associated with the entity, if any. 1237 "generation": "A String", # The content generation of the object, if applied to an object. 1238 "object": "A String", # The name of the object, if applied to an object. 1239 "bucket": "A String", # The name of the bucket. 1240 "kind": "storage#objectAccessControl", # The kind of item this is. For object access control entries, this is always storage#objectAccessControl. 1241 "entity": "A String", # The entity holding the permission, in one of the following forms: 1242 # - user-userId 1243 # - user-email 1244 # - group-groupId 1245 # - group-email 1246 # - domain-domain 1247 # - project-team-projectId 1248 # - allUsers 1249 # - allAuthenticatedUsers Examples: 1250 # - The user liz@example.com would be user-liz@example.com. 1251 # - The group example@googlegroups.com would be group-example@googlegroups.com. 1252 # - To refer to all members of the Google Apps for Business domain example.com, the entity would be domain-example.com. 1253 "etag": "A String", # HTTP 1.1 Entity tag for the access-control entry. 1254 "role": "A String", # The access permission for the entity. 1255 "id": "A String", # The ID of the access-control entry. 1256 "entityId": "A String", # The ID for the entity, if any. 1257 "projectTeam": { # The project team associated with the entity, if any. 1258 "projectNumber": "A String", # The project number. 1259 "team": "A String", # The team. 1260 }, 1261 "email": "A String", # The email address associated with the entity, if any. 1262 "selfLink": "A String", # The link to this access-control entry. 1263 }, 1264 ], 1265 "etag": "A String", # HTTP 1.1 Entity tag for the bucket. 1266 "location": "A String", # The location of the bucket. Object data for objects in the bucket resides in physical storage within this region. Defaults to US. See the developer's guide for the authoritative list. 1267 "cors": [ # The bucket's Cross-Origin Resource Sharing (CORS) configuration. 1268 { 1269 "origin": [ # The list of Origins eligible to receive CORS response headers. Note: "*" is permitted in the list of origins, and means "any Origin". 1270 "A String", 1271 ], 1272 "responseHeader": [ # The list of HTTP headers other than the simple response headers to give permission for the user-agent to share across domains. 1273 "A String", 1274 ], 1275 "method": [ # The list of HTTP methods on which to include CORS response headers, (GET, OPTIONS, POST, etc) Note: "*" is permitted in the list of methods, and means "any method". 1276 "A String", 1277 ], 1278 "maxAgeSeconds": 42, # The value, in seconds, to return in the Access-Control-Max-Age header used in preflight responses. 1279 }, 1280 ], 1281 "owner": { # The owner of the bucket. This is always the project team's owner group. 1282 "entityId": "A String", # The ID for the entity. 1283 "entity": "A String", # The entity, in the form project-owner-projectId. 1284 }, 1285 "lifecycle": { # The bucket's lifecycle configuration. See lifecycle management for more information. 1286 "rule": [ # A lifecycle management rule, which is made of an action to take and the condition(s) under which the action will be taken. 1287 { 1288 "action": { # The action to take. 1289 "type": "A String", # Type of the action. Currently, only Delete and SetStorageClass are supported. 1290 "storageClass": "A String", # Target storage class. Required iff the type of the action is SetStorageClass. 1291 }, 1292 "condition": { # The condition(s) under which the action will be taken. 1293 "isLive": True or False, # Relevant only for versioned objects. If the value is true, this condition matches live objects; if the value is false, it matches archived objects. 1294 "matchesStorageClass": [ # Objects having any of the storage classes specified by this condition will be matched. Values include MULTI_REGIONAL, REGIONAL, NEARLINE, COLDLINE, STANDARD, and DURABLE_REDUCED_AVAILABILITY. 1295 "A String", 1296 ], 1297 "age": 42, # Age of an object (in days). This condition is satisfied when an object reaches the specified age. 1298 "numNewerVersions": 42, # Relevant only for versioned objects. If the value is N, this condition is satisfied when there are at least N versions (including the live version) newer than this version of the object. 1299 "createdBefore": "A String", # A date in RFC 3339 format with only the date part (for instance, "2013-01-15"). This condition is satisfied when an object is created before midnight of the specified date in UTC. 1300 }, 1301 }, 1302 ], 1303 }, 1304 "selfLink": "A String", # The URI of this bucket. 1305 "id": "A String", # The ID of the bucket. For buckets, the id and name properities are the same. 1306 "projectNumber": "A String", # The project number of the project the bucket belongs to. 1307 "storageClass": "A String", # The bucket's default storage class, used whenever no storageClass is specified for a newly-created object. This defines how objects in the bucket are stored and determines the SLA and the cost of storage. Values include MULTI_REGIONAL, REGIONAL, STANDARD, NEARLINE, COLDLINE, and DURABLE_REDUCED_AVAILABILITY. If this value is not specified when the bucket is created, it will default to STANDARD. For more information, see storage classes. 1308 } 1309 1310 projection: string, Set of properties to return. Defaults to full. 1311 Allowed values 1312 full - Include all properties. 1313 noAcl - Omit owner, acl and defaultObjectAcl properties. 1314 ifMetagenerationMatch: string, Makes the return of the bucket metadata conditional on whether the bucket's current metageneration matches the given value. 1315 userProject: string, The project number to be billed for this request, for Requester Pays buckets. 1316 predefinedDefaultObjectAcl: string, Apply a predefined set of default object access controls to this bucket. 1317 Allowed values 1318 authenticatedRead - Object owner gets OWNER access, and allAuthenticatedUsers get READER access. 1319 bucketOwnerFullControl - Object owner gets OWNER access, and project team owners get OWNER access. 1320 bucketOwnerRead - Object owner gets OWNER access, and project team owners get READER access. 1321 private - Object owner gets OWNER access. 1322 projectPrivate - Object owner gets OWNER access, and project team members get access according to their roles. 1323 publicRead - Object owner gets OWNER access, and allUsers get READER access. 1324 predefinedAcl: string, Apply a predefined set of access controls to this bucket. 1325 Allowed values 1326 authenticatedRead - Project team owners get OWNER access, and allAuthenticatedUsers get READER access. 1327 private - Project team owners get OWNER access. 1328 projectPrivate - Project team members get access according to their roles. 1329 publicRead - Project team owners get OWNER access, and allUsers get READER access. 1330 publicReadWrite - Project team owners get OWNER access, and allUsers get WRITER access. 1331 ifMetagenerationNotMatch: string, Makes the return of the bucket metadata conditional on whether the bucket's current metageneration does not match the given value. 1332 1333Returns: 1334 An object of the form: 1335 1336 { # A bucket. 1337 "website": { # The bucket's website configuration, controlling how the service behaves when accessing bucket contents as a web site. See the Static Website Examples for more information. 1338 "notFoundPage": "A String", # If the requested object path is missing, and any mainPageSuffix object is missing, if applicable, the service will return the named object from this bucket as the content for a 404 Not Found result. 1339 "mainPageSuffix": "A String", # If the requested object path is missing, the service will ensure the path has a trailing '/', append this suffix, and attempt to retrieve the resulting object. This allows the creation of index.html objects to represent directory pages. 1340 }, 1341 "metageneration": "A String", # The metadata generation of this bucket. 1342 "kind": "storage#bucket", # The kind of item this is. For buckets, this is always storage#bucket. 1343 "logging": { # The bucket's logging configuration, which defines the destination bucket and optional name prefix for the current bucket's logs. 1344 "logObjectPrefix": "A String", # A prefix for log object names. 1345 "logBucket": "A String", # The destination bucket where the current bucket's logs should be placed. 1346 }, 1347 "name": "A String", # The name of the bucket. 1348 "billing": { # The bucket's billing configuration. 1349 "requesterPays": True or False, # When set to true, bucket is requester pays. 1350 }, 1351 "timeCreated": "A String", # The creation time of the bucket in RFC 3339 format. 1352 "labels": { # User-provided labels, in key/value pairs. 1353 "a_key": "A String", # An individual label entry. 1354 }, 1355 "updated": "A String", # The modification time of the bucket in RFC 3339 format. 1356 "versioning": { # The bucket's versioning configuration. 1357 "enabled": True or False, # While set to true, versioning is fully enabled for this bucket. 1358 }, 1359 "acl": [ # Access controls on the bucket. 1360 { # An access-control entry. 1361 "domain": "A String", # The domain associated with the entity, if any. 1362 "bucket": "A String", # The name of the bucket. 1363 "kind": "storage#bucketAccessControl", # The kind of item this is. For bucket access control entries, this is always storage#bucketAccessControl. 1364 "entity": "A String", # The entity holding the permission, in one of the following forms: 1365 # - user-userId 1366 # - user-email 1367 # - group-groupId 1368 # - group-email 1369 # - domain-domain 1370 # - project-team-projectId 1371 # - allUsers 1372 # - allAuthenticatedUsers Examples: 1373 # - The user liz@example.com would be user-liz@example.com. 1374 # - The group example@googlegroups.com would be group-example@googlegroups.com. 1375 # - To refer to all members of the Google Apps for Business domain example.com, the entity would be domain-example.com. 1376 "etag": "A String", # HTTP 1.1 Entity tag for the access-control entry. 1377 "role": "A String", # The access permission for the entity. 1378 "id": "A String", # The ID of the access-control entry. 1379 "entityId": "A String", # The ID for the entity, if any. 1380 "projectTeam": { # The project team associated with the entity, if any. 1381 "projectNumber": "A String", # The project number. 1382 "team": "A String", # The team. 1383 }, 1384 "email": "A String", # The email address associated with the entity, if any. 1385 "selfLink": "A String", # The link to this access-control entry. 1386 }, 1387 ], 1388 "defaultObjectAcl": [ # Default access controls to apply to new objects when no ACL is provided. 1389 { # An access-control entry. 1390 "domain": "A String", # The domain associated with the entity, if any. 1391 "generation": "A String", # The content generation of the object, if applied to an object. 1392 "object": "A String", # The name of the object, if applied to an object. 1393 "bucket": "A String", # The name of the bucket. 1394 "kind": "storage#objectAccessControl", # The kind of item this is. For object access control entries, this is always storage#objectAccessControl. 1395 "entity": "A String", # The entity holding the permission, in one of the following forms: 1396 # - user-userId 1397 # - user-email 1398 # - group-groupId 1399 # - group-email 1400 # - domain-domain 1401 # - project-team-projectId 1402 # - allUsers 1403 # - allAuthenticatedUsers Examples: 1404 # - The user liz@example.com would be user-liz@example.com. 1405 # - The group example@googlegroups.com would be group-example@googlegroups.com. 1406 # - To refer to all members of the Google Apps for Business domain example.com, the entity would be domain-example.com. 1407 "etag": "A String", # HTTP 1.1 Entity tag for the access-control entry. 1408 "role": "A String", # The access permission for the entity. 1409 "id": "A String", # The ID of the access-control entry. 1410 "entityId": "A String", # The ID for the entity, if any. 1411 "projectTeam": { # The project team associated with the entity, if any. 1412 "projectNumber": "A String", # The project number. 1413 "team": "A String", # The team. 1414 }, 1415 "email": "A String", # The email address associated with the entity, if any. 1416 "selfLink": "A String", # The link to this access-control entry. 1417 }, 1418 ], 1419 "etag": "A String", # HTTP 1.1 Entity tag for the bucket. 1420 "location": "A String", # The location of the bucket. Object data for objects in the bucket resides in physical storage within this region. Defaults to US. See the developer's guide for the authoritative list. 1421 "cors": [ # The bucket's Cross-Origin Resource Sharing (CORS) configuration. 1422 { 1423 "origin": [ # The list of Origins eligible to receive CORS response headers. Note: "*" is permitted in the list of origins, and means "any Origin". 1424 "A String", 1425 ], 1426 "responseHeader": [ # The list of HTTP headers other than the simple response headers to give permission for the user-agent to share across domains. 1427 "A String", 1428 ], 1429 "method": [ # The list of HTTP methods on which to include CORS response headers, (GET, OPTIONS, POST, etc) Note: "*" is permitted in the list of methods, and means "any method". 1430 "A String", 1431 ], 1432 "maxAgeSeconds": 42, # The value, in seconds, to return in the Access-Control-Max-Age header used in preflight responses. 1433 }, 1434 ], 1435 "owner": { # The owner of the bucket. This is always the project team's owner group. 1436 "entityId": "A String", # The ID for the entity. 1437 "entity": "A String", # The entity, in the form project-owner-projectId. 1438 }, 1439 "lifecycle": { # The bucket's lifecycle configuration. See lifecycle management for more information. 1440 "rule": [ # A lifecycle management rule, which is made of an action to take and the condition(s) under which the action will be taken. 1441 { 1442 "action": { # The action to take. 1443 "type": "A String", # Type of the action. Currently, only Delete and SetStorageClass are supported. 1444 "storageClass": "A String", # Target storage class. Required iff the type of the action is SetStorageClass. 1445 }, 1446 "condition": { # The condition(s) under which the action will be taken. 1447 "isLive": True or False, # Relevant only for versioned objects. If the value is true, this condition matches live objects; if the value is false, it matches archived objects. 1448 "matchesStorageClass": [ # Objects having any of the storage classes specified by this condition will be matched. Values include MULTI_REGIONAL, REGIONAL, NEARLINE, COLDLINE, STANDARD, and DURABLE_REDUCED_AVAILABILITY. 1449 "A String", 1450 ], 1451 "age": 42, # Age of an object (in days). This condition is satisfied when an object reaches the specified age. 1452 "numNewerVersions": 42, # Relevant only for versioned objects. If the value is N, this condition is satisfied when there are at least N versions (including the live version) newer than this version of the object. 1453 "createdBefore": "A String", # A date in RFC 3339 format with only the date part (for instance, "2013-01-15"). This condition is satisfied when an object is created before midnight of the specified date in UTC. 1454 }, 1455 }, 1456 ], 1457 }, 1458 "selfLink": "A String", # The URI of this bucket. 1459 "id": "A String", # The ID of the bucket. For buckets, the id and name properities are the same. 1460 "projectNumber": "A String", # The project number of the project the bucket belongs to. 1461 "storageClass": "A String", # The bucket's default storage class, used whenever no storageClass is specified for a newly-created object. This defines how objects in the bucket are stored and determines the SLA and the cost of storage. Values include MULTI_REGIONAL, REGIONAL, STANDARD, NEARLINE, COLDLINE, and DURABLE_REDUCED_AVAILABILITY. If this value is not specified when the bucket is created, it will default to STANDARD. For more information, see storage classes. 1462 }</pre> 1463</div> 1464 1465</body></html>