@kynver-app/mcp-estimator 0.2.16 → 0.2.18

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 (45) hide show
  1. package/dist/index.js +1 -14
  2. package/dist/sse.js +1 -9
  3. package/package.json +8 -5
  4. package/dist/index.d.ts +0 -7
  5. package/dist/lib/kynver-client.d.ts +0 -20
  6. package/dist/lib/kynver-client.js +0 -115
  7. package/dist/lib/mcp-sse-server.d.ts +0 -44
  8. package/dist/lib/mcp-sse-server.js +0 -441
  9. package/dist/lib/package-version.d.ts +0 -7
  10. package/dist/lib/package-version.js +0 -44
  11. package/dist/server.d.ts +0 -6
  12. package/dist/server.js +0 -119
  13. package/dist/sse.d.ts +0 -1
  14. package/dist/tools/catalog-tools.d.ts +0 -381
  15. package/dist/tools/catalog-tools.js +0 -192
  16. package/dist/tools/client-tools.d.ts +0 -193
  17. package/dist/tools/client-tools.js +0 -105
  18. package/dist/tools/company-tools.d.ts +0 -163
  19. package/dist/tools/company-tools.js +0 -98
  20. package/dist/tools/email-pdf-tools.d.ts +0 -51
  21. package/dist/tools/email-pdf-tools.js +0 -22
  22. package/dist/tools/estimate-tools.d.ts +0 -531
  23. package/dist/tools/estimate-tools.js +0 -259
  24. package/dist/tools/intake-tools.d.ts +0 -463
  25. package/dist/tools/intake-tools.js +0 -82
  26. package/dist/tools/photo-tools.d.ts +0 -77
  27. package/dist/tools/photo-tools.js +0 -51
  28. package/dist/tools/price-catalog-tools.d.ts +0 -96
  29. package/dist/tools/price-catalog-tools.js +0 -72
  30. package/dist/tools/remodel-deliverable-tools.d.ts +0 -1868
  31. package/dist/tools/remodel-deliverable-tools.js +0 -138
  32. package/dist/tools/remodel-estimate-tools.d.ts +0 -525
  33. package/dist/tools/remodel-estimate-tools.js +0 -71
  34. package/dist/tools/signing-tools.d.ts +0 -89
  35. package/dist/tools/signing-tools.js +0 -51
  36. package/dist/tools/stats-pdf-tools.d.ts +0 -113
  37. package/dist/tools/stats-pdf-tools.js +0 -73
  38. package/dist/tools/takeoff-tools.d.ts +0 -730
  39. package/dist/tools/takeoff-tools.js +0 -297
  40. package/dist/tools/template-tools.d.ts +0 -96
  41. package/dist/tools/template-tools.js +0 -70
  42. package/dist/tools/version-tools.d.ts +0 -46
  43. package/dist/tools/version-tools.js +0 -33
  44. package/dist/tools/vision-tools.d.ts +0 -52
  45. package/dist/tools/vision-tools.js +0 -42
