mirror of
https://github.com/danny-avila/LibreChat.git
synced 2026-01-05 10:08:52 +01:00
34 lines
578 B
TypeScript
34 lines
578 B
TypeScript
|
|
import { Schema, Document } from 'mongoose';
|
||
|
|
|
||
|
|
export interface IPluginAuth extends Document {
|
||
|
|
authField: string;
|
||
|
|
value: string;
|
||
|
|
userId: string;
|
||
|
|
pluginKey?: string;
|
||
|
|
createdAt?: Date;
|
||
|
|
updatedAt?: Date;
|
||
|
|
}
|
||
|
|
|
||
|
|
const pluginAuthSchema: Schema<IPluginAuth> = new Schema(
|
||
|
|
{
|
||
|
|
authField: {
|
||
|
|
type: String,
|
||
|
|
required: true,
|
||
|
|
},
|
||
|
|
value: {
|
||
|
|
type: String,
|
||
|
|
required: true,
|
||
|
|
},
|
||
|
|
userId: {
|
||
|
|
type: String,
|
||
|
|
required: true,
|
||
|
|
},
|
||
|
|
pluginKey: {
|
||
|
|
type: String,
|
||
|
|
},
|
||
|
|
},
|
||
|
|
{ timestamps: true },
|
||
|
|
);
|
||
|
|
|
||
|
|
export default pluginAuthSchema;
|