You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: packages/@aws-cdk/aws-stepfunctions-tasks/README.md
+13Lines changed: 13 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -623,6 +623,19 @@ new tasks.LambdaInvoke(this, 'Invoke and set function response as task output',
623
623
});
624
624
```
625
625
626
+
If you want to combine the input and the Lambda function response you can use
627
+
the `payloadResponseOnly` property and specify the `resultPath`. This will put the
628
+
Lambda function ARN directly in the "Resource" string, but it conflicts with the
629
+
integrationPattern, invocationType, clientContext, and qualifier properties.
630
+
631
+
```ts
632
+
newtasks.LambdaInvoke(this, 'Invoke and combine function response with task input', {
633
+
lambdaFunction: myLambda,
634
+
payloadResponseOnly: true,
635
+
resultPath: '$.myLambda',
636
+
});
637
+
```
638
+
626
639
You can have Step Functions pause a task, and wait for an external process to
627
640
return a task token. Read more about the [callback pattern](https://docs.aws.amazon.com/step-functions/latest/dg/callback-task-sample-sqs.html#call-back-lambda-example)
0 commit comments