Package Exports
- @aws-lite/lambda
- @aws-lite/lambda/src/index.mjs
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (@aws-lite/lambda) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
@aws-lite/lambda
Official
aws-liteplugin for Lambda
Maintained by: @architect
Install
npm i @aws-lite/lambdaOptionally install types:
npm i -D @aws-lite/lambda-typesReference
Reference documentation with examples at aws-lite.org
Methods
AddLayerVersionPermission
Properties:
LayerName(string) [required]- Name or ARN of the layer
RevisionId(string)- Update the function config only if the current revision ID matches the specified
RevisionId; used to avoid modifying a function that has changed since you last read it
- Update the function config only if the current revision ID matches the specified
VersionNumber(number) [required]- The version number of the layer
Action(string) [required]- The API action that grants access to the layer, for example
lambda:GetLayerVersion
- The API action that grants access to the layer, for example
OrganizationId(string)- When
Principalis set to*, permission will be granted to all accounts in the specified organization
- When
Principal(string)- Account ID being granted permissions. Use
*along with theOrganizationIdto grant permissions to all accounts in the specified organization
- Account ID being granted permissions. Use
StatementId(string) [required]- ID to distinguish the policy from other policies on the same layer version
AddPermission
Properties:
FunctionName(string) [required]- The name of the Lambda function, version, or alias
Qualifier(string)- Specify a version or alias to invoke a published version of the function
Action(string) [required]- Action that the principal can use on the function; for example,
lambda:InvokeFunction
- Action that the principal can use on the function; for example,
EventSourceToken(string)- A token that Alexa Smart Home requires from the invoker
FunctionUrlAuthType(string)- The type of authentication that your function URL uses. Set to AWS_IAM if you want to restrict access to authenticated users only. Set to NONE if you want to bypass IAM authentication to create a public endpoint
Principal(string) [required]- The AWS service or AWS account that invokes the function
PrincipalOrgID(string)- The identifier for your organization in AWS Organizations
RevisionId(string)- Update the function config only if the current revision ID matches the specified
RevisionId; used to avoid modifying a function that has changed since you last read it
- Update the function config only if the current revision ID matches the specified
SourceAccount(string)- ID of the AWS account that owns the resource
SourceArn(string)- ARN of the AWS resource that invokes the function, such as an Amazon S3 bucket
StatementId(string) [required]- A statement identifier that differentiates the statement from others in the same policy
CreateAlias
Properties:
FunctionName(string) [required]- The name of the Lambda function, version, or alias
Description(string)- Description of the function
FunctionVersion(string) [required]- Version of the aliased function
Name(string) [required]- Name of the alias
RoutingConfig(object)- Configure function version weights
- More details (AWS)
CreateCodeSigningConfig
Properties:
AllowedPublishers(object) [required]- Signing profiles for this code signing configuration
- More details (AWS)
CodeSigningPolicies(object)- Define actions to take if validation checks fail
- More details (AWS)
Description(string)- Description of the function
CreateEventSourceMapping
Properties:
FunctionName(string) [required]- The name of the Lambda function, version, or alias
AmazonManagedKafkaEventSourceConfig(object)- Configuration settings for an Amazon Managed Streaming for Apache Kafka event source
BatchSize(number)- Maximum number of records from 1 to 10000 in each batch that Lambda pulls from the stream or queue
- More details (AWS)
BisectBatchOnFunctionError(boolean)- If the function returns an error, divide the batch and try again (only for Kinesis and DynamoDB streams)
DestinationConfig(object)- Specify the destination of an event after being processed by Lambda
- More details (AWS)
DocumentDBEventSourceConfig(object)- Configuration for a
DocumentDBevent source - More details (AWS)
- Configuration for a
Enabled(boolean)- Set to
falseto disable event source upon creation
- Set to
EventSourceArn(string)- ARN of the event source
FilterCriteria(object)- Define how incoming events will be filtered
- More details (AWS)
FunctionResponseTypes(array)- A list of at most 1 string defining the current response type enum applied to the event source mapping; For Kinesis, DynamoDB Streams, and Amazon SQS
- More details (AWS)
MaximumBatchingWindowInSeconds(number)- Maximum time (in seconds) from 0 to 300 that Lambda may spend gathering records before invoking the function
- More details (AWS)
MaximumRecordAgeInSeconds(number)- Maximum age between -1 (infinite, default) to 604,800 of an event before it will be discarded; only for
KinesisandDynamoDBstreams
- Maximum age between -1 (infinite, default) to 604,800 of an event before it will be discarded; only for
MaximumRetryAttempts(number)- Maximum number of tries between -1 (infinite, default) to 10,000 before a record is discarded;
KinesisandDynamoDBonly
- Maximum number of tries between -1 (infinite, default) to 10,000 before a record is discarded;
ParallelizationFactor(number)- Number of batches between 1 to 10 that can be processed from each shard concurrently
Queues(array)- Array of exactly 1 string specifying the name of the
Amazon MQbroker destination queue to consume
- Array of exactly 1 string specifying the name of the
ScalingConfig(object)- Configure scaling for the event source; Amazon SQS only
- More details (AWS)
SelfManagedEventSource(object)- A self managed
Apache Kafkacluster to receive records from - More details (AWS)
- A self managed
SelfManagedKafkaEventSourceConfig(object)- Configure a self managed
Apache Kafkaevent source - More details (AWS)
- Configure a self managed
SourceAccessConfigurations(array)- Array of at most 22
SourceAccessConfigurationobjects to specifying authentication protocols or VPC components required to secure the event source - More details (AWS)
- Array of at most 22
StartingPosition(string)- Position in a stream to begin reading, valid entries are
TRIM_HORIZON(all available messages),LATEST(from now or after) orAT_TIMESTAMP(specify timestamp) - More details (AWS)
- Position in a stream to begin reading, valid entries are
StartingPositionTimestamp(object)- The
timestampinUnix time secondsused whenStartingPositionis set toAT_TIMESTAMP; cannot be in the future
- The
Topics(array)- Array of exactly 1 string specifying the name of the
Kafkatopic
- Array of exactly 1 string specifying the name of the
TumblingWindowInSeconds(number)- Time (in seconds) from 0 to 900 specifying the duration of a processing window for
DynamoDBandKinesisevent stream sources
- Time (in seconds) from 0 to 900 specifying the duration of a processing window for
CreateFunction
Properties:
Code(object) [required]- Code payload to be run in Lambda; object can contain:
ImageUri(ECR image),S3Bucket+S3Key+S3ObjectVersion(S3 bucket in the same region, key, and optional version), orZipFile(base64-encoded zip) - More details (AWS)
- Code payload to be run in Lambda; object can contain:
FunctionName(string) [required]- The name of the Lambda function, version, or alias
Role(string) [required]- ARN of the function's execution role
Architectures(array)- System architecture, array can contain either
x86_64(default) orarm64
- System architecture, array can contain either
CodeSigningConfigArn(string)- ARN of a code-signing configuration used to enable code signing for this function
DeadLetterConfig(object)- Dead-letter queue configuration
- More details (AWS)
Description(string)- Description of the function
Environment(object)- Environment variable configuration
- More details (AWS)
EphemeralStorage(object)- Size of the function
/tmpdirectory (in MB), from 512 (default) to 10240 - More details (AWS)
- Size of the function
FileSystemConfigs(array)- EFS file system connection settings
- More details (AWS)
Handler(string)- The name of the handler file and method method within your code that Lambda calls to run your function (e.g.
index.handler) - More details (AWS)
- The name of the handler file and method method within your code that Lambda calls to run your function (e.g.
ImageConfig(object)- Container image configuration (overrides Docker file)
- More details (AWS)
KMSKeyArn(string)- ARN of the Key Management Service (KMS) customer managed key used to encrypt your function environment variables
Layers(array)- List of function layer ARNs (including version) to add to the function execution environment
MemorySize(number)- Amount of memory available (in MB) at runtime from 128 to 10240; increasing memory also increases CPU allocation
PackageType(string)- Deployment package type, either
Image(container image) orZip(zip archive)
- Deployment package type, either
Publish(boolean)- Set to
trueto publish the first version of the function during creation
- Set to
Runtime(string)- Runtime identifier
- More details (AWS)
SnapStart(object)- SnapStart settings
- More details (AWS)
Tags(array)- List of tags to apply to the function
Timeout(number)- Time (in seconds) a function is allowed to run before being stopped, from 3 (default) to 900
TracingConfig(object)- Sample and trace a subset of incoming requests with X-Ray
- More details (AWS)
VpcConfig(object)- VPC networking configuration
- More details (AWS)
CreateFunctionUrlConfig
Properties:
AuthType(string) [required]- Type of authentication that the function URL will use, either
AWS_IAMorNONE
- Type of authentication that the function URL will use, either
FunctionName(string) [required]- The name of the Lambda function, version, or alias
Cors(object)- Cross-origin resource sharing settings
- More details (AWS)
InvokeMode(string)- Specify how the function will be invoked, either
BUFFERED(default, uses theInvokeAPI operation) orRESPONSE_STREAM(streams results as they become available, uses theInvokeWithResponseStreamAPI operation) - More details (AWS)
- Specify how the function will be invoked, either
Qualifier(string)- Specify a version or alias to invoke a published version of the function
DeleteAlias
Properties:
FunctionName(string) [required]- The name of the Lambda function, version, or alias
Name(string) [required]- Name of the alias
DeleteCodeSigningConfig
Properties:
CodeSigningConfigArn(string) [required]- ARN of the code signing configuration
DeleteEventSourceMapping
Properties:
UUID(string) [required]- UUID of the event source mapping
DeleteFunction
Properties:
FunctionName(string) [required]- The name of the Lambda function, version, or alias
Qualifier(string)- Specify a version or alias to invoke a published version of the function
DeleteFunctionCodeSigningConfig
Properties:
FunctionName(string) [required]- The name of the Lambda function, version, or alias
DeleteFunctionConcurrency
Properties:
FunctionName(string) [required]- The name of the Lambda function, version, or alias
DeleteFunctionEventInvokeConfig
Properties:
FunctionName(string) [required]- The name of the Lambda function, version, or alias
Qualifier(string)- Specify a version or alias to invoke a published version of the function
DeleteFunctionUrlConfig
Properties:
FunctionName(string) [required]- The name of the Lambda function, version, or alias
Qualifier(string)- Specify a version or alias to invoke a published version of the function
DeleteLayerVersion
Properties:
LayerName(string) [required]- Name or ARN of the layer
VersionNumber(number) [required]- The version number of the layer
DeleteProvisionedConcurrencyConfig
Properties:
FunctionName(string) [required]- The name of the Lambda function, version, or alias
Qualifier(string) [required]- Specify a version or alias to invoke a published version of the function
GetAccountSettings
Properties:
GetAlias
Properties:
FunctionName(string) [required]- The name of the Lambda function, version, or alias
Name(string) [required]- Name of the function alias
GetCodeSigningConfig
Properties:
CodeSigningConfigArn(string) [required]- ARN of the code signing configuration
GetEventSourceMapping
Properties:
UUID(string) [required]- ARN of the event source mapping
GetFunction
Properties:
FunctionName(string) [required]- The name of the Lambda function, version, or alias
Qualifier(string)- Specify a version or alias to invoke a published version of the function
GetFunctionCodeSigningConfig
Properties:
FunctionName(string) [required]- The name of the Lambda function, version, or alias
GetFunctionConcurrency
Properties:
FunctionName(string) [required]- The name of the Lambda function, version, or alias
GetFunctionConfiguration
Properties:
FunctionName(string) [required]- The name of the Lambda function, version, or alias
Qualifier(string)- Specify a version or alias to invoke a published version of the function
GetFunctionEventInvokeConfig
Properties:
FunctionName(string) [required]- The name of the Lambda function, version, or alias
Qualifier(string)- Specify a version or alias to invoke a published version of the function
GetFunctionUrlConfig
Properties:
FunctionName(string) [required]- The name of the Lambda function, version, or alias
Qualifier(string)- Specify a version or alias to invoke a published version of the function
GetLayerVersion
Properties:
LayerName(string) [required]- Name or ARN of the layer
VersionNumber(number) [required]- The version number of the layer
GetLayerVersionByArn
Properties:
Arn(string) [required]- The ARN of the layer version
GetLayerVersionPolicy
Properties:
LayerName(string) [required]- Name or ARN of the layer
VersionNumber(number) [required]- The version number of the layer
GetPolicy
Properties:
FunctionName(string) [required]- The name of the Lambda function, version, or alias
Qualifier(string)- Specify a version or alias to invoke a published version of the function
GetProvisionedConcurrencyConfig
Properties:
FunctionName(string) [required]- The name of the Lambda function, version, or alias
Qualifier(string) [required]- The version number or alias name
GetRuntimeManagementConfig
Properties:
FunctionName(string) [required]- The name of the Lambda function, version, or alias
Qualifier(string)- Specify a version or alias to invoke a published version of the function
Invoke
Properties:
FunctionName(string) [required]- The name of the Lambda function, version, or alias
InvocationType(string)- Set invocation type to one of:
RequestResponse(default, synchronous),Event(asynchronous),DryRun(validate invoke request only)
- Set invocation type to one of:
Payload(array, object) [required]- Event payload to invoke function with
LogType(string)- Set to
Tailto include the execution log in theX-Amz-Log-Resultresponse header of synchronously invoked functions
- Set to
ClientContext(string)- Up to 3,583 bytes of base64-encoded data to pass to the function in the context object
Qualifier(string)- Specify a version or alias to invoke a published version of the function
ListAliases
Properties:
FunctionName(string) [required]- The name of the Lambda function, version, or alias
FunctionVersion(string)- Version of the aliased function
Marker(string)- Pagination token
MaxItems(number)- Maximum number of items to be returned; maximum 10,000
paginate(boolean)- Enable automatic result pagination; use this instead of making your own individual pagination requests
ListCodeSigningConfigs
Properties:
Marker(string)- Pagination token
MaxItems(number)- Maximum number of items to be returned; maximum 10,000
paginate(boolean)- Enable automatic result pagination; use this instead of making your own individual pagination requests
ListFunctions
Properties:
FunctionVersion(string)- Set to
ALLto include entries for all published versions
- Set to
Marker(string)- Pagination token
MasterRegion(string)- Display
LambdaEdgefunctions replicated from a master function in a specified region - More details (AWS)
- Display
MaxItems(number)- Maximum number of items to be returned; maximum 10,000
paginate(boolean)- Enable automatic result pagination; use this instead of making your own individual pagination requests
ListFunctionUrlConfigs
Properties:
FunctionName(string) [required]- The name of the Lambda function, version, or alias
Marker(string)- Pagination token
MaxItems(number)- Maximum number of items to be returned; maximum 10,000
paginate(boolean)- Enable automatic result pagination; use this instead of making your own individual pagination requests
ListLayers
Properties:
CompatibleArchitecture(string)- Set instruction set architecture to one of:
x86_64,arm64
- Set instruction set architecture to one of:
CompatibleRuntime(string)- Set the runtime identifier
- More details (AWS)
Marker(string)- Pagination token
MaxItems(number)- Maximum number of items to be returned; maximum 10,000
paginate(boolean)- Enable automatic result pagination; use this instead of making your own individual pagination requests
ListLayerVersions
Properties:
LayerName(string) [required]- Name or ARN of the layer
CompatibleArchitecture(string)- Set instruction set architecture to one of:
x86_64,arm64
- Set instruction set architecture to one of:
CompatibleRuntime(string)- Set the runtime identifier
- More details (AWS)
Marker(string)- Pagination token
MaxItems(number)- Maximum number of items to be returned; maximum 10,000
paginate(boolean)- Enable automatic result pagination; use this instead of making your own individual pagination requests
PutFunctionConcurrency
Properties:
FunctionName(string) [required]- The name of the Lambda function, version, or alias
ReservedConcurrentExecutions(number) [required]- number of simultaneous executions to reserve
UpdateAlias
Properties:
FunctionName(string) [required]- The name of the Lambda function, version, or alias
Name(string) [required]- Name of the alias
Description(string)- Description of the function
FunctionVersion(string)- Version of the aliased function
RevisionId(string)- Update the function config only if the current revision ID matches the specified
RevisionId; used to avoid modifying a function that has changed since you last read it
- Update the function config only if the current revision ID matches the specified
RoutingConfig(object)- Configure function version weights
- More details (AWS)
UpdateFunctionCode
Properties:
FunctionName(string) [required]- The name of the Lambda function, version, or alias
Architectures(array)- System architecture, array can contain either
x86_64(default) orarm64
- System architecture, array can contain either
DryRun(string)- Validate the request parameters and access permissions without modifying the function code (
true)
- Validate the request parameters and access permissions without modifying the function code (
ImageUri(string)- URI of a container image in the Amazon ECR registry (if not using a .zip file)
Publish(boolean)- Publish a new version after after updating the code (
true); effectively the same as callingPublishVersion
- Publish a new version after after updating the code (
RevisionId(string)- Update the function config only if the current revision ID matches the specified
RevisionId; used to avoid modifying a function that has changed since you last read it
- Update the function config only if the current revision ID matches the specified
S3Bucket(string)- S3 bucket containing the key of the deployment package; must be in the same region
S3Key(string)- S3 key of the deployment package (must be a .zip file)
S3ObjectVersion(string)- S3 object version to use, if applicable
ZipFile(string, buffer)- File path or raw buffer of the .zip deployment package
UpdateFunctionConfiguration
Properties:
FunctionName(string) [required]- The name of the Lambda function, version, or alias
DeadLetterConfig(object)- Dead-letter queue configuration
- More details (AWS)
Description(string)- Description of the function
Environment(object)- Environment variable configuration
- More details (AWS)
EphemeralStorage(object)- Size of the function
/tmpdirectory (in MB), from 512 (default) to 10240 - More details (AWS)
- Size of the function
FileSystemConfigs(array)- EFS file system connection settings
- More details (AWS)
Handler(string)- The name of the handler file and method method within your code that Lambda calls to run your function (e.g.
index.handler) - More details (AWS)
- The name of the handler file and method method within your code that Lambda calls to run your function (e.g.
ImageConfig(object)- Container image configuration (overrides Docker file)
- More details (AWS)
KMSKeyArn(string)- ARN of the Key Management Service (KMS) customer managed key used to encrypt your function environment variables
Layers(array)- List of function layer ARNs (including version) to add to the function execution environment
MemorySize(number)- Amount of memory available (in MB) at runtime from 128 to 10240; increasing memory also increases CPU allocation
RevisionId(string)- Update the function config only if the current revision ID matches the specified
RevisionId; used to avoid modifying a function that has changed since you last read it
- Update the function config only if the current revision ID matches the specified
Role(string)- ARN of the function's execution role
Runtime(string)- Runtime identifier
- More details (AWS)
SnapStart(object)- SnapStart settings
- More details (AWS)
Timeout(number)- Time (in seconds) a function is allowed to run before being stopped, from 3 (default) to 900
TracingConfig(object)- Sample and trace a subset of incoming requests with X-Ray
- More details (AWS)
VpcConfig(object)- VPC networking configuration
- More details (AWS)
Methods yet to be implemented
Please help out by opening a PR!
InvokeAsyncInvokeWithResponseStreamListEventSourceMappingsListFunctionEventInvokeConfigsListFunctionsByCodeSigningConfigListProvisionedConcurrencyConfigsListTagsListVersionsByFunctionPublishLayerVersionPublishVersionPutFunctionCodeSigningConfigPutFunctionEventInvokeConfigPutProvisionedConcurrencyConfigPutRuntimeManagementConfigRemoveLayerVersionPermissionRemovePermissionTagResourceUntagResourceUpdateCodeSigningConfigUpdateEventSourceMappingUpdateFunctionEventInvokeConfigUpdateFunctionUrlConfig