Copyright | (c) 2013-2021 Brendan Hay |
---|---|
License | Mozilla Public License, v. 2.0. |
Maintainer | Brendan Hay <brendan.g.hay+amazonka@gmail.com> |
Stability | auto-generated |
Portability | non-portable (GHC extensions) |
Safe Haskell | None |
Creates an Amazon Lightsail bucket.
A bucket is a cloud storage resource available in the Lightsail object storage service. Use buckets to store objects such as data and its descriptive metadata. For more information about buckets, see Buckets in Amazon Lightsail in the Amazon Lightsail Developer Guide.
Synopsis
- data CreateBucket = CreateBucket' {
- enableObjectVersioning :: Maybe Bool
- tags :: Maybe [Tag]
- bucketName :: Text
- bundleId :: Text
- newCreateBucket :: Text -> Text -> CreateBucket
- createBucket_enableObjectVersioning :: Lens' CreateBucket (Maybe Bool)
- createBucket_tags :: Lens' CreateBucket (Maybe [Tag])
- createBucket_bucketName :: Lens' CreateBucket Text
- createBucket_bundleId :: Lens' CreateBucket Text
- data CreateBucketResponse = CreateBucketResponse' {
- bucket :: Maybe Bucket
- operations :: Maybe [Operation]
- httpStatus :: Int
- newCreateBucketResponse :: Int -> CreateBucketResponse
- createBucketResponse_bucket :: Lens' CreateBucketResponse (Maybe Bucket)
- createBucketResponse_operations :: Lens' CreateBucketResponse (Maybe [Operation])
- createBucketResponse_httpStatus :: Lens' CreateBucketResponse Int
Creating a Request
data CreateBucket Source #
See: newCreateBucket
smart constructor.
CreateBucket' | |
|
Instances
Create a value of CreateBucket
with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
$sel:enableObjectVersioning:CreateBucket'
, createBucket_enableObjectVersioning
- A Boolean value that indicates whether to enable versioning of objects
in the bucket.
For more information about versioning, see Enabling and suspending object versioning in a bucket in Amazon Lightsail in the Amazon Lightsail Developer Guide.
$sel:tags:CreateBucket'
, createBucket_tags
- The tag keys and optional values to add to the bucket during creation.
Use the TagResource action to tag the bucket after it's created.
$sel:bucketName:CreateBucket'
, createBucket_bucketName
- The name for the bucket.
For more information about bucket names, see Bucket naming rules in Amazon Lightsail in the Amazon Lightsail Developer Guide.
$sel:bundleId:CreateBucket'
, createBucket_bundleId
- The ID of the bundle to use for the bucket.
A bucket bundle specifies the monthly cost, storage space, and data transfer quota for a bucket.
Use the GetBucketBundles action to get a list of bundle IDs that you can specify.
Use the UpdateBucketBundle action to change the bundle after the bucket is created.
Request Lenses
createBucket_enableObjectVersioning :: Lens' CreateBucket (Maybe Bool) Source #
A Boolean value that indicates whether to enable versioning of objects in the bucket.
For more information about versioning, see Enabling and suspending object versioning in a bucket in Amazon Lightsail in the Amazon Lightsail Developer Guide.
createBucket_tags :: Lens' CreateBucket (Maybe [Tag]) Source #
The tag keys and optional values to add to the bucket during creation.
Use the TagResource action to tag the bucket after it's created.
createBucket_bucketName :: Lens' CreateBucket Text Source #
The name for the bucket.
For more information about bucket names, see Bucket naming rules in Amazon Lightsail in the Amazon Lightsail Developer Guide.
createBucket_bundleId :: Lens' CreateBucket Text Source #
The ID of the bundle to use for the bucket.
A bucket bundle specifies the monthly cost, storage space, and data transfer quota for a bucket.
Use the GetBucketBundles action to get a list of bundle IDs that you can specify.
Use the UpdateBucketBundle action to change the bundle after the bucket is created.
Destructuring the Response
data CreateBucketResponse Source #
See: newCreateBucketResponse
smart constructor.
CreateBucketResponse' | |
|
Instances
newCreateBucketResponse Source #
Create a value of CreateBucketResponse
with all optional fields omitted.
Use generic-lens or optics to modify other optional fields.
The following record fields are available, with the corresponding lenses provided for backwards compatibility:
$sel:bucket:CreateBucketResponse'
, createBucketResponse_bucket
- An object that describes the bucket that is created.
$sel:operations:CreateBucketResponse'
, createBucketResponse_operations
- An array of objects that describe the result of the action, such as the
status of the request, the timestamp of the request, and the resources
affected by the request.
$sel:httpStatus:CreateBucketResponse'
, createBucketResponse_httpStatus
- The response's http status code.
Response Lenses
createBucketResponse_bucket :: Lens' CreateBucketResponse (Maybe Bucket) Source #
An object that describes the bucket that is created.
createBucketResponse_operations :: Lens' CreateBucketResponse (Maybe [Operation]) Source #
An array of objects that describe the result of the action, such as the status of the request, the timestamp of the request, and the resources affected by the request.
createBucketResponse_httpStatus :: Lens' CreateBucketResponse Int Source #
The response's http status code.