# AWS Serverless Application Model Construct Library

This module is part of the [AWS Cloud Development Kit](https://github.com/aws/aws-cdk) project.

```ts
import * as serverless from 'aws-cdk-lib/aws-sam';
```

There are no official hand-written ([L2](https://docs.aws.amazon.com/cdk/latest/guide/constructs.html#constructs_lib)) constructs for this service yet. Here are some suggestions on how to proceed:

- Search [Construct Hub for Serverless construct libraries](https://constructs.dev/search?q=serverless)
- Use the automatically generated [L1](https://docs.aws.amazon.com/cdk/latest/guide/constructs.html#constructs_l1_using) constructs, in the same way you would use [the CloudFormation AWS::Serverless resources](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/AWS_Serverless.html) directly.

There are no hand-written ([L2](https://docs.aws.amazon.com/cdk/latest/guide/constructs.html#constructs_lib)) constructs for this service yet.
However, you can still use the automatically generated [L1](https://docs.aws.amazon.com/cdk/latest/guide/constructs.html#constructs_l1_using) constructs, and use this service exactly as you would using CloudFormation directly.

For more information on the resources and properties available for this service, see the [CloudFormation documentation for AWS::Serverless](https://docs.aws.amazon.com/AWSCloudFormation/latest/UserGuide/AWS_Serverless.html).

(Read the [CDK Contributing Guide](https://github.com/aws/aws-cdk/blob/main/CONTRIBUTING.md) and submit an RFC if you are interested in contributing to this construct library.)

## Types

| Name | Kind | Summary |
| --- | --- | --- |
| [`CfnApi`](/v2/docs/aws-cdk-lib.aws_sam.CfnApi) | Construct (L1) | https://github.com/awslabs/serverless-application-model/blob/master/versions/2016-10-31.md#awsserverlessapi. |
| [`CfnApplication`](/v2/docs/aws-cdk-lib.aws_sam.CfnApplication) | Construct (L1) | https://github.com/awslabs/serverless-application-model/blob/master/versions/2016-10-31.md#awsserverlessapplication. |
| [`CfnFunction`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction) | Construct (L1) | https://github.com/awslabs/serverless-application-model/blob/master/versions/2016-10-31.md#awsserverlessfunction. |
| [`CfnHttpApi`](/v2/docs/aws-cdk-lib.aws_sam.CfnHttpApi) | Construct (L1) | https://github.com/aws/serverless-application-model/blob/master/versions/2016-10-31.md#awsserverlesshttpapi. |
| [`CfnLayerVersion`](/v2/docs/aws-cdk-lib.aws_sam.CfnLayerVersion) | Construct (L1) | https://github.com/awslabs/serverless-application-model/blob/master/versions/2016-10-31.md#awsserverlesslayerversion. |
| [`CfnSimpleTable`](/v2/docs/aws-cdk-lib.aws_sam.CfnSimpleTable) | Construct (L1) | https://github.com/awslabs/serverless-application-model/blob/master/versions/2016-10-31.md#awsserverlesssimpletable. |
| [`CfnStateMachine`](/v2/docs/aws-cdk-lib.aws_sam.CfnStateMachine) | Construct (L1) | https://docs.aws.amazon.com/serverless-application-model/latest/developerguide/sam-resource-statemachine.html. |
| [`CfnApi.AccessLogSettingProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnApi.AccessLogSettingProperty) | Struct |  |
| [`CfnApi.AuthProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnApi.AuthProperty) | Struct |  |
| [`CfnApi.CanarySettingProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnApi.CanarySettingProperty) | Struct |  |
| [`CfnApi.CorsConfigurationProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnApi.CorsConfigurationProperty) | Struct |  |
| [`CfnApi.DomainConfigurationProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnApi.DomainConfigurationProperty) | Struct |  |
| [`CfnApi.EndpointConfigurationProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnApi.EndpointConfigurationProperty) | Struct |  |
| [`CfnApi.MutualTlsAuthenticationProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnApi.MutualTlsAuthenticationProperty) | Struct |  |
| [`CfnApi.Route53ConfigurationProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnApi.Route53ConfigurationProperty) | Struct |  |
| [`CfnApi.S3LocationProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnApi.S3LocationProperty) | Struct |  |
| [`CfnApiProps`](/v2/docs/aws-cdk-lib.aws_sam.CfnApiProps) | Struct | Properties for defining a `CfnApi`. |
| [`CfnApplication.ApplicationLocationProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnApplication.ApplicationLocationProperty) | Struct |  |
| [`CfnApplicationProps`](/v2/docs/aws-cdk-lib.aws_sam.CfnApplicationProps) | Struct | Properties for defining a `CfnApplication`. |
| [`CfnFunction.AlexaSkillEventProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.AlexaSkillEventProperty) | Struct |  |
| [`CfnFunction.ApiEventProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.ApiEventProperty) | Struct |  |
| [`CfnFunction.AuthProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.AuthProperty) | Struct |  |
| [`CfnFunction.AuthResourcePolicyProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.AuthResourcePolicyProperty) | Struct |  |
| [`CfnFunction.BucketSAMPTProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.BucketSAMPTProperty) | Struct |  |
| [`CfnFunction.CloudWatchEventEventProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.CloudWatchEventEventProperty) | Struct |  |
| [`CfnFunction.CloudWatchLogsEventProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.CloudWatchLogsEventProperty) | Struct |  |
| [`CfnFunction.CognitoEventProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.CognitoEventProperty) | Struct |  |
| [`CfnFunction.CollectionSAMPTProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.CollectionSAMPTProperty) | Struct |  |
| [`CfnFunction.CorsConfigurationProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.CorsConfigurationProperty) | Struct |  |
| [`CfnFunction.DeadLetterQueueProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.DeadLetterQueueProperty) | Struct |  |
| [`CfnFunction.DeploymentPreferenceProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.DeploymentPreferenceProperty) | Struct |  |
| [`CfnFunction.DestinationConfigProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.DestinationConfigProperty) | Struct |  |
| [`CfnFunction.DestinationProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.DestinationProperty) | Struct |  |
| [`CfnFunction.DomainSAMPTProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.DomainSAMPTProperty) | Struct |  |
| [`CfnFunction.DynamoDBEventProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.DynamoDBEventProperty) | Struct |  |
| [`CfnFunction.EmptySAMPTProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.EmptySAMPTProperty) | Struct |  |
| [`CfnFunction.EphemeralStorageProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.EphemeralStorageProperty) | Struct |  |
| [`CfnFunction.EventBridgeRuleEventProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.EventBridgeRuleEventProperty) | Struct |  |
| [`CfnFunction.EventInvokeConfigProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.EventInvokeConfigProperty) | Struct |  |
| [`CfnFunction.EventInvokeDestinationConfigProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.EventInvokeDestinationConfigProperty) | Struct |  |
| [`CfnFunction.EventSourceProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.EventSourceProperty) | Struct |  |
| [`CfnFunction.FileSystemConfigProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.FileSystemConfigProperty) | Struct |  |
| [`CfnFunction.FunctionEnvironmentProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.FunctionEnvironmentProperty) | Struct |  |
| [`CfnFunction.FunctionSAMPTProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.FunctionSAMPTProperty) | Struct |  |
| [`CfnFunction.FunctionUrlConfigProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.FunctionUrlConfigProperty) | Struct |  |
| [`CfnFunction.HooksProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.HooksProperty) | Struct |  |
| [`CfnFunction.HttpApiEventProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.HttpApiEventProperty) | Struct |  |
| [`CfnFunction.HttpApiFunctionAuthProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.HttpApiFunctionAuthProperty) | Struct |  |
| [`CfnFunction.IAMPolicyDocumentProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.IAMPolicyDocumentProperty) | Struct |  |
| [`CfnFunction.IdentitySAMPTProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.IdentitySAMPTProperty) | Struct |  |
| [`CfnFunction.ImageConfigProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.ImageConfigProperty) | Struct |  |
| [`CfnFunction.IoTRuleEventProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.IoTRuleEventProperty) | Struct |  |
| [`CfnFunction.KeySAMPTProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.KeySAMPTProperty) | Struct |  |
| [`CfnFunction.KinesisEventProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.KinesisEventProperty) | Struct |  |
| [`CfnFunction.LogGroupSAMPTProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.LogGroupSAMPTProperty) | Struct |  |
| [`CfnFunction.ParameterNameSAMPTProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.ParameterNameSAMPTProperty) | Struct |  |
| [`CfnFunction.ProvisionedConcurrencyConfigProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.ProvisionedConcurrencyConfigProperty) | Struct |  |
| [`CfnFunction.QueueSAMPTProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.QueueSAMPTProperty) | Struct |  |
| [`CfnFunction.RequestModelProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.RequestModelProperty) | Struct |  |
| [`CfnFunction.RequestParameterProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.RequestParameterProperty) | Struct |  |
| [`CfnFunction.RouteSettingsProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.RouteSettingsProperty) | Struct |  |
| [`CfnFunction.S3EventProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.S3EventProperty) | Struct |  |
| [`CfnFunction.S3KeyFilterProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.S3KeyFilterProperty) | Struct |  |
| [`CfnFunction.S3KeyFilterRuleProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.S3KeyFilterRuleProperty) | Struct |  |
| [`CfnFunction.S3LocationProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.S3LocationProperty) | Struct |  |
| [`CfnFunction.S3NotificationFilterProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.S3NotificationFilterProperty) | Struct |  |
| [`CfnFunction.SAMPolicyTemplateProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.SAMPolicyTemplateProperty) | Struct |  |
| [`CfnFunction.ScheduleEventProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.ScheduleEventProperty) | Struct |  |
| [`CfnFunction.SecretArnSAMPTProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.SecretArnSAMPTProperty) | Struct |  |
| [`CfnFunction.SNSEventProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.SNSEventProperty) | Struct |  |
| [`CfnFunction.SQSEventProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.SQSEventProperty) | Struct |  |
| [`CfnFunction.StateMachineSAMPTProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.StateMachineSAMPTProperty) | Struct |  |
| [`CfnFunction.StreamSAMPTProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.StreamSAMPTProperty) | Struct |  |
| [`CfnFunction.TableSAMPTProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.TableSAMPTProperty) | Struct |  |
| [`CfnFunction.TableStreamSAMPTProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.TableStreamSAMPTProperty) | Struct |  |
| [`CfnFunction.TopicSAMPTProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.TopicSAMPTProperty) | Struct |  |
| [`CfnFunction.VpcConfigProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunction.VpcConfigProperty) | Struct |  |
| [`CfnFunctionProps`](/v2/docs/aws-cdk-lib.aws_sam.CfnFunctionProps) | Struct | Properties for defining a `CfnFunction`. |
| [`CfnHttpApi.AccessLogSettingProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnHttpApi.AccessLogSettingProperty) | Struct |  |
| [`CfnHttpApi.CorsConfigurationObjectProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnHttpApi.CorsConfigurationObjectProperty) | Struct |  |
| [`CfnHttpApi.HttpApiAuthProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnHttpApi.HttpApiAuthProperty) | Struct |  |
| [`CfnHttpApi.HttpApiDomainConfigurationProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnHttpApi.HttpApiDomainConfigurationProperty) | Struct |  |
| [`CfnHttpApi.MutualTlsAuthenticationProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnHttpApi.MutualTlsAuthenticationProperty) | Struct |  |
| [`CfnHttpApi.Route53ConfigurationProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnHttpApi.Route53ConfigurationProperty) | Struct |  |
| [`CfnHttpApi.RouteSettingsProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnHttpApi.RouteSettingsProperty) | Struct |  |
| [`CfnHttpApi.S3LocationProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnHttpApi.S3LocationProperty) | Struct |  |
| [`CfnHttpApiProps`](/v2/docs/aws-cdk-lib.aws_sam.CfnHttpApiProps) | Struct | Properties for defining a `CfnHttpApi`. |
| [`CfnLayerVersion.S3LocationProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnLayerVersion.S3LocationProperty) | Struct |  |
| [`CfnLayerVersionProps`](/v2/docs/aws-cdk-lib.aws_sam.CfnLayerVersionProps) | Struct | Properties for defining a `CfnLayerVersion`. |
| [`CfnSimpleTable.PrimaryKeyProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnSimpleTable.PrimaryKeyProperty) | Struct |  |
| [`CfnSimpleTable.ProvisionedThroughputProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnSimpleTable.ProvisionedThroughputProperty) | Struct |  |
| [`CfnSimpleTable.SSESpecificationProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnSimpleTable.SSESpecificationProperty) | Struct |  |
| [`CfnSimpleTableProps`](/v2/docs/aws-cdk-lib.aws_sam.CfnSimpleTableProps) | Struct | Properties for defining a `CfnSimpleTable`. |
| [`CfnStateMachine.ApiEventProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnStateMachine.ApiEventProperty) | Struct |  |
| [`CfnStateMachine.CloudWatchEventEventProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnStateMachine.CloudWatchEventEventProperty) | Struct |  |
| [`CfnStateMachine.CloudWatchLogsLogGroupProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnStateMachine.CloudWatchLogsLogGroupProperty) | Struct |  |
| [`CfnStateMachine.EventBridgeRuleEventProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnStateMachine.EventBridgeRuleEventProperty) | Struct |  |
| [`CfnStateMachine.EventSourceProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnStateMachine.EventSourceProperty) | Struct |  |
| [`CfnStateMachine.FunctionSAMPTProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnStateMachine.FunctionSAMPTProperty) | Struct |  |
| [`CfnStateMachine.IAMPolicyDocumentProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnStateMachine.IAMPolicyDocumentProperty) | Struct |  |
| [`CfnStateMachine.LogDestinationProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnStateMachine.LogDestinationProperty) | Struct |  |
| [`CfnStateMachine.LoggingConfigurationProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnStateMachine.LoggingConfigurationProperty) | Struct |  |
| [`CfnStateMachine.S3LocationProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnStateMachine.S3LocationProperty) | Struct |  |
| [`CfnStateMachine.SAMPolicyTemplateProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnStateMachine.SAMPolicyTemplateProperty) | Struct |  |
| [`CfnStateMachine.ScheduleEventProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnStateMachine.ScheduleEventProperty) | Struct |  |
| [`CfnStateMachine.StateMachineSAMPTProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnStateMachine.StateMachineSAMPTProperty) | Struct |  |
| [`CfnStateMachine.TracingConfigurationProperty`](/v2/docs/aws-cdk-lib.aws_sam.CfnStateMachine.TracingConfigurationProperty) | Struct |  |
| [`CfnStateMachineProps`](/v2/docs/aws-cdk-lib.aws_sam.CfnStateMachineProps) | Struct | Properties for defining a `CfnStateMachine`. |
