Testing and Deployment
Which template declaration enables CloudFormation to process AWS::Serverless resources in an AWS SAM template?
Show the answer
Correct answerB. Transform: AWS::Serverless-2016-10-31
AWhy not this: This identifies the CloudFormation template format version but does not enable the SAM transform.
BWhy this is right: This invokes the AWS SAM transform to expand AWS::Serverless resource definitions.
CWhy not this: This metadata organizes parameter presentation in the CloudFormation console rather than expanding SAM resources.
DWhy not this: This is an IAM policy language version declaration, not a CloudFormation transform declaration.
The AWS::Serverless transform expands SAM resource definitions into CloudFormation resources. AWSTemplateFormatVersion identifies the CloudFormation template format; it does not enable SAM processing.