feat: add better-auth api-key plugin, import endpoint, and API key UI

This commit is contained in:
2026-06-28 05:30:48 +08:00
parent c4bede20d4
commit f7eda2bfc0
15 changed files with 3701 additions and 3 deletions
+3 -1
View File
@@ -1,6 +1,7 @@
import { createAuthClient } from 'better-auth/react'
import { adminClient, emailOTPClient, lastLoginMethodClient } from 'better-auth/client/plugins'
import { passkeyClient } from '@better-auth/passkey/client'
import { apiKeyClient } from '@better-auth/api-key/client'
export const authClient = createAuthClient({
baseURL: process.env.NEXT_PUBLIC_SITE_URL || "https://localhost:3000",
@@ -8,7 +9,8 @@ export const authClient = createAuthClient({
emailOTPClient(),
passkeyClient(),
lastLoginMethodClient(),
adminClient()
adminClient(),
apiKeyClient(),
]
})