[PR #2518] [MERGED] update(create-adapter): Allow providing id in create method #21253

Closed
opened 2026-04-15 20:14:13 -05:00 by GiteaMirror · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/better-auth/better-auth/pull/2518
Author: @ping-maxwell
Created: 5/2/2025
Status: Merged
Merged: 5/8/2025
Merged by: @Bekacru

Base: mainHead: update/create-adapter/allow-id


📝 Commits (2)

  • e87c660 update(create-adapter): Allow providing id in create method
  • a20f47f chore: cleanup

📊 Changes

3 files changed (+134 additions, -101 deletions)

View changed files

📝 docs/content/docs/guides/create-a-db-adapter.mdx (+114 -96)
📝 packages/better-auth/src/adapters/create-adapter/index.ts (+14 -5)
📝 packages/better-auth/src/types/adapter.ts (+6 -0)

📄 Description

Allow providing id in the data of a create method if forceAllowId is provided as true in the create method call.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/better-auth/better-auth/pull/2518 **Author:** [@ping-maxwell](https://github.com/ping-maxwell) **Created:** 5/2/2025 **Status:** ✅ Merged **Merged:** 5/8/2025 **Merged by:** [@Bekacru](https://github.com/Bekacru) **Base:** `main` ← **Head:** `update/create-adapter/allow-id` --- ### 📝 Commits (2) - [`e87c660`](https://github.com/better-auth/better-auth/commit/e87c660d04b1c89c83bfd43a7a0f79c04f1f4e33) update(create-adapter): Allow providing `id` in create method - [`a20f47f`](https://github.com/better-auth/better-auth/commit/a20f47f25a5ec31571d2607e5520cf27accf6890) chore: cleanup ### 📊 Changes **3 files changed** (+134 additions, -101 deletions) <details> <summary>View changed files</summary> 📝 `docs/content/docs/guides/create-a-db-adapter.mdx` (+114 -96) 📝 `packages/better-auth/src/adapters/create-adapter/index.ts` (+14 -5) 📝 `packages/better-auth/src/types/adapter.ts` (+6 -0) </details> ### 📄 Description Allow providing `id` in the data of a create method if `forceAllowId` is provided as `true` in the create method call. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
GiteaMirror added the pull-request label 2026-04-15 20:14:13 -05:00
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: github-starred/better-auth#21253