'use strict';

var chunkZYXDUS6Q_cjs = require('./chunk-ZYXDUS6Q.cjs');
var z = require('zod');

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

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

var storedMCPClientIdPathParams = z__default.default.object({
  storedMCPClientId: z__default.default.string().describe("Unique identifier for the stored MCP client")
});
var storageOrderBySchema = z__default.default.object({
  field: z__default.default.enum(["createdAt", "updatedAt"]).optional(),
  direction: z__default.default.enum(["ASC", "DESC"]).optional()
});
var listStoredMCPClientsQuerySchema = chunkZYXDUS6Q_cjs.createPagePaginationSchema(100).extend({
  orderBy: storageOrderBySchema.optional(),
  status: z__default.default.enum(["draft", "published", "archived"]).optional().default("published").describe("Filter MCP clients by status (defaults to published)"),
  authorId: z__default.default.string().optional().describe("Filter MCP clients by author identifier"),
  metadata: z__default.default.record(z__default.default.string(), z__default.default.unknown()).optional().describe("Filter MCP clients by metadata key-value pairs")
});
var mcpServerConfigSchema = z__default.default.object({
  type: z__default.default.enum(["stdio", "http"]).describe("Transport type: stdio for local processes, http for remote servers"),
  command: z__default.default.string().optional().describe("Command to run (stdio only)"),
  args: z__default.default.array(z__default.default.string()).optional().describe("Command arguments (stdio only)"),
  env: z__default.default.record(z__default.default.string(), z__default.default.string()).optional().describe("Environment variables (stdio only)"),
  url: z__default.default.string().optional().describe("Server URL (http only)"),
  timeout: z__default.default.number().optional().describe("Connection timeout in milliseconds")
});
var snapshotConfigSchema = z__default.default.object({
  name: z__default.default.string().describe("Name of the MCP client"),
  description: z__default.default.string().optional().describe("Description of the MCP client"),
  servers: z__default.default.record(z__default.default.string(), mcpServerConfigSchema).describe("Map of server name to server configuration")
});
var createStoredMCPClientBodySchema = z__default.default.object({
  id: z__default.default.string().optional().describe("Unique identifier. If not provided, derived from name."),
  authorId: z__default.default.string().optional().describe("Author identifier for multi-tenant filtering"),
  metadata: z__default.default.record(z__default.default.string(), z__default.default.unknown()).optional().describe("Additional metadata for the MCP client")
}).merge(snapshotConfigSchema);
var updateStoredMCPClientBodySchema = z__default.default.object({
  authorId: z__default.default.string().optional(),
  metadata: z__default.default.record(z__default.default.string(), z__default.default.unknown()).optional()
}).partial().merge(snapshotConfigSchema.partial());
var storedMCPClientSchema = z__default.default.object({
  id: z__default.default.string(),
  status: z__default.default.string().describe("MCP client status: draft, published, or archived"),
  activeVersionId: z__default.default.string().optional(),
  authorId: z__default.default.string().optional(),
  metadata: z__default.default.record(z__default.default.string(), z__default.default.unknown()).optional(),
  createdAt: z__default.default.coerce.date(),
  updatedAt: z__default.default.coerce.date(),
  name: z__default.default.string().describe("Name of the MCP client"),
  description: z__default.default.string().optional().describe("Description of the MCP client"),
  servers: z__default.default.record(z__default.default.string(), mcpServerConfigSchema).describe("Map of server name to server configuration")
});
var listStoredMCPClientsResponseSchema = chunkZYXDUS6Q_cjs.paginationInfoSchema.extend({
  mcpClients: z__default.default.array(storedMCPClientSchema)
});
var getStoredMCPClientResponseSchema = storedMCPClientSchema;
var createStoredMCPClientResponseSchema = storedMCPClientSchema;
var updateStoredMCPClientResponseSchema = z__default.default.union([
  z__default.default.object({
    id: z__default.default.string(),
    status: z__default.default.string(),
    activeVersionId: z__default.default.string().optional(),
    authorId: z__default.default.string().optional(),
    metadata: z__default.default.record(z__default.default.string(), z__default.default.unknown()).optional(),
    createdAt: z__default.default.coerce.date(),
    updatedAt: z__default.default.coerce.date()
  }),
  storedMCPClientSchema
]);
var deleteStoredMCPClientResponseSchema = z__default.default.object({
  success: z__default.default.boolean(),
  message: z__default.default.string()
});

exports.createStoredMCPClientBodySchema = createStoredMCPClientBodySchema;
exports.createStoredMCPClientResponseSchema = createStoredMCPClientResponseSchema;
exports.deleteStoredMCPClientResponseSchema = deleteStoredMCPClientResponseSchema;
exports.getStoredMCPClientResponseSchema = getStoredMCPClientResponseSchema;
exports.listStoredMCPClientsQuerySchema = listStoredMCPClientsQuerySchema;
exports.listStoredMCPClientsResponseSchema = listStoredMCPClientsResponseSchema;
exports.storedMCPClientIdPathParams = storedMCPClientIdPathParams;
exports.storedMCPClientSchema = storedMCPClientSchema;
exports.updateStoredMCPClientBodySchema = updateStoredMCPClientBodySchema;
exports.updateStoredMCPClientResponseSchema = updateStoredMCPClientResponseSchema;
//# sourceMappingURL=chunk-ULL6VJ5E.cjs.map
//# sourceMappingURL=chunk-ULL6VJ5E.cjs.map