feat(types): add AgentServerError schema for error handling

This commit is contained in:
icarus 2025-09-18 13:26:51 +08:00
parent 219844cb74
commit a264fd42e4

View File

@ -158,3 +158,11 @@ export type GetAgentSessionResponse = z.infer<typeof GetAgentSessionResponseSche
export interface CreateSessionMessageRequest {
content: string
}
export const AgentServerErrorSchema = z.object({
message: z.string(),
type: z.string(),
code: z.string()
})
export type AgentServerError = z.infer<typeof AgentServerErrorSchema>