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 |
Retrieves an object's retention settings. For more information, see Locking Objects.
This action is not supported by Amazon S3 on Outposts.
Synopsis
- data GetObjectRetention = GetObjectRetention' {}
- newGetObjectRetention :: BucketName -> ObjectKey -> GetObjectRetention
- getObjectRetention_versionId :: Lens' GetObjectRetention (Maybe ObjectVersionId)
- getObjectRetention_requestPayer :: Lens' GetObjectRetention (Maybe RequestPayer)
- getObjectRetention_expectedBucketOwner :: Lens' GetObjectRetention (Maybe Text)
- getObjectRetention_bucket :: Lens' GetObjectRetention BucketName
- getObjectRetention_key :: Lens' GetObjectRetention ObjectKey
- data GetObjectRetentionResponse = GetObjectRetentionResponse' {}
- newGetObjectRetentionResponse :: Int -> GetObjectRetentionResponse
- getObjectRetentionResponse_retention :: Lens' GetObjectRetentionResponse (Maybe ObjectLockRetention)
- getObjectRetentionResponse_httpStatus :: Lens' GetObjectRetentionResponse Int
Creating a Request
data GetObjectRetention Source #
See: newGetObjectRetention
smart constructor.
GetObjectRetention' | |
|
Instances
newGetObjectRetention Source #
Create a value of GetObjectRetention
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:versionId:GetObjectRetention'
, getObjectRetention_versionId
- The version ID for the object whose retention settings you want to
retrieve.
$sel:requestPayer:GetObjectRetention'
, getObjectRetention_requestPayer
- Undocumented member.
$sel:expectedBucketOwner:GetObjectRetention'
, getObjectRetention_expectedBucketOwner
- The account ID of the expected bucket owner. If the bucket is owned by a
different account, the request will fail with an HTTP
403 (Access Denied)
error.
$sel:bucket:GetObjectRetention'
, getObjectRetention_bucket
- The bucket name containing the object whose retention settings you want
to retrieve.
When using this action with an access point, you must direct requests to the access point hostname. The access point hostname takes the form AccessPointName-AccountId.s3-accesspoint.Region.amazonaws.com. When using this action with an access point through the Amazon Web Services SDKs, you provide the access point ARN in place of the bucket name. For more information about access point ARNs, see Using access points in the Amazon S3 User Guide.
$sel:key:GetObjectRetention'
, getObjectRetention_key
- The key name for the object whose retention settings you want to
retrieve.
Request Lenses
getObjectRetention_versionId :: Lens' GetObjectRetention (Maybe ObjectVersionId) Source #
The version ID for the object whose retention settings you want to retrieve.
getObjectRetention_requestPayer :: Lens' GetObjectRetention (Maybe RequestPayer) Source #
Undocumented member.
getObjectRetention_expectedBucketOwner :: Lens' GetObjectRetention (Maybe Text) Source #
The account ID of the expected bucket owner. If the bucket is owned by a
different account, the request will fail with an HTTP
403 (Access Denied)
error.
getObjectRetention_bucket :: Lens' GetObjectRetention BucketName Source #
The bucket name containing the object whose retention settings you want to retrieve.
When using this action with an access point, you must direct requests to the access point hostname. The access point hostname takes the form AccessPointName-AccountId.s3-accesspoint.Region.amazonaws.com. When using this action with an access point through the Amazon Web Services SDKs, you provide the access point ARN in place of the bucket name. For more information about access point ARNs, see Using access points in the Amazon S3 User Guide.
getObjectRetention_key :: Lens' GetObjectRetention ObjectKey Source #
The key name for the object whose retention settings you want to retrieve.
Destructuring the Response
data GetObjectRetentionResponse Source #
See: newGetObjectRetentionResponse
smart constructor.
GetObjectRetentionResponse' | |
|
Instances
newGetObjectRetentionResponse Source #
Create a value of GetObjectRetentionResponse
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:retention:GetObjectRetentionResponse'
, getObjectRetentionResponse_retention
- The container element for an object's retention settings.
$sel:httpStatus:GetObjectRetentionResponse'
, getObjectRetentionResponse_httpStatus
- The response's http status code.
Response Lenses
getObjectRetentionResponse_retention :: Lens' GetObjectRetentionResponse (Maybe ObjectLockRetention) Source #
The container element for an object's retention settings.
getObjectRetentionResponse_httpStatus :: Lens' GetObjectRetentionResponse Int Source #
The response's http status code.