refactor(types): replace GetAgentResponse interface with zod schema
Use zod schema for better type safety and validation
This commit is contained in:
@@ -120,9 +120,11 @@ export const CreateAgentResponseSchema = AgentEntitySchema
|
||||
|
||||
export interface UpdateAgentRequest extends Partial<AgentBase> {}
|
||||
|
||||
export interface GetAgentResponse extends AgentEntity {
|
||||
built_in_tools?: Tool[] // Built-in tools available to the agent
|
||||
}
|
||||
export const GetAgentResponseSchema = AgentEntitySchema.extend({
|
||||
built_in_tools: z.array(ToolSchema).optional() // Built-in tools available to the agent
|
||||
})
|
||||
|
||||
export type GetAgentResponse = z.infer<typeof GetAgentResponseSchema>
|
||||
|
||||
export type CreateSessionRequest = AgentBase
|
||||
|
||||
|
||||
Reference in New Issue
Block a user