百度智能云

All Product Document

          Object Storage

          DeleteBucketTrash

          Interface Description

          This interface is used to disable the Trash feature. The user must be the source bucket owner with the FULL_CONTROL permission and also the destination bucket owner.

          Request

          • Request syntax

            DELETE /?trash HTTP/1.1
            Host: <BucketName>.bj.bcebos.com
            Date: <Date>
            Authorization: <AuthorizationString>   
          • Request header field

            No special header parameters.

          • Request element

            None

          Response

          • Response header field

            None

          • Response element

            Name Description
            trashDir Trash folder with a length limit Optional. The default name is.trash if it is left blank.

            The return results are explained as follows:

            Results http status error code Description
            Success 204 - -
            The bucket does not exist. 404 NoSuchBucket -
            Access denied 403 AccessDenied Only the bucket owner can operate it.

            Description: It returns the message 204 to meet the DELETE idempotent even if the Trash feature is not enabled.

          Example

          • Request example

            DELETE /?trash HTTP/1.1
            Host: bucket.bj.bcebos.com
            x-bce-date: date
            Authorization: AuthorizationString
          • Response example

            HTTP/1.1 204 OK
            x-bce-request-id: 4db4b34d-653d-4d9a-b49b-3049ca786409
            Date: Wed, 31 May 2017 08:34:40 GMT
            Server: BceBos
            Connection: keep-alive
          Previous
          PutBucketTrash
          Next
          GetBucketTrash