@vitalyostanin/youtrack-mcp 0.13.2 → 0.13.3
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-ru.md +1 -0
- package/README.md +1 -0
- package/dist/package.json +1 -1
- package/dist/src/tools/issue-search-tools.js +1 -1
- package/dist/src/utils/validators.d.ts +6 -3
- package/dist/src/utils/validators.js +20 -10
- package/package.json +1 -1
package/README-ru.md
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
# YouTrack MCP Server
|
|
2
2
|
|
|
3
3
|
[](https://github.com/VitalyOstanin/youtrack-mcp/actions/workflows/ci.yml)
|
|
4
|
+
[](https://codecov.io/gh/VitalyOstanin/youtrack-mcp)
|
|
4
5
|
[](https://www.npmjs.com/package/@vitalyostanin/youtrack-mcp)
|
|
5
6
|
|
|
6
7
|
MCP сервер для полноценной интеграции с YouTrack со следующими возможностями:
|
package/README.md
CHANGED
|
@@ -3,6 +3,7 @@
|
|
|
3
3
|
Also available in Russian: [README-ru.md](README-ru.md)
|
|
4
4
|
|
|
5
5
|
[](https://github.com/VitalyOstanin/youtrack-mcp/actions/workflows/ci.yml)
|
|
6
|
+
[](https://codecov.io/gh/VitalyOstanin/youtrack-mcp)
|
|
6
7
|
[](https://www.npmjs.com/package/@vitalyostanin/youtrack-mcp)
|
|
7
8
|
|
|
8
9
|
MCP server for comprehensive YouTrack integration with the following capabilities:
|
package/dist/package.json
CHANGED
|
@@ -7,7 +7,7 @@ import { createToolHandler } from "../utils/tool-handler.js";
|
|
|
7
7
|
export const issuesSearchArgs = {
|
|
8
8
|
query: yqlQuerySchema
|
|
9
9
|
.optional()
|
|
10
|
-
.describe("Search string for issues (e.g., 'login error'). If not provided or empty, all issues will be returned. You can
|
|
10
|
+
.describe("Search string for issues (e.g., 'login error'). If not provided or empty, all issues will be returned. You can use YouTrack Query Language, including {curly braces} to enclose multi-word attribute values (e.g., 'State: {In Progress}', 'tag: {Technical debt}', 'Type: Bug')."),
|
|
11
11
|
limit: z.number().int().positive().max(200).default(50).describe("Max results per page"),
|
|
12
12
|
skip: z.number().int().nonnegative().default(0).describe("Offset for pagination"),
|
|
13
13
|
projects: z.array(yqlIdentifierSchema).optional().describe("Filter by project short names (e.g., ['PROJ', 'TEST'])"),
|
|
@@ -22,9 +22,12 @@ export declare const articleIdSchema: z.ZodString;
|
|
|
22
22
|
*/
|
|
23
23
|
export declare const yqlIdentifierSchema: z.ZodString;
|
|
24
24
|
/**
|
|
25
|
-
* Free-text YQL fragment used as a search query.
|
|
26
|
-
*
|
|
27
|
-
*
|
|
25
|
+
* Free-text YQL fragment used as a search query. Allows `{` and `}` because
|
|
26
|
+
* they are valid YQL syntax for multi-word attribute values. Only ASCII
|
|
27
|
+
* control characters are rejected.
|
|
28
|
+
*
|
|
29
|
+
* Callers MUST NOT interpolate this value inside another `{...}` wrapper —
|
|
30
|
+
* use yqlIdentifierSchema for that.
|
|
28
31
|
*/
|
|
29
32
|
export declare const yqlQuerySchema: z.ZodString;
|
|
30
33
|
//# sourceMappingURL=validators.d.ts.map
|
|
@@ -44,12 +44,19 @@ export const articleIdSchema = z
|
|
|
44
44
|
.min(1)
|
|
45
45
|
.regex(internalIdRegex, "Article id must be alphanumeric with . _ -");
|
|
46
46
|
/**
|
|
47
|
-
* Reject `{`, `}` and ASCII control characters
|
|
48
|
-
*
|
|
49
|
-
* fragments, field values and identifiers.
|
|
47
|
+
* Reject `{`, `}` and ASCII control characters in values that are interpolated
|
|
48
|
+
* inside a `{...}` wrapper. Used by yqlIdentifierSchema.
|
|
50
49
|
*/
|
|
51
50
|
// eslint-disable-next-line no-control-regex
|
|
52
|
-
const
|
|
51
|
+
const YQL_IDENTIFIER_FORBIDDEN = /[{}\x00-\x1F\x7F]/;
|
|
52
|
+
/**
|
|
53
|
+
* Reject only ASCII control characters in free-text YQL queries. `{` and `}`
|
|
54
|
+
* are part of the YouTrack Query Language — they enclose attribute values
|
|
55
|
+
* that contain spaces (e.g. `tag: {Technical debt}`, `State: {In Progress}`).
|
|
56
|
+
* See: https://www.jetbrains.com/help/youtrack/server/search-and-command-attributes.html
|
|
57
|
+
*/
|
|
58
|
+
// eslint-disable-next-line no-control-regex
|
|
59
|
+
const YQL_QUERY_FORBIDDEN = /[\x00-\x1F\x7F]/;
|
|
53
60
|
/**
|
|
54
61
|
* YQL identifier value used inside `{...}` wrappers (state/type names,
|
|
55
62
|
* project short names, login-like ids). Permits spaces, hyphens, dots and
|
|
@@ -59,17 +66,20 @@ const YQL_FORBIDDEN = /[{}\x00-\x1F\x7F]/;
|
|
|
59
66
|
export const yqlIdentifierSchema = z
|
|
60
67
|
.string()
|
|
61
68
|
.min(1)
|
|
62
|
-
.refine((value) => !
|
|
69
|
+
.refine((value) => !YQL_IDENTIFIER_FORBIDDEN.test(value), {
|
|
63
70
|
message: "YQL identifier must not contain { } or control characters",
|
|
64
71
|
});
|
|
65
72
|
/**
|
|
66
|
-
* Free-text YQL fragment used as a search query.
|
|
67
|
-
*
|
|
68
|
-
*
|
|
73
|
+
* Free-text YQL fragment used as a search query. Allows `{` and `}` because
|
|
74
|
+
* they are valid YQL syntax for multi-word attribute values. Only ASCII
|
|
75
|
+
* control characters are rejected.
|
|
76
|
+
*
|
|
77
|
+
* Callers MUST NOT interpolate this value inside another `{...}` wrapper —
|
|
78
|
+
* use yqlIdentifierSchema for that.
|
|
69
79
|
*/
|
|
70
80
|
export const yqlQuerySchema = z
|
|
71
81
|
.string()
|
|
72
|
-
.refine((value) => !
|
|
73
|
-
message: "Search query must not contain
|
|
82
|
+
.refine((value) => !YQL_QUERY_FORBIDDEN.test(value), {
|
|
83
|
+
message: "Search query must not contain control characters",
|
|
74
84
|
});
|
|
75
85
|
//# sourceMappingURL=validators.js.map
|