@@ -1,463 +0,0 @@
1
- import { z } from "zod";
2
- declare const normalizeRemodelIntakeSchema: z.ZodObject<{
3
- projectType: z.ZodEnum<["kitchen_remodel", "bath_remodel", "kitchen_and_bath_remodel", "whole_home_remodel", "other_remodel"]>;
4
- projectName: z.ZodOptional<z.ZodString>;
5
- siteAddress: z.ZodOptional<z.ZodString>;
6
- baseScopes: z.ZodOptional<z.ZodArray<z.ZodObject<{
7
- key: z.ZodOptional<z.ZodString>;
8
- label: z.ZodString;
9
- quantity: z.ZodOptional<z.ZodNumber>;
10
- unit: z.ZodOptional<z.ZodString>;
11
- serviceCode: z.ZodOptional<z.ZodString>;
12
- budgetLump: z.ZodOptional<z.ZodNumber>;
13
- notes: z.ZodOptional<z.ZodString>;
14
- confidence: z.ZodOptional<z.ZodEnum<["high", "medium", "low", "unknown"]>>;
15
- isAlternate: z.ZodOptional<z.ZodBoolean>;
16
- alternateGroup: z.ZodOptional<z.ZodString>;
17
- }, "strip", z.ZodTypeAny, {
18
- label: string;
19
- serviceCode?: string | undefined;
20
- unit?: string | undefined;
21
- notes?: string | undefined;
22
- quantity?: number | undefined;
23
- key?: string | undefined;
24
- budgetLump?: number | undefined;
25
- confidence?: "unknown" | "high" | "medium" | "low" | undefined;
26
- isAlternate?: boolean | undefined;
27
- alternateGroup?: string | undefined;
28
- }, {
29
- label: string;
30
- serviceCode?: string | undefined;
31
- unit?: string | undefined;
32
- notes?: string | undefined;
33
- quantity?: number | undefined;
34
- key?: string | undefined;
35
- budgetLump?: number | undefined;
36
- confidence?: "unknown" | "high" | "medium" | "low" | undefined;
37
- isAlternate?: boolean | undefined;
38
- alternateGroup?: string | undefined;
39
- }>, "many">>;
40
- alternates: z.ZodOptional<z.ZodArray<z.ZodObject<{
41
- key: z.ZodString;
42
- label: z.ZodString;
43
- scopeKeys: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
44
- lumpAdd: z.ZodOptional<z.ZodNumber>;
45
- notes: z.ZodOptional<z.ZodString>;
46
- }, "strip", z.ZodTypeAny, {
47
- label: string;
48
- key: string;
49
- notes?: string | undefined;
50
- scopeKeys?: string[] | undefined;
51
- lumpAdd?: number | undefined;
52
- }, {
53
- label: string;
54
- key: string;
55
- notes?: string | undefined;
56
- scopeKeys?: string[] | undefined;
57
- lumpAdd?: number | undefined;
58
- }>, "many">>;
59
- attachments: z.ZodOptional<z.ZodArray<z.ZodObject<{
60
- id: z.ZodString;
61
- kind: z.ZodEnum<["photo", "drawing", "plan_set", "spec_pdf", "spreadsheet", "other"]>;
62
- fileName: z.ZodOptional<z.ZodString>;
63
- caption: z.ZodOptional<z.ZodString>;
64
- url: z.ZodOptional<z.ZodString>;
65
- mimeType: z.ZodOptional<z.ZodString>;
66
- }, "strip", z.ZodTypeAny, {
67
- id: string;
68
- kind: "photo" | "drawing" | "plan_set" | "spec_pdf" | "spreadsheet" | "other";
69
- caption?: string | undefined;
70
- fileName?: string | undefined;
71
- mimeType?: string | undefined;
72
- url?: string | undefined;
73
- }, {
74
- id: string;
75
- kind: "photo" | "drawing" | "plan_set" | "spec_pdf" | "spreadsheet" | "other";
76
- caption?: string | undefined;
77
- fileName?: string | undefined;
78
- mimeType?: string | undefined;
79
- url?: string | undefined;
80
- }>, "many">>;
81
- exclusions: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
82
- surprises: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
83
- rateReferences: z.ZodOptional<z.ZodArray<z.ZodObject<{
84
- key: z.ZodString;
85
- label: z.ZodString;
86
- value: z.ZodNumber;
87
- unit: z.ZodOptional<z.ZodString>;
88
- source: z.ZodEnum<["operating_rule", "catalog", "user", "takeoff"]>;
89
- catalogId: z.ZodOptional<z.ZodString>;
90
- confidence: z.ZodOptional<z.ZodEnum<["high", "medium", "low", "unknown"]>>;
91
- }, "strip", z.ZodTypeAny, {
92
- value: number;
93
- label: string;
94
- key: string;
95
- source: "operating_rule" | "catalog" | "user" | "takeoff";
96
- unit?: string | undefined;
97
- catalogId?: string | undefined;
98
- confidence?: "unknown" | "high" | "medium" | "low" | undefined;
99
- }, {
100
- value: number;
101
- label: string;
102
- key: string;
103
- source: "operating_rule" | "catalog" | "user" | "takeoff";
104
- unit?: string | undefined;
105
- catalogId?: string | undefined;
106
- confidence?: "unknown" | "high" | "medium" | "low" | undefined;
107
- }>, "many">>;
108
- assumptionsNeedingReview: z.ZodOptional<z.ZodArray<z.ZodObject<{
109
- id: z.ZodString;
110
- text: z.ZodString;
111
- severity: z.ZodEnum<["info", "warn", "blocker"]>;
112
- relatedScopeKey: z.ZodOptional<z.ZodString>;
113
- }, "strip", z.ZodTypeAny, {
114
- id: string;
115
- text: string;
116
- severity: "info" | "warn" | "blocker";
117
- relatedScopeKey?: string | undefined;
118
- }, {
119
- id: string;
120
- text: string;
121
- severity: "info" | "warn" | "blocker";
122
- relatedScopeKey?: string | undefined;
123
- }>, "many">>;
124
- remodelHints: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
125
- includeStandardAlternates: z.ZodOptional<z.ZodBoolean>;
126
- notes: z.ZodOptional<z.ZodString>;
127
- }, "strip", z.ZodTypeAny, {
128
- projectType: "kitchen_remodel" | "bath_remodel" | "kitchen_and_bath_remodel" | "whole_home_remodel" | "other_remodel";
129
- notes?: string | undefined;
130
- projectName?: string | undefined;
131
- siteAddress?: string | undefined;
132
- remodelHints?: Record<string, unknown> | undefined;
133
- baseScopes?: {
134
- label: string;
135
- serviceCode?: string | undefined;
136
- unit?: string | undefined;
137
- notes?: string | undefined;
138
- quantity?: number | undefined;
139
- key?: string | undefined;
140
- budgetLump?: number | undefined;
141
- confidence?: "unknown" | "high" | "medium" | "low" | undefined;
142
- isAlternate?: boolean | undefined;
143
- alternateGroup?: string | undefined;
144
- }[] | undefined;
145
- alternates?: {
146
- label: string;
147
- key: string;
148
- notes?: string | undefined;
149
- scopeKeys?: string[] | undefined;
150
- lumpAdd?: number | undefined;
151
- }[] | undefined;
152
- attachments?: {
153
- id: string;
154
- kind: "photo" | "drawing" | "plan_set" | "spec_pdf" | "spreadsheet" | "other";
155
- caption?: string | undefined;
156
- fileName?: string | undefined;
157
- mimeType?: string | undefined;
158
- url?: string | undefined;
159
- }[] | undefined;
160
- exclusions?: string[] | undefined;
161
- surprises?: string[] | undefined;
162
- rateReferences?: {
163
- value: number;
164
- label: string;
165
- key: string;
166
- source: "operating_rule" | "catalog" | "user" | "takeoff";
167
- unit?: string | undefined;
168
- catalogId?: string | undefined;
169
- confidence?: "unknown" | "high" | "medium" | "low" | undefined;
170
- }[] | undefined;
171
- assumptionsNeedingReview?: {
172
- id: string;
173
- text: string;
174
- severity: "info" | "warn" | "blocker";
175
- relatedScopeKey?: string | undefined;
176
- }[] | undefined;
177
- includeStandardAlternates?: boolean | undefined;
178
- }, {
179
- projectType: "kitchen_remodel" | "bath_remodel" | "kitchen_and_bath_remodel" | "whole_home_remodel" | "other_remodel";
180
- notes?: string | undefined;
181
- projectName?: string | undefined;
182
- siteAddress?: string | undefined;
183
- remodelHints?: Record<string, unknown> | undefined;
184
- baseScopes?: {
185
- label: string;
186
- serviceCode?: string | undefined;
187
- unit?: string | undefined;
188
- notes?: string | undefined;
189
- quantity?: number | undefined;
190
- key?: string | undefined;
191
- budgetLump?: number | undefined;
192
- confidence?: "unknown" | "high" | "medium" | "low" | undefined;
193
- isAlternate?: boolean | undefined;
194
- alternateGroup?: string | undefined;
195
- }[] | undefined;
196
- alternates?: {
197
- label: string;
198
- key: string;
199
- notes?: string | undefined;
200
- scopeKeys?: string[] | undefined;
201
- lumpAdd?: number | undefined;
202
- }[] | undefined;
203
- attachments?: {
204
- id: string;
205
- kind: "photo" | "drawing" | "plan_set" | "spec_pdf" | "spreadsheet" | "other";
206
- caption?: string | undefined;
207
- fileName?: string | undefined;
208
- mimeType?: string | undefined;
209
- url?: string | undefined;
210
- }[] | undefined;
211
- exclusions?: string[] | undefined;
212
- surprises?: string[] | undefined;
213
- rateReferences?: {
214
- value: number;
215
- label: string;
216
- key: string;
217
- source: "operating_rule" | "catalog" | "user" | "takeoff";
218
- unit?: string | undefined;
219
- catalogId?: string | undefined;
220
- confidence?: "unknown" | "high" | "medium" | "low" | undefined;
221
- }[] | undefined;
222
- assumptionsNeedingReview?: {
223
- id: string;
224
- text: string;
225
- severity: "info" | "warn" | "blocker";
226
- relatedScopeKey?: string | undefined;
227
- }[] | undefined;
228
- includeStandardAlternates?: boolean | undefined;
229
- }>;
230
- export declare const normalizeRemodelIntake: {
231
- name: string;
232
- description: string;
233
- inputSchemaZod: z.ZodObject<{
234
- projectType: z.ZodEnum<["kitchen_remodel", "bath_remodel", "kitchen_and_bath_remodel", "whole_home_remodel", "other_remodel"]>;
235
- projectName: z.ZodOptional<z.ZodString>;
236
- siteAddress: z.ZodOptional<z.ZodString>;
237
- baseScopes: z.ZodOptional<z.ZodArray<z.ZodObject<{
238
- key: z.ZodOptional<z.ZodString>;
239
- label: z.ZodString;
240
- quantity: z.ZodOptional<z.ZodNumber>;
241
- unit: z.ZodOptional<z.ZodString>;
242
- serviceCode: z.ZodOptional<z.ZodString>;
243
- budgetLump: z.ZodOptional<z.ZodNumber>;
244
- notes: z.ZodOptional<z.ZodString>;
245
- confidence: z.ZodOptional<z.ZodEnum<["high", "medium", "low", "unknown"]>>;
246
- isAlternate: z.ZodOptional<z.ZodBoolean>;
247
- alternateGroup: z.ZodOptional<z.ZodString>;
248
- }, "strip", z.ZodTypeAny, {
249
- label: string;
250
- serviceCode?: string | undefined;
251
- unit?: string | undefined;
252
- notes?: string | undefined;
253
- quantity?: number | undefined;
254
- key?: string | undefined;
255
- budgetLump?: number | undefined;
256
- confidence?: "unknown" | "high" | "medium" | "low" | undefined;
257
- isAlternate?: boolean | undefined;
258
- alternateGroup?: string | undefined;
259
- }, {
260
- label: string;
261
- serviceCode?: string | undefined;
262
- unit?: string | undefined;
263
- notes?: string | undefined;
264
- quantity?: number | undefined;
265
- key?: string | undefined;
266
- budgetLump?: number | undefined;
267
- confidence?: "unknown" | "high" | "medium" | "low" | undefined;
268
- isAlternate?: boolean | undefined;
269
- alternateGroup?: string | undefined;
270
- }>, "many">>;
271
- alternates: z.ZodOptional<z.ZodArray<z.ZodObject<{
272
- key: z.ZodString;
273
- label: z.ZodString;
274
- scopeKeys: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
275
- lumpAdd: z.ZodOptional<z.ZodNumber>;
276
- notes: z.ZodOptional<z.ZodString>;
277
- }, "strip", z.ZodTypeAny, {
278
- label: string;
279
- key: string;
280
- notes?: string | undefined;
281
- scopeKeys?: string[] | undefined;
282
- lumpAdd?: number | undefined;
283
- }, {
284
- label: string;
285
- key: string;
286
- notes?: string | undefined;
287
- scopeKeys?: string[] | undefined;
288
- lumpAdd?: number | undefined;
289
- }>, "many">>;
290
- attachments: z.ZodOptional<z.ZodArray<z.ZodObject<{
291
- id: z.ZodString;
292
- kind: z.ZodEnum<["photo", "drawing", "plan_set", "spec_pdf", "spreadsheet", "other"]>;
293
- fileName: z.ZodOptional<z.ZodString>;
294
- caption: z.ZodOptional<z.ZodString>;
295
- url: z.ZodOptional<z.ZodString>;
296
- mimeType: z.ZodOptional<z.ZodString>;
297
- }, "strip", z.ZodTypeAny, {
298
- id: string;
299
- kind: "photo" | "drawing" | "plan_set" | "spec_pdf" | "spreadsheet" | "other";
300
- caption?: string | undefined;
301
- fileName?: string | undefined;
302
- mimeType?: string | undefined;
303
- url?: string | undefined;
304
- }, {
305
- id: string;
306
- kind: "photo" | "drawing" | "plan_set" | "spec_pdf" | "spreadsheet" | "other";
307
- caption?: string | undefined;
308
- fileName?: string | undefined;
309
- mimeType?: string | undefined;
310
- url?: string | undefined;
311
- }>, "many">>;
312
- exclusions: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
313
- surprises: z.ZodOptional<z.ZodArray<z.ZodString, "many">>;
314
- rateReferences: z.ZodOptional<z.ZodArray<z.ZodObject<{
315
- key: z.ZodString;
316
- label: z.ZodString;
317
- value: z.ZodNumber;
318
- unit: z.ZodOptional<z.ZodString>;
319
- source: z.ZodEnum<["operating_rule", "catalog", "user", "takeoff"]>;
320
- catalogId: z.ZodOptional<z.ZodString>;
321
- confidence: z.ZodOptional<z.ZodEnum<["high", "medium", "low", "unknown"]>>;
322
- }, "strip", z.ZodTypeAny, {
323
- value: number;
324
- label: string;
325
- key: string;
326
- source: "operating_rule" | "catalog" | "user" | "takeoff";
327
- unit?: string | undefined;
328
- catalogId?: string | undefined;
329
- confidence?: "unknown" | "high" | "medium" | "low" | undefined;
330
- }, {
331
- value: number;
332
- label: string;
333
- key: string;
334
- source: "operating_rule" | "catalog" | "user" | "takeoff";
335
- unit?: string | undefined;
336
- catalogId?: string | undefined;
337
- confidence?: "unknown" | "high" | "medium" | "low" | undefined;
338
- }>, "many">>;
339
- assumptionsNeedingReview: z.ZodOptional<z.ZodArray<z.ZodObject<{
340
- id: z.ZodString;
341
- text: z.ZodString;
342
- severity: z.ZodEnum<["info", "warn", "blocker"]>;
343
- relatedScopeKey: z.ZodOptional<z.ZodString>;
344
- }, "strip", z.ZodTypeAny, {
345
- id: string;
346
- text: string;
347
- severity: "info" | "warn" | "blocker";
348
- relatedScopeKey?: string | undefined;
349
- }, {
350
- id: string;
351
- text: string;
352
- severity: "info" | "warn" | "blocker";
353
- relatedScopeKey?: string | undefined;
354
- }>, "many">>;
355
- remodelHints: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
356
- includeStandardAlternates: z.ZodOptional<z.ZodBoolean>;
357
- notes: z.ZodOptional<z.ZodString>;
358
- }, "strip", z.ZodTypeAny, {
359
- projectType: "kitchen_remodel" | "bath_remodel" | "kitchen_and_bath_remodel" | "whole_home_remodel" | "other_remodel";
360
- notes?: string | undefined;
361
- projectName?: string | undefined;
362
- siteAddress?: string | undefined;
363
- remodelHints?: Record<string, unknown> | undefined;
364
- baseScopes?: {
365
- label: string;
366
- serviceCode?: string | undefined;
367
- unit?: string | undefined;
368
- notes?: string | undefined;
369
- quantity?: number | undefined;
370
- key?: string | undefined;
371
- budgetLump?: number | undefined;
372
- confidence?: "unknown" | "high" | "medium" | "low" | undefined;
373
- isAlternate?: boolean | undefined;
374
- alternateGroup?: string | undefined;
375
- }[] | undefined;
376
- alternates?: {
377
- label: string;
378
- key: string;
379
- notes?: string | undefined;
380
- scopeKeys?: string[] | undefined;
381
- lumpAdd?: number | undefined;
382
- }[] | undefined;
383
- attachments?: {
384
- id: string;
385
- kind: "photo" | "drawing" | "plan_set" | "spec_pdf" | "spreadsheet" | "other";
386
- caption?: string | undefined;
387
- fileName?: string | undefined;
388
- mimeType?: string | undefined;
389
- url?: string | undefined;
390
- }[] | undefined;
391
- exclusions?: string[] | undefined;
392
- surprises?: string[] | undefined;
393
- rateReferences?: {
394
- value: number;
395
- label: string;
396
- key: string;
397
- source: "operating_rule" | "catalog" | "user" | "takeoff";
398
- unit?: string | undefined;
399
- catalogId?: string | undefined;
400
- confidence?: "unknown" | "high" | "medium" | "low" | undefined;
401
- }[] | undefined;
402
- assumptionsNeedingReview?: {
403
- id: string;
404
- text: string;
405
- severity: "info" | "warn" | "blocker";
406
- relatedScopeKey?: string | undefined;
407
- }[] | undefined;
408
- includeStandardAlternates?: boolean | undefined;
409
- }, {
410
- projectType: "kitchen_remodel" | "bath_remodel" | "kitchen_and_bath_remodel" | "whole_home_remodel" | "other_remodel";
411
- notes?: string | undefined;
412
- projectName?: string | undefined;
413
- siteAddress?: string | undefined;
414
- remodelHints?: Record<string, unknown> | undefined;
415
- baseScopes?: {
416
- label: string;
417
- serviceCode?: string | undefined;
418
- unit?: string | undefined;
419
- notes?: string | undefined;
420
- quantity?: number | undefined;
421
- key?: string | undefined;
422
- budgetLump?: number | undefined;
423
- confidence?: "unknown" | "high" | "medium" | "low" | undefined;
424
- isAlternate?: boolean | undefined;
425
- alternateGroup?: string | undefined;
426
- }[] | undefined;
427
- alternates?: {
428
- label: string;
429
- key: string;
430
- notes?: string | undefined;
431
- scopeKeys?: string[] | undefined;
432
- lumpAdd?: number | undefined;
433
- }[] | undefined;
434
- attachments?: {
435
- id: string;
436
- kind: "photo" | "drawing" | "plan_set" | "spec_pdf" | "spreadsheet" | "other";
437
- caption?: string | undefined;
438
- fileName?: string | undefined;
439
- mimeType?: string | undefined;
440
- url?: string | undefined;
441
- }[] | undefined;
442
- exclusions?: string[] | undefined;
443
- surprises?: string[] | undefined;
444
- rateReferences?: {
445
- value: number;
446
- label: string;
447
- key: string;
448
- source: "operating_rule" | "catalog" | "user" | "takeoff";
449
- unit?: string | undefined;
450
- catalogId?: string | undefined;
451
- confidence?: "unknown" | "high" | "medium" | "low" | undefined;
452
- }[] | undefined;
453
- assumptionsNeedingReview?: {
454
- id: string;
455
- text: string;
456
- severity: "info" | "warn" | "blocker";
457
- relatedScopeKey?: string | undefined;
458
- }[] | undefined;
459
- includeStandardAlternates?: boolean | undefined;
460
- }>;
461
- execute: (args: z.infer<typeof normalizeRemodelIntakeSchema>) => Promise<string>;
462
- };
463
- export {};
@@ -1,82 +0,0 @@
1
- import { z } from "zod";
2
- import * as client from "../lib/kynver-client.js";
3
- const remodelProjectTypeSchema = z.enum([
4
- "kitchen_remodel",
5
- "bath_remodel",
6
- "kitchen_and_bath_remodel",
7
- "whole_home_remodel",
8
- "other_remodel",
9
- ]);
10
- const normalizeRemodelIntakeSchema = z.object({
11
- projectType: remodelProjectTypeSchema,
12
- projectName: z.string().optional(),
13
- siteAddress: z.string().optional(),
14
- baseScopes: z
15
- .array(z.object({
16
- key: z.string().optional(),
17
- label: z.string(),
18
- quantity: z.number().optional(),
19
- unit: z.string().optional(),
20
- serviceCode: z.string().optional(),
21
- budgetLump: z.number().optional(),
22
- notes: z.string().optional(),
23
- confidence: z.enum(["high", "medium", "low", "unknown"]).optional(),
24
- isAlternate: z.boolean().optional(),
25
- alternateGroup: z.string().optional(),
26
- }))
27
- .optional(),
28
- alternates: z
29
- .array(z.object({
30
- key: z.string(),
31
- label: z.string(),
32
- scopeKeys: z.array(z.string()).optional(),
33
- lumpAdd: z.number().optional(),
34
- notes: z.string().optional(),
35
- }))
36
- .optional(),
37
- attachments: z
38
- .array(z.object({
39
- id: z.string(),
40
- kind: z.enum(["photo", "drawing", "plan_set", "spec_pdf", "spreadsheet", "other"]),
41
- fileName: z.string().optional(),
42
- caption: z.string().optional(),
43
- url: z.string().optional(),
44
- mimeType: z.string().optional(),
45
- }))
46
- .optional(),
47
- exclusions: z.array(z.string()).optional(),
48
- surprises: z.array(z.string()).optional(),
49
- rateReferences: z
50
- .array(z.object({
51
- key: z.string(),
52
- label: z.string(),
53
- value: z.number(),
54
- unit: z.string().optional(),
55
- source: z.enum(["operating_rule", "catalog", "user", "takeoff"]),
56
- catalogId: z.string().optional(),
57
- confidence: z.enum(["high", "medium", "low", "unknown"]).optional(),
58
- }))
59
- .optional(),
60
- assumptionsNeedingReview: z
61
- .array(z.object({
62
- id: z.string(),
63
- text: z.string(),
64
- severity: z.enum(["info", "warn", "blocker"]),
65
- relatedScopeKey: z.string().optional(),
66
- }))
67
- .optional(),
68
- remodelHints: z.record(z.string(), z.unknown()).optional(),
69
- includeStandardAlternates: z.boolean().optional(),
70
- notes: z.string().optional(),
71
- });
72
- export const normalizeRemodelIntake = {
73
- name: "estimator_normalize_remodel_intake",
74
- description: "Validate and normalize a residential remodel intake payload for kitchen/bath estimating. Accepts project type, base scopes vs alternates, drawing/photo attachment metadata, exclusions/surprises, rate references, and optional remodelHints from takeoff. Returns provenance-backed scopes, Will Portland default rates, assumptions needing review, and an estimate-builder-ready payload.",
75
- inputSchemaZod: normalizeRemodelIntakeSchema,
76
- execute: async (args) => {
77
- if (!client.hasApiKey())
78
- return client.noApiKeyMessage();
79
- const data = await client.post("/estimator/intake/normalize-remodel", args);
80
- return JSON.stringify(data, null, 2);
81
- },
82
- };
@@ -1,77 +0,0 @@
1
- import { z } from "zod";
2
- declare const uploadPhotoSchema: z.ZodObject<{
3
- estimateId: z.ZodString;
4
- imageUrl: z.ZodString;
5
- caption: z.ZodOptional<z.ZodString>;
6
- }, "strip", z.ZodTypeAny, {
7
- estimateId: string;
8
- imageUrl: string;
9
- caption?: string | undefined;
10
- }, {
11
- estimateId: string;
12
- imageUrl: string;
13
- caption?: string | undefined;
14
- }>;
15
- export declare const uploadPhoto: {
16
- name: string;
17
- description: string;
18
- inputSchemaZod: z.ZodObject<{
19
- estimateId: z.ZodString;
20
- imageUrl: z.ZodString;
21
- caption: z.ZodOptional<z.ZodString>;
22
- }, "strip", z.ZodTypeAny, {
23
- estimateId: string;
24
- imageUrl: string;
25
- caption?: string | undefined;
26
- }, {
27
- estimateId: string;
28
- imageUrl: string;
29
- caption?: string | undefined;
30
- }>;
31
- execute: (args: z.infer<typeof uploadPhotoSchema>) => Promise<string>;
32
- };
33
- declare const listPhotosSchema: z.ZodObject<{
34
- estimateId: z.ZodString;
35
- }, "strip", z.ZodTypeAny, {
36
- estimateId: string;
37
- }, {
38
- estimateId: string;
39
- }>;
40
- export declare const listPhotos: {
41
- name: string;
42
- description: string;
43
- inputSchemaZod: z.ZodObject<{
44
- estimateId: z.ZodString;
45
- }, "strip", z.ZodTypeAny, {
46
- estimateId: string;
47
- }, {
48
- estimateId: string;
49
- }>;
50
- execute: (args: z.infer<typeof listPhotosSchema>) => Promise<string>;
51
- };
52
- declare const deletePhotoSchema: z.ZodObject<{
53
- estimateId: z.ZodString;
54
- photoId: z.ZodString;
55
- }, "strip", z.ZodTypeAny, {
56
- estimateId: string;
57
- photoId: string;
58
- }, {
59
- estimateId: string;
60
- photoId: string;
61
- }>;
62
- export declare const deletePhoto: {
63
- name: string;
64
- description: string;
65
- inputSchemaZod: z.ZodObject<{
66
- estimateId: z.ZodString;
67
- photoId: z.ZodString;
68
- }, "strip", z.ZodTypeAny, {
69
- estimateId: string;
70
- photoId: string;
71
- }, {
72
- estimateId: string;
73
- photoId: string;
74
- }>;
75
- execute: (args: z.infer<typeof deletePhotoSchema>) => Promise<string>;
76
- };
77
- export {};
@@ -1,51 +0,0 @@
1
- import { z } from "zod";
2
- import * as client from "../lib/kynver-client.js";
3
- // --- estimator_upload_photo ---
4
- const uploadPhotoSchema = z.object({
5
- estimateId: z.string(),
6
- imageUrl: z.string(),
7
- caption: z.string().optional(),
8
- });
9
- export const uploadPhoto = {
10
- name: "estimator_upload_photo",
11
- description: "Attach a photo to an estimate by URL. The photo is downloaded and stored. Include a caption to describe what the photo shows (e.g., 'North-facing roof slope showing damaged shingles'). Photos can be included in PDF exports and analyzed with estimator_analyze_photos.",
12
- inputSchemaZod: uploadPhotoSchema,
13
- execute: async (args) => {
14
- if (!client.hasApiKey())
15
- return client.noApiKeyMessage();
16
- const { estimateId, ...body } = args;
17
- const data = await client.post(`/estimator/estimates/${estimateId}/photos`, body);
18
- return JSON.stringify(data);
19
- },
20
- };
21
- // --- estimator_list_photos ---
22
- const listPhotosSchema = z.object({
23
- estimateId: z.string(),
24
- });
25
- export const listPhotos = {
26
- name: "estimator_list_photos",
27
- description: "List all photos attached to an estimate. Returns photo IDs, URLs, captions, and sort order. Use photo IDs when deleting photos or configuring PDF output.",
28
- inputSchemaZod: listPhotosSchema,
29
- execute: async (args) => {
30
- if (!client.hasApiKey())
31
- return client.noApiKeyMessage();
32
- const data = await client.get(`/estimator/estimates/${args.estimateId}/photos`);
33
- return JSON.stringify(data);
34
- },
35
- };
36
- // --- estimator_delete_photo ---
37
- const deletePhotoSchema = z.object({
38
- estimateId: z.string(),
39
- photoId: z.string(),
40
- });
41
- export const deletePhoto = {
42
- name: "estimator_delete_photo",
43
- description: "Remove a photo from an estimate. Requires estimateId and photoId (get IDs from estimator_list_photos).",
44
- inputSchemaZod: deletePhotoSchema,
45
- execute: async (args) => {
46
- if (!client.hasApiKey())
47
- return client.noApiKeyMessage();
48
- const data = await client.del(`/estimator/estimates/${args.estimateId}/photos/${args.photoId}`);
49
- return JSON.stringify(data);
50
- },
51
- };