@firfi/huly-mcp 0.7.0 → 0.9.0
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.
- package/README.md +17 -5
- package/dist/index.cjs +25992 -25310
- package/package.json +31 -19
- package/dist/index.js +0 -116694
- package/dist/src/config/config.d.ts +0 -94
- package/dist/src/config/config.d.ts.map +0 -1
- package/dist/src/config/config.js +0 -247
- package/dist/src/config/config.js.map +0 -1
- package/dist/src/domain/schemas.d.ts +0 -256
- package/dist/src/domain/schemas.d.ts.map +0 -1
- package/dist/src/domain/schemas.js +0 -275
- package/dist/src/domain/schemas.js.map +0 -1
- package/dist/src/huly/client.d.ts +0 -63
- package/dist/src/huly/client.d.ts.map +0 -1
- package/dist/src/huly/client.js +0 -149
- package/dist/src/huly/client.js.map +0 -1
- package/dist/src/huly/errors.d.ts +0 -133
- package/dist/src/huly/errors.d.ts.map +0 -1
- package/dist/src/huly/errors.js +0 -108
- package/dist/src/huly/errors.js.map +0 -1
- package/dist/src/huly/operations/issues.d.ts +0 -122
- package/dist/src/huly/operations/issues.d.ts.map +0 -1
- package/dist/src/huly/operations/issues.js +0 -627
- package/dist/src/huly/operations/issues.js.map +0 -1
- package/dist/src/index.d.ts +0 -43
- package/dist/src/index.d.ts.map +0 -1
- package/dist/src/index.js +0 -154
- package/dist/src/index.js.map +0 -1
- package/dist/src/mcp/error-mapping.d.ts +0 -67
- package/dist/src/mcp/error-mapping.d.ts.map +0 -1
- package/dist/src/mcp/error-mapping.js +0 -195
- package/dist/src/mcp/error-mapping.js.map +0 -1
- package/dist/src/mcp/server.d.ts +0 -86
- package/dist/src/mcp/server.d.ts.map +0 -1
- package/dist/src/mcp/server.js +0 -216
- package/dist/src/mcp/server.js.map +0 -1
- package/dist/tsconfig.tsbuildinfo +0 -1
|
@@ -1,94 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Configuration module for Huly MCP server.
|
|
3
|
-
*
|
|
4
|
-
* Loads config from environment variables and optional .hulyrc.json file.
|
|
5
|
-
* Credentials (email, password) only from env vars for security.
|
|
6
|
-
* Non-sensitive config (url, workspace, timeout) can come from file.
|
|
7
|
-
* Env vars always override file config.
|
|
8
|
-
*
|
|
9
|
-
* @module
|
|
10
|
-
*/
|
|
11
|
-
import { Context, Layer, Redacted, Schema } from "effect";
|
|
12
|
-
/**
|
|
13
|
-
* Schema for optional config file content (.hulyrc.json).
|
|
14
|
-
* Only non-sensitive values allowed.
|
|
15
|
-
*/
|
|
16
|
-
export declare const FileConfigSchema: Schema.Struct<{
|
|
17
|
-
url: Schema.optional<Schema.filter<typeof Schema.String>>;
|
|
18
|
-
workspace: Schema.optional<Schema.filter<typeof Schema.String>>;
|
|
19
|
-
connectionTimeout: Schema.optional<Schema.filter<Schema.filter<typeof Schema.Number>>>;
|
|
20
|
-
}>;
|
|
21
|
-
export type FileConfig = Schema.Schema.Type<typeof FileConfigSchema>;
|
|
22
|
-
/**
|
|
23
|
-
* Full configuration schema after merging sources.
|
|
24
|
-
*/
|
|
25
|
-
export declare const HulyConfigSchema: Schema.Struct<{
|
|
26
|
-
url: Schema.filter<typeof Schema.String>;
|
|
27
|
-
email: Schema.filter<typeof Schema.String>;
|
|
28
|
-
password: Schema.Redacted<Schema.filter<typeof Schema.String>>;
|
|
29
|
-
workspace: Schema.filter<typeof Schema.String>;
|
|
30
|
-
connectionTimeout: Schema.filter<Schema.filter<typeof Schema.Number>>;
|
|
31
|
-
}>;
|
|
32
|
-
export type HulyConfig = Schema.Schema.Type<typeof HulyConfigSchema>;
|
|
33
|
-
declare const ConfigValidationError_base: Schema.TaggedErrorClass<ConfigValidationError, "ConfigValidationError", {
|
|
34
|
-
readonly _tag: Schema.tag<"ConfigValidationError">;
|
|
35
|
-
} & {
|
|
36
|
-
message: typeof Schema.String;
|
|
37
|
-
field: Schema.optional<typeof Schema.String>;
|
|
38
|
-
cause: Schema.optional<typeof Schema.Defect>;
|
|
39
|
-
}>;
|
|
40
|
-
/**
|
|
41
|
-
* Configuration validation error.
|
|
42
|
-
*/
|
|
43
|
-
export declare class ConfigValidationError extends ConfigValidationError_base {
|
|
44
|
-
}
|
|
45
|
-
declare const ConfigFileError_base: Schema.TaggedErrorClass<ConfigFileError, "ConfigFileError", {
|
|
46
|
-
readonly _tag: Schema.tag<"ConfigFileError">;
|
|
47
|
-
} & {
|
|
48
|
-
message: typeof Schema.String;
|
|
49
|
-
path: typeof Schema.String;
|
|
50
|
-
cause: Schema.optional<typeof Schema.Defect>;
|
|
51
|
-
}>;
|
|
52
|
-
/**
|
|
53
|
-
* Configuration file read error.
|
|
54
|
-
*/
|
|
55
|
-
export declare class ConfigFileError extends ConfigFileError_base {
|
|
56
|
-
}
|
|
57
|
-
export type HulyConfigError = ConfigValidationError | ConfigFileError;
|
|
58
|
-
declare const HulyConfigService_base: Context.TagClass<HulyConfigService, "@hulymcp/HulyConfig", {
|
|
59
|
-
readonly url: string;
|
|
60
|
-
readonly workspace: string;
|
|
61
|
-
readonly connectionTimeout: number;
|
|
62
|
-
readonly email: string;
|
|
63
|
-
readonly password: Redacted.Redacted<string>;
|
|
64
|
-
}>;
|
|
65
|
-
/**
|
|
66
|
-
* HulyConfig service tag.
|
|
67
|
-
*/
|
|
68
|
-
export declare class HulyConfigService extends HulyConfigService_base {
|
|
69
|
-
/**
|
|
70
|
-
* Default connection timeout (30 seconds).
|
|
71
|
-
*/
|
|
72
|
-
static readonly DEFAULT_TIMEOUT = 30000;
|
|
73
|
-
/**
|
|
74
|
-
* Config file name.
|
|
75
|
-
*/
|
|
76
|
-
static readonly CONFIG_FILE_NAME = ".hulyrc.json";
|
|
77
|
-
/**
|
|
78
|
-
* Load config from env vars, with optional file fallback.
|
|
79
|
-
* This is the production layer.
|
|
80
|
-
*/
|
|
81
|
-
static readonly layer: Layer.Layer<HulyConfigService, HulyConfigError>;
|
|
82
|
-
/**
|
|
83
|
-
* Create a test layer with explicit config values.
|
|
84
|
-
*/
|
|
85
|
-
static testLayer(config: {
|
|
86
|
-
url: string;
|
|
87
|
-
email: string;
|
|
88
|
-
password: string;
|
|
89
|
-
workspace: string;
|
|
90
|
-
connectionTimeout?: number;
|
|
91
|
-
}): Layer.Layer<HulyConfigService>;
|
|
92
|
-
}
|
|
93
|
-
export {};
|
|
94
|
-
//# sourceMappingURL=config.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../../src/config/config.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AACH,OAAO,EAAU,OAAO,EAAU,KAAK,EAAU,QAAQ,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAA;AAmCjF;;;GAGG;AACH,eAAO,MAAM,gBAAgB;;;;EAI3B,CAAA;AAEF,MAAM,MAAM,UAAU,GAAG,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,OAAO,gBAAgB,CAAC,CAAA;AAEpE;;GAEG;AACH,eAAO,MAAM,gBAAgB;;;;;;EAM3B,CAAA;AAEF,MAAM,MAAM,UAAU,GAAG,MAAM,CAAC,MAAM,CAAC,IAAI,CAAC,OAAO,gBAAgB,CAAC,CAAA;;;;;;;;AAIpE;;GAEG;AACH,qBAAa,qBAAsB,SAAQ,0BAO1C;CAAG;;;;;;;;AAEJ;;GAEG;AACH,qBAAa,eAAgB,SAAQ,oBAOpC;CAAG;AAEJ,MAAM,MAAM,eAAe,GAAG,qBAAqB,GAAG,eAAe,CAAA;;;;;;;;AAkNrE;;GAEG;AACH,qBAAa,iBAAkB,SAAQ,sBAGpC;IACD;;OAEG;IACH,MAAM,CAAC,QAAQ,CAAC,eAAe,SAAkB;IAEjD;;OAEG;IACH,MAAM,CAAC,QAAQ,CAAC,gBAAgB,kBAAmB;IAEnD;;;OAGG;IACH,MAAM,CAAC,QAAQ,CAAC,KAAK,EAAE,KAAK,CAAC,KAAK,CAAC,iBAAiB,EAAE,eAAe,CAAC,CAGrE;IAED;;OAEG;IACH,MAAM,CAAC,SAAS,CAAC,MAAM,EAAE;QACvB,GAAG,EAAE,MAAM,CAAA;QACX,KAAK,EAAE,MAAM,CAAA;QACb,QAAQ,EAAE,MAAM,CAAA;QAChB,SAAS,EAAE,MAAM,CAAA;QACjB,iBAAiB,CAAC,EAAE,MAAM,CAAA;KAC3B,GAAG,KAAK,CAAC,KAAK,CAAC,iBAAiB,CAAC;CAYnC"}
|
|
@@ -1,247 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Configuration module for Huly MCP server.
|
|
3
|
-
*
|
|
4
|
-
* Loads config from environment variables and optional .hulyrc.json file.
|
|
5
|
-
* Credentials (email, password) only from env vars for security.
|
|
6
|
-
* Non-sensitive config (url, workspace, timeout) can come from file.
|
|
7
|
-
* Env vars always override file config.
|
|
8
|
-
*
|
|
9
|
-
* @module
|
|
10
|
-
*/
|
|
11
|
-
import { Config, Context, Effect, Layer, Option, Redacted, Schema } from "effect";
|
|
12
|
-
import * as fs from "node:fs";
|
|
13
|
-
import * as path from "node:path";
|
|
14
|
-
// --- Schemas ---
|
|
15
|
-
/**
|
|
16
|
-
* Schema for URL validation - must be valid http/https URL.
|
|
17
|
-
*/
|
|
18
|
-
const UrlSchema = Schema.String.pipe(Schema.filter((s) => {
|
|
19
|
-
try {
|
|
20
|
-
const url = new URL(s);
|
|
21
|
-
return url.protocol === "http:" || url.protocol === "https:";
|
|
22
|
-
}
|
|
23
|
-
catch {
|
|
24
|
-
return false;
|
|
25
|
-
}
|
|
26
|
-
}, { message: () => "Must be a valid http or https URL" }));
|
|
27
|
-
/**
|
|
28
|
-
* Schema for non-empty string.
|
|
29
|
-
*/
|
|
30
|
-
const NonEmptyString = Schema.String.pipe(Schema.filter((s) => s.trim().length > 0, { message: () => "Must not be empty" }));
|
|
31
|
-
/**
|
|
32
|
-
* Schema for positive integer (timeout in ms).
|
|
33
|
-
*/
|
|
34
|
-
const PositiveInt = Schema.Number.pipe(Schema.int({ message: () => "Must be an integer" }), Schema.positive({ message: () => "Must be positive" }));
|
|
35
|
-
/**
|
|
36
|
-
* Schema for optional config file content (.hulyrc.json).
|
|
37
|
-
* Only non-sensitive values allowed.
|
|
38
|
-
*/
|
|
39
|
-
export const FileConfigSchema = Schema.Struct({
|
|
40
|
-
url: Schema.optional(UrlSchema),
|
|
41
|
-
workspace: Schema.optional(NonEmptyString),
|
|
42
|
-
connectionTimeout: Schema.optional(PositiveInt),
|
|
43
|
-
});
|
|
44
|
-
/**
|
|
45
|
-
* Full configuration schema after merging sources.
|
|
46
|
-
*/
|
|
47
|
-
export const HulyConfigSchema = Schema.Struct({
|
|
48
|
-
url: UrlSchema,
|
|
49
|
-
email: NonEmptyString,
|
|
50
|
-
password: Schema.Redacted(NonEmptyString),
|
|
51
|
-
workspace: NonEmptyString,
|
|
52
|
-
connectionTimeout: PositiveInt,
|
|
53
|
-
});
|
|
54
|
-
// --- Config Errors ---
|
|
55
|
-
/**
|
|
56
|
-
* Configuration validation error.
|
|
57
|
-
*/
|
|
58
|
-
export class ConfigValidationError extends Schema.TaggedError()("ConfigValidationError", {
|
|
59
|
-
message: Schema.String,
|
|
60
|
-
field: Schema.optional(Schema.String),
|
|
61
|
-
cause: Schema.optional(Schema.Defect),
|
|
62
|
-
}) {
|
|
63
|
-
}
|
|
64
|
-
/**
|
|
65
|
-
* Configuration file read error.
|
|
66
|
-
*/
|
|
67
|
-
export class ConfigFileError extends Schema.TaggedError()("ConfigFileError", {
|
|
68
|
-
message: Schema.String,
|
|
69
|
-
path: Schema.String,
|
|
70
|
-
cause: Schema.optional(Schema.Defect),
|
|
71
|
-
}) {
|
|
72
|
-
}
|
|
73
|
-
// --- Internal Functions ---
|
|
74
|
-
/**
|
|
75
|
-
* Default connection timeout (30 seconds).
|
|
76
|
-
*/
|
|
77
|
-
const DEFAULT_TIMEOUT = 30000;
|
|
78
|
-
/**
|
|
79
|
-
* Config file name.
|
|
80
|
-
*/
|
|
81
|
-
const CONFIG_FILE_NAME = ".hulyrc.json";
|
|
82
|
-
/**
|
|
83
|
-
* Load and parse config file if it exists.
|
|
84
|
-
*/
|
|
85
|
-
const loadConfigFile = (filePath) => Effect.gen(function* () {
|
|
86
|
-
const exists = yield* Effect.try({
|
|
87
|
-
try: () => fs.existsSync(filePath),
|
|
88
|
-
catch: () => new ConfigFileError({
|
|
89
|
-
message: "Failed to check config file existence",
|
|
90
|
-
path: filePath,
|
|
91
|
-
}),
|
|
92
|
-
});
|
|
93
|
-
if (!exists) {
|
|
94
|
-
return null;
|
|
95
|
-
}
|
|
96
|
-
const content = yield* Effect.try({
|
|
97
|
-
try: () => fs.readFileSync(filePath, "utf-8"),
|
|
98
|
-
catch: (e) => new ConfigFileError({
|
|
99
|
-
message: "Failed to read config file",
|
|
100
|
-
path: filePath,
|
|
101
|
-
cause: e,
|
|
102
|
-
}),
|
|
103
|
-
});
|
|
104
|
-
const parsed = yield* Effect.try({
|
|
105
|
-
try: () => JSON.parse(content),
|
|
106
|
-
catch: (e) => new ConfigFileError({
|
|
107
|
-
message: "Config file is not valid JSON",
|
|
108
|
-
path: filePath,
|
|
109
|
-
cause: e,
|
|
110
|
-
}),
|
|
111
|
-
});
|
|
112
|
-
const decoded = yield* Schema.decodeUnknown(FileConfigSchema)(parsed).pipe(Effect.mapError((e) => new ConfigFileError({
|
|
113
|
-
message: `Config file validation failed: ${e.message}`,
|
|
114
|
-
path: filePath,
|
|
115
|
-
})));
|
|
116
|
-
return decoded;
|
|
117
|
-
});
|
|
118
|
-
/**
|
|
119
|
-
* Get env var value, returning undefined if not set.
|
|
120
|
-
*/
|
|
121
|
-
const getEnvVar = (key) => Config.string(key).pipe(Config.option, Effect.map((opt) => Option.isSome(opt) ? opt.value : undefined),
|
|
122
|
-
// Ignore config errors (missing key), just return undefined
|
|
123
|
-
Effect.catchAll(() => Effect.succeed(undefined)));
|
|
124
|
-
/**
|
|
125
|
-
* Load config value from env with fallback to file config.
|
|
126
|
-
*/
|
|
127
|
-
const getConfigValue = (envKey, fileValue, defaultValue, parser) => Effect.gen(function* () {
|
|
128
|
-
const envValue = yield* getEnvVar(envKey);
|
|
129
|
-
if (envValue !== undefined) {
|
|
130
|
-
return yield* Effect.try({
|
|
131
|
-
try: () => parser(envValue),
|
|
132
|
-
catch: () => new ConfigValidationError({
|
|
133
|
-
message: `Invalid value for ${envKey}`,
|
|
134
|
-
field: envKey,
|
|
135
|
-
}),
|
|
136
|
-
});
|
|
137
|
-
}
|
|
138
|
-
if (fileValue !== undefined) {
|
|
139
|
-
return fileValue;
|
|
140
|
-
}
|
|
141
|
-
return defaultValue;
|
|
142
|
-
});
|
|
143
|
-
/**
|
|
144
|
-
* Load required config value.
|
|
145
|
-
*/
|
|
146
|
-
const getRequiredConfigValue = (envKey, fileValue, parser) => Effect.gen(function* () {
|
|
147
|
-
const value = yield* getConfigValue(envKey, fileValue, undefined, parser);
|
|
148
|
-
if (value === undefined) {
|
|
149
|
-
return yield* new ConfigValidationError({
|
|
150
|
-
message: `Missing required config: ${envKey}`,
|
|
151
|
-
field: envKey,
|
|
152
|
-
});
|
|
153
|
-
}
|
|
154
|
-
return value;
|
|
155
|
-
});
|
|
156
|
-
/**
|
|
157
|
-
* Load the full configuration.
|
|
158
|
-
*/
|
|
159
|
-
const loadConfig = () => Effect.gen(function* () {
|
|
160
|
-
// Try to load config file from current working directory
|
|
161
|
-
const configPath = path.resolve(process.cwd(), CONFIG_FILE_NAME);
|
|
162
|
-
const fileConfig = yield* loadConfigFile(configPath);
|
|
163
|
-
// Load each config value with proper fallback chain
|
|
164
|
-
const url = yield* getRequiredConfigValue("HULY_URL", fileConfig?.url, (s) => s);
|
|
165
|
-
// Credentials only from env vars (security)
|
|
166
|
-
const email = yield* getRequiredConfigValue("HULY_EMAIL", undefined, (s) => s);
|
|
167
|
-
const passwordStr = yield* getRequiredConfigValue("HULY_PASSWORD", undefined, (s) => s);
|
|
168
|
-
const workspace = yield* getRequiredConfigValue("HULY_WORKSPACE", fileConfig?.workspace, (s) => s);
|
|
169
|
-
const connectionTimeout = yield* getConfigValue("HULY_CONNECTION_TIMEOUT", fileConfig?.connectionTimeout, DEFAULT_TIMEOUT, (s) => {
|
|
170
|
-
const n = parseInt(s, 10);
|
|
171
|
-
if (isNaN(n) || n <= 0) {
|
|
172
|
-
throw new Error("Must be a positive integer");
|
|
173
|
-
}
|
|
174
|
-
return n;
|
|
175
|
-
});
|
|
176
|
-
// Validate the assembled config
|
|
177
|
-
const config = {
|
|
178
|
-
url,
|
|
179
|
-
email,
|
|
180
|
-
password: Redacted.make(passwordStr),
|
|
181
|
-
workspace,
|
|
182
|
-
connectionTimeout: connectionTimeout ?? DEFAULT_TIMEOUT,
|
|
183
|
-
};
|
|
184
|
-
// Validate URL format
|
|
185
|
-
yield* Schema.decodeUnknown(UrlSchema)(config.url).pipe(Effect.mapError(() => new ConfigValidationError({
|
|
186
|
-
message: "HULY_URL must be a valid http or https URL",
|
|
187
|
-
field: "HULY_URL",
|
|
188
|
-
})));
|
|
189
|
-
// Validate non-empty strings
|
|
190
|
-
if (config.email.trim().length === 0) {
|
|
191
|
-
return yield* new ConfigValidationError({
|
|
192
|
-
message: "HULY_EMAIL must not be empty",
|
|
193
|
-
field: "HULY_EMAIL",
|
|
194
|
-
});
|
|
195
|
-
}
|
|
196
|
-
if (Redacted.value(config.password).trim().length === 0) {
|
|
197
|
-
return yield* new ConfigValidationError({
|
|
198
|
-
message: "HULY_PASSWORD must not be empty",
|
|
199
|
-
field: "HULY_PASSWORD",
|
|
200
|
-
});
|
|
201
|
-
}
|
|
202
|
-
if (config.workspace.trim().length === 0) {
|
|
203
|
-
return yield* new ConfigValidationError({
|
|
204
|
-
message: "HULY_WORKSPACE must not be empty",
|
|
205
|
-
field: "HULY_WORKSPACE",
|
|
206
|
-
});
|
|
207
|
-
}
|
|
208
|
-
if (config.connectionTimeout <= 0) {
|
|
209
|
-
return yield* new ConfigValidationError({
|
|
210
|
-
message: "HULY_CONNECTION_TIMEOUT must be positive",
|
|
211
|
-
field: "HULY_CONNECTION_TIMEOUT",
|
|
212
|
-
});
|
|
213
|
-
}
|
|
214
|
-
return config;
|
|
215
|
-
});
|
|
216
|
-
// --- Config Service ---
|
|
217
|
-
/**
|
|
218
|
-
* HulyConfig service tag.
|
|
219
|
-
*/
|
|
220
|
-
export class HulyConfigService extends Context.Tag("@hulymcp/HulyConfig")() {
|
|
221
|
-
/**
|
|
222
|
-
* Default connection timeout (30 seconds).
|
|
223
|
-
*/
|
|
224
|
-
static DEFAULT_TIMEOUT = DEFAULT_TIMEOUT;
|
|
225
|
-
/**
|
|
226
|
-
* Config file name.
|
|
227
|
-
*/
|
|
228
|
-
static CONFIG_FILE_NAME = CONFIG_FILE_NAME;
|
|
229
|
-
/**
|
|
230
|
-
* Load config from env vars, with optional file fallback.
|
|
231
|
-
* This is the production layer.
|
|
232
|
-
*/
|
|
233
|
-
static layer = Layer.effect(HulyConfigService, loadConfig());
|
|
234
|
-
/**
|
|
235
|
-
* Create a test layer with explicit config values.
|
|
236
|
-
*/
|
|
237
|
-
static testLayer(config) {
|
|
238
|
-
return Layer.succeed(HulyConfigService, {
|
|
239
|
-
url: config.url,
|
|
240
|
-
email: config.email,
|
|
241
|
-
password: Redacted.make(config.password),
|
|
242
|
-
workspace: config.workspace,
|
|
243
|
-
connectionTimeout: config.connectionTimeout ?? DEFAULT_TIMEOUT,
|
|
244
|
-
});
|
|
245
|
-
}
|
|
246
|
-
}
|
|
247
|
-
//# sourceMappingURL=config.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"config.js","sourceRoot":"","sources":["../../../src/config/config.ts"],"names":[],"mappings":"AAAA;;;;;;;;;GASG;AACH,OAAO,EAAE,MAAM,EAAE,OAAO,EAAE,MAAM,EAAE,KAAK,EAAE,MAAM,EAAE,QAAQ,EAAE,MAAM,EAAE,MAAM,QAAQ,CAAA;AACjF,OAAO,KAAK,EAAE,MAAM,SAAS,CAAA;AAC7B,OAAO,KAAK,IAAI,MAAM,WAAW,CAAA;AAEjC,kBAAkB;AAElB;;GAEG;AACH,MAAM,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AAK,EAAE,gBAAgB;SACxB,CAAC,CAAA;IACJ,CAAC;IAED,IAAI,MAAM,CAAC,iBAAiB,IAAI,CAAC,EAAE,CAAC;QAClC,OAAO,KAAK,CAAC,CAAC,IAAI,qBAAqB,CAAC;YACtC,OAAO,EAAE,0CAA0C;YACnD,KAAK,EAAE,yBAAyB;SACjC,CAAC,CAAA;IACJ,CAAC;IAED,OAAO,MAAM,CAAA;AACf,CAAC,CAAC,CAAA;AAEJ,yBAAyB;AAEzB;;GAEG;AACH,MAAM,OAAO,iBAAkB,SAAQ,OAAO,CAAC,GAAG,CAAC,qBAAqB,CAAC,EAGtE;IACD;;OAEG;IACH,MAAM,CAAU,eAAe,GAAG,eAAe,CAAA;IAEjD;;OAEG;IACH,MAAM,CAAU,gBAAgB,GAAG,gBAAgB,CAAA;IAEnD;;;OAGG;IACH,MAAM,CAAU,KAAK,GAAoD,KAAK,CAAC,MAAM,CACnF,iBAAiB,EACjB,UAAU,EAAE,CACb,CAAA;IAED;;OAEG;IACH,MAAM,CAAC,SAAS,CAAC,MAMhB;QACC,OAAO,KAAK,CAAC,OAAO,CAClB,iBAAiB,EACjB;YACE,GAAG,EAAE,MAAM,CAAC,GAAG;YACf,KAAK,EAAE,MAAM,CAAC,KAAK;YACnB,QAAQ,EAAE,QAAQ,CAAC,IAAI,CAAC,MAAM,CAAC,QAAQ,CAAC;YACxC,SAAS,EAAE,MAAM,CAAC,SAAS;YAC3B,iBAAiB,EAAE,MAAM,CAAC,iBAAiB,IAAI,eAAe;SAC/D,CACF,CAAA;IACH,CAAC"}
|
|
@@ -1,256 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Domain type schemas for Huly MCP server.
|
|
3
|
-
*
|
|
4
|
-
* Type-safe representations of Huly domain objects (issues, projects, people)
|
|
5
|
-
* with validation. Schemas enable:
|
|
6
|
-
* - Parsing Huly API responses into typed objects
|
|
7
|
-
* - Validating MCP tool parameters
|
|
8
|
-
* - JSON Schema generation for MCP tool definitions
|
|
9
|
-
*
|
|
10
|
-
* @module
|
|
11
|
-
*/
|
|
12
|
-
import { JSONSchema, Schema } from "effect";
|
|
13
|
-
/**
|
|
14
|
-
* Issue priority values.
|
|
15
|
-
* Maps to Huly IssuePriority enum: NoPriority=0, Urgent=1, High=2, Medium=3, Low=4
|
|
16
|
-
*/
|
|
17
|
-
export declare const IssuePriorityValues: readonly ["urgent", "high", "medium", "low", "no-priority"];
|
|
18
|
-
/**
|
|
19
|
-
* Issue priority schema.
|
|
20
|
-
*/
|
|
21
|
-
export declare const IssuePrioritySchema: Schema.Literal<["urgent", "high", "medium", "low", "no-priority"]>;
|
|
22
|
-
export type IssuePriority = Schema.Schema.Type<typeof IssuePrioritySchema>;
|
|
23
|
-
/**
|
|
24
|
-
* Label schema for issue tags/labels.
|
|
25
|
-
*/
|
|
26
|
-
export declare const LabelSchema: Schema.Struct<{
|
|
27
|
-
title: Schema.filter<typeof Schema.String>;
|
|
28
|
-
color: Schema.optional<typeof Schema.Number>;
|
|
29
|
-
}>;
|
|
30
|
-
export type Label = Schema.Schema.Type<typeof LabelSchema>;
|
|
31
|
-
/**
|
|
32
|
-
* Person reference schema (assignee, reporter).
|
|
33
|
-
*/
|
|
34
|
-
export declare const PersonRefSchema: Schema.Struct<{
|
|
35
|
-
id: Schema.filter<typeof Schema.String>;
|
|
36
|
-
name: Schema.optional<typeof Schema.String>;
|
|
37
|
-
email: Schema.optional<typeof Schema.String>;
|
|
38
|
-
}>;
|
|
39
|
-
export type PersonRef = Schema.Schema.Type<typeof PersonRefSchema>;
|
|
40
|
-
/**
|
|
41
|
-
* Project summary schema for list operations.
|
|
42
|
-
*/
|
|
43
|
-
export declare const ProjectSummarySchema: Schema.Struct<{
|
|
44
|
-
identifier: Schema.filter<typeof Schema.String>;
|
|
45
|
-
name: typeof Schema.String;
|
|
46
|
-
description: Schema.optional<typeof Schema.String>;
|
|
47
|
-
}>;
|
|
48
|
-
export type ProjectSummary = Schema.Schema.Type<typeof ProjectSummarySchema>;
|
|
49
|
-
/**
|
|
50
|
-
* Full project schema with statuses.
|
|
51
|
-
*/
|
|
52
|
-
export declare const ProjectSchema: Schema.Struct<{
|
|
53
|
-
identifier: Schema.filter<typeof Schema.String>;
|
|
54
|
-
name: typeof Schema.String;
|
|
55
|
-
description: Schema.optional<typeof Schema.String>;
|
|
56
|
-
defaultStatus: Schema.optional<typeof Schema.String>;
|
|
57
|
-
statuses: Schema.optional<Schema.Array$<typeof Schema.String>>;
|
|
58
|
-
}>;
|
|
59
|
-
export type Project = Schema.Schema.Type<typeof ProjectSchema>;
|
|
60
|
-
/**
|
|
61
|
-
* Issue summary schema for list operations.
|
|
62
|
-
* Lighter weight than full Issue - used when listing multiple issues.
|
|
63
|
-
*/
|
|
64
|
-
export declare const IssueSummarySchema: Schema.Struct<{
|
|
65
|
-
identifier: Schema.filter<typeof Schema.String>;
|
|
66
|
-
title: typeof Schema.String;
|
|
67
|
-
status: typeof Schema.String;
|
|
68
|
-
priority: Schema.optional<Schema.Literal<["urgent", "high", "medium", "low", "no-priority"]>>;
|
|
69
|
-
assignee: Schema.optional<typeof Schema.String>;
|
|
70
|
-
modifiedOn: Schema.optional<Schema.filter<Schema.filter<typeof Schema.Number>>>;
|
|
71
|
-
}>;
|
|
72
|
-
export type IssueSummary = Schema.Schema.Type<typeof IssueSummarySchema>;
|
|
73
|
-
/**
|
|
74
|
-
* Full issue schema with all fields.
|
|
75
|
-
*/
|
|
76
|
-
export declare const IssueSchema: Schema.Struct<{
|
|
77
|
-
identifier: Schema.filter<typeof Schema.String>;
|
|
78
|
-
title: typeof Schema.String;
|
|
79
|
-
description: Schema.optional<typeof Schema.String>;
|
|
80
|
-
status: typeof Schema.String;
|
|
81
|
-
priority: Schema.optional<Schema.Literal<["urgent", "high", "medium", "low", "no-priority"]>>;
|
|
82
|
-
assignee: Schema.optional<typeof Schema.String>;
|
|
83
|
-
assigneeRef: Schema.optional<Schema.Struct<{
|
|
84
|
-
id: Schema.filter<typeof Schema.String>;
|
|
85
|
-
name: Schema.optional<typeof Schema.String>;
|
|
86
|
-
email: Schema.optional<typeof Schema.String>;
|
|
87
|
-
}>>;
|
|
88
|
-
labels: Schema.optional<Schema.Array$<Schema.Struct<{
|
|
89
|
-
title: Schema.filter<typeof Schema.String>;
|
|
90
|
-
color: Schema.optional<typeof Schema.Number>;
|
|
91
|
-
}>>>;
|
|
92
|
-
project: Schema.filter<typeof Schema.String>;
|
|
93
|
-
modifiedOn: Schema.optional<Schema.filter<Schema.filter<typeof Schema.Number>>>;
|
|
94
|
-
createdOn: Schema.optional<Schema.filter<Schema.filter<typeof Schema.Number>>>;
|
|
95
|
-
dueDate: Schema.optional<Schema.NullOr<Schema.filter<Schema.filter<typeof Schema.Number>>>>;
|
|
96
|
-
estimation: Schema.optional<typeof Schema.Number>;
|
|
97
|
-
}>;
|
|
98
|
-
export type Issue = Schema.Schema.Type<typeof IssueSchema>;
|
|
99
|
-
/**
|
|
100
|
-
* Parameters for list_issues tool.
|
|
101
|
-
*/
|
|
102
|
-
export declare const ListIssuesParamsSchema: Schema.Struct<{
|
|
103
|
-
project: Schema.refine<string, typeof Schema.String>;
|
|
104
|
-
status: Schema.optional<Schema.SchemaClass<string, string, never>>;
|
|
105
|
-
assignee: Schema.optional<Schema.SchemaClass<string, string, never>>;
|
|
106
|
-
limit: Schema.optional<Schema.refine<number, Schema.filter<typeof Schema.Number>>>;
|
|
107
|
-
}>;
|
|
108
|
-
export type ListIssuesParams = Schema.Schema.Type<typeof ListIssuesParamsSchema>;
|
|
109
|
-
/**
|
|
110
|
-
* Parameters for get_issue tool.
|
|
111
|
-
*/
|
|
112
|
-
export declare const GetIssueParamsSchema: Schema.Struct<{
|
|
113
|
-
project: Schema.refine<string, typeof Schema.String>;
|
|
114
|
-
identifier: Schema.refine<string, typeof Schema.String>;
|
|
115
|
-
}>;
|
|
116
|
-
export type GetIssueParams = Schema.Schema.Type<typeof GetIssueParamsSchema>;
|
|
117
|
-
/**
|
|
118
|
-
* Parameters for create_issue tool.
|
|
119
|
-
*/
|
|
120
|
-
export declare const CreateIssueParamsSchema: Schema.Struct<{
|
|
121
|
-
project: Schema.refine<string, typeof Schema.String>;
|
|
122
|
-
title: Schema.refine<string, typeof Schema.String>;
|
|
123
|
-
description: Schema.optional<Schema.SchemaClass<string, string, never>>;
|
|
124
|
-
priority: Schema.optional<Schema.Literal<["urgent", "high", "medium", "low", "no-priority"]>>;
|
|
125
|
-
assignee: Schema.optional<Schema.SchemaClass<string, string, never>>;
|
|
126
|
-
status: Schema.optional<Schema.SchemaClass<string, string, never>>;
|
|
127
|
-
}>;
|
|
128
|
-
export type CreateIssueParams = Schema.Schema.Type<typeof CreateIssueParamsSchema>;
|
|
129
|
-
/**
|
|
130
|
-
* Parameters for update_issue tool.
|
|
131
|
-
*/
|
|
132
|
-
export declare const UpdateIssueParamsSchema: Schema.Struct<{
|
|
133
|
-
project: Schema.refine<string, typeof Schema.String>;
|
|
134
|
-
identifier: Schema.refine<string, typeof Schema.String>;
|
|
135
|
-
title: Schema.optional<Schema.refine<string, typeof Schema.String>>;
|
|
136
|
-
description: Schema.optional<Schema.SchemaClass<string, string, never>>;
|
|
137
|
-
priority: Schema.optional<Schema.Literal<["urgent", "high", "medium", "low", "no-priority"]>>;
|
|
138
|
-
assignee: Schema.optional<Schema.NullOr<typeof Schema.String>>;
|
|
139
|
-
status: Schema.optional<Schema.SchemaClass<string, string, never>>;
|
|
140
|
-
}>;
|
|
141
|
-
export type UpdateIssueParams = Schema.Schema.Type<typeof UpdateIssueParamsSchema>;
|
|
142
|
-
/**
|
|
143
|
-
* Parameters for add_label tool.
|
|
144
|
-
*/
|
|
145
|
-
export declare const AddLabelParamsSchema: Schema.Struct<{
|
|
146
|
-
project: Schema.refine<string, typeof Schema.String>;
|
|
147
|
-
identifier: Schema.refine<string, typeof Schema.String>;
|
|
148
|
-
label: Schema.refine<string, typeof Schema.String>;
|
|
149
|
-
color: Schema.optional<Schema.refine<number, Schema.filter<Schema.filter<typeof Schema.Number>>>>;
|
|
150
|
-
}>;
|
|
151
|
-
export type AddLabelParams = Schema.Schema.Type<typeof AddLabelParamsSchema>;
|
|
152
|
-
/**
|
|
153
|
-
* Generate JSON Schema from an Effect Schema.
|
|
154
|
-
* Use for MCP tool parameter definitions.
|
|
155
|
-
*/
|
|
156
|
-
export declare const makeJsonSchema: <A, I, R>(schema: Schema.Schema<A, I, R>) => ReturnType<typeof JSONSchema.make>;
|
|
157
|
-
export declare const listIssuesParamsJsonSchema: JSONSchema.JsonSchema7Root;
|
|
158
|
-
export declare const getIssueParamsJsonSchema: JSONSchema.JsonSchema7Root;
|
|
159
|
-
export declare const createIssueParamsJsonSchema: JSONSchema.JsonSchema7Root;
|
|
160
|
-
export declare const updateIssueParamsJsonSchema: JSONSchema.JsonSchema7Root;
|
|
161
|
-
export declare const addLabelParamsJsonSchema: JSONSchema.JsonSchema7Root;
|
|
162
|
-
/**
|
|
163
|
-
* Parse unknown data into an Issue.
|
|
164
|
-
*/
|
|
165
|
-
export declare const parseIssue: (u: unknown, overrideOptions?: import("effect/SchemaAST").ParseOptions) => import("effect/Effect").Effect<{
|
|
166
|
-
readonly title: string;
|
|
167
|
-
readonly description?: string | undefined;
|
|
168
|
-
readonly identifier: string;
|
|
169
|
-
readonly status: string;
|
|
170
|
-
readonly priority?: "urgent" | "high" | "medium" | "low" | "no-priority" | undefined;
|
|
171
|
-
readonly assignee?: string | undefined;
|
|
172
|
-
readonly modifiedOn?: number | undefined;
|
|
173
|
-
readonly assigneeRef?: {
|
|
174
|
-
readonly email?: string | undefined;
|
|
175
|
-
readonly id: string;
|
|
176
|
-
readonly name?: string | undefined;
|
|
177
|
-
} | undefined;
|
|
178
|
-
readonly labels?: readonly {
|
|
179
|
-
readonly title: string;
|
|
180
|
-
readonly color?: number | undefined;
|
|
181
|
-
}[] | undefined;
|
|
182
|
-
readonly project: string;
|
|
183
|
-
readonly createdOn?: number | undefined;
|
|
184
|
-
readonly dueDate?: number | null | undefined;
|
|
185
|
-
readonly estimation?: number | undefined;
|
|
186
|
-
}, import("effect/ParseResult").ParseError, never>;
|
|
187
|
-
/**
|
|
188
|
-
* Parse unknown data into an IssueSummary.
|
|
189
|
-
*/
|
|
190
|
-
export declare const parseIssueSummary: (u: unknown, overrideOptions?: import("effect/SchemaAST").ParseOptions) => import("effect/Effect").Effect<{
|
|
191
|
-
readonly title: string;
|
|
192
|
-
readonly identifier: string;
|
|
193
|
-
readonly status: string;
|
|
194
|
-
readonly priority?: "urgent" | "high" | "medium" | "low" | "no-priority" | undefined;
|
|
195
|
-
readonly assignee?: string | undefined;
|
|
196
|
-
readonly modifiedOn?: number | undefined;
|
|
197
|
-
}, import("effect/ParseResult").ParseError, never>;
|
|
198
|
-
/**
|
|
199
|
-
* Parse unknown data into a Project.
|
|
200
|
-
*/
|
|
201
|
-
export declare const parseProject: (u: unknown, overrideOptions?: import("effect/SchemaAST").ParseOptions) => import("effect/Effect").Effect<{
|
|
202
|
-
readonly description?: string | undefined;
|
|
203
|
-
readonly name: string;
|
|
204
|
-
readonly identifier: string;
|
|
205
|
-
readonly defaultStatus?: string | undefined;
|
|
206
|
-
readonly statuses?: readonly string[] | undefined;
|
|
207
|
-
}, import("effect/ParseResult").ParseError, never>;
|
|
208
|
-
/**
|
|
209
|
-
* Parse unknown data into ListIssuesParams.
|
|
210
|
-
*/
|
|
211
|
-
export declare const parseListIssuesParams: (u: unknown, overrideOptions?: import("effect/SchemaAST").ParseOptions) => import("effect/Effect").Effect<{
|
|
212
|
-
readonly status?: string | undefined;
|
|
213
|
-
readonly assignee?: string | undefined;
|
|
214
|
-
readonly project: string;
|
|
215
|
-
readonly limit?: number | undefined;
|
|
216
|
-
}, import("effect/ParseResult").ParseError, never>;
|
|
217
|
-
/**
|
|
218
|
-
* Parse unknown data into GetIssueParams.
|
|
219
|
-
*/
|
|
220
|
-
export declare const parseGetIssueParams: (u: unknown, overrideOptions?: import("effect/SchemaAST").ParseOptions) => import("effect/Effect").Effect<{
|
|
221
|
-
readonly identifier: string;
|
|
222
|
-
readonly project: string;
|
|
223
|
-
}, import("effect/ParseResult").ParseError, never>;
|
|
224
|
-
/**
|
|
225
|
-
* Parse unknown data into CreateIssueParams.
|
|
226
|
-
*/
|
|
227
|
-
export declare const parseCreateIssueParams: (u: unknown, overrideOptions?: import("effect/SchemaAST").ParseOptions) => import("effect/Effect").Effect<{
|
|
228
|
-
readonly title: string;
|
|
229
|
-
readonly description?: string | undefined;
|
|
230
|
-
readonly status?: string | undefined;
|
|
231
|
-
readonly priority?: "urgent" | "high" | "medium" | "low" | "no-priority" | undefined;
|
|
232
|
-
readonly assignee?: string | undefined;
|
|
233
|
-
readonly project: string;
|
|
234
|
-
}, import("effect/ParseResult").ParseError, never>;
|
|
235
|
-
/**
|
|
236
|
-
* Parse unknown data into UpdateIssueParams.
|
|
237
|
-
*/
|
|
238
|
-
export declare const parseUpdateIssueParams: (u: unknown, overrideOptions?: import("effect/SchemaAST").ParseOptions) => import("effect/Effect").Effect<{
|
|
239
|
-
readonly title?: string | undefined;
|
|
240
|
-
readonly description?: string | undefined;
|
|
241
|
-
readonly identifier: string;
|
|
242
|
-
readonly status?: string | undefined;
|
|
243
|
-
readonly priority?: "urgent" | "high" | "medium" | "low" | "no-priority" | undefined;
|
|
244
|
-
readonly assignee?: string | null | undefined;
|
|
245
|
-
readonly project: string;
|
|
246
|
-
}, import("effect/ParseResult").ParseError, never>;
|
|
247
|
-
/**
|
|
248
|
-
* Parse unknown data into AddLabelParams.
|
|
249
|
-
*/
|
|
250
|
-
export declare const parseAddLabelParams: (u: unknown, overrideOptions?: import("effect/SchemaAST").ParseOptions) => import("effect/Effect").Effect<{
|
|
251
|
-
readonly color?: number | undefined;
|
|
252
|
-
readonly identifier: string;
|
|
253
|
-
readonly project: string;
|
|
254
|
-
readonly label: string;
|
|
255
|
-
}, import("effect/ParseResult").ParseError, never>;
|
|
256
|
-
//# sourceMappingURL=schemas.d.ts.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"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