GetAccessPointPolicyForObjectLambda
Note
Amazon S3 Object Lambda will no longer be open to new customers starting on 11/7/2025. If you would like to use the service, please sign up prior to 11/7/2025. For capabilities similar to S3 Object Lambda, learn more here - Amazon S3 Object Lambda availability change.
Note
This operation is not supported by directory buckets.
Returns the resource policy for an Object Lambda Access Point.
The following actions are related to
GetAccessPointPolicyForObjectLambda
:
Important
You must URL encode any signed header values that contain spaces. For example, if your header value is my file.txt
, containing two spaces after my
, you must URL encode this value to my%20%20file.txt
.
Request Syntax
GET /v20180820/accesspointforobjectlambda/name
/policy HTTP/1.1
Host: s3-control.amazonaws.com
x-amz-account-id: AccountId
URI Request Parameters
The request uses the following URI parameters.
- name
-
The name of the Object Lambda Access Point.
Length Constraints: Minimum length of 3. Maximum length of 45.
Pattern:
^[a-z0-9]([a-z0-9\-]*[a-z0-9])?$
Required: Yes
- x-amz-account-id
-
The account ID for the account that owns the specified Object Lambda Access Point.
Length Constraints: Maximum length of 64.
Pattern:
^\d{12}$
Required: Yes
Request Body
The request does not have a request body.
Response Syntax
HTTP/1.1 200
<?xml version="1.0" encoding="UTF-8"?>
<GetAccessPointPolicyForObjectLambdaResult>
<Policy>string</Policy>
</GetAccessPointPolicyForObjectLambdaResult>
Response Elements
If the action is successful, the service sends back an HTTP 200 response.
The following data is returned in XML format by the service.
- GetAccessPointPolicyForObjectLambdaResult
-
Root level tag for the GetAccessPointPolicyForObjectLambdaResult parameters.
Required: Yes
- Policy
-
Object Lambda Access Point resource policy document.
Type: String
Examples
Sample resource policy
The following illustrates a sample resource policy.
{ "Version" : "2008-10-17", "Statement":[{ "Sid": "Grant account 123456789012 GetObject access", "Effect":"Allow", "Principal" : { "AWS": "arn:aws:iam::123456789012:root" }, "Action":["s3-object-lambda:GetObject"], "Resource":["arn:aws:s3-object-lambda:us-east-1:123456789012:accesspoint/my-object-lambda-ap"] }, { "Sid": "Grant account 444455556666 GetObject access", "Effect":"Allow", "Principal" : { "AWS": "arn:aws:iam::444455556666:root" }, "Action":["s3-object-lambda:GetObject"], "Resource":["arn:aws:s3-object-lambda:us-east-1:123456789012:accesspoint/my-object-lambda-ap"] } ] }
See Also
For more information about using this API in one of the language-specific AWS SDKs, see the following: