libZSservicesZSamazonka-lambdaZSamazonka-lambda
Copyright(c) 2013-2021 Brendan Hay
LicenseMozilla Public License, v. 2.0.
MaintainerBrendan Hay <brendan.g.hay+amazonka@gmail.com>
Stabilityauto-generated
Portabilitynon-portable (GHC extensions)
Safe HaskellNone

Amazonka.Lambda.GetPolicy

Description

Returns the resource-based IAM policy for a function, version, or alias.

Synopsis

Creating a Request

data GetPolicy Source #

See: newGetPolicy smart constructor.

Constructors

GetPolicy' 

Fields

  • qualifier :: Maybe Text

    Specify a version or alias to get the policy for that resource.

  • functionName :: Text

    The name of the Lambda function, version, or alias.

    Name formats

    • Function name - my-function (name-only), my-function:v1 (with alias).
    • Function ARN - arn:aws:lambda:us-west-2:123456789012:function:my-function.
    • Partial ARN - 123456789012:function:my-function.

    You can append a version number or alias to any of the formats. The length constraint applies only to the full ARN. If you specify only the function name, it is limited to 64 characters in length.

Instances

Instances details
Eq GetPolicy Source # 
Instance details

Defined in Amazonka.Lambda.GetPolicy

Read GetPolicy Source # 
Instance details

Defined in Amazonka.Lambda.GetPolicy

Show GetPolicy Source # 
Instance details

Defined in Amazonka.Lambda.GetPolicy

Generic GetPolicy Source # 
Instance details

Defined in Amazonka.Lambda.GetPolicy

Associated Types

type Rep GetPolicy :: Type -> Type #

NFData GetPolicy Source # 
Instance details

Defined in Amazonka.Lambda.GetPolicy

Methods

rnf :: GetPolicy -> () #

Hashable GetPolicy Source # 
Instance details

Defined in Amazonka.Lambda.GetPolicy

AWSRequest GetPolicy Source # 
Instance details

Defined in Amazonka.Lambda.GetPolicy

Associated Types

type AWSResponse GetPolicy #

ToHeaders GetPolicy Source # 
Instance details

Defined in Amazonka.Lambda.GetPolicy

Methods

toHeaders :: GetPolicy -> [Header] #

ToPath GetPolicy Source # 
Instance details

Defined in Amazonka.Lambda.GetPolicy

ToQuery GetPolicy Source # 
Instance details

Defined in Amazonka.Lambda.GetPolicy

type Rep GetPolicy Source # 
Instance details

Defined in Amazonka.Lambda.GetPolicy

type Rep GetPolicy = D1 ('MetaData "GetPolicy" "Amazonka.Lambda.GetPolicy" "libZSservicesZSamazonka-lambdaZSamazonka-lambda" 'False) (C1 ('MetaCons "GetPolicy'" 'PrefixI 'True) (S1 ('MetaSel ('Just "qualifier") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text)) :*: S1 ('MetaSel ('Just "functionName") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Text)))
type AWSResponse GetPolicy Source # 
Instance details

Defined in Amazonka.Lambda.GetPolicy

newGetPolicy Source #

Create a value of GetPolicy 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:qualifier:GetPolicy', getPolicy_qualifier - Specify a version or alias to get the policy for that resource.

$sel:functionName:GetPolicy', getPolicy_functionName - The name of the Lambda function, version, or alias.

Name formats

  • Function name - my-function (name-only), my-function:v1 (with alias).
  • Function ARN - arn:aws:lambda:us-west-2:123456789012:function:my-function.
  • Partial ARN - 123456789012:function:my-function.

You can append a version number or alias to any of the formats. The length constraint applies only to the full ARN. If you specify only the function name, it is limited to 64 characters in length.

Request Lenses

getPolicy_qualifier :: Lens' GetPolicy (Maybe Text) Source #

Specify a version or alias to get the policy for that resource.

getPolicy_functionName :: Lens' GetPolicy Text Source #

The name of the Lambda function, version, or alias.

Name formats

  • Function name - my-function (name-only), my-function:v1 (with alias).
  • Function ARN - arn:aws:lambda:us-west-2:123456789012:function:my-function.
  • Partial ARN - 123456789012:function:my-function.

You can append a version number or alias to any of the formats. The length constraint applies only to the full ARN. If you specify only the function name, it is limited to 64 characters in length.

Destructuring the Response

data GetPolicyResponse Source #

See: newGetPolicyResponse smart constructor.

Constructors

GetPolicyResponse' 

Fields

Instances

Instances details
Eq GetPolicyResponse Source # 
Instance details

Defined in Amazonka.Lambda.GetPolicy

Read GetPolicyResponse Source # 
Instance details

Defined in Amazonka.Lambda.GetPolicy

Show GetPolicyResponse Source # 
Instance details

Defined in Amazonka.Lambda.GetPolicy

Generic GetPolicyResponse Source # 
Instance details

Defined in Amazonka.Lambda.GetPolicy

Associated Types

type Rep GetPolicyResponse :: Type -> Type #

NFData GetPolicyResponse Source # 
Instance details

Defined in Amazonka.Lambda.GetPolicy

Methods

rnf :: GetPolicyResponse -> () #

type Rep GetPolicyResponse Source # 
Instance details

Defined in Amazonka.Lambda.GetPolicy

type Rep GetPolicyResponse = D1 ('MetaData "GetPolicyResponse" "Amazonka.Lambda.GetPolicy" "libZSservicesZSamazonka-lambdaZSamazonka-lambda" 'False) (C1 ('MetaCons "GetPolicyResponse'" 'PrefixI 'True) (S1 ('MetaSel ('Just "policy") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text)) :*: (S1 ('MetaSel ('Just "revisionId") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 (Maybe Text)) :*: S1 ('MetaSel ('Just "httpStatus") 'NoSourceUnpackedness 'NoSourceStrictness 'DecidedStrict) (Rec0 Int))))

newGetPolicyResponse Source #

Create a value of GetPolicyResponse 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:policy:GetPolicyResponse', getPolicyResponse_policy - The resource-based policy.

$sel:revisionId:GetPolicyResponse', getPolicyResponse_revisionId - A unique identifier for the current revision of the policy.

$sel:httpStatus:GetPolicyResponse', getPolicyResponse_httpStatus - The response's http status code.

Response Lenses

getPolicyResponse_revisionId :: Lens' GetPolicyResponse (Maybe Text) Source #

A unique identifier for the current revision of the policy.

getPolicyResponse_httpStatus :: Lens' GetPolicyResponse Int Source #

The response's http status code.