1
votes

In reviewing this URL from AWS I don't see any obvious way to add a "test event" programatically via the AWS CLI? Is there a way to do this?

https://docs.aws.amazon.com/cli/latest/reference/lambda/index.html

1
I haven't yet explored using SAM too much, although I think I'd like to. I was hoping for something in the AWS CLI natively, without using something else like SAM.atom88
Unfortunatly, as @JohnRotenstein explained, its not available in CLI. You can generate events from SAM or copy/paste from console and use that, if this is any help. If you want something more advanced, then there is moto.Marcin

1 Answers

2
votes

The Test capabilities presented in the AWS Lambda management console are a feature of the console itself, not the AWS Lambda service.

The Test feature provides the ability to define an incoming event record, then invoke the Lambda using that record.

You could do the same thing from an AWS CLI call, but you would need to provide the event to pass to the function.