โœจ Powered by Amazon Bedrock

GenAI Chat
Platform

A serverless AI chat application built on AWS. Converse with Claude foundation models through a secure, production-grade interface.

๐Ÿง 

5 Claude Models

Haiku to Opus โ€” pick the right model for every task

๐Ÿ“Š

Usage Analytics

Track tokens, cost, and usage per user and model

๐Ÿ”

Secure by Default

Cognito auth, CloudFront CDN, private S3 origin

โšก

Serverless Stack

Lambda + API Gateway โ€” zero servers to manage

๐Ÿค–

Welcome Back

Sign in to start chatting

Available Models
Haiku 4.5 Sonnet 4.5 Sonnet 4.6 Opus 4.5 Opus 4.6
CloudFront ยท Lambda ยท Bedrock ยท DynamoDB

๐Ÿค– GenAI Chat

โš ๏ธ Rate limit reached. Retrying in 5s โ€” or switch to a different model.

Hello!

I'm powered by Amazon Bedrock. Send me a message and I'll respond using Claude.

Application Architecture

๐Ÿง‘โ€๐Ÿ’ป User Browser ๐Ÿ›ก๏ธ WAF Web ACL Managed Rules โ˜๏ธ CloudFront CDN Distribution /* โ†’ S3 /api/* โ†’ API Gateway ๐Ÿชฃ S3 Bucket Static Frontend HTML / CSS / JS ๐Ÿ” Cognito User Pool OAuth2 / JWT ๐Ÿ”€ API Gateway REST API /api/chat ยท /api/usage Cognito Authorizer โšก Lambda Node.js 22 (ARM64) Chat + Usage API ๐Ÿง  Bedrock Converse API Claude Models ๐Ÿ“Š DynamoDB Usage Tracking Per-user / Per-model ๐Ÿ’ฐ Cost Explorer Billing Data Actual AWS Cost HTTPS Allow OAC /api/* Proxy Converse Track Query cost Validate JWT Login redirect

๐Ÿ›ก๏ธ AWS WAF

Web Application Firewall protecting the CloudFront distribution with AWS managed rule groups and rate limiting.

โ˜๏ธ CloudFront

CDN distribution with three behaviors: default serves static files from S3, /api/chat and /api/usage route to API Gateway. HTTPS enforced, HTTP/2 enabled. WAF-protected. Host-based access control (custom domain only).

๐Ÿชฃ S3 Bucket

Private S3 bucket hosts the static SPA frontend. All public access blocked โ€” served exclusively through CloudFront via Origin Access Control (OAC).

๐Ÿ” Cognito

Shared Cognito user pool with OAuth2 authorization code flow. Browser redirects to Cognito Hosted UI, exchanges code for JWT tokens. No client secret (public SPA client).

๐Ÿ”€ API Gateway

Regional REST API with Cognito authorizer validating JWT on every request. POST /api/chat for conversations, GET /api/usage for analytics. CORS enabled with gateway response headers.

โšก Lambda

Node.js 22 on ARM64 (Graviton). Handles chat (Bedrock Converse), usage tracking (DynamoDB writes), and usage queries (DynamoDB reads + Cost Explorer).

๐Ÿง  Amazon Bedrock

Converse API with US inference profiles. 5 Claude models from Haiku 4.5 to Opus 4.6. User selects model per-message. Throttle detection with graceful retry.

๐Ÿ“Š DynamoDB

Usage tracking table with per-user, per-model, per-month granularity. Tracks input/output tokens and request counts. PAY_PER_REQUEST billing.

๐Ÿ’ฐ Cost Explorer

Queried for actual AWS Bedrock billing data. Provides real cost alongside token-based estimates. Data has 24โ€“48h delay from AWS.

๐Ÿ“Š Monthly Usage

๐Ÿ’ฌ
โ€”
Requests
๐Ÿ“ฅ
โ€”
Input Tokens
๐Ÿ“ค
โ€”
Output Tokens
๐Ÿ’ฐ
โ€”
Estimated Cost
โ˜๏ธ
โ€”
Actual Bedrock Cost
Breakdown by Model
Model Requests Input Tokens Output Tokens Est. Cost
Loading usage data...
Breakdown by User
User Requests Input Tokens Output Tokens Est. Cost
Switch to "All Users" view