Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
59 KiB
@better-auth/scim
1.7.12
1.7.11
1.7.10
1.7.9
1.7.8
Patch Changes
-
#11512
4175b34Thanks @bytaesu! - Align the installed@better-auth/utilsversion withbetter-callwhile accepting^0.4.2 || ^0.5.0across official package peers. -
#11644
f556970Thanks @gustavovalverde! - If your SCIM provider sends attribute names with different letter case than the SCIM schema, such asActiveorEmails, Better Auth now applies them. Previously these keys were ignored while the request still succeeded, so aPUTwithActive: falseleft the User active. A request that sends the same attribute twice with different letter case now returns400 Bad Request. Providers that send the standard attribute names are unaffected. -
#11638
39f0980Thanks @gustavovalverde! - SCIM User and Group requests now accept JSONnullattribute values, such as the unpopulated attributes Microsoft Entra ID sends, instead of returning400 Bad Request. InPOSTandPUTbodies anullattribute is treated as omitted, and in PATCH anullvalue removes the attribute.active: nullis still rejected, andnullon a read-only attribute is ignored. -
#11167
666e1deThanks @jonathansamines! - FixPOST /scim/v2/Usersrejecting a reprovisioned user with a uniqueness conflict when an inactive SCIM User already has the sameexternalId, such as when Okta reassigns a deactivated user. The inactive SCIM User is now reprovisioned in place and keeps its ID and linked Better Auth User. -
#11669
8409fb2Thanks @gustavovalverde! - SCIM directories that send concurrent updates now get a409uniqueness error when a UserPATCH, GroupPUT, or GroupPATCHclaims auserName,displayName,externalId, or managed email that another request saved first. Previously the losing request failed with a500server error. Requests that don't race are unaffected.
1.7.7
1.7.6
1.7.5
1.7.4
1.7.3
1.7.2
1.7.1
1.7.0
Minor Changes
-
#10474
dec763eThanks @gustavovalverde! - AddacquireActiveSCIMUserLinkfor transaction-safe authentication of provisioned users. The helper maps an exact SCIM connection ID andexternalIdto an active Better Auth User while fencing concurrent subject changes, deactivation, deletion, and connection decommissioning.Compose the helper with SSO
resolveUserto link the provisioned User without matching by email oruserName. -
#10390
0de88f5Thanks @gustavovalverde! - SCIM connections can now provision Users, Groups, and direct memberships into application-defined provisioning domains without the organization or SSO plugins. Applications can map Group membership to validated custom roles through projections. The service also supports SCIM 2.0 discovery, filtering, pagination, response attribute selection, atomic PATCH operations, and common request patterns used by Microsoft Entra ID and Okta.This replaces the previous SCIM configuration, client APIs, database schema, and organization-backed Group model. Existing SCIM installations cannot migrate provisioning state in place. Follow the SCIM cutover in the 1.7 upgrade guide, including full directory reprovisioning, before resuming traffic.
Deferred database side effects now run only after a successful transaction. A rolled-back User update no longer refreshes its cached profile, and a rolled-back bulk session revocation no longer invalidates sessions.
-
#10592
26b1949Thanks @gustavovalverde! - Allow SCIM bearer verification to resolve application-owned connections at request time. Dynamic connections use the same scope enforcement, immutable provisioning-domain binding, decommissioning, and request fencing as code-defined connections, while an empty static connection list is supported when a verifier is configured. -
#10620
b7683b8Thanks @gustavovalverde! - Add the standard Enterprise User extension (employeeNumber,costCenter,organization,division,department,manager) and the classictitle,userType,preferredLanguage,locale,timezone,phoneNumbers,addresses,roles, andentitlementsUser attributes, plusname.middleName,name.honorificPrefix, andname.honorificSuffix. All are readable, filterable bytypeorprimary, and writable through PATCH, including the classic Microsoft Entramanagerpath aliases.Add
compatibility.microsoftEntra.acceptLegacyGroupSchemato accept Microsoft Entra's legacy, attribute-less Group schema marker onPOST /Groupswithout storing or returning it.Microsoft Entra interoperability fixes:
- A bare
attributes/excludedAttributesname for an Enterprise User sub-attribute (for example?attributes=manager) no longer drops the whole extension from the response. - Multi-op PATCH paths filtered by
[primary eq true](or[primary eq "true"]) with a sub-attribute target now work onemails,phoneNumbers,addresses,roles, andentitlements. - A single-element array wrapping a scalar PATCH replace value is unwrapped instead of rejected, on User scalars, Enterprise User fields, and Group
displayNameandexternalId. - Removing the last sub-attribute of a complex attribute (for example
manager.value) clears the emptied Enterprise User extension instead of leaving it declared. - Replacing
managerwith an empty string clears it, matching how Microsoft Entra removes a manager. - A PATCH with an empty
Operationsarray is a valid no-op instead of an error, for both Users and Groups. PATCH /Users/:idandPATCH /Groups/:idreturn200 OKwith the updated resource instead of204 No Content.
- A bare
-
#10682
8b96573Thanks @gustavovalverde! - SCIM PATCH operations that target filtered multi-valued attributes (phoneNumbers,addresses,roles,entitlements,emails) now create the value when the filter matches nothing instead of rejecting the request with anoTargeterror. Microsoft Entra ID sends these operations for attributes that are not populated yet, and the rejection also discarded every other operation bundled in the same PATCH request. -
#10018
445b034Thanks @gustavovalverde! - Add durable SCIM Group resources with connection-scoped membership, projection callbacks, metadata, and Group lifecycle endpoints. Groups belong to SCIM connections rather than Better Auth Organizations. -
#10592
26b1949Thanks @gustavovalverde! - Add an optional SCIM-owned connection and credential catalog. ConfiguremanagedConnectionsto let trusted server code create runtime tenant connections and issue, rotate, and revoke their bearer credentials through server-onlyauth.apimethods, without a code-defined connection or an application-owned verifier.
Patch Changes
-
#10620
b7683b8Thanks @gustavovalverde! - Accept exact case-insensitive string Boolean values for SCIM Useractiveand theprimarysub-attribute ofemails,phoneNumbers,addresses,roles, andentitlementsat the HTTP ingress for Microsoft Entra interoperability. -
#10592
26b1949Thanks @gustavovalverde! - Allow trusted server code to retain a terminal connection binding before a dynamic SCIM connection's first authenticated request by supplying its provisioning domain during decommissioning. -
#9864
41cca60Thanks @GautamBytes! - Add auser.validateUserInfoprovisioning gate that lets applications reject an identity before a user is created or a new account is linked. It runs once at the creation step for every method that provisions a user (OAuth, SSO/SAML, email/password, magic link, email OTP, anonymous, SIWE, phone number, admin-created users, and SCIM), including stateless setups with no persistent database.It also re-runs when an existing OAuth or SSO user signs in again (
source.actionis"sign-in"), where it receives the fresh provider email and profile so a domain or org policy can reject a user whose provider identity moved out of bounds. Non-provider returning sign-ins are not re-validated.The callback receives the mapped
userplus asourcedescribing theaction(create-user,link-account, orsign-in), themethod, and provider metadata:source.oauthfor OAuth providers andsource.ssofor OIDC/SAML SSO providers. Return{ error, errorDescription }to reject: browser flows redirect to the error URL and programmatic flows return a403.
1.7.0-rc.6
1.7.0-rc.5
1.7.0-rc.4
Minor Changes
- #10682
8b96573Thanks @gustavovalverde! - SCIM PATCH operations that target filtered multi-valued attributes (phoneNumbers,addresses,roles,entitlements,emails) now create the value when the filter matches nothing instead of rejecting the request with anoTargeterror. Microsoft Entra ID sends these operations for attributes that are not populated yet, and the rejection also discarded every other operation bundled in the same PATCH request.
1.7.0-rc.3
Minor Changes
-
#10592
26b1949Thanks @gustavovalverde! - Allow SCIM bearer verification to resolve application-owned connections at request time. Dynamic connections use the same scope enforcement, immutable provisioning-domain binding, decommissioning, and request fencing as code-defined connections, while an empty static connection list is supported when a verifier is configured. -
#10620
b7683b8Thanks @gustavovalverde! - Add the standard Enterprise User extension (employeeNumber,costCenter,organization,division,department,manager) and the classictitle,userType,preferredLanguage,locale,timezone,phoneNumbers,addresses,roles, andentitlementsUser attributes, plusname.middleName,name.honorificPrefix, andname.honorificSuffix. All are readable, filterable bytypeorprimary, and writable through PATCH, including the classic Microsoft Entramanagerpath aliases.Add
compatibility.microsoftEntra.acceptLegacyGroupSchemato accept Microsoft Entra's legacy, attribute-less Group schema marker onPOST /Groupswithout storing or returning it.Microsoft Entra interoperability fixes:
- A bare
attributes/excludedAttributesname for an Enterprise User sub-attribute (for example?attributes=manager) no longer drops the whole extension from the response. - Multi-op PATCH paths filtered by
[primary eq true](or[primary eq "true"]) with a sub-attribute target now work onemails,phoneNumbers,addresses,roles, andentitlements. - A single-element array wrapping a scalar PATCH replace value is unwrapped instead of rejected, on User scalars, Enterprise User fields, and Group
displayNameandexternalId. - Removing the last sub-attribute of a complex attribute (for example
manager.value) clears the emptied Enterprise User extension instead of leaving it declared. - Replacing
managerwith an empty string clears it, matching how Microsoft Entra removes a manager. - A PATCH with an empty
Operationsarray is a valid no-op instead of an error, for both Users and Groups. PATCH /Users/:idandPATCH /Groups/:idreturn200 OKwith the updated resource instead of204 No Content.
- A bare
-
#10592
26b1949Thanks @gustavovalverde! - Add an optional SCIM-owned connection and credential catalog. ConfiguremanagedConnectionsto let trusted server code create runtime tenant connections and issue, rotate, and revoke their bearer credentials through server-onlyauth.apimethods, without a code-defined connection or an application-owned verifier.
Patch Changes
-
#10620
b7683b8Thanks @gustavovalverde! - Accept exact case-insensitive string Boolean values for SCIM Useractiveand theprimarysub-attribute ofemails,phoneNumbers,addresses,roles, andentitlementsat the HTTP ingress for Microsoft Entra interoperability. -
#10592
26b1949Thanks @gustavovalverde! - Allow trusted server code to retain a terminal connection binding before a dynamic SCIM connection's first authenticated request by supplying its provisioning domain during decommissioning.
1.7.0-rc.2
Minor Changes
-
#10474
dec763eThanks @gustavovalverde! - AddacquireActiveSCIMUserLinkfor transaction-safe authentication of provisioned users. The helper maps an exact SCIM connection ID andexternalIdto an active Better Auth User while fencing concurrent subject changes, deactivation, deletion, and connection decommissioning.Compose the helper with SSO
resolveUserto link the provisioned User without matching by email oruserName. -
#10390
0de88f5Thanks @gustavovalverde! - SCIM connections can now provision Users, Groups, and direct memberships into application-defined provisioning domains without the organization or SSO plugins. Applications can map Group membership to validated custom roles through projections. The service also supports SCIM 2.0 discovery, filtering, pagination, response attribute selection, atomic PATCH operations, and common request patterns used by Microsoft Entra ID and Okta.This replaces the previous SCIM configuration, client APIs, database schema, and organization-backed Group model. Existing SCIM installations cannot migrate provisioning state in place. Follow the SCIM cutover in the 1.7 upgrade guide, including full directory reprovisioning, before resuming traffic.
Deferred database side effects now run only after a successful transaction. A rolled-back User update no longer refreshes its cached profile, and a rolled-back bulk session revocation no longer invalidates sessions.
1.7.0-rc.1
1.7.0-rc.0
Minor Changes
-
#10249
dfecb48Thanks @gustavovalverde! - Runtime SCIM tokens now requireorganizationId; usestaticProvidersfor app-level SCIM.SCIM-managed accounts now use namespaced provider IDs (
scim:{organizationId}:{providerId}orscim:{providerId}for app-level static providers). Migrate only known SCIM-managed account rows before upgrading; leave non-SCIM accounts unchanged even when they share the same provider ID.Organization-scoped
active: falsenow makes a user inactive in that organization while keeping SCIM group and team associations available for reactivation. UseDELETEto fully deprovision organization-scoped SCIM state.defaultSCIMhas been replaced bystaticProviders.linkExistingUsers.trustedDomainshas been removed; userequireExistingOrgMembership,shouldLinkUser, or explicittrueinstead.
1.7.0-beta.10
1.7.0-beta.9
Patch Changes
- Updated dependencies []:
- better-auth@1.7.0-beta.9
- @better-auth/core@1.7.0-beta.9
1.7.0-beta.8
Patch Changes
- Updated dependencies [
7c7313c,06daf70,a83152e,97903c9,3a79aff]:- better-auth@1.7.0-beta.8
- @better-auth/core@1.7.0-beta.8
1.7.0-beta.7
Patch Changes
1.7.0-beta.6
Minor Changes
- #10018
445b034Thanks @gustavovalverde! - Add durable SCIM Group resources with organization-scoped membership, role projection, metadata, and Group lifecycle endpoints.
Patch Changes
- Updated dependencies [
b36c38f,73541c1,bf39cbf,e53582c,aedcb97,2196ea6,d2a79ba,34558bc,652fa53,6fe9faa,ad35ead]:- better-auth@1.7.0-beta.6
- @better-auth/core@1.7.0-beta.6
1.7.0-beta.5
Patch Changes
-
#9864
41cca60Thanks @GautamBytes! - Add auser.validateUserInfoprovisioning gate that lets applications reject an identity before a user is created or a new account is linked. It runs once at the creation step for every method that provisions a user (OAuth, SSO/SAML, email/password, magic link, email OTP, anonymous, SIWE, phone number, admin-created users, and SCIM), including stateless setups with no persistent database.It also re-runs when an existing OAuth or SSO user signs in again (
source.actionis"sign-in"), where it receives the fresh provider email and profile so a domain or org policy can reject a user whose provider identity moved out of bounds. Non-provider returning sign-ins are not re-validated.The callback receives the mapped
userplus asourcedescribing theaction(create-user,link-account, orsign-in), themethod, and provider metadata:source.oauthfor OAuth providers andsource.ssofor OIDC/SAML SSO providers. Return{ error, errorDescription }to reject: browser flows redirect to the error URL and programmatic flows return a403. -
Updated dependencies [
0cbaf81,e014029,ec8a38c,7fe0e2b,4f53b61,e0d2b9e,91f235f,76a3342,41cca60]:- better-auth@1.7.0-beta.5
- @better-auth/core@1.7.0-beta.5
1.7.0-beta.4
Minor Changes
-
#9840
a8ea86eThanks @gustavovalverde! - Personal (non-organization) SCIM connections now always belong to the user who created them. Owner binding used to be opt-in through theproviderOwnershipoption, which defaulted to off. With it off, a personal connection was stored without an owner, and the management endpoints denied access only when a stored owner differed from the caller. An unowned connection passed that check for any signed-in user, who could read it, list it, regenerate its token, or delete it. Regenerating the token rotated the secret and invalidated the original.generateSCIMTokennow records the creator'suserIdon every personal connection. Thegenerate-token,list-provider-connections,get-provider-connection, anddelete-provider-connectionendpoints grant access only to that owner. Organization-scoped connections keep their existing behavior and continue to use organization membership and the configuredrequiredRolechecks.This release is breaking. It removes the
providerOwnershipoption, and owner binding can no longer be disabled. ThescimProvider.userIdcolumn is now a permanent part of the schema, so run a migration after upgrading withnpx auth migrateornpx auth generate.Connections created before this release carry no owner. Access now fails closed, so those connections are no longer reachable through the management endpoints, including token regeneration. Reclaim them at the database level: delete
scimProviderrows that have neitherorganizationIdnoruserId, or setuserIdto the intended owner, then regenerate tokens as needed. Organization-scoped connections are not affected.
1.6.30
Patch Changes
- Updated dependencies [
07c1718]:- @better-auth/core@1.6.30
- better-auth@1.6.30
1.6.29
Patch Changes
- Updated dependencies [
e6e1b4e]:- better-auth@1.6.29
- @better-auth/core@1.6.29
1.6.28
Patch Changes
1.6.27
Patch Changes
1.6.26
Patch Changes
- Updated dependencies [
9ede805,5a811f1,d8327f1,e2c73fb,af50c45,701cd43,a30e274,e7b0eba,2b4a14f,7552a3b,ea38fca,a03e4c1]:- better-auth@1.6.26
- @better-auth/core@1.6.26
1.6.25
Patch Changes
1.6.24
Patch Changes
- Updated dependencies [
03dc5a0,7508940,bae7198,ef4d273,6758231,99dbdd7,086ca91,8f2dedd,4e685ee,3bf0e49,f59a0ee,54fab08,0f2cc1b,ae78109,46d2bf0,29a373e,f6d18fa,f23ce50,c4d1dda]:- better-auth@1.6.24
- @better-auth/core@1.6.24
1.6.23
Patch Changes
- Updated dependencies [
8581f97]:- better-auth@1.6.23
- @better-auth/core@1.6.23
1.6.22
Patch Changes
-
#10242
7c126dcThanks @gustavovalverde! - Tighten the SCIM user write path and honor theactiveattribute.A non-organization SCIM
DELETEnow unlinks the provider's own account when the user has other linked identities, and deletes the global user only when the SCIM account is their sole identity.PUTandPATCHreject changing a user's email to one already used by another user with a409conflict, and clearemailVerifiedwhen the email changes.The SCIM
activeattribute is honored on create, update, and patch.active: falsedeactivates the user through the admin plugin's banned state and revokes their sessions;active: truereactivates. The user resource reports the real state instead of always reporting active. Honoringactiverequires the admin plugin. -
Updated dependencies [
c06a56d,8bd43d9,3a035e9]:- better-auth@1.6.22
- @better-auth/core@1.6.22
1.6.21
Patch Changes
-
#10224
7a7a7b3Thanks @Bekacru! - Deleting an SSO provider no longer leaves linked accounts that a later provider with the same provider ID can reuse.SSO and SCIM provider setup now rejects provider IDs already used by another account provider.
SSO provider updates now reject identity-defining changes, such as issuer, login endpoints, client ID, SAML metadata, or user ID mappings, after accounts are linked. Secret rotation and same-value updates still work.
-
Updated dependencies [
e0762a1,882cf9e,f52e1ab,90d509e,b5bec19,816d7f9,239bcc8,1bc370a,570267c,461ca6f,88409b0,5953157,b046f9e,ae647b4]:- better-auth@1.6.21
- @better-auth/core@1.6.21
1.6.20
Patch Changes
1.6.19
Patch Changes
-
#10087
f3e1a40Thanks @bytaesu! - Stopped logging SCIM user filter values when listing users. -
Updated dependencies [
de4aa52,b4b0266,5bd5e1c,581f827,8407885,c1a8a64,635f190,a787e0b,c2f718f,7d18175]:- better-auth@1.6.19
- @better-auth/core@1.6.19
1.6.18
Patch Changes
1.6.17
Patch Changes
-
#9987
7343284Thanks @bytaesu! - Organization-scoped SCIM deletes now remove the user's organization member through the organization adapter so related team memberships and member-removal hooks are applied. -
#10002
ed7b6c9Thanks @gustavovalverde! - SCIM bearer tokens are now compared in constant time during request authentication, closing a timing side channel that could help an attacker recover a valid token. This applies to every storage mode: plain, hashed, encrypted, and custom. -
Updated dependencies [
baeaa00,3e99e6c,96c78c3,baeaa00,baeaa00,0c3856f,baeaa00,baeaa00,ed7b6c9,e0a768c,7343284,0c3856f,baeaa00,baeaa00,7343284,7343284,0c3856f,fdef997,0c3856f,d9c526b,0c3856f,fdef997,baeaa00,baeaa00,baeaa00,baeaa00,fdef997,7343284,baeaa00,8960f5f,baeaa00,5c289b5,1dbf5bb,baeaa00,baeaa00,59e0ccb,b803c61,fdef997]:- better-auth@1.6.17
- @better-auth/core@1.6.17
1.6.16
Patch Changes
-
#9974
cb1cbfaThanks @Bekacru! - SCIM user provisioning no longer links to a pre-existing user by matching email alone. When a user with the same email already exists,createSCIMUsernow returns409(uniqueness) unless the newlinkExistingUsersoption explicitly opts in (viatrue,trustedDomains,requireExistingOrgMembership, or ashouldLinkUsercallback). Additionally, an organization-scoped SCIMDELETEnow deprovisions the user — removing their organization membership and the SCIM account link — instead of deleting the global Better Auth user. A newcanGenerateTokenoption lets applications authorize SCIM token creation, including restricting personal (non-org) tokens. -
Updated dependencies [
cb1cbfa,cb1cbfa,cb1cbfa,cb1cbfa,cb1cbfa,cb1cbfa,87e7aa5,cb1cbfa,cb1cbfa,cb1cbfa,893cf6c,cb1cbfa,cb1cbfa,5e49c56,cb1cbfa]:- better-auth@1.6.16
- @better-auth/core@1.6.16
1.6.15
Patch Changes
- Updated dependencies [
1012b69,ad60333,0933c05,b0ddfd3]:- better-auth@1.6.15
- @better-auth/core@1.6.15
1.6.14
Patch Changes
- Updated dependencies [
2d9781a,5a2d642,13abc79,9d3450a]:- better-auth@1.6.14
- @better-auth/core@1.6.14
1.6.13
Patch Changes
- Updated dependencies [
e7eb45b,03e6c94,1e5b808,13abc79]:- better-auth@1.7.0-beta.4
- @better-auth/core@1.7.0-beta.4
1.7.0-beta.3
Patch Changes
- Updated dependencies [
4e8e4c7,523f95c,729c00d]:- better-auth@1.7.0-beta.3
- @better-auth/core@1.7.0-beta.3
1.7.0-beta.2
Patch Changes
- Updated dependencies [
9aed910,acbd6ef,954b664,39d6af2]:- better-auth@1.7.0-beta.2
- @better-auth/core@1.7.0-beta.2
1.7.0-beta.1
Patch Changes
- Updated dependencies [
5142e9c,484ce6a,f875897,c7d2253,9a6d475,513dabb,6f2948e]:- better-auth@1.7.0-beta.1
- @better-auth/core@1.7.0-beta.1
1.7.0-beta.0
Patch Changes
- Updated dependencies [
6ce30cf,f6428d0,c5066fe,5f84335,93d3871,544f1c6]:- better-auth@1.7.0-beta.0
- @better-auth/core@1.7.0-beta.0
1.6.10
Patch Changes
- Updated dependencies [
1e0f26d,8c1e917,b2d655c,09f1327,906b7b3,e9c978e,e71aad3,80a655d,15ff28a,88a7c67,9a7b51d,1b25902,cf59136,a597ee0,fc02ced,9f1ef1f,36ef808,c1336c5,3a9a2c3,fde0432,2220a6d]:- better-auth@1.6.10
- @better-auth/core@1.6.10
1.6.9
Patch Changes
- Updated dependencies [
815ecf6]:- @better-auth/core@1.6.9
- better-auth@1.6.9
1.6.8
Patch Changes
1.6.7
Patch Changes
- Updated dependencies [
307196a,4a180f0,4f373ee,e1b1cfc,d053a45]:- better-auth@1.6.7
- @better-auth/core@1.6.7
1.6.6
Patch Changes
- Updated dependencies [
b5742f9,4debfb6,9ea7eb1,a844c7d,ab4c10f,a61083e,e64ff72]:- @better-auth/core@1.6.6
- better-auth@1.6.6
1.6.5
Patch Changes
1.6.4
Patch Changes
1.6.3
Patch Changes
- Updated dependencies [
5142e9c,484ce6a,f875897,6ce30cf,f6428d0,9a6d475,513dabb,c5066fe,5f84335]:- better-auth@1.6.3
- @better-auth/core@1.6.3
1.6.2
Patch Changes
- Updated dependencies [
9deb793,2cbcb9b,b20fa42,608d8c3,8409843,e78a7b1]:- better-auth@1.6.2
- @better-auth/core@1.6.2
1.6.1
Patch Changes
1.6.0
Minor Changes
- #8836
5dd9e44Thanks @gustavovalverde! - Add optional version field to the plugin interface and expose version from all built-in plugins
Patch Changes
- Updated dependencies [
dd537cb,bd9bd58,5dd9e44,5dd9e44,5dd9e44,5dd9e44,5dd9e44,5dd9e44,5dd9e44,5dd9e44,5dd9e44,5dd9e44,5dd9e44,5dd9e44,5dd9e44,469eee6,560230f]:- better-auth@1.6.0
- @better-auth/core@1.6.0
1.6.0-beta.0
Minor Changes
28b1291Thanks @gustavovalverde! - Add optional version field to the plugin interface and expose version from all built-in plugins