mcp-grampsweb 1.0.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.
Files changed (67) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +133 -0
  3. package/dist/auth.d.ts +37 -0
  4. package/dist/auth.d.ts.map +1 -0
  5. package/dist/auth.js +119 -0
  6. package/dist/auth.js.map +1 -0
  7. package/dist/client.d.ts +44 -0
  8. package/dist/client.d.ts.map +1 -0
  9. package/dist/client.js +153 -0
  10. package/dist/client.js.map +1 -0
  11. package/dist/config.d.ts +11 -0
  12. package/dist/config.d.ts.map +1 -0
  13. package/dist/config.js +32 -0
  14. package/dist/config.js.map +1 -0
  15. package/dist/constants.d.ts +24 -0
  16. package/dist/constants.d.ts.map +1 -0
  17. package/dist/constants.js +50 -0
  18. package/dist/constants.js.map +1 -0
  19. package/dist/index.d.ts +9 -0
  20. package/dist/index.d.ts.map +1 -0
  21. package/dist/index.js +132 -0
  22. package/dist/index.js.map +1 -0
  23. package/dist/schemas/common.d.ts +308 -0
  24. package/dist/schemas/common.d.ts.map +1 -0
  25. package/dist/schemas/common.js +120 -0
  26. package/dist/schemas/common.js.map +1 -0
  27. package/dist/schemas/entities.d.ts +1165 -0
  28. package/dist/schemas/entities.d.ts.map +1 -0
  29. package/dist/schemas/entities.js +125 -0
  30. package/dist/schemas/entities.js.map +1 -0
  31. package/dist/schemas/index.d.ts +7 -0
  32. package/dist/schemas/index.d.ts.map +1 -0
  33. package/dist/schemas/index.js +7 -0
  34. package/dist/schemas/index.js.map +1 -0
  35. package/dist/schemas/search.d.ts +47 -0
  36. package/dist/schemas/search.d.ts.map +1 -0
  37. package/dist/schemas/search.js +24 -0
  38. package/dist/schemas/search.js.map +1 -0
  39. package/dist/tools/analysis.d.ts +115 -0
  40. package/dist/tools/analysis.d.ts.map +1 -0
  41. package/dist/tools/analysis.js +387 -0
  42. package/dist/tools/analysis.js.map +1 -0
  43. package/dist/tools/create.d.ts +355 -0
  44. package/dist/tools/create.d.ts.map +1 -0
  45. package/dist/tools/create.js +547 -0
  46. package/dist/tools/create.js.map +1 -0
  47. package/dist/tools/index.d.ts +468 -0
  48. package/dist/tools/index.d.ts.map +1 -0
  49. package/dist/tools/index.js +17 -0
  50. package/dist/tools/index.js.map +1 -0
  51. package/dist/tools/search.d.ts +95 -0
  52. package/dist/tools/search.d.ts.map +1 -0
  53. package/dist/tools/search.js +161 -0
  54. package/dist/tools/search.js.map +1 -0
  55. package/dist/types.d.ts +210 -0
  56. package/dist/types.d.ts.map +1 -0
  57. package/dist/types.js +5 -0
  58. package/dist/types.js.map +1 -0
  59. package/dist/utils/errors.d.ts +19 -0
  60. package/dist/utils/errors.d.ts.map +1 -0
  61. package/dist/utils/errors.js +48 -0
  62. package/dist/utils/errors.js.map +1 -0
  63. package/dist/utils/formatting.d.ts +60 -0
  64. package/dist/utils/formatting.d.ts.map +1 -0
  65. package/dist/utils/formatting.js +256 -0
  66. package/dist/utils/formatting.js.map +1 -0
  67. package/package.json +48 -0
