This is a demo project showcasing how to use AWS Lambda handlers locally as a server using Vite.
It demonstrates how to configure multiple Lambda functions for different HTTP methods and routes in a local development environment.
- Node.js (>= 16.x)
- npm or yarn
- AWS Lambda knowledge is helpful but not required.
-
Clone this repository:
git clone https://github.com/medvedevden1s/LAAS cd LAAS -
Install dependencies:
npm install
Start the development server:
npm run dev| Method | Endpoint | Description |
|---|---|---|
| POST | /v1/posts |
Create a new blog post |
| GET | /v1/posts/{id} |
Retrieve a blog post by ID |
| GET | /v1/posts |
Retrieve all blog posts (v1) |
| GET | /v2/posts |
Retrieve all blog posts (v2) |
curl -X POST http://localhost:8080/v1/posts \
-H "Content-Type: application/json" \
-d '{"title": "My First Post", "content": "Hello, World!"}'This project is open-source and available under the MIT License.