Last active
October 11, 2020 14:02
-
-
Save bmccann36/4f6417f5c4e7372599db658629e4c2b6 to your computer and use it in GitHub Desktop.
example of invoking a Lambda function from Javascript api
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
const params = { | |
FunctionName: "my-function", InvocationType: "Event", Payload: "<Binary String>", Qualifier: "1" | |
}; | |
lambda.invoke(params, function (err, data) { | |
if (err) console.log(err, err.stack); // an error occurred | |
else console.log(data); // successful response | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment