better-auth
Complete Better Auth documentation in markdown format. Use when implementing authentication in TypeScript projects - covers OAuth providers (Google, GitHub, etc.), email/password, passkeys, 2FA, session management, database adapters (Prisma, Drizzle), and framework integrations (Next.js, SvelteKit, etc.).
- License 许可
- MIT
- 最近更新
- 2026-06-07
- Stars
- ★ 0
- Forks
- 1
01 前言 Front Matter
- name
- better-auth
- description
- Complete Better Auth documentation in markdown format. Use when implementing authentication in TypeScript projects - covers OAuth providers (Google, GitHub, etc.), email/password, passkeys, 2FA, session management, database adapters (Prisma, Drizzle), and framework integrations (Next.js, SvelteKit, etc.).
03 SKILL.md 正文
Better Auth Documentation
Complete Better Auth documentation embedded in markdown. Read from references/ to answer questions about authentication implementation, OAuth setup, database configuration, and framework integration.
Documentation Structure
All documentation is in references/ organized by topic:
Core Documentation
Getting Started
references/introduction.mdx- What is Better Authreferences/installation.mdx- Setup guidereferences/basic-usage.mdx- Authentication basicsreferences/comparison.mdx- vs other auth libraries
Authentication Methods (references/authentication/)
OAuth providers and authentication strategies:
google.mdx- Google OAuthgithub.mdx- GitHub OAuthmicrosoft.mdx- Microsoft/Azure ADapple.mdx- Apple Sign Indiscord.mdx,facebook.mdx,twitter.mdx, etc.email-password.mdx- Email & password authmagic-link.mdx- Passwordless magic linkspasskey.mdx- WebAuthn passkeys
Database Adapters (references/adapters/)
prisma.mdx- Prisma ORMdrizzle.mdx- Drizzle ORMkysely.mdx- Kyselymongodb.mdx- MongoDBpg.mdx- node-postgres
Concepts (references/concepts/)
Core authentication concepts:
session.mdx- Session managementoauth.mdx- OAuth flowdatabase.mdx- Database schemarate-limit.mdx- Rate limitingmiddleware.mdx- Auth middlewarecookies.mdx- Cookie handling
Plugins (references/plugins/)
Extension features:
two-factor.mdx- 2FA/TOTPpasskey.mdx- WebAuthn/passkeysemail-verification.mdx- Email verificationmagic-link.mdx- Magic link authorganization.mdx- Organizations & teamsmulti-session.mdx- Multiple sessionsanonymous.mdx- Anonymous users
Integrations (references/integrations/)
Framework-specific guides:
next-js.mdx- Next.js integrationsveltekit.mdx- SvelteKitastro.mdx- Astrosolid-start.mdx- SolidStart
Examples (references/examples/)
Working examples:
next-js.mdx- Complete Next.js examplesveltekit.mdx- SvelteKit example
Guides (references/guides/)
How-to guides:
custom-session.mdx- Custom session handlingtesting.mdx- Testing auth flowsdeployment.mdx- Production deployment
API Reference (references/reference/)
Complete API documentation.
Quick Reference
Common Tasks
| Task | File to Read |
|---|---|
| Initial setup | references/installation.mdx |
| Email & password auth | references/authentication/email-password.mdx |
| Google OAuth | references/authentication/google.mdx |
| GitHub OAuth | references/authentication/github.mdx |
| Setup with Prisma | references/adapters/prisma.mdx |
| Setup with Drizzle | references/adapters/drizzle.mdx |
| Session management | references/concepts/session.mdx |
| Add 2FA | references/plugins/two-factor.mdx |
| Add passkeys | references/plugins/passkey.mdx |
| Next.js integration | references/integrations/next-js.mdx |
| Organizations/teams | references/plugins/organization.mdx |
| Rate limiting | references/concepts/rate-limit.mdx |
When to Use This Skill
- Implementing authentication in a TypeScript project
- Setting up OAuth providers (Google, GitHub, Microsoft, etc.)
- Configuring database adapters (Prisma, Drizzle, etc.)
- Adding 2FA, passkeys, or magic links
- Managing sessions and cookies
- Integrating with Next.js, SvelteKit, or other frameworks
- Questions about auth patterns and best practices
How to Navigate
- Start with
references/introduction.mdxfor overview - For setup: Read
references/installation.mdx - For auth methods: Browse
references/authentication/ - For database: Check
references/adapters/ - For advanced features: See
references/plugins/ - For framework integration: Use
references/integrations/
All files are .mdx (Markdown + JSX) but readable as plain markdown.
04 同仓库更多 Skills
crowd-prompting
A marketplace where AI agents improve prompts, system instructions, tool descriptions, and other text-based content with domain expertise from real-world operations — and earn tokens for valuable contributions.
ceaser
Interact with the Ceaser privacy protocol on Base L2 using the ceaser-mcp MCP tools. This skill uses the ceaser-mcp npm package for ALL operations -- shield, unshield, note management, and protocol queries. All ceaser tool calls use CLI subcommands (npx -y ceaser-mcp <subcommand>). Ceaser is a privacy-preserving ETH wrapper using Noir/UltraHonk zero-knowledge proofs on Base L2 (chain ID 8453).
ceaser-send
Fully automated private ETH transfer via Ceaser Protocol on Base L2 using the ceaser-mcp MCP tools. This skill uses the ceaser-mcp npm package for ALL operations -- all ceaser tool calls use CLI subcommands (npx -y ceaser-mcp <subcommand>). WARNING -- creates observable on-chain links between user wallet and hot wallet (see Privacy Warning). Generates an ephemeral hot wallet with BIP-39 mnemonic recovery, user funds it, agent signs and broadcasts the Shield TX automatically. Exactly one manual step required (funding the hot wallet with ETH). Uses Noir/UltraHonk zero-knowledge proofs.
dilemm-ai
Compete in DilemmAI, the prisoner's dilemma AI arena at dilemm.ai. Use when an OpenClaw agent wants to create an account, design and submit strategy prompts for their bot, enter matchmaking, analyze historical matches and leaderboards, and iterate on bot strategy. Requires headless browser automation (no API available yet).
moldium
Post and manage content on the Moldium blog platform. Triggered by "post to Moldium", "write a blog post", "publish an article", etc.
arxiv-paper-reviews
Interact with arXiv Crawler API to fetch papers, read reviews, submit comments, search papers, and import papers. Use when working with arXiv papers, fetching paper lists by date/category/interest, viewing paper details with comments, submitting paper reviews, searching papers by title, or importing papers from arXiv URLs via API at http://weakaccept.top:8000/.