feat: support device authorization (#3811)

This commit is contained in:
Alex Yang
2025-08-21 14:59:31 -07:00
committed by GitHub
parent 2edb2d6816
commit 5ded0904d4
28 changed files with 3150 additions and 74 deletions

View File

@@ -9,6 +9,7 @@ import {
oAuthProxy,
openAPI,
customSession,
deviceAuthorization,
} from "better-auth/plugins";
import { reactInvitationEmail } from "./email/invitation";
import { LibsqlDialect } from "@libsql/kysely-libsql";
@@ -198,6 +199,10 @@ export const auth = betterAuth({
],
},
}),
deviceAuthorization({
expiresIn: "3min",
interval: "5s",
}),
],
trustedOrigins: ["exp://"],
advanced: {