![]() The lambda “ context” which provides details about the context of the function, as well as some methods for the response.The request “ event” containing all sorts of details like the route requested, the request method, the request headers, and more.This configuration assumes we have a function called generatePdf which is exported from the file called index.js located inside a folder called src.Įach serverless function handler is provided with 3 parameters: This file should look something like so: service: generatePdf We will need to use a configuration file called serverless.yml (for more details on the file options, see here). Getting started with serverless functions with Node on AWS Lambda is pretty straight forward. No need for Express, no HTML parsing, and no uploading to S3. ![]() ![]() In this post, I’ll cover only the minimum to create a Serverless function on AWS Lambda which generates PDFs using Node and PDFKit. There are a few blog posts out there already covering this subject, but most of them include extra packages or steps than are actually necessary.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |