LibreChat/api/models/schema/shareSchema.js
Ruben Talstra 94d32906f1
refactor: fully working E2EE
small issue to fix. when full response is received it replaces the text with the text from the DB. and then the decryption is not yet implement.
2025-02-16 09:48:08 +01:00

30 lines
561 B
JavaScript

const mongoose = require('mongoose');
const shareSchema = mongoose.Schema(
{
conversationId: {
type: String,
required: true,
},
title: {
type: String,
index: true,
},
user: {
type: String,
index: true,
},
messages: [{ type: mongoose.Schema.Types.ObjectId, ref: 'Message' }],
shareId: {
type: String,
index: true,
},
isPublic: {
type: Boolean,
default: true,
},
},
{ timestamps: true },
);
module.exports = mongoose.model('SharedLink', shareSchema);