'use strict';

var z = require('zod');

function _interopDefault (e) { return e && e.__esModule ? e : { default: e }; }

var z__default = /*#__PURE__*/_interopDefault(z);

// src/server/schemas/processors.ts
var processorIdPathParams = z__default.default.object({
  processorId: z__default.default.string().describe("Unique identifier for the processor")
});
var processorConfigurationSchema = z__default.default.object({
  agentId: z__default.default.string(),
  agentName: z__default.default.string(),
  type: z__default.default.enum(["input", "output"])
});
var processorListConfigurationSchema = z__default.default.object({
  agentId: z__default.default.string(),
  type: z__default.default.enum(["input", "output"])
});
var serializedProcessorSchema = z__default.default.object({
  id: z__default.default.string(),
  name: z__default.default.string().optional(),
  description: z__default.default.string().optional(),
  phases: z__default.default.array(z__default.default.enum(["input", "inputStep", "outputStream", "outputResult", "outputStep"])),
  agentIds: z__default.default.array(z__default.default.string()),
  configurations: z__default.default.array(processorListConfigurationSchema),
  isWorkflow: z__default.default.boolean()
});
var serializedProcessorDetailSchema = z__default.default.object({
  id: z__default.default.string(),
  name: z__default.default.string().optional(),
  description: z__default.default.string().optional(),
  phases: z__default.default.array(z__default.default.enum(["input", "inputStep", "outputStream", "outputResult", "outputStep"])),
  configurations: z__default.default.array(processorConfigurationSchema),
  isWorkflow: z__default.default.boolean()
});
var listProcessorsResponseSchema = z__default.default.record(z__default.default.string(), serializedProcessorSchema);
var messageContentSchema = z__default.default.object({
  format: z__default.default.literal(2).optional(),
  parts: z__default.default.array(z__default.default.any()).optional(),
  content: z__default.default.string().optional()
}).passthrough();
var processorMessageSchema = z__default.default.object({
  id: z__default.default.string(),
  role: z__default.default.enum(["user", "assistant", "system", "tool"]),
  createdAt: z__default.default.coerce.date().optional(),
  content: z__default.default.union([messageContentSchema, z__default.default.string()])
}).passthrough();
var executeProcessorBodySchema = z__default.default.object({
  phase: z__default.default.enum(["input", "inputStep", "outputStream", "outputResult", "outputStep"]),
  messages: z__default.default.array(processorMessageSchema),
  agentId: z__default.default.string().optional(),
  requestContext: z__default.default.record(z__default.default.string(), z__default.default.any()).optional()
});
var tripwireSchema = z__default.default.object({
  triggered: z__default.default.boolean(),
  reason: z__default.default.string().optional(),
  metadata: z__default.default.any().optional()
});
var executeProcessorResponseSchema = z__default.default.object({
  success: z__default.default.boolean(),
  phase: z__default.default.string(),
  messages: z__default.default.array(processorMessageSchema).optional(),
  messageList: z__default.default.object({
    messages: z__default.default.array(processorMessageSchema)
  }).optional(),
  tripwire: tripwireSchema.optional(),
  error: z__default.default.string().optional()
});

exports.executeProcessorBodySchema = executeProcessorBodySchema;
exports.executeProcessorResponseSchema = executeProcessorResponseSchema;
exports.listProcessorsResponseSchema = listProcessorsResponseSchema;
exports.processorConfigurationSchema = processorConfigurationSchema;
exports.processorIdPathParams = processorIdPathParams;
exports.serializedProcessorDetailSchema = serializedProcessorDetailSchema;
exports.serializedProcessorSchema = serializedProcessorSchema;
//# sourceMappingURL=chunk-WOMVBFIP.cjs.map
//# sourceMappingURL=chunk-WOMVBFIP.cjs.map