Reputation: 11
How do I invoke an AWS Step Function using an API Gateway GET request, and the request's JSON payload to the Step Function?
I need the API Gateway to start a Step Function which then invokes a Lambda function that uses the URL input parameter 'pk'.
I have tried this by adding a mapping template within the integration request section. It looks like this:
{
"input": {
"pk": "$input.params('pk')"
}
"stateMachineArn": "arn:aws:states:eu-central-1:............"
}
Upvotes: 1
Views: 1058
Reputation: 2219
I suggest you check out Serverlessland and specifically the Workflows Collection. Lots of awesome examples! You can filter by service to show examples that involve API Gateway. Here's a specific example that might be helpful for you.
There's also a module in the Step Functions Workshop that covers this topic.
Hope this helps!
Upvotes: 1