mirror of
https://github.com/wu736139669/hapi.git
synced 2026-08-05 06:24:37 +00:00
fix: make TodoItemSchema tolerant of Claude's TodoWrite payload (#502)
This commit is contained in:
@@ -90,8 +90,9 @@ export type AgentState = z.infer<typeof AgentStateSchema>
|
||||
export const TodoItemSchema = z.object({
|
||||
content: z.string(),
|
||||
status: z.enum(['pending', 'in_progress', 'completed']),
|
||||
priority: z.enum(['high', 'medium', 'low']),
|
||||
id: z.string()
|
||||
priority: z.enum(['high', 'medium', 'low']).optional().default('medium'),
|
||||
id: z.string().optional().default(''),
|
||||
activeForm: z.string().optional()
|
||||
})
|
||||
|
||||
export type TodoItem = z.infer<typeof TodoItemSchema>
|
||||
|
||||
Reference in New Issue
Block a user