feat(chat): render commercial actions and persist greetings
This commit is contained in:
@@ -7,6 +7,8 @@ import {
|
||||
ChatHistoryResponse,
|
||||
ChatPreviewsResponse,
|
||||
ChatSendResponse,
|
||||
OpeningMessageRequestSchema,
|
||||
OpeningMessageResponse,
|
||||
SendMessageRequestSchema,
|
||||
UnlockHistoryRequestSchema,
|
||||
UnlockHistoryResponse,
|
||||
@@ -50,6 +52,19 @@ export class ChatRemoteDataSource {
|
||||
});
|
||||
}
|
||||
|
||||
async saveOpeningMessage(
|
||||
characterId: string,
|
||||
openingMessage: string,
|
||||
options?: ChatRequestOptions,
|
||||
): Promise<Result<OpeningMessageResponse>> {
|
||||
return Result.wrap(() =>
|
||||
this.api.saveOpeningMessage(
|
||||
OpeningMessageRequestSchema.parse({ characterId, openingMessage }),
|
||||
options,
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
async getPreviews(
|
||||
options?: ChatRequestOptions,
|
||||
): Promise<Result<ChatPreviewsResponse>> {
|
||||
|
||||
Reference in New Issue
Block a user