github better-auth/better-auth v1.8.0-beta.3

pre-release2 hours ago

Important

Action required

OAuth profile types for Apple, Cognito, Discord, Dropbox, Facebook, GitHub, GitLab, Gumroad, Linear, Microsoft Entra ID, Notion, Patreon, PayPal, Railway, Slack, and Twitter(X) were reviewed against each provider's official resources and updated to match. If you use custom profile mappings or profile types for any of them, review the changes below and handle fields that are now optional, nullable, or retyped.

better-auth

❗ Breaking Changes

  • Fixed the Gumroad OAuth helper to return undefined for accounts without a name, matching its declared profile type (#11864)
  • Fixed the Patreon OAuth helper to normalize null names and images to missing values while preserving empty strings, and to allow email to be null or omitted when email access is not granted (#11863)
  • Fixed Slack sign-in to support scoped profiles with optional SlackProfile email and profile claims, use POST for userinfo in the built-in provider and Generic OAuth helper, and reject Slack errors returned with HTTP 200 (#11851)

For detailed changes, see CHANGELOG

@better-auth/core

❗ Breaking Changes

  • Fixed Apple profile types to align with identity tokens, making private-email status, user status, and pictures optional and accepting boolean or string email-verification claims (#11842)
  • Fixed CognitoProfile to make profile and token claims optional, accept boolean or "true"/"false" verification values, fall back to cognito:username for ID-token names, and verify tokens against both documented issuer formats (#11843)
  • Fixed Discord profile types to reflect optional user metadata, added avatar decoration, collectible, and primary guild details, and defaulted missing email verification to false (#11867)
  • Fixed Dropbox profile types to include account status, locale, referral links, pairing status, account type, team policies, and root information, with home_path required for team roots (#11846)
  • Fixed Facebook Limited Login profile callbacks to accept tokens without name, email, or picture claims (#11856)
  • Fixed GithubProfile types to match GitHub API responses, with numeric id and account counters, nullable details, and omitted scope-dependent fields such as twitter_username (#11839)
  • Fixed GitLab profile handling for nullable details and omitted conditional fields, made locked a required boolean, and preserved stored images for null avatars when profile updates are enabled (#11853)
  • Fixed LinearUser.avatarUrl to be required and typed as string | null, preserved stored images for null avatars during enabled profile updates, and made authorization scopes comma-separated (#11855)
  • Fixed MicrosoftEntraIDProfile claim types so timestamps are numbers, groups, acrs, and xms_cc are string arrays, in_corp is boolean, and conditional claims and profile photos can be omitted (#11854)
  • Fixed Notion users without an avatar to keep their existing profile image when profile updates are enabled, with optional type, nullable name and avatar_url, missing image as undefined, and optional person.email_verified metadata (#11859)
  • Fixed PayPal profile types to handle omitted names, email, and verification claims when personal permissions are not granted, defaulting missing email verification to false (#11862)
  • Fixed RailwayProfile to make email, name, and picture optional, reflecting the granted scopes (#11861)
  • Fixed Slack sign-in to support scoped profiles with optional SlackProfile email and profile claims, use POST for userinfo in the built-in provider and Generic OAuth helper, and reject Slack errors returned with HTTP 200 (#11851)
  • Fixed TwitterProfile types so nested entity objects, arrays, and URL details can be omitted or null, and added description cashtags, mentions, and URL preview metadata (#11852)

For detailed changes, see CHANGELOG

Contributors

Thanks to everyone who contributed to this release:

@bytaesu

Full changelog: v1.8.0-beta.2...v1.8.0-beta.3

Don't miss a new better-auth release

NewReleases is sending notifications on new releases.