
Security News
/Research
Popular node-ipc npm Package Infected with Credential Stealer
Socket detected malicious node-ipc versions with obfuscated stealer/backdoor behavior in a developing npm supply chain attack.
@nodeboot/lambda-server
Advanced tools
Node-Boot AWS Lambda server package. It provides a simple way to create Lambda handlers using NodeBoot, with support for routing, middleware, and request handling.
AWS Lambda server package for NodeBoot framework. Provides seamless integration with AWS Lambda while maintaining all NodeBoot features including dependency injection, middleware, routing, and error handling.
npm install @nodeboot/lambda-server
import {LambdaServer} from "@nodeboot/lambda-server";
import {NodeBootApplication} from "@nodeboot/core";
@EnableDI(Container)
@EnableValidations()
@EnableComponentScan()
@NodeBootApplication()
export class LambdaSampleApp implements NodeBootApp {
start(): Promise<NodeBootAppView> {
return NodeBoot.run(LambdaServer);
}
}
import {LambdaSampleApp} from './LambdaSampleApp';
import {LambdaHandler, LambdaServer} from "@nodeboot/lambda-server";
...
let lambdaHandler: LambdaHandler | null = null;
/**
* AWS Lambda handler function
* This function is called by AWS Lambda for each request
*/
export const handler = async (event: APIGatewayProxyEvent, context: Context): Promise<APIGatewayProxyResult> => {
// Initialize the handler only once
if (!lambdaHandler) {
const app = await new LambdaSampleApp()
.start();
const lambdaServer = app.server as LambdaServer;
lambdaHandler = lambdaServer.getHandler();
}
// Handle the request
return await lambdaHandler(event, context);
};
import {Controller, Get, Post, Param, Body} from "@nodeboot/core";
@Controller("/api")
export class UserController {
@Get("/users/:id")
getUser(@Param("id") id: string) {
return {id, name: `User ${id}`};
}
@Post("/users")
createUser(@Body() userData: any) {
return {success: true, user: userData};
}
}
The exported handler function can be deployed directly to AWS Lambda and integrated with API Gateway.
Configure API Gateway to proxy all requests to your Lambda function:
{proxy+}ANYThis allows the Lambda function to handle all HTTP methods and paths using NodeBoot's internal routing.
All NodeBoot middleware is supported:
import {Middleware, MiddlewareInterface, Action} from "@nodeboot/core";
@Middleware({type: "before"})
export class LoggingMiddleware implements MiddlewareInterface {
@Inject()
private logger: Logger;
use(action: Action, payload: any): void {
this.logger.info(`${action.request.httpMethod} ${action.request.path}`);
}
}
Custom error handlers work seamlessly:
import {ErrorHandler, ErrorHandlerInterface} from "@nodeboot/core";
@ErrorHandler()
export class CustomErrorHandler implements ErrorHandlerInterface {
onError(error: any, action: Action): void {
// Custom error handling logic
}
}
NodeBoot's authorization system is fully supported. Use decorators like @Authorize() in your controllers to protect
routes.
import {Authorize, Controller, Get} from "@nodeboot/core";
@Controller("/secure")
export class SecureController {
@Get("/data")
@Authorize("admin")
getSecureData() {
return {secret: "This is secure data"};
}
}
The NodeBoot Lambda Server package provides a powerful way to build serverless applications using the familiar NodeBoot framework. With full support for routing, middleware, error handling, and authorization, you can create robust APIs that run on AWS Lambda with ease.
This project is licensed under the MIT License.
FAQs
Node-Boot AWS Lambda server package. It provides a simple way to create Lambda handlers using NodeBoot, with support for routing, middleware, and request handling.
The npm package @nodeboot/lambda-server receives a total of 32 weekly downloads. As such, @nodeboot/lambda-server popularity was classified as not popular.
We found that @nodeboot/lambda-server demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Security News
/Research
Socket detected malicious node-ipc versions with obfuscated stealer/backdoor behavior in a developing npm supply chain attack.

Security News
TeamPCP and BreachForums are promoting a Shai-Hulud supply chain attack contest with a $1,000 prize for the biggest package compromise.

Security News
Packagist urges PHP projects to update Composer after a GitHub token format change exposed some GitHub Actions tokens in CI logs.