Zapier Provides Data to Your Pre-Built Function

This is the Invoke Function action. This presumes you have a pre-built function that you just want Zapier to invoke with some special arguments or data we provide from a trigger. Return data is ignored.

Invoking a Lambda function from Zapier is simple. First select your region, and choose the function to invoke:

Then, provide the arguments that you want to be provided to your function when it is invoked - you'll access it as the event object you may recognize from the AWS Lambda documentation.

To add more arguments, use the + button. A function you would upload to AWS Lambda to consume this event might look something like:

exports.handler = function(event, context) {
  // you have access to the event object:
  // event == {name: "FancyFile.pdf", size: 165435}
  context.succeed();
};

Note - if you are using Java or some other runtime - you may need to deserialize the payload/event as it could be passed in as a JSON bytestring. This is done for you automatically in the Node.js runtime.

Was this article helpful?
0 out of 0 found this helpful