@@ -0,0 +1,468 @@
1
+ /**
2
+ * Tool registry - exports all tools for MCP server
3
+ */
4
+ import { searchTools } from "./search.js";
5
+ import { createTools } from "./create.js";
6
+ import { analysisTools } from "./analysis.js";
7
+ export declare const allTools: {
8
+ gramps_tree_stats: {
9
+ name: string;
10
+ description: string;
11
+ inputSchema: {
12
+ type: "object";
13
+ properties: {};
14
+ required: never[];
15
+ };
16
+ handler: typeof import("./analysis.js").grampsTreeStats;
17
+ };
18
+ gramps_get_ancestors: {
19
+ name: string;
20
+ description: string;
21
+ inputSchema: {
22
+ type: "object";
23
+ properties: {
24
+ handle: {
25
+ type: string;
26
+ description: string;
27
+ };
28
+ generations: {
29
+ type: string;
30
+ description: string;
31
+ default: number;
32
+ };
33
+ };
34
+ required: string[];
35
+ };
36
+ handler: typeof import("./analysis.js").grampsGetAncestors;
37
+ };
38
+ gramps_get_descendants: {
39
+ name: string;
40
+ description: string;
41
+ inputSchema: {
42
+ type: "object";
43
+ properties: {
44
+ handle: {
45
+ type: string;
46
+ description: string;
47
+ };
48
+ generations: {
49
+ type: string;
50
+ description: string;
51
+ default: number;
52
+ };
53
+ };
54
+ required: string[];
55
+ };
56
+ handler: typeof import("./analysis.js").grampsGetDescendants;
57
+ };
58
+ gramps_recent_changes: {
59
+ name: string;
60
+ description: string;
61
+ inputSchema: {
62
+ type: "object";
63
+ properties: {
64
+ page: {
65
+ type: string;
66
+ description: string;
67
+ default: number;
68
+ };
69
+ pagesize: {
70
+ type: string;
71
+ description: string;
72
+ default: number;
73
+ };
74
+ };
75
+ required: never[];
76
+ };
77
+ handler: typeof import("./analysis.js").grampsRecentChanges;
78
+ };
79
+ gramps_create_person: {
80
+ name: string;
81
+ description: string;
82
+ inputSchema: {
83
+ type: "object";
84
+ properties: {
85
+ gramps_id: {
86
+ type: string;
87
+ description: string;
88
+ };
89
+ primary_name: {
90
+ type: string;
91
+ description: string;
92
+ properties: {
93
+ first_name: {
94
+ type: string;
95
+ };
96
+ surname: {
97
+ type: string;
98
+ };
99
+ suffix: {
100
+ type: string;
101
+ };
102
+ title: {
103
+ type: string;
104
+ };
105
+ };
106
+ };
107
+ gender: {
108
+ type: string;
109
+ enum: string[];
110
+ description: string;
111
+ };
112
+ private: {
113
+ type: string;
114
+ description: string;
115
+ };
116
+ };
117
+ required: string[];
118
+ };
119
+ handler: typeof import("./create.js").grampsCreatePerson;
120
+ };
121
+ gramps_create_family: {
122
+ name: string;
123
+ description: string;
124
+ inputSchema: {
125
+ type: "object";
126
+ properties: {
127
+ gramps_id: {
128
+ type: string;
129
+ description: string;
130
+ };
131
+ father_handle: {
132
+ type: string;
133
+ description: string;
134
+ };
135
+ mother_handle: {
136
+ type: string;
137
+ description: string;
138
+ };
139
+ child_ref_list: {
140
+ type: string;
141
+ items: {
142
+ type: string;
143
+ properties: {
144
+ ref: {
145
+ type: string;
146
+ description: string;
147
+ };
148
+ frel: {
149
+ type: string;
150
+ description: string;
151
+ };
152
+ mrel: {
153
+ type: string;
154
+ description: string;
155
+ };
156
+ };
157
+ required: string[];
158
+ };
159
+ description: string;
160
+ };
161
+ type: {
162
+ type: string;
163
+ description: string;
164
+ };
165
+ };
166
+ required: never[];
167
+ };
168
+ handler: typeof import("./create.js").grampsCreateFamily;
169
+ };
170
+ gramps_create_event: {
171
+ name: string;
172
+ description: string;
173
+ inputSchema: {
174
+ type: "object";
175
+ properties: {
176
+ gramps_id: {
177
+ type: string;
178
+ description: string;
179
+ };
180
+ type: {
181
+ type: string;
182
+ description: string;
183
+ };
184
+ date: {
185
+ type: string;
186
+ description: string;
187
+ properties: {
188
+ dateval: {
189
+ type: string;
190
+ items: {
191
+ type: string;
192
+ };
193
+ description: string;
194
+ };
195
+ text: {
196
+ type: string;
197
+ description: string;
198
+ };
199
+ };
200
+ };
201
+ place: {
202
+ type: string;
203
+ description: string;
204
+ };
205
+ description: {
206
+ type: string;
207
+ description: string;
208
+ };
209
+ };
210
+ required: string[];
211
+ };
212
+ handler: typeof import("./create.js").grampsCreateEvent;
213
+ };
214
+ gramps_create_place: {
215
+ name: string;
216
+ description: string;
217
+ inputSchema: {
218
+ type: "object";
219
+ properties: {
220
+ gramps_id: {
221
+ type: string;
222
+ description: string;
223
+ };
224
+ title: {
225
+ type: string;
226
+ description: string;
227
+ };
228
+ name: {
229
+ type: string;
230
+ properties: {
231
+ value: {
232
+ type: string;
233
+ description: string;
234
+ };
235
+ };
236
+ description: string;
237
+ };
238
+ lat: {
239
+ type: string;
240
+ description: string;
241
+ };
242
+ long: {
243
+ type: string;
244
+ description: string;
245
+ };
246
+ place_type: {
247
+ type: string;
248
+ description: string;
249
+ };
250
+ };
251
+ required: never[];
252
+ };
253
+ handler: typeof import("./create.js").grampsCreatePlace;
254
+ };
255
+ gramps_create_source: {
256
+ name: string;
257
+ description: string;
258
+ inputSchema: {
259
+ type: "object";
260
+ properties: {
261
+ gramps_id: {
262
+ type: string;
263
+ description: string;
264
+ };
265
+ title: {
266
+ type: string;
267
+ description: string;
268
+ };
269
+ author: {
270
+ type: string;
271
+ description: string;
272
+ };
273
+ pubinfo: {
274
+ type: string;
275
+ description: string;
276
+ };
277
+ abbrev: {
278
+ type: string;
279
+ description: string;
280
+ };
281
+ };
282
+ required: string[];
283
+ };
284
+ handler: typeof import("./create.js").grampsCreateSource;
285
+ };
286
+ gramps_create_citation: {
287
+ name: string;
288
+ description: string;
289
+ inputSchema: {
290
+ type: "object";
291
+ properties: {
292
+ gramps_id: {
293
+ type: string;
294
+ description: string;
295
+ };
296
+ source_handle: {
297
+ type: string;
298
+ description: string;
299
+ };
300
+ page: {
301
+ type: string;
302
+ description: string;
303
+ };
304
+ confidence: {
305
+ type: string;
306
+ description: string;
307
+ };
308
+ };
309
+ required: string[];
310
+ };
311
+ handler: typeof import("./create.js").grampsCreateCitation;
312
+ };
313
+ gramps_create_note: {
314
+ name: string;
315
+ description: string;
316
+ inputSchema: {
317
+ type: "object";
318
+ properties: {
319
+ gramps_id: {
320
+ type: string;
321
+ description: string;
322
+ };
323
+ text: {
324
+ type: string;
325
+ description: string;
326
+ };
327
+ type: {
328
+ type: string;
329
+ description: string;
330
+ };
331
+ format: {
332
+ type: string;
333
+ description: string;
334
+ };
335
+ };
336
+ required: string[];
337
+ };
338
+ handler: typeof import("./create.js").grampsCreateNote;
339
+ };
340
+ gramps_create_media: {
341
+ name: string;
342
+ description: string;
343
+ inputSchema: {
344
+ type: "object";
345
+ properties: {
346
+ gramps_id: {
347
+ type: string;
348
+ description: string;
349
+ };
350
+ path: {
351
+ type: string;
352
+ description: string;
353
+ };
354
+ mime: {
355
+ type: string;
356
+ description: string;
357
+ };
358
+ desc: {
359
+ type: string;
360
+ description: string;
361
+ };
362
+ };
363
+ required: string[];
364
+ };
365
+ handler: typeof import("./create.js").grampsCreateMedia;
366
+ };
367
+ gramps_create_repository: {
368
+ name: string;
369
+ description: string;
370
+ inputSchema: {
371
+ type: "object";
372
+ properties: {
373
+ gramps_id: {
374
+ type: string;
375
+ description: string;
376
+ };
377
+ name: {
378
+ type: string;
379
+ description: string;
380
+ };
381
+ type: {
382
+ type: string;
383
+ description: string;
384
+ };
385
+ };
386
+ required: string[];
387
+ };
388
+ handler: typeof import("./create.js").grampsCreateRepository;
389
+ };
390
+ gramps_search: {
391
+ name: string;
392
+ description: string;
393
+ inputSchema: {
394
+ type: "object";
395
+ properties: {
396
+ query: {
397
+ type: string;
398
+ description: string;
399
+ };
400
+ entity_type: {
401
+ type: string;
402
+ enum: string[];
403
+ description: string;
404
+ };
405
+ page: {
406
+ type: string;
407
+ description: string;
408
+ default: number;
409
+ };
410
+ pagesize: {
411
+ type: string;
412
+ description: string;
413
+ default: number;
414
+ };
415
+ };
416
+ required: string[];
417
+ };
418
+ handler: typeof import("./search.js").grampsSearch;
419
+ };
420
+ gramps_find: {
421
+ name: string;
422
+ description: string;
423
+ inputSchema: {
424
+ type: "object";
425
+ properties: {
426
+ query: {
427
+ type: string;
428
+ description: string;
429
+ };
430
+ page: {
431
+ type: string;
432
+ description: string;
433
+ default: number;
434
+ };
435
+ pagesize: {
436
+ type: string;
437
+ description: string;
438
+ default: number;
439
+ };
440
+ };
441
+ required: string[];
442
+ };
443
+ handler: typeof import("./search.js").grampsFind;
444
+ };
445
+ gramps_get: {
446
+ name: string;
447
+ description: string;
448
+ inputSchema: {
449
+ type: "object";
450
+ properties: {
451
+ entity_type: {
452
+ type: string;
453
+ enum: string[];
454
+ description: string;
455
+ };
456
+ handle: {
457
+ type: string;
458
+ description: string;
459
+ };
460
+ };
461
+ required: string[];
462
+ };
463
+ handler: typeof import("./search.js").grampsGet;
464
+ };
465
+ };
466
+ export declare const toolNames: string[];
467
+ export { searchTools, createTools, analysisTools };
468
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/tools/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAC1C,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAC1C,OAAO,EAAE,aAAa,EAAE,MAAM,eAAe,CAAC;AAG9C,eAAO,MAAM,QAAQ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAIpB,CAAC;AAGF,eAAO,MAAM,SAAS,UAAwB,CAAC;AAG/C,OAAO,EAAE,WAAW,EAAE,WAAW,EAAE,aAAa,EAAE,CAAC"}
@@ -0,0 +1,17 @@
1
+ /**
2
+ * Tool registry - exports all tools for MCP server
3
+ */
4
+ import { searchTools } from "./search.js";
5
+ import { createTools } from "./create.js";
6
+ import { analysisTools } from "./analysis.js";
7
+ // Combine all tools
8
+ export const allTools = {
9
+ ...searchTools,
10
+ ...createTools,
11
+ ...analysisTools,
12
+ };
13
+ // Export tool names for registration
14
+ export const toolNames = Object.keys(allTools);
15
+ // Export individual tool groups
16
+ export { searchTools, createTools, analysisTools };
17
+ //# sourceMappingURL=index.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/tools/index.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAC1C,OAAO,EAAE,WAAW,EAAE,MAAM,aAAa,CAAC;AAC1C,OAAO,EAAE,aAAa,EAAE,MAAM,eAAe,CAAC;AAE9C,oBAAoB;AACpB,MAAM,CAAC,MAAM,QAAQ,GAAG;IACtB,GAAG,WAAW;IACd,GAAG,WAAW;IACd,GAAG,aAAa;CACjB,CAAC;AAEF,qCAAqC;AACrC,MAAM,CAAC,MAAM,SAAS,GAAG,MAAM,CAAC,IAAI,CAAC,QAAQ,CAAC,CAAC;AAE/C,gCAAgC;AAChC,OAAO,EAAE,WAAW,EAAE,WAAW,EAAE,aAAa,EAAE,CAAC"}
@@ -0,0 +1,95 @@
1
+ /**
2
+ * Search and retrieval tools
3
+ */
4
+ import { z } from "zod";
5
+ import { searchSchema, findSchema, getEntitySchema } from "../schemas/search.js";
6
+ /**
7
+ * GQL-based search for entities
8
+ */
9
+ export declare function grampsSearch(params: z.infer<typeof searchSchema>): Promise<string>;
10
+ /**
11
+ * Full-text search across all entities
12
+ */
13
+ export declare function grampsFind(params: z.infer<typeof findSchema>): Promise<string>;
14
+ /**
15
+ * Get a specific entity by handle or ID
16
+ */
17
+ export declare function grampsGet(params: z.infer<typeof getEntitySchema>): Promise<string>;
18
+ export declare const searchTools: {
19
+ gramps_search: {
20
+ name: string;
21
+ description: string;
22
+ inputSchema: {
23
+ type: "object";
24
+ properties: {
25
+ query: {
26
+ type: string;
27
+ description: string;
28
+ };
29
+ entity_type: {
30
+ type: string;
31
+ enum: string[];
32
+ description: string;
33
+ };
34
+ page: {
35
+ type: string;
36
+ description: string;
37
+ default: number;
38
+ };
39
+ pagesize: {
40
+ type: string;
41
+ description: string;
42
+ default: number;
43
+ };
44
+ };
45
+ required: string[];
46
+ };
47
+ handler: typeof grampsSearch;
48
+ };
49
+ gramps_find: {
50
+ name: string;
51
+ description: string;
52
+ inputSchema: {
53
+ type: "object";
54
+ properties: {
55
+ query: {
56
+ type: string;
57
+ description: string;
58
+ };
59
+ page: {
60
+ type: string;
61
+ description: string;
62
+ default: number;
63
+ };
64
+ pagesize: {
65
+ type: string;
66
+ description: string;
67
+ default: number;
68
+ };
69
+ };
70
+ required: string[];
71
+ };
72
+ handler: typeof grampsFind;
73
+ };
74
+ gramps_get: {
75
+ name: string;
76
+ description: string;
77
+ inputSchema: {
78
+ type: "object";
79
+ properties: {
80
+ entity_type: {
81
+ type: string;
82
+ enum: string[];
83
+ description: string;
84
+ };
85
+ handle: {
86
+ type: string;
87
+ description: string;
88
+ };
89
+ };
90
+ required: string[];
91
+ };
92
+ handler: typeof grampsGet;
93
+ };
94
+ };
95
+ //# sourceMappingURL=search.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"search.d.ts","sourceRoot":"","sources":["../../src/tools/search.ts"],"names":[],"mappings":"AAAA;;GAEG;AAEH,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAGxB,OAAO,EAAE,YAAY,EAAE,UAAU,EAAE,eAAe,EAAE,MAAM,sBAAsB,CAAC;AAYjF;;GAEG;AACH,wBAAsB,YAAY,CAAC,MAAM,EAAE,CAAC,CAAC,KAAK,CAAC,OAAO,YAAY,CAAC,GAAG,OAAO,CAAC,MAAM,CAAC,CAyBxF;AAED;;GAEG;AACH,wBAAsB,UAAU,CAAC,MAAM,EAAE,CAAC,CAAC,KAAK,CAAC,OAAO,UAAU,CAAC,GAAG,OAAO,CAAC,MAAM,CAAC,CAoBpF;AAED;;GAEG;AACH,wBAAsB,SAAS,CAAC,MAAM,EAAE,CAAC,CAAC,KAAK,CAAC,OAAO,eAAe,CAAC,GAAG,OAAO,CAAC,MAAM,CAAC,CAyBxF;AAGD,eAAO,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAsFvB,CAAC"}