@enconvo/dxt 0.2.6

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,97 @@
1
+ import * as z from "zod";
2
+ export const McpServerConfigSchema = z.object({
3
+ command: z.string(),
4
+ args: z.array(z.string()).optional(),
5
+ env: z.record(z.string(), z.string()).optional(),
6
+ });
7
+ export const DxtManifestAuthorSchema = z.object({
8
+ name: z.string(),
9
+ email: z.string().email().optional(),
10
+ url: z.string().url().optional(),
11
+ });
12
+ export const DxtManifestRepositorySchema = z.object({
13
+ type: z.string(),
14
+ url: z.string().url(),
15
+ });
16
+ export const DxtManifestPlatformOverrideSchema = McpServerConfigSchema.partial();
17
+ export const DxtManifestMcpConfigSchema = McpServerConfigSchema.extend({
18
+ platform_overrides: z
19
+ .record(z.string(), DxtManifestPlatformOverrideSchema)
20
+ .optional(),
21
+ });
22
+ export const DxtManifestServerSchema = z.object({
23
+ type: z.enum(["python", "node", "binary"]),
24
+ entry_point: z.string(),
25
+ mcp_config: DxtManifestMcpConfigSchema,
26
+ });
27
+ export const DxtManifestCompatibilitySchema = z
28
+ .object({
29
+ claude_desktop: z.string().optional(),
30
+ platforms: z.array(z.enum(["darwin", "win32", "linux"])).optional(),
31
+ runtimes: z
32
+ .object({
33
+ python: z.string().optional(),
34
+ node: z.string().optional(),
35
+ })
36
+ .optional(),
37
+ })
38
+ .passthrough();
39
+ export const DxtManifestToolSchema = z.object({
40
+ name: z.string(),
41
+ description: z.string().optional(),
42
+ });
43
+ export const DxtManifestPromptSchema = z.object({
44
+ name: z.string(),
45
+ description: z.string().optional(),
46
+ arguments: z.array(z.string()).optional(),
47
+ text: z.string(),
48
+ });
49
+ export const DxtUserConfigurationOptionSchema = z.object({
50
+ type: z.enum(["string", "number", "boolean", "directory", "file"]),
51
+ title: z.string(),
52
+ description: z.string(),
53
+ required: z.boolean().optional(),
54
+ default: z
55
+ .union([z.string(), z.number(), z.boolean(), z.array(z.string())])
56
+ .optional(),
57
+ multiple: z.boolean().optional(),
58
+ sensitive: z.boolean().optional(),
59
+ min: z.number().optional(),
60
+ max: z.number().optional(),
61
+ });
62
+ export const DxtUserConfigValuesSchema = z.record(z.string(), z.union([z.string(), z.number(), z.boolean(), z.array(z.string())]));
63
+ export const DxtManifestSchema = z.object({
64
+ $schema: z.string().optional(),
65
+ dxt_version: z.string(),
66
+ name: z.string(),
67
+ display_name: z.string().optional(),
68
+ version: z.string(),
69
+ description: z.string(),
70
+ long_description: z.string().optional(),
71
+ author: DxtManifestAuthorSchema,
72
+ repository: DxtManifestRepositorySchema.optional(),
73
+ homepage: z.string().url().optional(),
74
+ documentation: z.string().url().optional(),
75
+ support: z.string().url().optional(),
76
+ icon: z.string().optional(),
77
+ screenshots: z.array(z.string()).optional(),
78
+ server: DxtManifestServerSchema,
79
+ tools: z.array(DxtManifestToolSchema).optional(),
80
+ tools_generated: z.boolean().optional(),
81
+ prompts: z.array(DxtManifestPromptSchema).optional(),
82
+ prompts_generated: z.boolean().optional(),
83
+ keywords: z.array(z.string()).optional(),
84
+ license: z.string().optional(),
85
+ compatibility: DxtManifestCompatibilitySchema.optional(),
86
+ user_config: z
87
+ .record(z.string(), DxtUserConfigurationOptionSchema)
88
+ .optional(),
89
+ });
90
+ export const DxtSignatureInfoSchema = z.object({
91
+ status: z.enum(["signed", "unsigned", "self-signed"]),
92
+ publisher: z.string().optional(),
93
+ issuer: z.string().optional(),
94
+ valid_from: z.string().optional(),
95
+ valid_to: z.string().optional(),
96
+ fingerprint: z.string().optional(),
97
+ });