Skip to content

Use cases

Each card below maps to a runnable example under examples/ in the source repo. Examples build behind the example build tag so they don't bloat your go.sum or get pulled into go test ./...:

sh
go run -tags example ./examples/01-minimal

Index

Every example folder maps to one of the use-case pages below.

Bootstrap & wiring

Use caseExamplePage
Smallest possible OP01-minimalMinimal OP
Comprehensive bundle (every option a typical embedder uses)02-bundleComprehensive bundle

Profile & flow

Use caseExamplePage
FAPI 2.0 Baseline (PAR + JAR + DPoP)03-fapi2, 50-fapi-tls-jwksFAPI 2.0 Baseline
Service-to-service tokens05-client-credentialsclient_credentials
Plain OAuth 2.0 alongside OIDC15-oauth2-onlyOAuth 2.0 (no openid)
DPoP server nonce flow51-dpop-nonceDPoP nonce flow

UI

Use caseExamplePage
Drive UI from a SPA04-custom-interaction + 10-react-loginSPA / custom interaction
Custom HTML consent page11-custom-consent-uiCustom consent UI
Multi-account chooser (prompt=select_account)13-multi-accountMulti-account chooser
Cross-origin SPA (CORS)14-cors-spaCORS for SPA
Locale negotiation16-i18n-localei18n / locale

Storage

Use caseExamplePage
Persist on a real database06-sql-store, 07-mysql-storePersistent storage (SQL)
Hot/cold split (Redis volatile)08-composite-hot-cold, 09-redis-volatileHot/cold + Redis

Scopes & claims

Use caseExamplePage
Public / internal scope split12-scopes-public-privatePublic / internal scopes
OIDC §5.5 claims request parameter17-claims-requestClaims request

Authentication

Use caseExamplePage
MFA, captcha, step-up20, 21, 22, 23MFA / step-up

Governance

Use caseExamplePage
First-party consent skip40-first-party-skip-consentFirst-party consent skip
Dynamic Client Registration (RFC 7591)41-dynamic-registrationDynamic Client Registration
Back-Channel Logout 1.042-back-channel-logoutBack-Channel Logout

Operations

Use caseExamplePage
Prometheus metrics52-prometheus-metricsPrometheus metrics

Numeric inventory

The example folders are grouped by topic, not by chronology:

BandTopic
00–09bootstrap, grant variants, storage adapters
10–19UI, scopes, SPA, locale, claims request, CORS
20–29MFA and authentication rules (TOTP / risk / captcha / step-up)
30–39identity federation (reserved — v1.x)
40–49governance: first-party, DCR, back-channel logout
50–59operations: FAPI helpers, metrics, tracing, DPoP nonce
60–69compliance (reserved — v1.x late)

(Reserved bands are placeholders for in-flight or v1.x work; the README in the source repo is the authoritative inventory.)