Skip to main content

Interface: ConversationsService

Service for managing Conversations.

Properties

addConversationMessage

addConversationMessage: (params: AddConversationMessageParams) => Promise<Message>

Type declaration

▸ (params): Promise<Message>

Add a Message to a Conversation.

Parameters
NameType
paramsAddConversationMessageParams
Returns

Promise<Message>

Defined in

packages/mongodb-chatbot-server/src/services/ConversationsService.ts:247


addManyConversationMessages

addManyConversationMessages: (params: AddManyConversationMessagesParams) => Promise<Message[]>

Type declaration

▸ (params): Promise<Message[]>

Add multiple Message objects to a Conversation.

Parameters
NameType
paramsAddManyConversationMessagesParams
Returns

Promise<Message[]>

Defined in

packages/mongodb-chatbot-server/src/services/ConversationsService.ts:253


commentMessage

commentMessage: (__namedParameters: CommentMessageParams) => Promise<boolean>

Type declaration

▸ («destructured»): Promise<boolean>

Add a user comment to an assistant Message.

Parameters
NameType
«destructured»CommentMessageParams
Returns

Promise<boolean>

Defined in

packages/mongodb-chatbot-server/src/services/ConversationsService.ts:270


conversationConstants

conversationConstants: ConversationConstants

Defined in

packages/mongodb-chatbot-server/src/services/ConversationsService.ts:237


create

create: (params?: CreateConversationParams) => Promise<Conversation<ConversationCustomData>>

Type declaration

▸ (params?): Promise<Conversation<ConversationCustomData>>

Create a new Conversation.

Parameters
NameType
params?CreateConversationParams
Returns

Promise<Conversation<ConversationCustomData>>

Defined in

packages/mongodb-chatbot-server/src/services/ConversationsService.ts:242


findById

findById: (__namedParameters: FindByIdParams) => Promise<null | Conversation<ConversationCustomData>>

Type declaration

▸ («destructured»): Promise<null | Conversation<ConversationCustomData>>

Parameters
NameType
«destructured»FindByIdParams
Returns

Promise<null | Conversation<ConversationCustomData>>

Defined in

packages/mongodb-chatbot-server/src/services/ConversationsService.ts:256


rateMessage

rateMessage: (__namedParameters: RateMessageParams) => Promise<boolean>

Type declaration

▸ («destructured»): Promise<boolean>

Rate a Message in a Conversation.

Parameters
NameType
«destructured»RateMessageParams
Returns

Promise<boolean>

Defined in

packages/mongodb-chatbot-server/src/services/ConversationsService.ts:261