@tigerdata/mcp-boilerplate 1.2.0 → 1.3.1

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.
@@ -17,6 +17,10 @@ export const createViewSkillToolFactory = (options = {}) => async (ctx, mcpFlags
17
17
  : ''}`,
18
18
  inputSchema: zViewSkillInputSchema,
19
19
  outputSchema: zViewSkillOutputSchema,
20
+ annotations: {
21
+ readOnlyHint: true,
22
+ idempotentHint: true,
23
+ },
20
24
  },
21
25
  fn: async ({ skill_name: name, path, }) => {
22
26
  if (!name || name === '.') {
@@ -1,32 +1,23 @@
1
1
  import type { Octokit } from '@octokit/rest';
2
2
  import { z } from 'zod';
3
3
  import type { InferSchema } from '../types.js';
4
- export declare const zSkillType: z.ZodEnum<["local", "local_collection", "github", "github_collection"]>;
4
+ export declare const zSkillType: z.ZodEnum<{
5
+ local: "local";
6
+ local_collection: "local_collection";
7
+ github: "github";
8
+ github_collection: "github_collection";
9
+ }>;
5
10
  export type SkillType = z.infer<typeof zSkillType>;
6
11
  export declare const zLocalSkillCfg: z.ZodObject<{
7
12
  type: z.ZodLiteral<"local">;
8
13
  path: z.ZodString;
9
- }, "strip", z.ZodTypeAny, {
10
- type: "local";
11
- path: string;
12
- }, {
13
- type: "local";
14
- path: string;
15
- }>;
14
+ }, z.core.$strip>;
16
15
  export type LocalSkillCfg = z.infer<typeof zLocalSkillCfg>;
17
16
  declare const zCollectionFlagsCfg: z.ZodObject<{
18
- enabled_skills: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
19
- disabled_skills: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
20
- ignored_paths: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
21
- }, "strip", z.ZodTypeAny, {
22
- enabled_skills?: string[] | undefined;
23
- disabled_skills?: string[] | undefined;
24
- ignored_paths?: string[] | undefined;
25
- }, {
26
- enabled_skills?: string[] | undefined;
27
- disabled_skills?: string[] | undefined;
28
- ignored_paths?: string[] | undefined;
29
- }>;
17
+ enabled_skills: z.ZodOptional<z.ZodArray<z.ZodString>>;
18
+ disabled_skills: z.ZodOptional<z.ZodArray<z.ZodString>>;
19
+ ignored_paths: z.ZodOptional<z.ZodArray<z.ZodString>>;
20
+ }, z.core.$strip>;
30
21
  export type CollectionFlagsCfg = z.infer<typeof zCollectionFlagsCfg>;
31
22
  export interface CollectionFlags {
32
23
  enabledSkills: Set<string> | null;
@@ -34,315 +25,117 @@ export interface CollectionFlags {
34
25
  ignoredPaths: Set<string> | null;
35
26
  }
36
27
  export declare const zLocalCollectionSkillCfg: z.ZodObject<{
37
- enabled_skills: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
38
- disabled_skills: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
39
- ignored_paths: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
40
- } & {
28
+ enabled_skills: z.ZodOptional<z.ZodArray<z.ZodString>>;
29
+ disabled_skills: z.ZodOptional<z.ZodArray<z.ZodString>>;
30
+ ignored_paths: z.ZodOptional<z.ZodArray<z.ZodString>>;
41
31
  type: z.ZodLiteral<"local_collection">;
42
32
  path: z.ZodString;
43
- }, "strip", z.ZodTypeAny, {
44
- type: "local_collection";
45
- path: string;
46
- enabled_skills?: string[] | undefined;
47
- disabled_skills?: string[] | undefined;
48
- ignored_paths?: string[] | undefined;
49
- }, {
50
- type: "local_collection";
51
- path: string;
52
- enabled_skills?: string[] | undefined;
53
- disabled_skills?: string[] | undefined;
54
- ignored_paths?: string[] | undefined;
55
- }>;
33
+ }, z.core.$strip>;
56
34
  export type LocalCollectionSkillCfg = z.infer<typeof zLocalCollectionSkillCfg>;
57
35
  export declare const zGitHubSkillCfg: z.ZodObject<{
58
36
  type: z.ZodLiteral<"github">;
59
37
  repo: z.ZodString;
60
38
  path: z.ZodOptional<z.ZodString>;
61
- }, "strip", z.ZodTypeAny, {
62
- type: "github";
63
- repo: string;
64
- path?: string | undefined;
65
- }, {
66
- type: "github";
67
- repo: string;
68
- path?: string | undefined;
69
- }>;
39
+ }, z.core.$strip>;
70
40
  export type GitHubSkillCfg = z.infer<typeof zGitHubSkillCfg>;
71
41
  export declare const zGitHubCollectionSkillCfg: z.ZodObject<{
72
- enabled_skills: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
73
- disabled_skills: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
74
- ignored_paths: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
75
- } & {
42
+ enabled_skills: z.ZodOptional<z.ZodArray<z.ZodString>>;
43
+ disabled_skills: z.ZodOptional<z.ZodArray<z.ZodString>>;
44
+ ignored_paths: z.ZodOptional<z.ZodArray<z.ZodString>>;
76
45
  type: z.ZodLiteral<"github_collection">;
77
46
  repo: z.ZodString;
78
47
  path: z.ZodOptional<z.ZodString>;
79
- }, "strip", z.ZodTypeAny, {
80
- type: "github_collection";
81
- repo: string;
82
- path?: string | undefined;
83
- enabled_skills?: string[] | undefined;
84
- disabled_skills?: string[] | undefined;
85
- ignored_paths?: string[] | undefined;
86
- }, {
87
- type: "github_collection";
88
- repo: string;
89
- path?: string | undefined;
90
- enabled_skills?: string[] | undefined;
91
- disabled_skills?: string[] | undefined;
92
- ignored_paths?: string[] | undefined;
93
- }>;
48
+ }, z.core.$strip>;
94
49
  export type GitHubCollectionSkillCfg = z.infer<typeof zGitHubCollectionSkillCfg>;
95
- export declare const zSkillCfg: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
50
+ export declare const zSkillCfg: z.ZodDiscriminatedUnion<[z.ZodObject<{
96
51
  type: z.ZodLiteral<"local">;
97
52
  path: z.ZodString;
98
- }, "strip", z.ZodTypeAny, {
99
- type: "local";
100
- path: string;
101
- }, {
102
- type: "local";
103
- path: string;
104
- }>, z.ZodObject<{
105
- enabled_skills: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
106
- disabled_skills: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
107
- ignored_paths: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
108
- } & {
53
+ }, z.core.$strip>, z.ZodObject<{
54
+ enabled_skills: z.ZodOptional<z.ZodArray<z.ZodString>>;
55
+ disabled_skills: z.ZodOptional<z.ZodArray<z.ZodString>>;
56
+ ignored_paths: z.ZodOptional<z.ZodArray<z.ZodString>>;
109
57
  type: z.ZodLiteral<"local_collection">;
110
58
  path: z.ZodString;
111
- }, "strip", z.ZodTypeAny, {
112
- type: "local_collection";
113
- path: string;
114
- enabled_skills?: string[] | undefined;
115
- disabled_skills?: string[] | undefined;
116
- ignored_paths?: string[] | undefined;
117
- }, {
118
- type: "local_collection";
119
- path: string;
120
- enabled_skills?: string[] | undefined;
121
- disabled_skills?: string[] | undefined;
122
- ignored_paths?: string[] | undefined;
123
- }>, z.ZodObject<{
59
+ }, z.core.$strip>, z.ZodObject<{
124
60
  type: z.ZodLiteral<"github">;
125
61
  repo: z.ZodString;
126
62
  path: z.ZodOptional<z.ZodString>;
127
- }, "strip", z.ZodTypeAny, {
128
- type: "github";
129
- repo: string;
130
- path?: string | undefined;
131
- }, {
132
- type: "github";
133
- repo: string;
134
- path?: string | undefined;
135
- }>, z.ZodObject<{
136
- enabled_skills: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
137
- disabled_skills: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
138
- ignored_paths: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
139
- } & {
63
+ }, z.core.$strip>, z.ZodObject<{
64
+ enabled_skills: z.ZodOptional<z.ZodArray<z.ZodString>>;
65
+ disabled_skills: z.ZodOptional<z.ZodArray<z.ZodString>>;
66
+ ignored_paths: z.ZodOptional<z.ZodArray<z.ZodString>>;
140
67
  type: z.ZodLiteral<"github_collection">;
141
68
  repo: z.ZodString;
142
69
  path: z.ZodOptional<z.ZodString>;
143
- }, "strip", z.ZodTypeAny, {
144
- type: "github_collection";
145
- repo: string;
146
- path?: string | undefined;
147
- enabled_skills?: string[] | undefined;
148
- disabled_skills?: string[] | undefined;
149
- ignored_paths?: string[] | undefined;
150
- }, {
151
- type: "github_collection";
152
- repo: string;
153
- path?: string | undefined;
154
- enabled_skills?: string[] | undefined;
155
- disabled_skills?: string[] | undefined;
156
- ignored_paths?: string[] | undefined;
157
- }>]>;
70
+ }, z.core.$strip>], "type">;
158
71
  export type SkillCfg = z.infer<typeof zSkillCfg>;
159
- export declare const zSkillCfgMap: z.ZodRecord<z.ZodString, z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
72
+ export declare const zSkillCfgMap: z.ZodRecord<z.ZodString, z.ZodDiscriminatedUnion<[z.ZodObject<{
160
73
  type: z.ZodLiteral<"local">;
161
74
  path: z.ZodString;
162
- }, "strip", z.ZodTypeAny, {
163
- type: "local";
164
- path: string;
165
- }, {
166
- type: "local";
167
- path: string;
168
- }>, z.ZodObject<{
169
- enabled_skills: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
170
- disabled_skills: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
171
- ignored_paths: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
172
- } & {
75
+ }, z.core.$strip>, z.ZodObject<{
76
+ enabled_skills: z.ZodOptional<z.ZodArray<z.ZodString>>;
77
+ disabled_skills: z.ZodOptional<z.ZodArray<z.ZodString>>;
78
+ ignored_paths: z.ZodOptional<z.ZodArray<z.ZodString>>;
173
79
  type: z.ZodLiteral<"local_collection">;
174
80
  path: z.ZodString;
175
- }, "strip", z.ZodTypeAny, {
176
- type: "local_collection";
177
- path: string;
178
- enabled_skills?: string[] | undefined;
179
- disabled_skills?: string[] | undefined;
180
- ignored_paths?: string[] | undefined;
181
- }, {
182
- type: "local_collection";
183
- path: string;
184
- enabled_skills?: string[] | undefined;
185
- disabled_skills?: string[] | undefined;
186
- ignored_paths?: string[] | undefined;
187
- }>, z.ZodObject<{
81
+ }, z.core.$strip>, z.ZodObject<{
188
82
  type: z.ZodLiteral<"github">;
189
83
  repo: z.ZodString;
190
84
  path: z.ZodOptional<z.ZodString>;
191
- }, "strip", z.ZodTypeAny, {
192
- type: "github";
193
- repo: string;
194
- path?: string | undefined;
195
- }, {
196
- type: "github";
197
- repo: string;
198
- path?: string | undefined;
199
- }>, z.ZodObject<{
200
- enabled_skills: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
201
- disabled_skills: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
202
- ignored_paths: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
203
- } & {
85
+ }, z.core.$strip>, z.ZodObject<{
86
+ enabled_skills: z.ZodOptional<z.ZodArray<z.ZodString>>;
87
+ disabled_skills: z.ZodOptional<z.ZodArray<z.ZodString>>;
88
+ ignored_paths: z.ZodOptional<z.ZodArray<z.ZodString>>;
204
89
  type: z.ZodLiteral<"github_collection">;
205
90
  repo: z.ZodString;
206
91
  path: z.ZodOptional<z.ZodString>;
207
- }, "strip", z.ZodTypeAny, {
208
- type: "github_collection";
209
- repo: string;
210
- path?: string | undefined;
211
- enabled_skills?: string[] | undefined;
212
- disabled_skills?: string[] | undefined;
213
- ignored_paths?: string[] | undefined;
214
- }, {
215
- type: "github_collection";
216
- repo: string;
217
- path?: string | undefined;
218
- enabled_skills?: string[] | undefined;
219
- disabled_skills?: string[] | undefined;
220
- ignored_paths?: string[] | undefined;
221
- }>]>>;
92
+ }, z.core.$strip>], "type">>;
222
93
  export type SkillCfgMap = z.infer<typeof zSkillCfgMap>;
223
94
  export declare const zSkillMatter: z.ZodObject<{
224
95
  name: z.ZodString;
225
96
  description: z.ZodString;
226
- }, "strip", z.ZodTypeAny, {
227
- description: string;
228
- name: string;
229
- }, {
230
- description: string;
231
- name: string;
232
- }>;
97
+ }, z.core.$strip>;
233
98
  export type SkillMatter = z.infer<typeof zSkillMatter>;
234
99
  export declare const zLocalSkill: z.ZodObject<{
235
100
  name: z.ZodString;
236
101
  description: z.ZodString;
237
- } & {
238
102
  type: z.ZodLiteral<"local">;
239
103
  path: z.ZodString;
240
- }, "strip", z.ZodTypeAny, {
241
- type: "local";
242
- description: string;
243
- name: string;
244
- path: string;
245
- }, {
246
- type: "local";
247
- description: string;
248
- name: string;
249
- path: string;
250
- }>;
104
+ }, z.core.$strip>;
251
105
  export type LocalSkill = z.infer<typeof zLocalSkill>;
252
106
  export declare const zGitHubSkill: z.ZodObject<{
253
107
  name: z.ZodString;
254
108
  description: z.ZodString;
255
- } & {
256
109
  type: z.ZodLiteral<"github">;
257
110
  repo: z.ZodString;
258
111
  path: z.ZodOptional<z.ZodString>;
259
- }, "strip", z.ZodTypeAny, {
260
- type: "github";
261
- description: string;
262
- name: string;
263
- repo: string;
264
- path?: string | undefined;
265
- }, {
266
- type: "github";
267
- description: string;
268
- name: string;
269
- repo: string;
270
- path?: string | undefined;
271
- }>;
112
+ }, z.core.$strip>;
272
113
  export type GitHubSkill = z.infer<typeof zGitHubSkill>;
273
- export declare const zSkill: z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
114
+ export declare const zSkill: z.ZodDiscriminatedUnion<[z.ZodObject<{
274
115
  name: z.ZodString;
275
116
  description: z.ZodString;
276
- } & {
277
117
  type: z.ZodLiteral<"local">;
278
118
  path: z.ZodString;
279
- }, "strip", z.ZodTypeAny, {
280
- type: "local";
281
- description: string;
282
- name: string;
283
- path: string;
284
- }, {
285
- type: "local";
286
- description: string;
287
- name: string;
288
- path: string;
289
- }>, z.ZodObject<{
119
+ }, z.core.$strip>, z.ZodObject<{
290
120
  name: z.ZodString;
291
121
  description: z.ZodString;
292
- } & {
293
122
  type: z.ZodLiteral<"github">;
294
123
  repo: z.ZodString;
295
124
  path: z.ZodOptional<z.ZodString>;
296
- }, "strip", z.ZodTypeAny, {
297
- type: "github";
298
- description: string;
299
- name: string;
300
- repo: string;
301
- path?: string | undefined;
302
- }, {
303
- type: "github";
304
- description: string;
305
- name: string;
306
- repo: string;
307
- path?: string | undefined;
308
- }>]>;
125
+ }, z.core.$strip>], "type">;
309
126
  export type Skill = z.infer<typeof zSkill>;
310
- export declare const zSkillMap: z.ZodRecord<z.ZodString, z.ZodDiscriminatedUnion<"type", [z.ZodObject<{
127
+ export declare const zSkillMap: z.ZodRecord<z.ZodString, z.ZodDiscriminatedUnion<[z.ZodObject<{
311
128
  name: z.ZodString;
312
129
  description: z.ZodString;
313
- } & {
314
130
  type: z.ZodLiteral<"local">;
315
131
  path: z.ZodString;
316
- }, "strip", z.ZodTypeAny, {
317
- type: "local";
318
- description: string;
319
- name: string;
320
- path: string;
321
- }, {
322
- type: "local";
323
- description: string;
324
- name: string;
325
- path: string;
326
- }>, z.ZodObject<{
132
+ }, z.core.$strip>, z.ZodObject<{
327
133
  name: z.ZodString;
328
134
  description: z.ZodString;
329
- } & {
330
135
  type: z.ZodLiteral<"github">;
331
136
  repo: z.ZodString;
332
137
  path: z.ZodOptional<z.ZodString>;
333
- }, "strip", z.ZodTypeAny, {
334
- type: "github";
335
- description: string;
336
- name: string;
337
- repo: string;
338
- path?: string | undefined;
339
- }, {
340
- type: "github";
341
- description: string;
342
- name: string;
343
- repo: string;
344
- path?: string | undefined;
345
- }>]>>;
138
+ }, z.core.$strip>], "type">>;
346
139
  export type SkillMap = z.infer<typeof zSkillMap>;
347
140
  export interface SkillsFlags {
348
141
  enabledSkills?: Set<string> | null;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tigerdata/mcp-boilerplate",
3
- "version": "1.2.0",
3
+ "version": "1.3.1",
4
4
  "description": "MCP boilerplate code for Node.js",
5
5
  "license": "Apache-2.0",
6
6
  "author": "TigerData",
@@ -40,16 +40,16 @@
40
40
  "lint": "./bun x @biomejs/biome check"
41
41
  },
42
42
  "dependencies": {
43
- "@mcp-use/inspector": "^0.14.0",
44
- "@modelcontextprotocol/sdk": "^1.25.1",
43
+ "@mcp-use/inspector": "^0.24.5",
44
+ "@modelcontextprotocol/sdk": "^1.27.1",
45
45
  "@opentelemetry/api": "^1.9.0",
46
- "@opentelemetry/auto-instrumentations-node": "^0.67.3",
47
- "@opentelemetry/exporter-trace-otlp-grpc": "^0.208.0",
48
- "@opentelemetry/instrumentation-http": "^0.208.0",
49
- "@opentelemetry/sdk-metrics": "^2.2.0",
50
- "@opentelemetry/sdk-node": "^0.208.0",
51
- "@opentelemetry/sdk-trace-node": "^2.2.0",
52
- "@opentelemetry/semantic-conventions": "^1.38.0",
46
+ "@opentelemetry/auto-instrumentations-node": "^0.71.0",
47
+ "@opentelemetry/exporter-trace-otlp-grpc": "^0.213.0",
48
+ "@opentelemetry/instrumentation-http": "^0.213.0",
49
+ "@opentelemetry/sdk-metrics": "^2.6.0",
50
+ "@opentelemetry/sdk-node": "^0.213.0",
51
+ "@opentelemetry/sdk-trace-node": "^2.6.0",
52
+ "@opentelemetry/semantic-conventions": "^1.40.0",
53
53
  "@toon-format/toon": "^2.1.0",
54
54
  "express": "^5.2.1",
55
55
  "gray-matter": "^4.0.3",
@@ -60,15 +60,15 @@
60
60
  "zod": "^3.25 || ^4.0"
61
61
  },
62
62
  "devDependencies": {
63
- "@biomejs/biome": "^2.3.11",
64
- "zod": "^3.25.0",
63
+ "@biomejs/biome": "^2.4.8",
64
+ "zod": "^4.3.6",
65
65
  "@octokit/rest": "^22.0.1",
66
- "@types/bun": "^1.3.5",
66
+ "@types/bun": "^1.3.10",
67
67
  "@types/express": "^5.0.6",
68
- "@types/node": "^22.19.3",
69
- "@typescript-eslint/typescript-estree": "^8.52.0",
70
- "ai": "^5.0.118",
71
- "eslint": "^9.39.2",
68
+ "@types/node": "^22.19.15",
69
+ "@typescript-eslint/typescript-estree": "^8.57.1",
70
+ "ai": "^5.0.155",
71
+ "eslint": "^9.39.4",
72
72
  "typescript": "^5.9.3"
73
73
  },
74
74
  "publishConfig": {