Skip to content

DeleteBucketRequest

Source code in docs_src/capo_lightsail/types/delete_bucket_request.py
class DeleteBucketRequest(TypedDict, closed=True):
    bucket_name: "capo_lightsail.types.bucket_name.BucketName"
    """<p>The name of the bucket to delete.</p> <p>Use the <a href="https://docs.aws.amazon.com/lightsail/2016-11-28/api-reference/API_GetBuckets.html">GetBuckets</a> action to get a list of bucket names that you can specify.</p>"""
    force_delete: NotRequired["capo_lightsail.types.boolean.boolean"]
    """<p>A Boolean value that indicates whether to force delete the bucket.</p> <p>You must force delete the bucket if it has one of the following conditions:</p> <ul> <li> <p>The bucket is the origin of a distribution.</p> </li> <li> <p>The bucket has instances that were granted access to it using the <a href="https://docs.aws.amazon.com/lightsail/2016-11-28/api-reference/API_SetResourceAccessForBucket.html">SetResourceAccessForBucket</a> action.</p> </li> <li> <p>The bucket has objects.</p> </li> <li> <p>The bucket has access keys.</p> </li> </ul> <important> <p>Force deleting a bucket might impact other resources that rely on the bucket, such as instances, distributions, or software that use the issued access keys.</p> </important>"""

bucket_name instance-attribute

bucket_name: BucketName

The name of the bucket to delete.

Use the GetBuckets action to get a list of bucket names that you can specify.

force_delete instance-attribute

force_delete: NotRequired[boolean]

A Boolean value that indicates whether to force delete the bucket.

You must force delete the bucket if it has one of the following conditions:

  • The bucket is the origin of a distribution.

  • The bucket has instances that were granted access to it using the SetResourceAccessForBucket action.

  • The bucket has objects.

  • The bucket has access keys.

Force deleting a bucket might impact other resources that rely on the bucket, such as instances, distributions, or software that use the issued access keys.