This folder contains the public integration demos for MrWhoOidc.
Do not begin with the demos if the issuer is not already running.
The recommended order is:
If you need Redis-backed distributed features before you test demos, use the Redis path in ../docs/deployment-paths.md and keep following the published-image workflow in this repository.
| Demo | Stack | Scenario |
|---|---|---|
| dotnet-mvc-client | ASP.NET Core Razor Pages | confidential client with interactive sign-in and downstream API call |
| react-client | React + Vite + TypeScript | public SPA client using PKCE and PAR when available |
| go-client | Go | confidential web client |
| kotlin-spring-client | Kotlin + Spring Boot | Java/Spring confidential client with OBO and M2M patterns |
| obo-demo-api | ASP.NET Core minimal API | delegated token validation and OBO vs M2M comparison |
| Goal | Recommended Demo | Why |
|---|---|---|
| Confidential web app | dotnet-mvc-client | Fastest way to understand the full sign-in and downstream API flow |
| Browser-only SPA | react-client | Best starting point for PKCE and PAR in a frontend-only client |
| Downstream API validation | obo-demo-api | Clearest path for access token validation and OBO vs M2M comparison |
| Non-.NET confidential client | go-client or kotlin-spring-client | Better fit when your application stack is not .NET |
The docs in this repo assume you bring up the issuer separately using the root-level deployment assets:
./scripts/generate-cert.sh localhost changeit
cp .env.example .env
docker compose up -d
Once the issuer is running, follow the README inside the specific demo directory.
Before running any demo, register the client in MrWhoOidc Admin UI:
| Field | .NET MVC | React SPA | Go Client |
|---|---|---|---|
| Client ID | dotnet-mvc-demo |
react-spa-demo |
go-demo |
| Client Type | Confidential | Public | Confidential |
| Grant Types | authorization_code, refresh_token |
authorization_code |
authorization_code, refresh_token |
| Redirect URIs | https://localhost:5001/signin-oidc |
https://localhost:5173/callback |
https://localhost:5080/callback |
| Post Logout URIs | https://localhost:5001/signout-callback-oidc |
https://localhost:5173/ |
https://localhost:5080/ |
| Require PKCE | Optional | Required | Optional |
| Client Secret | ✅ Generated | ❌ None | ✅ Generated |
| Scenario | Recommended Demo |
|---|---|
| Building ASP.NET Core web app | .NET MVC Client |
| Building React/Vue/Angular SPA | React SPA Client |
| Building Go microservice | Go Web Client |
| Need server-side rendering | .NET MVC or Go Client |
| Need stateless client | React SPA Client |
| High performance requirements | Go Web Client |
| Enterprise .NET environment | .NET MVC Client |
| Cloud-native architecture | Go or React Client |
Cause: MrWhoOidc uses self-signed certificate for development.
Solution:
dotnet dev-certs https --trustCause: MrWhoOidc container not running.
Solution:
# Check status
docker ps | grep mrwho-oidc
# Start MrWhoOidc from the deployment repository root
cd /path/to/MrWho
docker compose up -d
Cause: Redirect URI mismatch between client registration and configuration.
Solution:
Cause: Client not registered or misconfigured.
Solution:
authorization_codeAll demos extend the parent docker-compose.yml using Docker Compose overlay pattern:
# Parent: MrWho/docker-compose.yml
# - Defines MrWhoOidc services (webauth, postgres, redis)
# - Creates shared networks (mrwho_edge, internal)
# Overlay: demos/<demo>/docker-compose.demo.yml
# - Extends parent configuration
# - Adds demo-specific service
# - Connects to shared networks
# - Sets environment variables
Benefits:
Running Multiple Demos:
# Start MrWhoOidc once
cd MrWho
docker compose up -d
# Start .NET demo
cd demos/dotnet-mvc-client
docker compose -f ../docker-compose.yml -f docker-compose.demo.yml up -d
# Start React demo (in another terminal)
cd demos/react-client
docker compose -f ../docker-compose.yml -f docker-compose.demo.yml up -d
# Start Go demo (in another terminal)
cd demos/go-client
docker compose -f ../docker-compose.yml -f docker-compose.demo.yml up -d
All three demos can run simultaneously on different ports.
Happy coding! 🚀
If you have questions or encounter issues, please open an issue on GitHub or start a discussion.