Skip to content

Latest commit

 

History

History
19 lines (11 loc) · 1.32 KB

File metadata and controls

19 lines (11 loc) · 1.32 KB

Use AWS Lambda Function URL to Receive Live Stream Thumbnails

This repository includes the sample code to receive and store thumbnails after you set up an Lambda function enabling Function URL and setting up an S3 Bucket.

To learn how to do it step by step, follow this blog post.

If you decide to use different names than the ones in the example, you need to update the package name(in package.json), and update the S3 bucket name in index.mjs. Then, type npm install to obtain node_modules locally and zip your folder to be able to use this sample code directly from AWS Lambda Console code editor.

Note: You might be having an issue if you tried to zip the file using Mac's built-in compression function in Finder. If you're a Mac user you should run the following script in terminal when you are in the root directory of your project (folder containing your index.mjs, node_modules, etc. files).

  • zip -r ../yourfilename.zip *

For Windows:
Compress-Archive -LiteralPath node_modules, index.mjs -DestinationPath yourfilename.zip

Required environment variables

  • WEBHOOK_SECRET - the webhook secret from the Dolby.io dashboard.
  • AWS_S3_BUCKET_NAME - the name of the AWS S3 bucket you want to write the thumbnails to.