Command
CLI startup
npx auth-mini origin add ... --value http://127.0.0.1:8080 npx auth-mini start ... --issuer https://auth.zccz14.com
auth-mini
A small, self-hosted auth server for apps that just need auth.
An interactive demo for teams exploring auth-mini integration with email OTP, passkeys, JWTs, JWKS, and SQLite.
Shortest path
Point this page at your auth-mini server, store the page origin with
origin add, then verify email OTP and passkeys from the
same page.
Config validation messages render here when runtime wiring lands.
Quick start
The command below stays aligned with this page and your chosen auth origin. Copy it first, then come back to the playground.
Command
npx auth-mini origin add ... --value http://127.0.0.1:8080 npx auth-mini start ... --issuer https://auth.zccz14.com
Runtime snippet target: Task 4 renders the config-derived script tag here.
Playground
Keep the same controls from the original demo, but place them inside a page that also explains how to wire auth-mini in production.
Config
This page loads the singleton SDK from the auth server origin so the script origin stays equal to the API origin.
Static layout note: runtime-derived values stay centralized in the docs sections above and will be rendered here later if the playground needs a secondary view.
Step 1
No request yet.
Step 2
No request yet.
Step 3
Uses window.AuthMini.webauthn.register() to fetch
options, complete the browser passkey prompt, and verify the
credential.
No request yet.
Step 4
Starts a username-less passkey login through
window.AuthMini.webauthn.authenticate() and waits
until session + /me state are ready.
No request yet.
How it works
The docs, snippets, and playground should all update from the same derived setup state.
origin add value.
API reference
Keep the shortest request path visible first, then expand details per endpoint only when needed.
Example
Static placeholder for Task 4 runtime-generated API reference entries.
Placeholder only: request/response examples render here after runtime content wiring.
Backend JWT
The primary backend path is local JWT verification with JWKS, not a round-trip to the auth server on every request.
jose
Runtime snippet target: Task 4 renders the jose JWT verification example here.
Deployment notes
Use relative local assets for this page, then configure auth-mini to trust whatever final page origin you deploy.
demo/ so
index.html, ./style.css, and
./main.js stay path-safe on GitHub Pages.
npx auth-mini origin add, then use
?sdk-origin= when the docs page and auth server are
on different origins.
CNAME file so the browser origin stays stable for
WebAuthn and CORS.