Skip to content

chore(deps): upgrade better-auth from 1.3.12 to 1.4.18#3255

Open
waleedlatif1 wants to merge 1 commit intostagingfrom
chor/deps
Open

chore(deps): upgrade better-auth from 1.3.12 to 1.4.18#3255
waleedlatif1 wants to merge 1 commit intostagingfrom
chor/deps

Conversation

@waleedlatif1
Copy link
Collaborator

Summary

  • Upgrade better-auth, @better-auth/sso, @better-auth/stripe from 1.3.12 to 1.4.18
  • Rename auth.api.forgetPasswordauth.api.requestPasswordReset (breaking rename in 1.4)
  • Migrate organizationCreation.afterCreateorganizationHooks.afterCreateOrganization
  • Fix oneTimeToken expiresIn from 86400 (60 days) to 1440 (24 hours) — unit is minutes not seconds
  • Update sendResetPassword callback signature (requestctx)

Type of Change

  • Dependency upgrade

Testing

  • All 3,997 tests passing
  • TypeScript compilation clean

Checklist

  • Code follows project style guidelines
  • Self-reviewed my changes
  • Tests added/updated and passing
  • No new warnings introduced
  • I confirm that I have read and agree to the terms outlined in the Contributor License Agreement (CLA)

@vercel
Copy link

vercel bot commented Feb 19, 2026

The latest updates on your projects. Learn more about Vercel for GitHub.

Project Deployment Actions Updated (UTC)
docs Ready Ready Preview, Comment Feb 19, 2026 0:45am

Request Review

Copy link

@cursor cursor bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Cursor Bugbot has reviewed your changes and found 1 potential issue.

Bugbot Autofix is OFF. To automatically fix reported issues with Cloud Agents, enable Autofix in the Cursor dashboard.

"@better-auth/sso": "1.4.18",
"@better-auth/stripe": "1.4.18",
"better-auth": "1.4.18"
}
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Duplicate dependencies added to root monorepo package.json

Low Severity

better-auth, @better-auth/sso, and @better-auth/stripe were added as runtime dependencies in the root monorepo package.json, but they already exist in apps/sim/package.json. The root previously had no dependencies section at all — only devDependencies and overrides. This looks like the upgrade command was accidentally run from the repo root instead of from apps/sim/. Having these duplicated at both levels is unnecessary and inconsistent with the monorepo convention used by this project.

Additional Locations (1)

Fix in Cursor Fix in Web

@greptile-apps
Copy link
Contributor

greptile-apps bot commented Feb 19, 2026

Greptile Summary

This PR upgrades better-auth and related packages from 1.3.12 to 1.4.18, addressing breaking API changes introduced in version 1.4.

Key Changes:

  • Renamed auth.api.forgetPasswordauth.api.requestPasswordReset across API routes and tests
  • Updated sendResetPassword callback signature from request to ctx parameter
  • Migrated organizationCreation.afterCreateorganizationHooks.afterCreateOrganization with updated parameters
  • Fixed oneTimeToken expiresIn from 86400 (incorrectly interpreted as 60 days in seconds) to 1440 (24 hours in minutes) - the plugin expects minutes, not seconds
  • All tests passing (3,997), TypeScript compilation clean

Confidence Score: 5/5

  • This PR is safe to merge with minimal risk
  • All breaking changes from better-auth 1.4 upgrade have been properly handled with correct API renames, parameter updates, and bug fix for token expiration. All 3,997 tests pass, TypeScript compiles cleanly, and changes follow a systematic pattern across files.
  • No files require special attention

Important Files Changed

Filename Overview
apps/sim/package.json Upgraded better-auth, @better-auth/sso, @better-auth/stripe from 1.3.12 to 1.4.18
apps/sim/lib/auth/auth.ts Updated API signatures: sendResetPassword callback parameter and organizationCreationorganizationHooks, fixed oneTimeToken expiresIn to use minutes
apps/sim/app/api/auth/forget-password/route.ts Renamed auth.api.forgetPasswordauth.api.requestPasswordReset to match breaking change

Flowchart

%%{init: {'theme': 'neutral'}}%%
flowchart TD
    A[better-auth v1.3.12] -->|Upgrade| B[better-auth v1.4.18]
    B --> C[API Rename: forgetPassword to requestPasswordReset]
    B --> D[Callback Update: sendResetPassword parameter]
    B --> E[Hook Migration: organizationCreation to organizationHooks]
    B --> F[Bug Fix: oneTimeToken expiresIn units]
    C --> G[Update route.ts]
    C --> H[Update test files]
    D --> I[Change request to ctx]
    E --> J[Update afterCreate to afterCreateOrganization]
    F --> K[86400 seconds to 1440 minutes]
Loading

Last reviewed commit: 248b513

Copy link
Contributor

@greptile-apps greptile-apps bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

7 files reviewed, no comments

Edit Code Review Agent Settings | Greptile

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant

Comments