chatbot-template/lib/types.ts
2023-06-16 22:43:24 +02:00

18 lines
307 B
TypeScript

import { type Message } from 'ai'
export interface Chat extends Record<string, any> {
id: string
title: string
createdAt: Date
userId: string
path: string
messages: Message[]
sharePath?: string
}
export type ServerActionResult<Result> = Promise<
| Result
| {
error: string
}
>