AWSTemplateFormatVersion: "2010-09-09" Transform: AWS::Serverless-2016-10-31 Description: > call-http-api Sample SAM Template for call-http-api Resources: StateMachineArn: Type: AWS::Serverless::StateMachine # More info about State Machine Resource: https://docs.aws.amazon.com/serverless-application-model/latest/developerguide/sam-resource-statemachine.html Properties: DefinitionUri: statemachine/statemachine.asl.json DefinitionSubstitutions: CallToAPIFunctionName: !Ref LambdaFunctionCallToApiFunction Policies: # Find out more about SAM policy templates: https://docs.aws.amazon.com/serverless-application-model/latest/developerguide/serverless-policy-templates.html - LambdaInvokePolicy: FunctionName: !Ref LambdaFunctionCallToApiFunction LambdaFunctionCallToApiFunction: Type: AWS::Serverless::Function Properties: CodeUri: CallToApiFunction/function/ Handler: app.lambdaHandler Runtime: nodejs14.x Timeout: 3 Outputs: # StockTradingStateMachineHourlyTradingSchedule is an implicit Schedule event rule created out of Events key under Serverless::StateMachine # Find out more about other implicit resources you can reference within SAM # https://docs.aws.amazon.com/serverless-application-model/latest/developerguide/sam-specification-generated-resources.html StateMachineArn: Description: "state machine ARN" Value: !Ref StateMachineArn