chatbot-template/lib/types.ts

19 lines
317 B
TypeScript
Raw Normal View History

2023-06-02 15:33:48 -04:00
import { type Message } from 'ai-connector'
2023-06-02 15:15:35 -04:00
export interface Chat extends Record<string, any> {
2023-06-02 15:33:48 -04:00
id: string
title: string
createdAt: Date
userId: string
2023-06-16 15:20:42 +04:00
path: string
2023-06-02 15:33:48 -04:00
messages: Message[]
sharePath?: string
2023-06-16 15:20:42 +04:00
}
2023-06-16 21:52:01 +04:00
export type ServerActionResult<Result> = Promise<
| Result
| {
error: string
}
>