Functions
Add Netlify Functions.
On this page
./functions/
See also the Netlify docs: Functions overview
Example
./functions/hi-from-lambda.js
exports.handler = (event, context, callback) => {
callback (null, {
statusCode: 200,
headers: {
'Content-Type': 'application/json',
},
body: JSON.stringify({
message: 'Hi from Lambda.',
}),
});
}