@clerk/backend
3.29.0 · 14 Nov 2026MIT8.4M / weekRepositoryHomepagenpmAtom feed
3.31.4 is the newest release of 3.x.
In short
2 deprecated3 new2 fixed1 changed1 internal
- Deprecated
Deprecated
syncUserAttributesonCreateEnterpriseConnectionParams. The Backend API ignores this parameter on create; useupdateEnterpriseConnection()to set it. - Deprecated
Deprecated
provideronUpdateEnterpriseConnectionParams. The Backend API ignores this parameter on update; the provider cannot be changed after creation.
Release note
Minor Changes
Fix a cross-origin handshake bypass where
isKnownClerkReferrer()trusted overly broad referrer hosts as Clerk-owned: anyaccounts.*host (e.g.accounts.attacker.com), plus dev account-portal domains (*.accounts.devand legacy suffixes) on production instances. These let unrelated origins skip the handshake and its session-freshness check. The referrer is now trusted only for the accounts portal derived from the instance's frontend API, plus dev account-portal domains on non-production instances.Add an optional
orgIdparameter tocreateSignInToken()for activating an Organization when the token is redeemed.
Patch Changes
Standardize JSDoc punctuation to always follow
e.g.andi.e.with a comma (e.g.,/i.e.,), matching the docs style guide. Comment-only change; no runtime behavior is affected. This keeps the generated Typedoc reference output consistent.Add the required
providerfield toCreateEnterpriseConnectionParams. The Backend API has always requiredproviderwhen creating an enterprise connection, so calls tocreateEnterpriseConnection()without it type-checked but failed at runtime. The field is typed to the supported provider values ('saml_custom','saml_okta','saml_google','saml_microsoft','oidc_custom','oidc_github_enterprise','oidc_gitlab'), so unsupported values are also caught at compile time.Add the remaining optional enterprise connection parameters supported by the Backend API.
CreateEnterpriseConnectionParamsandUpdateEnterpriseConnectionParamsnow acceptallowOrganizationAccountLinking,customAttributes,authenticatable, anddisableJitProvisioning(update also acceptsdisableAdditionalIdentifications), and SAML params acceptloginHintfor configuring thelogin_hintsent to the IdP.Align
CreateEnterpriseConnectionParamsandUpdateEnterpriseConnectionParamswith the Backend API contract:nameanddomainsare now required onCreateEnterpriseConnectionParams. The Backend API already rejected requests missing either of them, so calls that omitted these fields failed at runtime; the types now surface this at compile time.Deprecated
syncUserAttributesonCreateEnterpriseConnectionParams. The Backend API ignores this parameter on create; useupdateEnterpriseConnection()to set it.Deprecated
provideronUpdateEnterpriseConnectionParams. The Backend API ignores this parameter on update; the provider cannot be changed after creation.
A whole project to check? Paste its package.json in the dependency check: every deprecated, outdated or vulnerable dependency, with what to upgrade to. Free, no account.