mirror of
https://github.com/better-auth/better-auth.git
synced 2026-08-15 08:25:06 -05:00
The OAuth Provider extension surface let a grant handler drift from what it issued in two ways. The client-registration check honored a request-supplied grant type while issuance used the provider-bound grant, so a handler could authenticate a client for a permissive grant and mint under a stricter one. And a client-authentication strategy returned the client record the provider then authorized against, so a strategy could supply a client's grants, scopes, or enabled state. The provider-bound grant is now the sole authority for the registration check, and grantType is removed from OAuthClientAuthenticationRequest. A strategy proves only the client id it authenticated (plus an optional confirmation); the provider resolves and authorizes the client record itself via getClient. The strategy result type is now OAuthClientAuthenticationResult.
Website & Docs
The main website and documentation for better-auth.com
Quick Start
# install
pnpm install
# develop
pnpm dev
Open localhost:3000 to preview.
Stack
- Framework: Next.js 16 (App Router, Turbopack)
- Styling: Tailwind CSS 4
- Animation: Framer Motion
- Docs: Fumadocs
- Icons: Lucide React
- Fonts: Geist Sans & Geist Mono
Structure
├─ app/
│ ├─ page.tsx # Home — hero + sign-in demo
│ ├─ products/ # Products page
│ ├─ blog/ # Blog posts
│ └─ docs/[[...slug]]/ # Documentation (MDX)
│
├─ components/
│ ├─ landing/ # Marketing components
│ ├─ docs/ # Documentation components
│ ├─ ui/ # Shared primitives
│ └─ icons/ # Brand icons & logo
│
├─ content/ # MDX documentation files
│
├─ lib/
│ ├─ source.ts # Fumadocs content source
│ └─ utils.ts # Utilities
│
└─ public/
└─ branding/ # Logo assets (SVG + PNG)
Scripts
pnpm dev # Start dev server (Turbopack)
pnpm build # Production build
pnpm start # Serve production build
pnpm lint:fix # Lint & auto-fix with Biome