@deepintel-ltd/farmpro-contracts 1.3.1 → 1.3.4
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/index.d.ts +7 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +10 -1
- package/dist/routes/admin.routes.d.ts +747 -0
- package/dist/routes/admin.routes.d.ts.map +1 -0
- package/dist/routes/admin.routes.js +26 -0
- package/dist/routes/agent-workflows.routes.d.ts +2900 -0
- package/dist/routes/agent-workflows.routes.d.ts.map +1 -0
- package/dist/routes/agent-workflows.routes.js +160 -0
- package/dist/routes/documents.routes.d.ts +417 -0
- package/dist/routes/documents.routes.d.ts.map +1 -1
- package/dist/routes/documents.routes.js +16 -0
- package/dist/routes/field-monitoring.routes.d.ts +568 -23
- package/dist/routes/field-monitoring.routes.d.ts.map +1 -1
- package/dist/routes/field-monitoring.routes.js +64 -0
- package/dist/routes/field-observations.routes.d.ts +130 -58
- package/dist/routes/field-observations.routes.d.ts.map +1 -1
- package/dist/routes/health.routes.d.ts +317 -0
- package/dist/routes/health.routes.d.ts.map +1 -0
- package/dist/routes/health.routes.js +18 -0
- package/dist/routes/index.d.ts +9 -0
- package/dist/routes/index.d.ts.map +1 -1
- package/dist/routes/index.js +6 -0
- package/dist/routes/tasks.routes.d.ts +408 -0
- package/dist/routes/tasks.routes.d.ts.map +1 -1
- package/dist/routes/weather.routes.d.ts +264 -17
- package/dist/routes/weather.routes.d.ts.map +1 -1
- package/dist/schemas/admin.schemas.d.ts +1063 -0
- package/dist/schemas/admin.schemas.d.ts.map +1 -0
- package/dist/schemas/admin.schemas.js +63 -0
- package/dist/schemas/agent-workflows.schemas.d.ts +2399 -0
- package/dist/schemas/agent-workflows.schemas.d.ts.map +1 -0
- package/dist/schemas/agent-workflows.schemas.js +70 -0
- package/dist/schemas/documents.schemas.d.ts +202 -0
- package/dist/schemas/documents.schemas.d.ts.map +1 -1
- package/dist/schemas/documents.schemas.js +10 -1
- package/dist/schemas/field-monitoring.schemas.d.ts +215 -9
- package/dist/schemas/field-monitoring.schemas.d.ts.map +1 -1
- package/dist/schemas/field-monitoring.schemas.js +26 -2
- package/dist/schemas/field-observations.schemas.d.ts +100 -40
- package/dist/schemas/field-observations.schemas.d.ts.map +1 -1
- package/dist/schemas/field-observations.schemas.js +2 -24
- package/dist/schemas/health.schemas.d.ts +176 -0
- package/dist/schemas/health.schemas.d.ts.map +1 -0
- package/dist/schemas/health.schemas.js +26 -0
- package/dist/schemas/recommendations.schemas.d.ts +112 -0
- package/dist/schemas/recommendations.schemas.d.ts.map +1 -0
- package/dist/schemas/recommendations.schemas.js +32 -0
- package/dist/schemas/tasks.schemas.d.ts +344 -0
- package/dist/schemas/tasks.schemas.d.ts.map +1 -1
- package/dist/schemas/tasks.schemas.js +9 -0
- package/dist/schemas/weather.schemas.d.ts +780 -44
- package/dist/schemas/weather.schemas.d.ts.map +1 -1
- package/dist/schemas/weather.schemas.js +2 -1
- package/package.json +1 -1
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"agent-workflows.routes.d.ts","sourceRoot":"","sources":["../../src/routes/agent-workflows.routes.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AASxB;;;;;;GAMG;AACH,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA+J/B,CAAC"}
|
|
@@ -0,0 +1,160 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.agentWorkflowsRouter = void 0;
|
|
4
|
+
const core_1 = require("@ts-rest/core");
|
|
5
|
+
const zod_1 = require("zod");
|
|
6
|
+
const agent_workflows_schemas_1 = require("../schemas/agent-workflows.schemas");
|
|
7
|
+
const c = (0, core_1.initContract)();
|
|
8
|
+
/**
|
|
9
|
+
* Agent Workflows Routes
|
|
10
|
+
*
|
|
11
|
+
* API endpoints for querying and monitoring autonomous agent workflows.
|
|
12
|
+
* These workflows track the system's automated decision-making process
|
|
13
|
+
* for converting recommendations into tasks.
|
|
14
|
+
*/
|
|
15
|
+
exports.agentWorkflowsRouter = c.router({
|
|
16
|
+
/**
|
|
17
|
+
* List agent workflows with filters
|
|
18
|
+
*/
|
|
19
|
+
listWorkflows: {
|
|
20
|
+
method: 'GET',
|
|
21
|
+
path: '/agent-workflows',
|
|
22
|
+
query: zod_1.z.object({
|
|
23
|
+
farmId: zod_1.z.string().uuid().optional(),
|
|
24
|
+
fieldId: zod_1.z.string().uuid().optional(),
|
|
25
|
+
status: agent_workflows_schemas_1.agentWorkflowStatusSchema.optional(),
|
|
26
|
+
triggerEvent: zod_1.z.string().optional(), // e.g., 'observation.analysis.completed'
|
|
27
|
+
startDate: zod_1.z.string().datetime().optional(),
|
|
28
|
+
endDate: zod_1.z.string().datetime().optional(),
|
|
29
|
+
limit: zod_1.z.number().int().min(1).max(100).default(20),
|
|
30
|
+
offset: zod_1.z.number().int().min(0).default(0),
|
|
31
|
+
}),
|
|
32
|
+
responses: {
|
|
33
|
+
200: agent_workflows_schemas_1.agentWorkflowListResponseSchema,
|
|
34
|
+
400: zod_1.z.object({
|
|
35
|
+
errors: zod_1.z.array(zod_1.z.object({
|
|
36
|
+
status: zod_1.z.string(),
|
|
37
|
+
code: zod_1.z.string(),
|
|
38
|
+
title: zod_1.z.string(),
|
|
39
|
+
detail: zod_1.z.string(),
|
|
40
|
+
})),
|
|
41
|
+
}),
|
|
42
|
+
},
|
|
43
|
+
summary: 'List agent workflows with filters',
|
|
44
|
+
},
|
|
45
|
+
/**
|
|
46
|
+
* Get a specific workflow by ID
|
|
47
|
+
*/
|
|
48
|
+
getWorkflow: {
|
|
49
|
+
method: 'GET',
|
|
50
|
+
path: '/agent-workflows/:id',
|
|
51
|
+
responses: {
|
|
52
|
+
200: agent_workflows_schemas_1.agentWorkflowResponseSchema,
|
|
53
|
+
404: zod_1.z.object({
|
|
54
|
+
errors: zod_1.z.array(zod_1.z.object({
|
|
55
|
+
status: zod_1.z.literal('404'),
|
|
56
|
+
code: zod_1.z.string(),
|
|
57
|
+
title: zod_1.z.string(),
|
|
58
|
+
detail: zod_1.z.string(),
|
|
59
|
+
})),
|
|
60
|
+
}),
|
|
61
|
+
},
|
|
62
|
+
summary: 'Get agent workflow details',
|
|
63
|
+
},
|
|
64
|
+
/**
|
|
65
|
+
* Get workflows for a specific farm
|
|
66
|
+
*/
|
|
67
|
+
getWorkflowsByFarm: {
|
|
68
|
+
method: 'GET',
|
|
69
|
+
path: '/farms/:farmId/agent-workflows',
|
|
70
|
+
query: zod_1.z.object({
|
|
71
|
+
status: agent_workflows_schemas_1.agentWorkflowStatusSchema.optional(),
|
|
72
|
+
limit: zod_1.z.number().int().min(1).max(100).default(20),
|
|
73
|
+
offset: zod_1.z.number().int().min(0).default(0),
|
|
74
|
+
}),
|
|
75
|
+
responses: {
|
|
76
|
+
200: agent_workflows_schemas_1.agentWorkflowListResponseSchema,
|
|
77
|
+
404: zod_1.z.object({
|
|
78
|
+
errors: zod_1.z.array(zod_1.z.object({
|
|
79
|
+
status: zod_1.z.literal('404'),
|
|
80
|
+
code: zod_1.z.string(),
|
|
81
|
+
title: zod_1.z.string(),
|
|
82
|
+
detail: zod_1.z.string(),
|
|
83
|
+
})),
|
|
84
|
+
}),
|
|
85
|
+
},
|
|
86
|
+
summary: 'Get all workflows for a farm',
|
|
87
|
+
},
|
|
88
|
+
/**
|
|
89
|
+
* Get workflows for a specific field
|
|
90
|
+
*/
|
|
91
|
+
getWorkflowsByField: {
|
|
92
|
+
method: 'GET',
|
|
93
|
+
path: '/fields/:fieldId/agent-workflows',
|
|
94
|
+
query: zod_1.z.object({
|
|
95
|
+
status: agent_workflows_schemas_1.agentWorkflowStatusSchema.optional(),
|
|
96
|
+
limit: zod_1.z.number().int().min(1).max(100).default(20),
|
|
97
|
+
offset: zod_1.z.number().int().min(0).default(0),
|
|
98
|
+
}),
|
|
99
|
+
responses: {
|
|
100
|
+
200: agent_workflows_schemas_1.agentWorkflowListResponseSchema,
|
|
101
|
+
404: zod_1.z.object({
|
|
102
|
+
errors: zod_1.z.array(zod_1.z.object({
|
|
103
|
+
status: zod_1.z.literal('404'),
|
|
104
|
+
code: zod_1.z.string(),
|
|
105
|
+
title: zod_1.z.string(),
|
|
106
|
+
detail: zod_1.z.string(),
|
|
107
|
+
})),
|
|
108
|
+
}),
|
|
109
|
+
},
|
|
110
|
+
summary: 'Get all workflows for a field',
|
|
111
|
+
},
|
|
112
|
+
/**
|
|
113
|
+
* Get workflow statistics
|
|
114
|
+
*/
|
|
115
|
+
getWorkflowStats: {
|
|
116
|
+
method: 'GET',
|
|
117
|
+
path: '/agent-workflows/stats',
|
|
118
|
+
query: zod_1.z.object({
|
|
119
|
+
farmId: zod_1.z.string().uuid().optional(),
|
|
120
|
+
startDate: zod_1.z.string().datetime().optional(),
|
|
121
|
+
endDate: zod_1.z.string().datetime().optional(),
|
|
122
|
+
}),
|
|
123
|
+
responses: {
|
|
124
|
+
200: zod_1.z.object({
|
|
125
|
+
data: zod_1.z.object({
|
|
126
|
+
overall: zod_1.z.object({
|
|
127
|
+
totalWorkflows: zod_1.z.number().int(),
|
|
128
|
+
successRate: zod_1.z.number(),
|
|
129
|
+
avgProcessingTime: zod_1.z.number(),
|
|
130
|
+
tasksCreated: zod_1.z.number().int(),
|
|
131
|
+
tasksUpdated: zod_1.z.number().int(),
|
|
132
|
+
skipped: zod_1.z.number().int(),
|
|
133
|
+
}),
|
|
134
|
+
bySource: zod_1.z.record(zod_1.z.object({
|
|
135
|
+
workflows: zod_1.z.number().int(),
|
|
136
|
+
tasksCreated: zod_1.z.number().int(),
|
|
137
|
+
tasksUpdated: zod_1.z.number().int(),
|
|
138
|
+
skipped: zod_1.z.number().int(),
|
|
139
|
+
skipRate: zod_1.z.number(),
|
|
140
|
+
avgConfidence: zod_1.z.number().optional(),
|
|
141
|
+
})),
|
|
142
|
+
deduplication: zod_1.z.object({
|
|
143
|
+
exactMatches: zod_1.z.number().int(),
|
|
144
|
+
semanticMatches: zod_1.z.number().int(),
|
|
145
|
+
categoryMatches: zod_1.z.number().int(),
|
|
146
|
+
crossSourceMatches: zod_1.z.number().int(),
|
|
147
|
+
avgSimilarityScore: zod_1.z.number(),
|
|
148
|
+
}),
|
|
149
|
+
outcomes: zod_1.z.object({
|
|
150
|
+
tasksCompleted: zod_1.z.number().int(),
|
|
151
|
+
tasksPending: zod_1.z.number().int(),
|
|
152
|
+
tasksInProgress: zod_1.z.number().int(),
|
|
153
|
+
completionRate: zod_1.z.number(),
|
|
154
|
+
}),
|
|
155
|
+
}),
|
|
156
|
+
}),
|
|
157
|
+
},
|
|
158
|
+
summary: 'Get agent workflow statistics and analytics',
|
|
159
|
+
},
|
|
160
|
+
});
|
|
@@ -448,6 +448,423 @@ export declare const documentsRouter: {
|
|
|
448
448
|
}>;
|
|
449
449
|
};
|
|
450
450
|
};
|
|
451
|
+
uploadDocumentFile: {
|
|
452
|
+
pathParams: z.ZodObject<{
|
|
453
|
+
farmId: z.ZodString;
|
|
454
|
+
}, "strip", z.ZodTypeAny, {
|
|
455
|
+
farmId: string;
|
|
456
|
+
}, {
|
|
457
|
+
farmId: string;
|
|
458
|
+
}>;
|
|
459
|
+
summary: "Upload document file";
|
|
460
|
+
description: "Upload a file and get back the file URL in JSON:API format";
|
|
461
|
+
method: "POST";
|
|
462
|
+
contentType: "multipart/form-data";
|
|
463
|
+
body: import("@ts-rest/core").ContractPlainType<{
|
|
464
|
+
file: File;
|
|
465
|
+
}>;
|
|
466
|
+
path: "/farms/:farmId/documents/upload";
|
|
467
|
+
responses: {
|
|
468
|
+
200: z.ZodObject<{
|
|
469
|
+
data: z.ZodObject<{
|
|
470
|
+
type: z.ZodLiteral<string>;
|
|
471
|
+
id: z.ZodString;
|
|
472
|
+
attributes: z.ZodObject<{
|
|
473
|
+
fileUrl: z.ZodString;
|
|
474
|
+
fileSize: z.ZodNumber;
|
|
475
|
+
fileName: z.ZodString;
|
|
476
|
+
contentType: z.ZodOptional<z.ZodString>;
|
|
477
|
+
uploadedAt: z.ZodString;
|
|
478
|
+
}, "strip", z.ZodTypeAny, {
|
|
479
|
+
fileUrl: string;
|
|
480
|
+
fileSize: number;
|
|
481
|
+
fileName: string;
|
|
482
|
+
uploadedAt: string;
|
|
483
|
+
contentType?: string | undefined;
|
|
484
|
+
}, {
|
|
485
|
+
fileUrl: string;
|
|
486
|
+
fileSize: number;
|
|
487
|
+
fileName: string;
|
|
488
|
+
uploadedAt: string;
|
|
489
|
+
contentType?: string | undefined;
|
|
490
|
+
}>;
|
|
491
|
+
relationships: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
492
|
+
links: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
493
|
+
meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
494
|
+
}, "strip", z.ZodTypeAny, {
|
|
495
|
+
type: string;
|
|
496
|
+
id: string;
|
|
497
|
+
attributes: {
|
|
498
|
+
fileUrl: string;
|
|
499
|
+
fileSize: number;
|
|
500
|
+
fileName: string;
|
|
501
|
+
uploadedAt: string;
|
|
502
|
+
contentType?: string | undefined;
|
|
503
|
+
};
|
|
504
|
+
relationships?: Record<string, unknown> | undefined;
|
|
505
|
+
links?: Record<string, string> | undefined;
|
|
506
|
+
meta?: Record<string, unknown> | undefined;
|
|
507
|
+
}, {
|
|
508
|
+
type: string;
|
|
509
|
+
id: string;
|
|
510
|
+
attributes: {
|
|
511
|
+
fileUrl: string;
|
|
512
|
+
fileSize: number;
|
|
513
|
+
fileName: string;
|
|
514
|
+
uploadedAt: string;
|
|
515
|
+
contentType?: string | undefined;
|
|
516
|
+
};
|
|
517
|
+
relationships?: Record<string, unknown> | undefined;
|
|
518
|
+
links?: Record<string, string> | undefined;
|
|
519
|
+
meta?: Record<string, unknown> | undefined;
|
|
520
|
+
}>;
|
|
521
|
+
included: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
522
|
+
type: z.ZodString;
|
|
523
|
+
id: z.ZodString;
|
|
524
|
+
attributes: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
525
|
+
relationships: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
526
|
+
links: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
527
|
+
meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
528
|
+
}, "strip", z.ZodTypeAny, {
|
|
529
|
+
type: string;
|
|
530
|
+
id: string;
|
|
531
|
+
attributes?: Record<string, unknown> | undefined;
|
|
532
|
+
relationships?: Record<string, unknown> | undefined;
|
|
533
|
+
links?: Record<string, string> | undefined;
|
|
534
|
+
meta?: Record<string, unknown> | undefined;
|
|
535
|
+
}, {
|
|
536
|
+
type: string;
|
|
537
|
+
id: string;
|
|
538
|
+
attributes?: Record<string, unknown> | undefined;
|
|
539
|
+
relationships?: Record<string, unknown> | undefined;
|
|
540
|
+
links?: Record<string, string> | undefined;
|
|
541
|
+
meta?: Record<string, unknown> | undefined;
|
|
542
|
+
}>, "many">>;
|
|
543
|
+
meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
544
|
+
links: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
545
|
+
}, "strip", z.ZodTypeAny, {
|
|
546
|
+
data: {
|
|
547
|
+
type: string;
|
|
548
|
+
id: string;
|
|
549
|
+
attributes: {
|
|
550
|
+
fileUrl: string;
|
|
551
|
+
fileSize: number;
|
|
552
|
+
fileName: string;
|
|
553
|
+
uploadedAt: string;
|
|
554
|
+
contentType?: string | undefined;
|
|
555
|
+
};
|
|
556
|
+
relationships?: Record<string, unknown> | undefined;
|
|
557
|
+
links?: Record<string, string> | undefined;
|
|
558
|
+
meta?: Record<string, unknown> | undefined;
|
|
559
|
+
};
|
|
560
|
+
links?: Record<string, string> | undefined;
|
|
561
|
+
meta?: Record<string, unknown> | undefined;
|
|
562
|
+
included?: {
|
|
563
|
+
type: string;
|
|
564
|
+
id: string;
|
|
565
|
+
attributes?: Record<string, unknown> | undefined;
|
|
566
|
+
relationships?: Record<string, unknown> | undefined;
|
|
567
|
+
links?: Record<string, string> | undefined;
|
|
568
|
+
meta?: Record<string, unknown> | undefined;
|
|
569
|
+
}[] | undefined;
|
|
570
|
+
}, {
|
|
571
|
+
data: {
|
|
572
|
+
type: string;
|
|
573
|
+
id: string;
|
|
574
|
+
attributes: {
|
|
575
|
+
fileUrl: string;
|
|
576
|
+
fileSize: number;
|
|
577
|
+
fileName: string;
|
|
578
|
+
uploadedAt: string;
|
|
579
|
+
contentType?: string | undefined;
|
|
580
|
+
};
|
|
581
|
+
relationships?: Record<string, unknown> | undefined;
|
|
582
|
+
links?: Record<string, string> | undefined;
|
|
583
|
+
meta?: Record<string, unknown> | undefined;
|
|
584
|
+
};
|
|
585
|
+
links?: Record<string, string> | undefined;
|
|
586
|
+
meta?: Record<string, unknown> | undefined;
|
|
587
|
+
included?: {
|
|
588
|
+
type: string;
|
|
589
|
+
id: string;
|
|
590
|
+
attributes?: Record<string, unknown> | undefined;
|
|
591
|
+
relationships?: Record<string, unknown> | undefined;
|
|
592
|
+
links?: Record<string, string> | undefined;
|
|
593
|
+
meta?: Record<string, unknown> | undefined;
|
|
594
|
+
}[] | undefined;
|
|
595
|
+
}>;
|
|
596
|
+
400: z.ZodObject<{
|
|
597
|
+
errors: z.ZodArray<z.ZodObject<{
|
|
598
|
+
id: z.ZodOptional<z.ZodString>;
|
|
599
|
+
links: z.ZodOptional<z.ZodObject<{
|
|
600
|
+
about: z.ZodOptional<z.ZodString>;
|
|
601
|
+
}, "strip", z.ZodTypeAny, {
|
|
602
|
+
about?: string | undefined;
|
|
603
|
+
}, {
|
|
604
|
+
about?: string | undefined;
|
|
605
|
+
}>>;
|
|
606
|
+
status: z.ZodOptional<z.ZodString>;
|
|
607
|
+
code: z.ZodOptional<z.ZodString>;
|
|
608
|
+
title: z.ZodOptional<z.ZodString>;
|
|
609
|
+
detail: z.ZodOptional<z.ZodString>;
|
|
610
|
+
source: z.ZodOptional<z.ZodObject<{
|
|
611
|
+
pointer: z.ZodOptional<z.ZodString>;
|
|
612
|
+
parameter: z.ZodOptional<z.ZodString>;
|
|
613
|
+
}, "strip", z.ZodTypeAny, {
|
|
614
|
+
pointer?: string | undefined;
|
|
615
|
+
parameter?: string | undefined;
|
|
616
|
+
}, {
|
|
617
|
+
pointer?: string | undefined;
|
|
618
|
+
parameter?: string | undefined;
|
|
619
|
+
}>>;
|
|
620
|
+
meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
621
|
+
}, "strip", z.ZodTypeAny, {
|
|
622
|
+
status?: string | undefined;
|
|
623
|
+
code?: string | undefined;
|
|
624
|
+
id?: string | undefined;
|
|
625
|
+
links?: {
|
|
626
|
+
about?: string | undefined;
|
|
627
|
+
} | undefined;
|
|
628
|
+
meta?: Record<string, unknown> | undefined;
|
|
629
|
+
title?: string | undefined;
|
|
630
|
+
detail?: string | undefined;
|
|
631
|
+
source?: {
|
|
632
|
+
pointer?: string | undefined;
|
|
633
|
+
parameter?: string | undefined;
|
|
634
|
+
} | undefined;
|
|
635
|
+
}, {
|
|
636
|
+
status?: string | undefined;
|
|
637
|
+
code?: string | undefined;
|
|
638
|
+
id?: string | undefined;
|
|
639
|
+
links?: {
|
|
640
|
+
about?: string | undefined;
|
|
641
|
+
} | undefined;
|
|
642
|
+
meta?: Record<string, unknown> | undefined;
|
|
643
|
+
title?: string | undefined;
|
|
644
|
+
detail?: string | undefined;
|
|
645
|
+
source?: {
|
|
646
|
+
pointer?: string | undefined;
|
|
647
|
+
parameter?: string | undefined;
|
|
648
|
+
} | undefined;
|
|
649
|
+
}>, "many">;
|
|
650
|
+
meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
651
|
+
}, "strip", z.ZodTypeAny, {
|
|
652
|
+
errors: {
|
|
653
|
+
status?: string | undefined;
|
|
654
|
+
code?: string | undefined;
|
|
655
|
+
id?: string | undefined;
|
|
656
|
+
links?: {
|
|
657
|
+
about?: string | undefined;
|
|
658
|
+
} | undefined;
|
|
659
|
+
meta?: Record<string, unknown> | undefined;
|
|
660
|
+
title?: string | undefined;
|
|
661
|
+
detail?: string | undefined;
|
|
662
|
+
source?: {
|
|
663
|
+
pointer?: string | undefined;
|
|
664
|
+
parameter?: string | undefined;
|
|
665
|
+
} | undefined;
|
|
666
|
+
}[];
|
|
667
|
+
meta?: Record<string, unknown> | undefined;
|
|
668
|
+
}, {
|
|
669
|
+
errors: {
|
|
670
|
+
status?: string | undefined;
|
|
671
|
+
code?: string | undefined;
|
|
672
|
+
id?: string | undefined;
|
|
673
|
+
links?: {
|
|
674
|
+
about?: string | undefined;
|
|
675
|
+
} | undefined;
|
|
676
|
+
meta?: Record<string, unknown> | undefined;
|
|
677
|
+
title?: string | undefined;
|
|
678
|
+
detail?: string | undefined;
|
|
679
|
+
source?: {
|
|
680
|
+
pointer?: string | undefined;
|
|
681
|
+
parameter?: string | undefined;
|
|
682
|
+
} | undefined;
|
|
683
|
+
}[];
|
|
684
|
+
meta?: Record<string, unknown> | undefined;
|
|
685
|
+
}>;
|
|
686
|
+
404: z.ZodObject<{
|
|
687
|
+
errors: z.ZodArray<z.ZodObject<{
|
|
688
|
+
id: z.ZodOptional<z.ZodString>;
|
|
689
|
+
links: z.ZodOptional<z.ZodObject<{
|
|
690
|
+
about: z.ZodOptional<z.ZodString>;
|
|
691
|
+
}, "strip", z.ZodTypeAny, {
|
|
692
|
+
about?: string | undefined;
|
|
693
|
+
}, {
|
|
694
|
+
about?: string | undefined;
|
|
695
|
+
}>>;
|
|
696
|
+
status: z.ZodOptional<z.ZodString>;
|
|
697
|
+
code: z.ZodOptional<z.ZodString>;
|
|
698
|
+
title: z.ZodOptional<z.ZodString>;
|
|
699
|
+
detail: z.ZodOptional<z.ZodString>;
|
|
700
|
+
source: z.ZodOptional<z.ZodObject<{
|
|
701
|
+
pointer: z.ZodOptional<z.ZodString>;
|
|
702
|
+
parameter: z.ZodOptional<z.ZodString>;
|
|
703
|
+
}, "strip", z.ZodTypeAny, {
|
|
704
|
+
pointer?: string | undefined;
|
|
705
|
+
parameter?: string | undefined;
|
|
706
|
+
}, {
|
|
707
|
+
pointer?: string | undefined;
|
|
708
|
+
parameter?: string | undefined;
|
|
709
|
+
}>>;
|
|
710
|
+
meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
711
|
+
}, "strip", z.ZodTypeAny, {
|
|
712
|
+
status?: string | undefined;
|
|
713
|
+
code?: string | undefined;
|
|
714
|
+
id?: string | undefined;
|
|
715
|
+
links?: {
|
|
716
|
+
about?: string | undefined;
|
|
717
|
+
} | undefined;
|
|
718
|
+
meta?: Record<string, unknown> | undefined;
|
|
719
|
+
title?: string | undefined;
|
|
720
|
+
detail?: string | undefined;
|
|
721
|
+
source?: {
|
|
722
|
+
pointer?: string | undefined;
|
|
723
|
+
parameter?: string | undefined;
|
|
724
|
+
} | undefined;
|
|
725
|
+
}, {
|
|
726
|
+
status?: string | undefined;
|
|
727
|
+
code?: string | undefined;
|
|
728
|
+
id?: string | undefined;
|
|
729
|
+
links?: {
|
|
730
|
+
about?: string | undefined;
|
|
731
|
+
} | undefined;
|
|
732
|
+
meta?: Record<string, unknown> | undefined;
|
|
733
|
+
title?: string | undefined;
|
|
734
|
+
detail?: string | undefined;
|
|
735
|
+
source?: {
|
|
736
|
+
pointer?: string | undefined;
|
|
737
|
+
parameter?: string | undefined;
|
|
738
|
+
} | undefined;
|
|
739
|
+
}>, "many">;
|
|
740
|
+
meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
741
|
+
}, "strip", z.ZodTypeAny, {
|
|
742
|
+
errors: {
|
|
743
|
+
status?: string | undefined;
|
|
744
|
+
code?: string | undefined;
|
|
745
|
+
id?: string | undefined;
|
|
746
|
+
links?: {
|
|
747
|
+
about?: string | undefined;
|
|
748
|
+
} | undefined;
|
|
749
|
+
meta?: Record<string, unknown> | undefined;
|
|
750
|
+
title?: string | undefined;
|
|
751
|
+
detail?: string | undefined;
|
|
752
|
+
source?: {
|
|
753
|
+
pointer?: string | undefined;
|
|
754
|
+
parameter?: string | undefined;
|
|
755
|
+
} | undefined;
|
|
756
|
+
}[];
|
|
757
|
+
meta?: Record<string, unknown> | undefined;
|
|
758
|
+
}, {
|
|
759
|
+
errors: {
|
|
760
|
+
status?: string | undefined;
|
|
761
|
+
code?: string | undefined;
|
|
762
|
+
id?: string | undefined;
|
|
763
|
+
links?: {
|
|
764
|
+
about?: string | undefined;
|
|
765
|
+
} | undefined;
|
|
766
|
+
meta?: Record<string, unknown> | undefined;
|
|
767
|
+
title?: string | undefined;
|
|
768
|
+
detail?: string | undefined;
|
|
769
|
+
source?: {
|
|
770
|
+
pointer?: string | undefined;
|
|
771
|
+
parameter?: string | undefined;
|
|
772
|
+
} | undefined;
|
|
773
|
+
}[];
|
|
774
|
+
meta?: Record<string, unknown> | undefined;
|
|
775
|
+
}>;
|
|
776
|
+
401: z.ZodObject<{
|
|
777
|
+
errors: z.ZodArray<z.ZodObject<{
|
|
778
|
+
id: z.ZodOptional<z.ZodString>;
|
|
779
|
+
links: z.ZodOptional<z.ZodObject<{
|
|
780
|
+
about: z.ZodOptional<z.ZodString>;
|
|
781
|
+
}, "strip", z.ZodTypeAny, {
|
|
782
|
+
about?: string | undefined;
|
|
783
|
+
}, {
|
|
784
|
+
about?: string | undefined;
|
|
785
|
+
}>>;
|
|
786
|
+
status: z.ZodOptional<z.ZodString>;
|
|
787
|
+
code: z.ZodOptional<z.ZodString>;
|
|
788
|
+
title: z.ZodOptional<z.ZodString>;
|
|
789
|
+
detail: z.ZodOptional<z.ZodString>;
|
|
790
|
+
source: z.ZodOptional<z.ZodObject<{
|
|
791
|
+
pointer: z.ZodOptional<z.ZodString>;
|
|
792
|
+
parameter: z.ZodOptional<z.ZodString>;
|
|
793
|
+
}, "strip", z.ZodTypeAny, {
|
|
794
|
+
pointer?: string | undefined;
|
|
795
|
+
parameter?: string | undefined;
|
|
796
|
+
}, {
|
|
797
|
+
pointer?: string | undefined;
|
|
798
|
+
parameter?: string | undefined;
|
|
799
|
+
}>>;
|
|
800
|
+
meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
801
|
+
}, "strip", z.ZodTypeAny, {
|
|
802
|
+
status?: string | undefined;
|
|
803
|
+
code?: string | undefined;
|
|
804
|
+
id?: string | undefined;
|
|
805
|
+
links?: {
|
|
806
|
+
about?: string | undefined;
|
|
807
|
+
} | undefined;
|
|
808
|
+
meta?: Record<string, unknown> | undefined;
|
|
809
|
+
title?: string | undefined;
|
|
810
|
+
detail?: string | undefined;
|
|
811
|
+
source?: {
|
|
812
|
+
pointer?: string | undefined;
|
|
813
|
+
parameter?: string | undefined;
|
|
814
|
+
} | undefined;
|
|
815
|
+
}, {
|
|
816
|
+
status?: string | undefined;
|
|
817
|
+
code?: string | undefined;
|
|
818
|
+
id?: string | undefined;
|
|
819
|
+
links?: {
|
|
820
|
+
about?: string | undefined;
|
|
821
|
+
} | undefined;
|
|
822
|
+
meta?: Record<string, unknown> | undefined;
|
|
823
|
+
title?: string | undefined;
|
|
824
|
+
detail?: string | undefined;
|
|
825
|
+
source?: {
|
|
826
|
+
pointer?: string | undefined;
|
|
827
|
+
parameter?: string | undefined;
|
|
828
|
+
} | undefined;
|
|
829
|
+
}>, "many">;
|
|
830
|
+
meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
831
|
+
}, "strip", z.ZodTypeAny, {
|
|
832
|
+
errors: {
|
|
833
|
+
status?: string | undefined;
|
|
834
|
+
code?: string | undefined;
|
|
835
|
+
id?: string | undefined;
|
|
836
|
+
links?: {
|
|
837
|
+
about?: string | undefined;
|
|
838
|
+
} | undefined;
|
|
839
|
+
meta?: Record<string, unknown> | undefined;
|
|
840
|
+
title?: string | undefined;
|
|
841
|
+
detail?: string | undefined;
|
|
842
|
+
source?: {
|
|
843
|
+
pointer?: string | undefined;
|
|
844
|
+
parameter?: string | undefined;
|
|
845
|
+
} | undefined;
|
|
846
|
+
}[];
|
|
847
|
+
meta?: Record<string, unknown> | undefined;
|
|
848
|
+
}, {
|
|
849
|
+
errors: {
|
|
850
|
+
status?: string | undefined;
|
|
851
|
+
code?: string | undefined;
|
|
852
|
+
id?: string | undefined;
|
|
853
|
+
links?: {
|
|
854
|
+
about?: string | undefined;
|
|
855
|
+
} | undefined;
|
|
856
|
+
meta?: Record<string, unknown> | undefined;
|
|
857
|
+
title?: string | undefined;
|
|
858
|
+
detail?: string | undefined;
|
|
859
|
+
source?: {
|
|
860
|
+
pointer?: string | undefined;
|
|
861
|
+
parameter?: string | undefined;
|
|
862
|
+
} | undefined;
|
|
863
|
+
}[];
|
|
864
|
+
meta?: Record<string, unknown> | undefined;
|
|
865
|
+
}>;
|
|
866
|
+
};
|
|
867
|
+
};
|
|
451
868
|
createDocument: {
|
|
452
869
|
pathParams: z.ZodObject<{
|
|
453
870
|
farmId: z.ZodString;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"documents.routes.d.ts","sourceRoot":"","sources":["../../src/routes/documents.routes.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;
|
|
1
|
+
{"version":3,"file":"documents.routes.d.ts","sourceRoot":"","sources":["../../src/routes/documents.routes.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAqBxB,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CAkF3B,CAAC"}
|
|
@@ -29,6 +29,22 @@ exports.documentsRouter = c.router({
|
|
|
29
29
|
summary: 'List documents',
|
|
30
30
|
description: 'Get all documents for a farm with optional filtering',
|
|
31
31
|
},
|
|
32
|
+
// Upload document file
|
|
33
|
+
uploadDocumentFile: {
|
|
34
|
+
method: 'POST',
|
|
35
|
+
path: '/farms/:farmId/documents/upload',
|
|
36
|
+
contentType: 'multipart/form-data',
|
|
37
|
+
pathParams: zod_1.z.object({ farmId: zod_1.z.string().uuid() }),
|
|
38
|
+
body: c.type(),
|
|
39
|
+
responses: {
|
|
40
|
+
200: documents_schemas_1.uploadedFileResponseSchema,
|
|
41
|
+
400: common_schemas_1.jsonApiErrorResponseSchema,
|
|
42
|
+
404: common_schemas_1.jsonApiErrorResponseSchema,
|
|
43
|
+
401: common_schemas_1.jsonApiErrorResponseSchema,
|
|
44
|
+
},
|
|
45
|
+
summary: 'Upload document file',
|
|
46
|
+
description: 'Upload a file and get back the file URL in JSON:API format',
|
|
47
|
+
},
|
|
32
48
|
// Create document
|
|
33
49
|
createDocument: {
|
|
34
50
|
method: 'POST',
|