Source Code Bundles
Deletes the bucket specified. Only buckets that contain no version of any files can be deleted.
Request HTTP Headers
An account authorization token, obtained from
Request HTTP Message Body Parameters
Your account ID.
The ID of the bucket to delete.
Response HTTP Status 200
Bucket successfully deleted. The JSON response will contain:
The account that the bucket is in.
The unique ID of the bucket.
The unique name of the bucket
One of: "allPublic", "allPrivate", "snapshot", or other values added in the future. "allPublic" means that anybody can download the files is the bucket; "allPrivate" means that you need an authorization token to download them; "snapshot" means that it's a private bucket containing snapshots created on the B2 web site.
The user data stored with this bucket.
The CORS rules for this bucket. See CORS Rules for an overview and the rule structure.
The list of lifecycle rules for this bucket. See Lifecycle Rules for an overview and the rule structure.
A counter that is updated every time the bucket is modified,
and can be used with the
A set of strings reserved for future use.
Bucket not deleted.
If possible the server will return a JSON error structure. Errors include:
v1: Application keys (July 26, 2018)
Incompatible change: After calling b2_authorize_account with an application key that does not have the right permissions, this call will return a 401 Unauthorized.
v1: Original release (September 22, 2015)