IPWorks Cloud 2020 PHP Edition

Questions / Feedback?

CreateBucket Method

Creates a new bucket.

Object Oriented Interface

public function doCreateBucket($bucketname, $kind);

Procedural Interface

ipworkscloud_backblazeb2_do_createbucket($res, $bucketname, $kind);

Remarks

This method creates a new bucket named BucketName of the specified Kind. Valid values for Kind are allPrivate (default if empty) and allPublic. Each account may have up to 100 buckets.

The value passed for BucketName must comply with the following restrictions:

  • Must be between 6 and 50 characters long (inclusive).
  • Must consist solely of letters, digits, and hyphens (-).
  • Cannot start with the string b2-.
  • Must be globally unique (i.e., no two accounts may have a bucket with the same name) when compared case-insensitively.

If any items are present in the Metadata* properties, they will also be included in the request and applied to the newly-created bucket. Keep in mind that the server enforces a limit of 10 metadata items per bucket.

The currently-authenticated application key must have the writeBuckets capability to call this method successfully, otherwise the server will return an error. Refer to the AccountCapabilities property for more information.

Copyright (c) 2022 /n software inc. - All rights reserved.
IPWorks Cloud 2020 PHP Edition - Version 20.0 [Build 8265]