UNPKG

serverless

Version:

Serverless Framework - Build web, mobile and IoT applications with serverless architectures using AWS Lambda, Azure Functions, Google CloudFunctions & more

11 lines (8 loc) 375 B
'use strict'; module.exports.hello = function (context, req) { // Add any necessary telemetry to support diagnosing your function context.log('HTTP trigger occured!'); // Read properties from the incoming request, and respond as appropriate. const name = req.query.name || (req.body && req.body.name) || 'World'; context.done(null, { body: `Hello ${name}` }); };