Skip to main content

aliases

Creates, updates, deletes, gets or lists an aliases resource.

Overview

Namealiases
TypeResource
Idaws.lambda.aliases

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
alias_arnstringThe Amazon Resource Name (ARN) of the alias. (pattern: <code>arn:(aws[a-zA-Z-]*)?:lambda:(eusc-)?[a-z]{2}((-gov)|(-iso([a-z]?)))?-[a-z]+-\d{1}:\d{12}:function:[a-zA-Z0-9-]+(:($LATEST|[a-zA-Z0-9-]+))?</code>)
descriptionstringA description of the alias.
function_versionstringThe function version that the alias invokes. (pattern: <code>($LATEST|[0-9]+)</code>)
namestringThe name of the alias. (pattern: <code>(?!^[0-9]+$)([a-zA-Z0-9-_]+)</code>)
revision_idstringA unique identifier that changes when you update the alias.
routing_configobjectThe traffic-shifting configuration of a Lambda function alias.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
list_aliasesselectfunction_name, regionFunctionVersion, Marker, MaxItemsReturns a list of aliases for a Lambda function.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
function_namestringThe name or ARN of the Lambda function. Name formats Function name - MyFunction. Function ARN - arn:aws:lambda:us-west-2:123456789012:function:MyFunction. Partial ARN - 123456789012:function:MyFunction. The length constraint applies only to the full ARN. If you specify only the function name, it is limited to 64 characters in length.
regionstringAWS region (default: us-east-1)
FunctionVersionstringSpecify a function version to only list aliases that invoke that version.
MarkerstringSpecify the pagination token that's returned by a previous request to retrieve the next page of results.
MaxItemsintegerLimit the number of aliases returned.

SELECT examples

Returns a list of aliases for a Lambda function.

SELECT
alias_arn,
description,
function_version,
name,
revision_id,
routing_config
FROM aws.lambda.aliases
WHERE function_name = '{{ function_name }}' -- required
AND region = '{{ region }}' -- required
AND FunctionVersion = '{{ FunctionVersion }}'
AND Marker = '{{ Marker }}'
AND MaxItems = '{{ MaxItems }}'
;