Skip to content

remove_permission

Operation

remove_permission

remove_permission(request: RemovePermissionInput | RemovePermissionInputDict | None = None, /, *, plugins: list[Plugin] | None = None, **kwargs: Unpack[RemovePermissionInputDict]) -> RemovePermissionOutput

Revokes function-use permission from an Amazon Web Services service or another Amazon Web Services account. You can get the ID of the statement from the output of GetPolicy.

Parameters:

Name Type Description Default
request RemovePermissionInput | RemovePermissionInputDict | None

The input as a model or dictionary. Pass this or keyword arguments, not both.

None
plugins list[Plugin] | None

A list of callables that modify the configuration dynamically. Changes made by these plugins only apply for the duration of the operation execution and will not affect any other operation invocations.

None
**kwargs Unpack[RemovePermissionInputDict]

The input fields as keyword arguments.

{}

Returns:

Type Description
RemovePermissionOutput

An instance of RemovePermissionOutput.

remove_permission async

remove_permission(request: RemovePermissionInput | RemovePermissionInputDict | None = None, /, *, plugins: list[Plugin] | None = None, **kwargs: Unpack[RemovePermissionInputDict]) -> RemovePermissionOutput

Revokes function-use permission from an Amazon Web Services service or another Amazon Web Services account. You can get the ID of the statement from the output of GetPolicy.

Parameters:

Name Type Description Default
request RemovePermissionInput | RemovePermissionInputDict | None

The input as a model or dictionary. Pass this or keyword arguments, not both.

None
plugins list[Plugin] | None

A list of callables that modify the configuration dynamically. Changes made by these plugins only apply for the duration of the operation execution and will not affect any other operation invocations.

None
**kwargs Unpack[RemovePermissionInputDict]

The input fields as keyword arguments.

{}

Returns:

Type Description
RemovePermissionOutput

An instance of RemovePermissionOutput.

Input

Pass the input as keyword arguments, a positional dictionary, or a positional model object. Pass plugins separately as a keyword argument.

RemovePermissionInputDict

Bases: TypedDict

Dictionary form of RemovePermissionInput.

Attributes

function_name instance-attribute
function_name: Required[str]

The name or ARN 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.

qualifier instance-attribute
qualifier: str | None

Specify a version or alias to remove permissions from a published version of the function.

revision_id instance-attribute
revision_id: str | None

Update the policy only if the revision ID matches the ID that's specified. Use this option to avoid modifying a policy that has changed since you last read it.

statement_id instance-attribute
statement_id: Required[str]

Statement ID of the permission to remove.

RemovePermissionInput dataclass

Bases: _SerdeShape

Dataclass for RemovePermissionInput structure.

Attributes

function_name class-attribute instance-attribute
function_name: str | None = ...

The name or ARN 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.

qualifier class-attribute instance-attribute
qualifier: str | None = ...

Specify a version or alias to remove permissions from a published version of the function.

revision_id class-attribute instance-attribute
revision_id: str | None = ...

Update the policy only if the revision ID matches the ID that's specified. Use this option to avoid modifying a policy that has changed since you last read it.

statement_id class-attribute instance-attribute
statement_id: str | None = ...

Statement ID of the permission to remove.

Output

RemovePermissionOutput dataclass

Bases: _SerdeShape

Dataclass for RemovePermissionOutput structure.

Attributes

response_metadata class-attribute instance-attribute
response_metadata: ResponseMetadata = ...

Metadata about the response that produced this output. Use this to recover the request identifiers a service's support team needs in order to investigate a call. Members of the metadata are individually optional.