⚠️ Deprecated ⚠️

Install and import from the "@langchain/mongodb" integration package instead.

This feature is deprecated and will be removed in the future.

It is not recommended for use.

Example

const chatHistory = new MongoDBChatMessageHistory({
collection: myCollection,
sessionId: 'unique-session-id',
});
const messages = await chatHistory.getMessages();
await chatHistory.clear();

Hierarchy

  • BaseListChatMessageHistory
    • MongoDBChatMessageHistory

Constructors

Methods

Generated using TypeDoc