Repository navigation
v1.2.4-fork.1
Pre-release
Pre-release
·
1904 commits
to main
since this release
🚀 Features
- Cleanup expired verification data on fetch - by @Bekacru in https://github.com/runreal/better-auth/issues/1110 (1a492)
- Disable default scopes and allow scopes to be passed on request - by @Bekacru in https://github.com/runreal/better-auth/issues/1240 (4ba72)
- Move to better call version 1 - by @Bekacru in https://github.com/runreal/better-auth/issues/1402 (46dfc)
- Captcha Plugin with multiple providers - by @0scrm in https://github.com/runreal/better-auth/issues/957 (363ca)
- Add VK ID social provider - by @nukhtarov and @Bekacru in https://github.com/runreal/better-auth/issues/1013 (700d3)
- Implement JWT token generation and retrieval with encryption support - by @Bekacru (1a482)
- Check organization slug - by @Bekacru in https://github.com/runreal/better-auth/issues/1201 (51e2b)
- Support stroring dispaly username to store un-normalized username - by @Bekacru in https://github.com/runreal/better-auth/issues/1204 (047d6)
- Add Roblox social provider - by @D3visionNL and @Bekacru in https://github.com/runreal/better-auth/issues/1249 (e6470)
- Add total users table/collection count to admin plugin list-users endpoint - by @D3visionNL and Kinfe123 in https://github.com/runreal/better-auth/issues/1258 (d28e4)
- Add context to database hooks - by @kzlar in https://github.com/runreal/better-auth/issues/1180 (63fbd)
- Base64 conversion without Buffer - by @BlankParticle in https://github.com/runreal/better-auth/issues/1523 (27401)
- Add cloudflare worker basic tests - by @BlankParticle in https://github.com/runreal/better-auth/issues/1524 (d7f66)
- Add access control to admin plugin - by @jslno in https://github.com/runreal/better-auth/issues/1424 (61212)
- API Key plugin - by @ping-maxwell in https://github.com/runreal/better-auth/issues/1515 (ec9ed)
- TikTok social provider - by @DewinU and @Bekacru in https://github.com/runreal/better-auth/issues/397 (7fffd)
initBetter Auth CLI command - by @ping-maxwell and @Bekacru in https://github.com/runreal/better-auth/issues/1427 (c66fd)- Add disabling email and password signup config - by @jslno in https://github.com/runreal/better-auth/issues/1428 (6ae53)
- Team support for organization - by @Bekacru and Kinfe123 in https://github.com/runreal/better-auth/issues/1425 (695f2)
- Passkey plugin with client-side
authenticatorAttachmentand globalauthenticatorSelectionconfiguration - by @benbehringer, @acusti and @Bekacru in https://github.com/runreal/better-auth/issues/1318 (d7496) - Add
errorURLfor custom error pages - by @Bekacru in https://github.com/runreal/better-auth/issues/1593 (8ec35) - Stripe plugin to handle subscriptions and customers - by @Bekacru in https://github.com/runreal/better-auth/issues/1588 (4f560)
- Disable Implicit Signup - by @kzlar and @Bekacru in https://github.com/runreal/better-auth/issues/1179 (44d6d)
- Improve Stripe webhook error handling and add trial lifecycle hooks - by @Bekacru (44018)
- Support promise return trusted origins - by @Bekacru (f743c)
- Support reverse proxied base URLs - by @Bekacru in https://github.com/runreal/better-auth/issues/1788 (36a7d)
- account:
- Multiple account with the same provider - by @Kinfe123 in https://github.com/runreal/better-auth/issues/1803 (4ba4a)
- admin:
- cli:
- Add support for auth.server.ts - by @ardasoyturk in https://github.com/runreal/better-auth/issues/1456 (b9ccf)
- client:
- Add
basePathoption oncreateAuthClient- by @Bekacru in https://github.com/runreal/better-auth/issues/1571 (1a3af)
- Add
- email-otp:
- Add option to set a function to generate OTPs - by @CordlessWool in https://github.com/runreal/better-auth/issues/1472 (8ba7a)
- mongodb-adapter:
- Support custom ID generation in MongoDB adapter - by @Bekacru in https://github.com/runreal/better-auth/issues/1444 (abd58)
- oidc:
- Allow header auth for token endpoint - by @t3duk in https://github.com/runreal/better-auth/issues/1484 (15f97)
- oidc-provider:
- Implement OIDC rfc7591 compliant /register endpoint - by @remorses in https://github.com/runreal/better-auth/issues/1732 (2a495)
- one-tap:
- Improve Google One Tap integration with JWT verification and improved prompt handling - by @Bekacru in https://github.com/runreal/better-auth/issues/1452 (8a08a)
- Implement account linking - by @Bekacru (0a47a)
- organization:
- Support multiple roles - by @Bekacru in https://github.com/runreal/better-auth/issues/1037 (1971f)
- Add option to keep current active organization when creating a new one - by @Bekacru (a5d26)
- Add team management permissions and documentation - by @Bekacru (12baa)
- Add organization creation hooks and improve type safety - by @Bekacru (6131a)
- phone-number:
- Add reset password functionality with phone number - by @Bekacru in https://github.com/runreal/better-auth/issues/1202 (3766b)
- social-providers:
- sso:
- Sign in using the providerId - by @kamilkisiela in https://github.com/runreal/better-auth/issues/1533 (6c67e)
- two-factor:
- Activate two factor with email OTP to avoid Insecure skipVerificationOnEnable - by @GregorWedlich in https://github.com/runreal/better-auth/issues/1445 (28f18)
- username:
- Add default validation and options for validating username - by @Bekacru in https://github.com/runreal/better-auth/issues/1345 (c4f20)
🐞 Bug Fixes
- Update @better-fetch/fetch to version 1.1.14-beta.2 and clean up client options - by @Bekacru (29f2e)
- SetIssuer baseURL - by @runreal-warman (a3d5b)
- Add email verification for in place email updates - by @Bekacru (3ca6c)
- Add callback URL to update email verification link - by @Bekacru (9653f)
- Oauth failing when using drizzle adapter - by @focux in https://github.com/runreal/better-auth/issues/1563 (8a820)
- Add last semi-colon to the compiled migrations to support Cloudflare D1 migration - by @PitonsSkipper in https://github.com/runreal/better-auth/issues/1569 (1ecc7)
- Correct option name in the reset password error message - by @Igonato in https://github.com/runreal/better-auth/issues/1573 (38894)
- Export helper types to resolve type inference - by @Bekacru (fc2d0)
- Update user type inference should be fully partial - by @Bekacru (f6856)
- Update session cookie after in place email change - by @Bekacru (fb0a8)
- Lowercase email in change email process, find as it is - by @hyoban in https://github.com/runreal/better-auth/issues/1695 (c3a37)
- Should consitently use defaultErrorURL for fallback error redirections - by @Bekacru (64727)
- Use account ID instead of compound key for account unlinking - by @Bekacru (f44ba)
- Accept secure cookie flag on getSessionCookie helper - by @ahmed-m-abbass in https://github.com/runreal/better-auth/issues/1716 (c8de1)
- Remove otp code from the response of send phone number otp - by @Bekacru (846ee)
- Use subscription Id to fetch the current active subscription from stripe - by @x751685875 in https://github.com/runreal/better-auth/issues/1770 (ace8f)
- On change email request for unverified emails should use the newEmail on verification token payload - by @Bekacru in https://github.com/runreal/better-auth/issues/1801 (6efc7)
- admin:
- Impersonate user session expiration - by @Kinfe123 in https://github.com/runreal/better-auth/issues/1471 (072c5)
- Unban should reset expiration date and reason - by @Kinfe123 in https://github.com/runreal/better-auth/issues/1469 (954b1)
- Add granular permission check for setting user password - by @Bekacru (59f81)
- Missing options parameter on hasPermission checks - by @jslno in https://github.com/runreal/better-auth/issues/1666 (50637)
- Require adminRoles option for a role to be considered an admin role - by @Bekacru (31c97)
- Fetch session on has permission checks - by @Bekacru (e4f15)
- Only evaluate permissions for access control - by @Bekacru (388dd)
- anonymous:
- api:
- Config in
getSessionFromCtxoverrides query param - by @Kinfe123 in https://github.com/runreal/better-auth/issues/1496 (261fe)
- Config in
- api-key:
- Use date object for cleanup - by @Bekacru in https://github.com/runreal/better-auth/issues/1632 (ff34f)
- Simplify API key deletion auth check - by @Bekacru (2231d)
- Creating API keys metadata always returns null - by @ping-maxwell in https://github.com/runreal/better-auth/issues/1698 (0ffbb)
- Results of
verifyendpoint's metadata isn't parsed - by @ping-maxwell in https://github.com/runreal/better-auth/issues/1719 (e4aa6)
- auth:
- db:
- discord:
- Use global name for discord - by @juliesaia in https://github.com/runreal/better-auth/issues/1656 (122cb)
- drizzle-adapter:
- email-otp:
- Don’t save email address as user name - by @benkingcode and benkingcode in https://github.com/runreal/better-auth/issues/1519 (5f6cb)
- expo:
- Fix get headers key - by @ejjsharpe in https://github.com/runreal/better-auth/issues/1634 (57c7d)
- Safely access headers - by @Bekacru (889ae)
- generic-oauth:
- Support allowDifferentEmails on Generic OAuth Plugin - by @alessandrojean in https://github.com/runreal/better-auth/issues/1481 (9c3b5)
- Store additional token details during account linking - by @Bekacru (74b0b)
- init-cmd:
- Dependencies do not install if ENVs are skipped - by @ping-maxwell and @Bekacru in https://github.com/runreal/better-auth/issues/1603 (8e47f)
- jwt:
- jwt-plugin:
- Include alg in jwks response - by @runreal-warman (459e7)
- Include alg in jwks response - by @runreal-warman (f4d1b)
- kysely-adapter:
- multi-session:
- Use small cased token name for multi-session cookie management - by @Bekacru (650d5)
- Return only unique user sessions - by @Bekacru (97a4c)
- Use small cased cookie name inside revoke endpoint - by @ahmed-m-abbass in https://github.com/runreal/better-auth/issues/1783 (284d4)
- oauth:
- Set tokens on oauth account created during link - by @thiagofelix in https://github.com/runreal/better-auth/issues/1462 (e5133)
- Remove state value on expiry - by @Bekacru (45dab)
- oidc-plugin:
- User info endpoint casing to match OIDC spec - by @stephenlacy in https://github.com/runreal/better-auth/issues/1446 (8d9fa)
- DeleteVerificationValue call by id - by @runreal-warman (c0bd4)
- Store and handle nonce value - by @runreal-warman (c39e1)
- DeleteVerificationValue call by id - by @runreal-warman (09d44)
- Store and handle nonce value - by @runreal-warman (12349)
- Temporary workaround to use jwks to sign - by @runreal-warman (b0b5c)
- Sub is required /userinfo response - by @runreal-warman (d165f)
- Sub is required /userinfo response - by @runreal-warman in https://github.com/runreal/better-auth/issues/1504 (8ac1f)
- Temporary workaround to use jwks to sign - by @runreal-warman (f86ef)
- oidc-provider:
- Add support for plain PKCE code challenge method and default config param allowPlainCodeChallengeMethod - by @kirill-dev-pro in https://github.com/runreal/better-auth/issues/1584 (b93f9)
- one-tap:
- Update import path for generateRandomString to fix unsupported crypto import for react native - by @Bekacru (ac848)
- Update import path for generateRandomString to fix unsupported crypto import for react native - by @Bekacru (73297)
- Remove random string generator for nonce to fix expo client - by @Bekacru (6440a)
- open-api:
- Convert path parameters to OpenAPI format - by @Phanuwat-Pao in https://github.com/runreal/better-auth/issues/1437 (06419)
- Add missing
idfield in generated OpenAPI for each schema (Models) - by @astahmer in https://github.com/runreal/better-auth/issues/1491 (add38) - Add authentication schemes - by @Bekacru (ee0d6)
- organizaiton:
- Restrict admins from removing or updating owners or members with creator roles - by @Bekacru in https://github.com/runreal/better-auth/issues/1520 (28cc6)
- organization:
- Respect membershipLimit - by @iqorex and @Bekacru in https://github.com/runreal/better-auth/issues/1600 (bdf69)
- Improve type inference and session handling - by @Bekacru (0c7a0)
- Default access control props - by @Bekacru (d79a8)
- Two members being created when team is enabled - by @Bekacru in https://github.com/runreal/better-auth/issues/1644 (32677)
- Remove unused schema type and make team creator optional - by @Bekacru (c5c5b)
- Custom permissions access control type inference breaking on the client - by @Bekacru (c051c)
- Use membership limit to fetch members user data - by @Bekacru (535c9)
- Properly throw error on update organization - by @Bekacru (e9993)
- Check permission types and support multiple permission on
hasPermissionschecks - by @Bekacru (59765)
- origin-check:
- passkey:
- Remove client export from the server plugin - by @Bekacru in https://github.com/runreal/better-auth/issues/1511 (bf47a)
- phone-number:
- rate-limiter:
- roblox:
- MapProfileToUser should run before returning user info - by @ping-maxwell in https://github.com/runreal/better-auth/issues/1706 (5c94c)
- session:
- stirpe:
- Inconsistent referenceId usage - by @Bekacru in https://github.com/runreal/better-auth/issues/1736 (0ce3f)
- stripe:
- Update Stripe subscription deletion webhook handling to use stripeSubId instead of local id - by @Bekacru (7ad4d)
- Improve subscription cancellation handling and add callback endpoint - by @Bekacru (1c912)
- Update subscription webhook handling should use customer id as a fallback - by @Bekacru (1c166)
- Add stripeSubscriptionId to subscription events and improve logging - by @Bekacru (33858)
- Add optional annual plan prop on upgrade - by @Bekacru (90521)
- Remove redundant error handling for existing subscriptions - by @Bekacru (bd266)
- Apply free trials properly - by @Bekacru (84ab2)
- Cancel should properly apply for immediate trail cancels - by @Bekacru (2704f)
- Improve handling of multiple subscriptions in webhook - by @Bekacru (c5c74)
- OnTrailEnd should only take subscription object - by @Bekacru (ad141)
- Convert subscription period timestamps to Date objects - by @Bekacru (0d6b4)
- Webhook constructor should use async version - by @BlueLightStudio in https://github.com/runreal/better-auth/issues/1664 (46dcd)
- Add origin check on success callback - by @Bekacru (d3d10)
- Call onCustomerCreate callback handle error logging - by @Bekacru (21fea)
- Rely on subscription Id instead of reference ID for subscriptions - by @Bekacru in https://github.com/runreal/better-auth/issues/1789 (35fe9)
- two-factor:
- Should respect
remember mevalue when a user logins in with 2fa - by @Bekacru in https://github.com/runreal/better-auth/issues/1566 (da1ee) - Should respect
remember mevalue when a user logins in with 2fa - by @Bekacru in https://github.com/runreal/better-auth/issues/1566 (c7d34) - Add device trust param for TOTP verification - by @Bekacru (1b9a7)
- Add device trust param for backup code verification - by @Bekacru (f1dc2)
- Custom user options should be passed to backup code generator - by @Wundero in https://github.com/runreal/better-auth/issues/1688 (88bab)
- Should respect
- types: