@better-i18n/mcp 0.2.0 → 0.4.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/dist/tools/createKeys.d.ts +1 -1
- package/dist/tools/createKeys.js +19 -19
- package/dist/tools/createKeys.js.map +1 -1
- package/dist/tools/listKeys.d.ts +7 -0
- package/dist/tools/listKeys.d.ts.map +1 -1
- package/dist/tools/listKeys.js +50 -2
- package/dist/tools/listKeys.js.map +1 -1
- package/dist/tools/updateKeys.d.ts +2 -2
- package/dist/tools/updateKeys.js +26 -26
- package/dist/tools/updateKeys.js.map +1 -1
- package/package.json +1 -1
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
* createKeys MCP Tool
|
|
3
3
|
*
|
|
4
4
|
* Creates one or more translation keys with source text and optional translations.
|
|
5
|
-
*
|
|
5
|
+
* Readable input schema mapped to compact API payload (k=[{n, ns, v, t}]).
|
|
6
6
|
*/
|
|
7
7
|
import type { Tool } from "../types/index.js";
|
|
8
8
|
export declare const createKeys: Tool;
|
package/dist/tools/createKeys.js
CHANGED
|
@@ -2,52 +2,52 @@
|
|
|
2
2
|
* createKeys MCP Tool
|
|
3
3
|
*
|
|
4
4
|
* Creates one or more translation keys with source text and optional translations.
|
|
5
|
-
*
|
|
5
|
+
* Readable input schema mapped to compact API payload (k=[{n, ns, v, t}]).
|
|
6
6
|
*/
|
|
7
7
|
import { z } from "zod";
|
|
8
8
|
import { executeTool, projectInputProperty, projectSchema, success, } from "../base-tool.js";
|
|
9
9
|
const inputSchema = projectSchema.extend({
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
10
|
+
keys: z.array(z.object({
|
|
11
|
+
name: z.string(),
|
|
12
|
+
namespace: z.string().optional(),
|
|
13
|
+
sourceText: z.string().optional(),
|
|
14
|
+
translations: z.record(z.string(), z.string()).optional(),
|
|
15
15
|
})),
|
|
16
16
|
});
|
|
17
17
|
export const createKeys = {
|
|
18
18
|
definition: {
|
|
19
19
|
name: "createKeys",
|
|
20
|
-
description: "Create translation keys
|
|
20
|
+
description: "Create translation keys with source text and optional translations. Don't include the source language in translations — use sourceText instead.",
|
|
21
21
|
inputSchema: {
|
|
22
22
|
type: "object",
|
|
23
23
|
properties: {
|
|
24
24
|
...projectInputProperty,
|
|
25
|
-
|
|
25
|
+
keys: {
|
|
26
26
|
type: "array",
|
|
27
27
|
items: {
|
|
28
28
|
type: "object",
|
|
29
29
|
properties: {
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
30
|
+
name: { type: "string", description: "Key name (e.g., 'submit_button', 'nav.home')" },
|
|
31
|
+
namespace: { type: "string", description: "Namespace (default: 'default')" },
|
|
32
|
+
sourceText: { type: "string", description: "Source language text" },
|
|
33
|
+
translations: { type: "object", description: "Target translations as {langCode: text}" },
|
|
34
34
|
},
|
|
35
|
-
required: ["
|
|
35
|
+
required: ["name"],
|
|
36
36
|
},
|
|
37
37
|
},
|
|
38
38
|
},
|
|
39
|
-
required: ["project", "
|
|
39
|
+
required: ["project", "keys"],
|
|
40
40
|
},
|
|
41
41
|
},
|
|
42
42
|
execute: (client, args) => executeTool(args, inputSchema, async (input, { workspaceId, projectSlug }) => {
|
|
43
43
|
const result = await client.mcp.createKeys.mutate({
|
|
44
44
|
orgSlug: workspaceId,
|
|
45
45
|
projectSlug,
|
|
46
|
-
k: input.
|
|
47
|
-
n: item.
|
|
48
|
-
ns: item.
|
|
49
|
-
v: item.
|
|
50
|
-
t: item.
|
|
46
|
+
k: input.keys.map((item) => ({
|
|
47
|
+
n: item.name,
|
|
48
|
+
ns: item.namespace || "default",
|
|
49
|
+
v: item.sourceText,
|
|
50
|
+
t: item.translations,
|
|
51
51
|
})),
|
|
52
52
|
});
|
|
53
53
|
return success({
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"createKeys.js","sourceRoot":"","sources":["../../src/tools/createKeys.ts"],"names":[],"mappings":"AAAA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lists ALL translation keys with source text and translations.
|
|
5
|
+
* Supports full-text search in source and target languages.
|
|
6
|
+
*
|
|
7
|
+
* EXAMPLES:
|
|
8
|
+
* - Find "login" in source: { search: "login" }
|
|
9
|
+
* - Find "Giriş" in Turkish: { search: "Giriş", languages: ["tr"] }
|
|
10
|
+
* - Get Turkish translations: { languages: ["tr"] }
|
|
11
|
+
* - Get specific keys: { keys: ["auth.login.title", "auth.login.button"] }
|
|
5
12
|
*/
|
|
6
13
|
import type { Tool } from "../types/index.js";
|
|
7
14
|
export declare const listKeys: Tool;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"listKeys.d.ts","sourceRoot":"","sources":["../../src/tools/listKeys.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"listKeys.d.ts","sourceRoot":"","sources":["../../src/tools/listKeys.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AASH,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,mBAAmB,CAAC;AAU9C,eAAO,MAAM,QAAQ,EAAE,IAyEtB,CAAC"}
|
package/dist/tools/listKeys.js
CHANGED
|
@@ -2,25 +2,70 @@
|
|
|
2
2
|
* listKeys MCP Tool
|
|
3
3
|
*
|
|
4
4
|
* Lists ALL translation keys with source text and translations.
|
|
5
|
+
* Supports full-text search in source and target languages.
|
|
6
|
+
*
|
|
7
|
+
* EXAMPLES:
|
|
8
|
+
* - Find "login" in source: { search: "login" }
|
|
9
|
+
* - Find "Giriş" in Turkish: { search: "Giriş", languages: ["tr"] }
|
|
10
|
+
* - Get Turkish translations: { languages: ["tr"] }
|
|
11
|
+
* - Get specific keys: { keys: ["auth.login.title", "auth.login.button"] }
|
|
5
12
|
*/
|
|
6
13
|
import { z } from "zod";
|
|
7
14
|
import { executeTool, projectInputProperty, projectSchema, success, } from "../base-tool.js";
|
|
8
15
|
const inputSchema = projectSchema.extend({
|
|
9
16
|
search: z.string().optional(),
|
|
17
|
+
languages: z.array(z.string()).optional(),
|
|
10
18
|
namespaces: z.array(z.string()).optional(),
|
|
19
|
+
keys: z.array(z.string()).optional(),
|
|
20
|
+
status: z.enum(["missing", "draft", "approved", "all"]).optional(),
|
|
11
21
|
});
|
|
12
22
|
export const listKeys = {
|
|
13
23
|
definition: {
|
|
14
24
|
name: "listKeys",
|
|
15
|
-
description:
|
|
25
|
+
description: `Get all translation keys with their id, source text, and translations.
|
|
26
|
+
|
|
27
|
+
SEARCH + FILTER:
|
|
28
|
+
- search: Text to search for (in source text or specified languages)
|
|
29
|
+
- languages: Languages to search in AND return translations for
|
|
30
|
+
|
|
31
|
+
FILTER OPTIONS:
|
|
32
|
+
- namespaces: Filter by namespace(s)
|
|
33
|
+
- keys: Fetch specific keys by exact name
|
|
34
|
+
- status: Filter by translation status ("missing", "draft", "approved", "all")
|
|
35
|
+
|
|
36
|
+
EXAMPLES:
|
|
37
|
+
- Find "login" in source: { search: "login" }
|
|
38
|
+
- Find "Giriş" in Turkish: { search: "Giriş", languages: ["tr"] }
|
|
39
|
+
- Get all Turkish translations: { languages: ["tr"] }
|
|
40
|
+
- Get missing Turkish translations: { languages: ["tr"], status: "missing" }
|
|
41
|
+
- Get specific keys: { keys: ["auth.login.title", "auth.login.button"] }`,
|
|
16
42
|
inputSchema: {
|
|
17
43
|
type: "object",
|
|
18
44
|
properties: {
|
|
19
45
|
...projectInputProperty,
|
|
20
|
-
search: {
|
|
46
|
+
search: {
|
|
47
|
+
type: "string",
|
|
48
|
+
description: "Text to search for in source text or translations (case-insensitive). If languages is specified, searches in those languages; otherwise searches source text.",
|
|
49
|
+
},
|
|
50
|
+
languages: {
|
|
51
|
+
type: "array",
|
|
52
|
+
items: { type: "string" },
|
|
53
|
+
description: "Language codes to search in and return (e.g., ['tr', 'de']). If omitted with search, searches source text. If omitted without search, returns all languages.",
|
|
54
|
+
},
|
|
21
55
|
namespaces: {
|
|
22
56
|
type: "array",
|
|
23
57
|
items: { type: "string" },
|
|
58
|
+
description: "Filter by namespace(s)",
|
|
59
|
+
},
|
|
60
|
+
keys: {
|
|
61
|
+
type: "array",
|
|
62
|
+
items: { type: "string" },
|
|
63
|
+
description: "Fetch specific keys by exact name",
|
|
64
|
+
},
|
|
65
|
+
status: {
|
|
66
|
+
type: "string",
|
|
67
|
+
enum: ["missing", "draft", "approved", "all"],
|
|
68
|
+
description: "Filter by translation status (default: all). Requires languages to be specified for filtering.",
|
|
24
69
|
},
|
|
25
70
|
},
|
|
26
71
|
required: ["project"],
|
|
@@ -31,7 +76,10 @@ export const listKeys = {
|
|
|
31
76
|
orgSlug: workspaceId,
|
|
32
77
|
projectSlug,
|
|
33
78
|
search: input.search,
|
|
79
|
+
languages: input.languages,
|
|
34
80
|
namespaces: input.namespaces,
|
|
81
|
+
keys: input.keys,
|
|
82
|
+
status: input.status,
|
|
35
83
|
});
|
|
36
84
|
return success(result);
|
|
37
85
|
}),
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"listKeys.js","sourceRoot":"","sources":["../../src/tools/listKeys.ts"],"names":[],"mappings":"AAAA
|
|
1
|
+
{"version":3,"file":"listKeys.js","sourceRoot":"","sources":["../../src/tools/listKeys.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;GAWG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EACL,WAAW,EACX,oBAAoB,EACpB,aAAa,EACb,OAAO,GACR,MAAM,iBAAiB,CAAC;AAGzB,MAAM,WAAW,GAAG,aAAa,CAAC,MAAM,CAAC;IACvC,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;IAC7B,SAAS,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,QAAQ,EAAE;IACzC,UAAU,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC,CAAC,MAAM,EAAE,CAAC,CAAC,QAAQ,EAAE;IAC1C,IAAI,EAAE,CAAC,CAAC,KAAK,CAAC,CAAC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AAM,MAAM,CAAC,GAAG,CAAC,kBAAkB,CAAC,KAAK,CAAC;YACvD,OAAO,EAAE,WAAW;YACpB,WAAW;YACX,MAAM,EAAE,KAAK,CAAC,MAAM;YACpB,SAAS,EAAE,KAAK,CAAC,SAAS;YAC1B,UAAU,EAAE,KAAK,CAAC,UAAU;YAC5B,IAAI,EAAE,KAAK,CAAC,IAAI;YAChB,MAAM,EAAE,KAAK,CAAC,MAAM;SACrB,CAAC,CAAC;QACH,OAAO,OAAO,CAAC,MAAM,CAAC,CAAC;IACzB,CAAC,CACF;CACJ,CAAC"}
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
* updateKeys MCP Tool
|
|
3
3
|
*
|
|
4
4
|
* Updates source text and/or target translations for one or more keys.
|
|
5
|
-
*
|
|
6
|
-
* Each entry = one language update for one key.
|
|
5
|
+
* Readable input schema mapped to compact API payload (t=[{k, ns, l, t, s, st}]).
|
|
6
|
+
* Each entry = one language update for one key. isSource=true for source text.
|
|
7
7
|
*/
|
|
8
8
|
import type { Tool } from "../types/index.js";
|
|
9
9
|
export declare const updateKeys: Tool;
|
package/dist/tools/updateKeys.js
CHANGED
|
@@ -2,59 +2,59 @@
|
|
|
2
2
|
* updateKeys MCP Tool
|
|
3
3
|
*
|
|
4
4
|
* Updates source text and/or target translations for one or more keys.
|
|
5
|
-
*
|
|
6
|
-
* Each entry = one language update for one key.
|
|
5
|
+
* Readable input schema mapped to compact API payload (t=[{k, ns, l, t, s, st}]).
|
|
6
|
+
* Each entry = one language update for one key. isSource=true for source text.
|
|
7
7
|
*/
|
|
8
8
|
import { z } from "zod";
|
|
9
9
|
import { executeTool, projectInputProperty, projectSchema, success, } from "../base-tool.js";
|
|
10
10
|
const inputSchema = projectSchema.extend({
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
11
|
+
translations: z.array(z.object({
|
|
12
|
+
key: z.string(),
|
|
13
|
+
namespace: z.string().optional(),
|
|
14
|
+
language: z.string(),
|
|
15
|
+
text: z.string(),
|
|
16
|
+
isSource: z.boolean().optional(),
|
|
17
|
+
status: z.string().optional(),
|
|
18
18
|
})),
|
|
19
19
|
});
|
|
20
20
|
export const updateKeys = {
|
|
21
21
|
definition: {
|
|
22
22
|
name: "updateKeys",
|
|
23
|
-
description: "Update translations. Each entry
|
|
23
|
+
description: "Update translations. Each entry updates ONE language for ONE key. Set isSource=true to update the source text.",
|
|
24
24
|
inputSchema: {
|
|
25
25
|
type: "object",
|
|
26
26
|
properties: {
|
|
27
27
|
...projectInputProperty,
|
|
28
|
-
|
|
28
|
+
translations: {
|
|
29
29
|
type: "array",
|
|
30
30
|
items: {
|
|
31
31
|
type: "object",
|
|
32
32
|
properties: {
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
|
|
36
|
-
|
|
37
|
-
|
|
38
|
-
|
|
33
|
+
key: { type: "string", description: "Key name (e.g., 'submit_button')" },
|
|
34
|
+
namespace: { type: "string", description: "Namespace (default: 'default')" },
|
|
35
|
+
language: { type: "string", description: "Language code (e.g., 'en', 'tr', 'de')" },
|
|
36
|
+
text: { type: "string", description: "Translation text" },
|
|
37
|
+
isSource: { type: "boolean", description: "true if updating source language text" },
|
|
38
|
+
status: { type: "string", description: "Translation status (e.g., 'approved')" },
|
|
39
39
|
},
|
|
40
|
-
required: ["
|
|
40
|
+
required: ["key", "language", "text"],
|
|
41
41
|
},
|
|
42
42
|
},
|
|
43
43
|
},
|
|
44
|
-
required: ["project", "
|
|
44
|
+
required: ["project", "translations"],
|
|
45
45
|
},
|
|
46
46
|
},
|
|
47
47
|
execute: (client, args) => executeTool(args, inputSchema, async (input, { workspaceId, projectSlug }) => {
|
|
48
48
|
const result = await client.mcp.updateKeys.mutate({
|
|
49
49
|
orgSlug: workspaceId,
|
|
50
50
|
projectSlug,
|
|
51
|
-
t: input.
|
|
52
|
-
k: item.
|
|
53
|
-
ns: item.
|
|
54
|
-
l: item.
|
|
55
|
-
t: item.
|
|
56
|
-
s: item.
|
|
57
|
-
st: item.
|
|
51
|
+
t: input.translations.map((item) => ({
|
|
52
|
+
k: item.key,
|
|
53
|
+
ns: item.namespace || "default",
|
|
54
|
+
l: item.language,
|
|
55
|
+
t: item.text,
|
|
56
|
+
s: item.isSource,
|
|
57
|
+
st: item.status,
|
|
58
58
|
})),
|
|
59
59
|
});
|
|
60
60
|
return success({
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"updateKeys.js","sourceRoot":"","sources":["../../src/tools/updateKeys.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EACL,WAAW,EACX,oBAAoB,EACpB,aAAa,EACb,OAAO,GACR,MAAM,iBAAiB,CAAC;AAGzB,MAAM,WAAW,GAAG,aAAa,CAAC,MAAM,CAAC;IACvC,
|
|
1
|
+
{"version":3,"file":"updateKeys.js","sourceRoot":"","sources":["../../src/tools/updateKeys.ts"],"names":[],"mappings":"AAAA;;;;;;GAMG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EACL,WAAW,EACX,oBAAoB,EACpB,aAAa,EACb,OAAO,GACR,MAAM,iBAAiB,CAAC;AAGzB,MAAM,WAAW,GAAG,aAAa,CAAC,MAAM,CAAC;IACvC,YAAY,EAAE,CAAC,CAAC,KAAK,CACnB,CAAC,CAAC,MAAM,CAAC;QACP,GAAG,EAAE,CAAC,CAAC,MAAM,EAAE;QACf,SAAS,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;QAChC,QAAQ,EAAE,CAAC,CAAC,MAAM,EAAE;QACpB,IAAI,EAAE,CAAC,CAAC,MAAM,EAAE;QAChB,QAAQ,EAAE,CAAC,CAAC,OAAO,EAAE,CAAC,QAAQ,EAAE;QAChC,MAAM,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE;KAC9B,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