A full-stack web application for looking up Pokémon card pricing data, built on Azure serverless architecture with a Svelte frontend, Azure Functions backend, Cosmos DB, and fully automated infrastructure via Terraform.
This is a monorepo consolidation of three prior projects into a single production-ready codebase.
graph TB
subgraph "Frontend"
SPA[Svelte SPA<br/>Static Web App]
end
subgraph "API Gateway"
APIM[Azure API Management<br/>Rate Limiting & Caching]
end
subgraph "Backend"
AF[Azure Functions v4<br/>Node.js 22 LTS]
end
subgraph "Data"
COSMOS[Cosmos DB<br/>Serverless NoSQL]
REDIS[Redis Cache<br/>Optional]
end
subgraph "External APIs"
POKEDATA[PokeData API]
POKEMONTCG[Pokemon TCG API]
end
SPA --> APIM
APIM --> AF
AF --> COSMOS
AF --> REDIS
AF --> POKEDATA
AF --> POKEMONTCG
| Layer | Technology | Purpose |
|---|---|---|
| Frontend | Svelte 4 | Reactive UI framework |
| API Gateway | Azure API Management | Rate limiting, caching, policies |
| Backend | Azure Functions v4 (Node.js 22 LTS) | Serverless compute |
| Database | Cosmos DB Serverless | NoSQL document storage |
| Caching | IndexedDB + Redis | Multi-tier caching |
| Infrastructure | Terraform | Infrastructure as Code |
| Dev Environment | DevContainer + ACR | Consistent, fast setup |
git clone https://github.com/Abernaughty/PCPC.git
cd PCPC
code .
When prompted by VS Code, click "Reopen in Container". The DevContainer will be ready in ~60 seconds.
node --version # v22.x LTS
terraform version # Latest
az --version # Latest Azure CLI
# Frontend (port 3000)
cd app/frontend && npm run dev
# Backend (port 7071)
cd app/backend && npm run start
npm test
PCPC/
├── app/
│ ├── frontend/ # Svelte application
│ └── backend/ # Azure Functions
├── infra/ # Terraform modules (7 modules)
│ ├── modules/
│ └── envs/
├── apim/ # API Management as Code
├── db/ # Cosmos DB schema management
├── tests/ # Test suite
├── docs/ # Documentation
├── .devcontainer/ # DevContainer configuration
└── .ado/ # Azure DevOps CI/CD pipelines
cd app/frontend && npm run dev # Frontend with hot reload
cd app/backend && npm run start # Azure Functions locally
npm test # Run test suite
npm test # All tests
npm run test:frontend # Frontend only
npm run test:backend # Backend only
npm run test:coverage # With coverage report
# Initialize and plan
make terraform-init ENVIRONMENT=dev
make terraform-plan ENVIRONMENT=dev
# Apply
make terraform-apply ENVIRONMENT=dev
| Environment | Purpose | Status |
|---|---|---|
| Development | Local development | ✅ Ready |
| Staging | Pre-production validation | 🚧 Planned |
| Production | Live application | 🚧 Planned |
The infrastructure is fully managed as code using Terraform with 7 modular configurations:
See infra/README.md for full details.
git checkout -b feature/your-featuregit commit -m 'Add your feature'MIT — see LICENSE for details.
Built for the Pokémon card collecting community and as a demonstration of Azure serverless architecture.