| Copyright | (c) 2013-2023 Brendan Hay | 
|---|---|
| License | Mozilla Public License, v. 2.0. | 
| Maintainer | Brendan Hay | 
| Stability | auto-generated | 
| Portability | non-portable (GHC extensions) | 
| Safe Haskell | Safe-Inferred | 
| Language | Haskell2010 | 
Amazonka.S3.GetObjectAcl
Description
Returns the access control list (ACL) of an object. To use this
 operation, you must have s3:GetObjectAcl permissions or READ_ACP
 access to the object. For more information, see
 Mapping of ACL permissions and access policy permissions
 in the Amazon S3 User Guide
This action is not supported by Amazon S3 on Outposts.
Versioning
By default, GET returns ACL information about the current version of an object. To return ACL information about a different version, use the versionId subresource.
If your bucket uses the bucket owner enforced setting for S3 Object
 Ownership, requests to read ACLs are still supported and return the
 bucket-owner-full-control ACL with the owner being the account that
 created the bucket. For more information, see
 Controlling object ownership and disabling ACLs
 in the Amazon S3 User Guide.
The following operations are related to GetObjectAcl:
Synopsis
- data GetObjectAcl = GetObjectAcl' {}
 - newGetObjectAcl :: BucketName -> ObjectKey -> GetObjectAcl
 - getObjectAcl_expectedBucketOwner :: Lens' GetObjectAcl (Maybe Text)
 - getObjectAcl_requestPayer :: Lens' GetObjectAcl (Maybe RequestPayer)
 - getObjectAcl_versionId :: Lens' GetObjectAcl (Maybe ObjectVersionId)
 - getObjectAcl_bucket :: Lens' GetObjectAcl BucketName
 - getObjectAcl_key :: Lens' GetObjectAcl ObjectKey
 - data GetObjectAclResponse = GetObjectAclResponse' {
- grants :: Maybe [Grant]
 - owner :: Maybe Owner
 - requestCharged :: Maybe RequestCharged
 - httpStatus :: Int
 
 - newGetObjectAclResponse :: Int -> GetObjectAclResponse
 - getObjectAclResponse_grants :: Lens' GetObjectAclResponse (Maybe [Grant])
 - getObjectAclResponse_owner :: Lens' GetObjectAclResponse (Maybe Owner)
 - getObjectAclResponse_requestCharged :: Lens' GetObjectAclResponse (Maybe RequestCharged)
 - getObjectAclResponse_httpStatus :: Lens' GetObjectAclResponse Int
 
Creating a Request
data GetObjectAcl Source #
See: newGetObjectAcl smart constructor.
Constructors
| GetObjectAcl' | |
Fields 
  | |
Instances
Arguments
| :: BucketName | |
| -> ObjectKey | |
| -> GetObjectAcl | 
Create a value of GetObjectAcl 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:expectedBucketOwner:GetObjectAcl', getObjectAcl_expectedBucketOwner - The account ID of the expected bucket owner. If the bucket is owned by a
 different account, the request fails with the HTTP status code
 403 Forbidden (access denied).
$sel:requestPayer:GetObjectAcl', getObjectAcl_requestPayer - Undocumented member.
GetObjectAcl, getObjectAcl_versionId - VersionId used to reference a specific version of the object.
GetObjectAcl, getObjectAcl_bucket - The bucket name that contains the object for which to get the ACL
 information.
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.
GetObjectAcl, getObjectAcl_key - The key of the object for which to get the ACL information.
Request Lenses
getObjectAcl_expectedBucketOwner :: Lens' GetObjectAcl (Maybe Text) Source #
The account ID of the expected bucket owner. If the bucket is owned by a
 different account, the request fails with the HTTP status code
 403 Forbidden (access denied).
getObjectAcl_requestPayer :: Lens' GetObjectAcl (Maybe RequestPayer) Source #
Undocumented member.
getObjectAcl_versionId :: Lens' GetObjectAcl (Maybe ObjectVersionId) Source #
VersionId used to reference a specific version of the object.
getObjectAcl_bucket :: Lens' GetObjectAcl BucketName Source #
The bucket name that contains the object for which to get the ACL information.
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.
getObjectAcl_key :: Lens' GetObjectAcl ObjectKey Source #
The key of the object for which to get the ACL information.
Destructuring the Response
data GetObjectAclResponse Source #
See: newGetObjectAclResponse smart constructor.
Constructors
| GetObjectAclResponse' | |
Fields 
  | |
Instances
newGetObjectAclResponse Source #
Arguments
| :: Int | |
| -> GetObjectAclResponse | 
Create a value of GetObjectAclResponse 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:
GetObjectAclResponse, getObjectAclResponse_grants - A list of grants.
GetObjectAclResponse, getObjectAclResponse_owner - Container for the bucket owner's display name and ID.
$sel:requestCharged:GetObjectAclResponse', getObjectAclResponse_requestCharged - Undocumented member.
$sel:httpStatus:GetObjectAclResponse', getObjectAclResponse_httpStatus - The response's http status code.
Response Lenses
getObjectAclResponse_grants :: Lens' GetObjectAclResponse (Maybe [Grant]) Source #
A list of grants.
getObjectAclResponse_owner :: Lens' GetObjectAclResponse (Maybe Owner) Source #
Container for the bucket owner's display name and ID.
getObjectAclResponse_requestCharged :: Lens' GetObjectAclResponse (Maybe RequestCharged) Source #
Undocumented member.
getObjectAclResponse_httpStatus :: Lens' GetObjectAclResponse Int Source #
The response's http status code.