New Case Study:See how Anthropic automated 95% of dependency reviews with Socket.Learn More
Socket
Sign inDemoInstall
Socket

hapi-aws-lambda

Package Overview
Dependencies
Maintainers
1
Versions
3
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

hapi-aws-lambda - npm Package Compare versions

Comparing version 0.0.3 to 0.0.4

2

package.json
{
"name": "hapi-aws-lambda",
"version": "0.0.3",
"version": "0.0.4",
"description": "Call AWS lambda functions from your hapi app!",

@@ -5,0 +5,0 @@ "main": "index.js",

@@ -16,23 +16,23 @@ hapi-aws-lambda

server.register({
register: require('hapi-aws-lambda'),
options: {
config: {
region: 'us-east-1',
credentials: {
accessKeyId: 'XXX',
secretAccessKey: 'XXX'
}
}
}
register: require('hapi-aws-lambda'),
options: {
config: {
region: 'us-east-1',
credentials: {
accessKeyId: 'XXX',
secretAccessKey: 'XXX'
}
}
}
}, (err) => {
if (err) {
throw err;
}
if (err) {
throw err;
}
// Use it here!
// Use it here!
server.start(() => {
console.log('Server started!');
});
server.start(() => {
console.log('Server started!');
});
});

@@ -48,10 +48,10 @@ ```

server.route({
method: 'GET',
path: '/',
handler: {
lambda: {
func: 'myExampleFunction', // short name or full arn
payload: { name: 'matt' }
}
}
method: 'GET',
path: '/',
handler: {
lambda: {
func: 'myExampleFunction', // short name or full arn
payload: { name: 'matt' }
}
}
});

@@ -64,22 +64,22 @@ ```

server.lambda('myExampleFunction', {
cache: {
expiresIn: 10000
}
cache: {
expiresIn: 10000
}
});
server.route({
method: 'GET',
path: '/',
handler: function (request, reply) {
method: 'GET',
path: '/',
handler: function (request, reply) {
server.methods.myExampleFunction({ name: 'matt' }, (err, data) => {
server.methods.myExampleFunction({ name: 'matt' }, (err, data) => {
if (err) {
throw err;
}
if (err) {
throw err;
}
reply(data);
});
}
reply(data);
});
}
});
```
SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc