Skip to main content

packages/contracts/src/schemas/execution.ts

Metadata

Indexed Symbols

No indexed functions/methods detected in this file.

Markdown Headings (if applicable)

No markdown headings detected.

Source Preview

import { z } from "zod";

export const executeAgentRequestSchema = z.object({
workspaceId: z.string().uuid(),
clientId: z.string().uuid().optional(),
correlationId: z.string().uuid(),
callbackUrl: z.string().url().optional(),
input: z.record(z.unknown())
});

export const executeAgentResponseSchema = z.object({
executionId: z.string().uuid(),
status: z.enum(["queued", "running"]),
acceptedAt: z.string().datetime()
});

export type ExecuteAgentRequest = z.infer<typeof executeAgentRequestSchema>;
export type ExecuteAgentResponse = z.infer<typeof executeAgentResponseSchema>;