How ppenumatsa1/poc-insurance-quotes works
Project Type and Purpose
• This is a full-stack web application (“Insurance Quotes”) with:
• A React SPA frontend
• An ASP.NET Core 8.0 REST API backend
• Azure infrastructure defined via Bicep
• GitHub CI/CD for both frontend and backend
• Purpose: allow users to fetch auto insurance quotes via authenticated API calls, deployable to Azure.
File Structure
• frontend/InsuranceQuotes.UI → React app (public, src, AuthProvider, components)
• backend/InsuranceQuotes.Api → ASP.NET Core API (Controllers, Models, Services)
• infra/ → Bicep templates for Azure resources (app services, key vault, monitoring)
• .github/workflows → CI pipelines for backend and frontend
README for Additional Insights
• Azure AD integration (Entra ID) for auth (client and API apps)
• Swagger UI for API docs
• Azure Developer CLI (azd) used for unified provisioning & deployment
Main Components
a. Presentation Tier
• React SPA (InsuranceQuotes.UI)
• AuthProvider handling Azure AD tokens
b. API Tier
• ASP.NET Core API (QuotesController)
• QuoteService (business logic)
• Quote model
c. Authentication & Authorization
• Microsoft Entra ID (Azure AD)
d. Infrastructure & Deployment
• Azure Static Web App (hosts React)
• Azure App Service (hosts API)
• App Service Plan
• Azure Key Vault (stores secrets/app settings)
• Application Insights (monitoring)
• Bicep templates (infra as code)
e. DevOps
• GitHub Actions (frontend-ci.yml, backend-ci.yml)
• Azure Developer CLI (azd)
Relationships and Data Flow
• User → React app (HTTPS)
• React app ↔ Azure AD (OpenID Connect / OAuth2) for tokens
• React app → API (HTTPS + Bearer token)
• API → Key Vault (for any secret retrieval)
• API → (In-memory or persisted) Quote data via QuoteService
• GitHub Actions → Azure (CI/CD pipelines)
Architectural Patterns & Principles
• Layered architecture in the API (Controllers → Services → Models)
• SPA + API separation
• Infrastructure as Code (Bicep)
• CI/CD with GitHub Actions
• Externalized configuration (appsettings.json, .env for frontend)
• Dev/prod environment isolation via azd environments