A team defines a serverless app (Lambda, API Gateway, DynamoDB) in YAML and wants shorthand syntax that expands into full CloudFormation. Which tool is this?
A.AWS CDK
CDK uses programming languages, not YAML shorthand.
B.AWS SAM — serverless-specific CloudFormation shorthand + local testing CLI
Correct. SAM = serverless CloudFormation macros.
C.Elastic Beanstalk
Beanstalk deploys traditional apps, not SAM templates.
D.AWS Amplify
Amplify is a frontend/mobile hosting toolchain.
Why this answer
SAM (Serverless Application Model) is CloudFormation's serverless shorthand — AWS::Serverless::Function expands to function + role + triggers — plus sam local for testing. CDK is code-first synthesis; Beanstalk is a PaaS for traditional apps.
Correct answer: B · Last reviewed 2026-11-03
Official AWS references
Practice this interactively
Answer without seeing the solution first in the CI/CD & Observability practice session.
Practice CI/CD & Observability