Skip to main content

AWS Full-Stack Example

This example demonstrates building a complete full-stack serverless application on AWS. The example uses the same infrastructure as the AWS Lambda example but can be extended with additional frontend resources.

Features

  • Lambda Function: Serverless API endpoints
  • DynamoDB Table: NoSQL database for data persistence
  • SQS Queue: Async message processing
  • IAM Roles: Security and permissions
  • Function URLs: Direct HTTP access
  • CORS: Cross-origin resource sharing

Architecture

The full-stack application consists of:
  1. Backend: AWS Lambda functions with TypeScript
  2. Database: DynamoDB for data storage
  3. Queue: SQS for background jobs
  4. API: Function URLs with CORS for frontend access

Project Setup

API Endpoints

Once deployed, your API supports:
  • POST /items - Create a new item
  • GET /items - List all items
  • GET /items/:id - Get a specific item
  • DELETE /items/:id - Delete an item

Frontend Integration

You can connect any frontend framework:

Key Features Explained

Parallel Resource Creation

Create multiple resources concurrently for faster deployment:

Environment Variables

Pass resource references to Lambda:

CORS Configuration

Enable frontend access:

Source Code

View the complete source code: examples/aws-app