LibreChat/api/server/utils
Danny Avila a2fc7d312a
🏗️ refactor: Extract DB layers to data-schemas for shared use (#7650)
* refactor: move model definitions and database-related methods to packages/data-schemas

* ci: update tests due to new DB structure

fix: disable mocking `librechat-data-provider`

feat: Add schema exports to data-schemas package

- Introduced a new schema module that exports various schemas including action, agent, and user schemas.
- Updated index.ts to include the new schema exports for better modularity and organization.

ci: fix appleStrategy tests

fix: Agent.spec.js

ci: refactor handleTools tests to use MongoMemoryServer for in-memory database

fix: getLogStores imports

ci: update banViolation tests to use MongoMemoryServer and improve session mocking

test: refactor samlStrategy tests to improve mock configurations and user handling

ci: fix crypto mock in handleText tests for improved accuracy

ci: refactor spendTokens tests to improve model imports and setup

ci: refactor Message model tests to use MongoMemoryServer and improve database interactions

* refactor: streamline IMessage interface and move feedback properties to types/message.ts

* refactor: use exported initializeRoles from `data-schemas`, remove api workspace version (this serves as an example of future migrations that still need to happen)

* refactor: update model imports to use destructuring from `~/db/models` for consistency and clarity

* refactor: remove unused mongoose imports from model files for cleaner code

* refactor: remove unused mongoose imports from Share, Prompt, and Transaction model files for cleaner code

* refactor: remove unused import in Transaction model for cleaner code

* ci: update deploy workflow to reference new Docker Dev Branch Images Build and add new workflow for building Docker images on dev branch

* chore: cleanup imports
2025-05-30 22:18:13 -04:00
..
emails 📩 feat: invite user (#3012) 2024-08-18 00:23:38 -04:00
import 🧩 feat: Web Search Config Validations & Clipboard Citation Processing (#7530) 2025-05-24 10:23:17 -04:00
countTokens.js feat: Assistants API, General File Support, Side Panel, File Explorer (#1696) 2024-02-13 20:42:27 -05:00
crypto.js 🏗️ refactor: Extract DB layers to data-schemas for shared use (#7650) 2025-05-30 22:18:13 -04:00
files.js feat: Assistants API, General File Support, Side Panel, File Explorer (#1696) 2024-02-13 20:42:27 -05:00
handleText.js 🔧 refactor: Centralize Default Agent Capabilities and Better Logging (#7598) 2025-05-27 15:48:43 -04:00
handleText.spec.js 🏗️ refactor: Extract DB layers to data-schemas for shared use (#7650) 2025-05-30 22:18:13 -04:00
index.js 🧹 chore: Remove Deprecated BingAI Code & Address Mobile Focus (#5565) 2025-01-30 17:22:29 -05:00
math.js refactor(api): Central Logging 📜 (#1348) 2023-12-14 07:49:27 -05:00
queue.js 🅰️ feat: Azure OpenAI Assistants API Support (#1992) 2024-03-14 17:21:42 -04:00
removePorts.js feat: bun api support 🥟 (#1021) 2023-10-07 11:16:06 -04:00
sendEmail.js 📧 fix: Cancel Signup if Email Issuance Fails (#3010) 2024-06-08 06:51:29 -04:00
staticCache.js 🔧 refactor: Build Process and Static Asset Handling (#7605) 2025-05-28 11:48:04 -04:00
streamResponse.js 🗓️ feat: Add Special Variables for Prompts & Agents, Prompt UI Improvements (#7123) 2025-04-29 03:49:02 -04:00