How do you access functions?

I created a folder with functions, told Netlify where to find it, and deployed. When I visit mysite.com/test.js I see the Javascript source code of my “test” function. Should I not see the result of executing the code?

Hi @trafnar,

Assuming the function name is test.js, you access your functions from /.netlify/functions/test, The function code you write is deployed to AWS lambda, we then setup an API gateway that you access via the path I just mentioned. We have a lot of great documentation on our functions, I recommend that you check it out.

Thanks Gerald, I was able to figure it out based on your comment, I’m excited to play with this feature now.

I had read through the documentation, but was kinda confused since I hadn’t seen a URL like /.netlify/ before, and I wasn’t sure if the url would end in test.js or just test.

Having an example like example.com/.netlify/functions/foo in the docs would make it super clear.