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
Name | Type |
---|---|
params | AddConversationMessageParams |
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
Name | Type |
---|---|
params | AddManyConversationMessagesParams |
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
Name | Type |
---|---|
«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
Name | Type |
---|---|
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
Name | Type |
---|---|
«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
Name | Type |
---|---|
«destructured» | RateMessageParams |
Returns
Promise
<boolean
>
Defined in
packages/mongodb-chatbot-server/src/services/ConversationsService.ts:261