How to access a JSON from a lambda function while deployed

Hi, @chrisleeharris. You are correct that the functions are not available in the deployment zip file.

It sounds like the require JSON file isn’t being bundled into the function archive so isn’t available post deployment.

Here is an example community topic where someone else is asking something similar:

One tool to prepare/bundle functions for deployment is the “zip-it-and-ship-it” tool:

Also, @marcus here at Netlify created the following repo as a demo of how this (bundling a JSON file to be read in by the function) can be done:

I’m hoping these examples provide additional insight into the how files, JSON or other types, are bundled with function code to be accessible by the function after deployment.

If there are other questions or if there is more we can do to assist, please let us know.