Role-based Authentication: Enable this setting to use the RudderStack IAM role for authentication. For more information on creating an AWS IAM role for RudderStack, refer to this guide.
IAM Role ARN: Enter the ARN of the IAM role.
It is highly recommended to enable this setting as the access keys-based authentication method is now deprecated.
If Role-based Authentication is disabled, you need to enter the AWS Access Key ID and AWS Secret Access Key to authorize RudderStack.
In both the role-based and access key-based authentication methods, you need to set a policy specifying the required permissions for RudderStack to send data to your Lambda function. Refer to the Policy permissions section below for more information.
Lambda: Enter the name of the Lambda function to be invoked. RudderStack supports the following formats:
You can also append a version number or alias to any of the above formats.
Enable Batch Input: Enable this setting if your lambda function expects a batch input (array of events) in the event object.
Max Batch Size: If Enable Batch Input setting is enabled, use this field to set the maximum size of the event batch.
Client Context: Use this field to pass up to 3583 bytes of Base64-encoded data about the invoking client to the function in the context object.
Policy permissions
To use the Lambda destination with RudderStack correctly, you must have a Lambda function set up in AWS. Refer to the AWS documentation for more information on setting up your Lambda function.
You also need to create an IAM role and grant the necessary permissions for RudderStack to send data to your lambda function. For more information, refer to this AWS documentation.
The following permission need to be attached to the role while setting up the policy:
"Action":["lambda:InvokeFunction"]
A sample permissions policy that allows a user to send event data into AWS Lambda is shown below:
This destination accepts raw event data similar to a webhook. RudderStack sends the entire event payload to AWS Lambda as is, without any transformation or modification.
RudderStack leverages the AWS SDK for Go to send the events to the lambda function. It uses the SDK’s Invoke method to asynchronously invoke the lambda function.
As RudderStack supports only asynchronous invocation, it only guarantees the order in which the events are triggered. Also, the execution time is completely dependent on the complexity of your lambda function.
It is highly recommended to configure a dead-letter queue to save the discarded events for further processing.
Viewing error logs
RudderStack does not get any information related to the runtime errors for your lambda function. As a result, you will not be able to view these errors in the Live Events tab of your dashboard.
To view these errors, you can configure the AWS CloudWatch logs for your lambda function.
FAQ
Why am I getting a UnrecognizedClientException/InvalidSignatureException error?
If you’re getting a UnrecognizedClientException error with a 403 status code, verify if your AWS credentials (both AWS Access Key ID and Secret Access Key) are valid.
For the InvalidSignatureException error, verify if the provided secret access key is valid.
This site uses cookies to improve your experience while you navigate through the website. Out of
these
cookies, the cookies that are categorized as necessary are stored on your browser as they are as
essential
for the working of basic functionalities of the website. We also use third-party cookies that
help
us
analyze and understand how you use this website. These cookies will be stored in your browser
only
with
your
consent. You also have the option to opt-out of these cookies. But opting out of some of these
cookies
may
have an effect on your browsing experience.
Necessary
Always Enabled
Necessary cookies are absolutely essential for the website to function properly. This
category only includes cookies that ensures basic functionalities and security
features of the website. These cookies do not store any personal information.
This site uses cookies to improve your experience. If you want to
learn more about cookies and why we use them, visit our cookie
policy. We'll assume you're ok with this, but you can opt-out if you wish Cookie Settings.