@deepintel-ltd/farmpro-contracts 1.0.1 → 1.0.3

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 (100) hide show
  1. package/dist/index.d.ts +41 -0
  2. package/dist/index.d.ts.map +1 -0
  3. package/dist/index.js +81 -0
  4. package/dist/routes/analytics.routes.d.ts +754 -0
  5. package/dist/routes/analytics.routes.d.ts.map +1 -0
  6. package/dist/routes/analytics.routes.js +24 -0
  7. package/dist/routes/auth.routes.d.ts +3836 -0
  8. package/dist/routes/auth.routes.d.ts.map +1 -0
  9. package/dist/routes/auth.routes.js +158 -0
  10. package/dist/routes/documents.routes.d.ts +2476 -0
  11. package/dist/routes/documents.routes.d.ts.map +1 -0
  12. package/dist/routes/documents.routes.js +100 -0
  13. package/dist/routes/equipment.routes.d.ts +3617 -0
  14. package/dist/routes/equipment.routes.d.ts.map +1 -0
  15. package/dist/routes/equipment.routes.js +118 -0
  16. package/dist/routes/farms.routes.d.ts +2202 -0
  17. package/dist/routes/farms.routes.d.ts.map +1 -0
  18. package/dist/routes/farms.routes.js +111 -0
  19. package/dist/routes/fields.routes.d.ts +3389 -0
  20. package/dist/routes/fields.routes.d.ts.map +1 -0
  21. package/dist/routes/fields.routes.js +95 -0
  22. package/dist/routes/finance.routes.d.ts +6855 -0
  23. package/dist/routes/finance.routes.d.ts.map +1 -0
  24. package/dist/routes/finance.routes.js +259 -0
  25. package/dist/routes/harvest.routes.d.ts +2337 -0
  26. package/dist/routes/harvest.routes.d.ts.map +1 -0
  27. package/dist/routes/harvest.routes.js +99 -0
  28. package/dist/routes/index.d.ts +68 -0
  29. package/dist/routes/index.d.ts.map +1 -0
  30. package/dist/routes/index.js +43 -0
  31. package/dist/routes/inventory.routes.d.ts +2853 -0
  32. package/dist/routes/inventory.routes.d.ts.map +1 -0
  33. package/dist/routes/inventory.routes.js +121 -0
  34. package/dist/routes/soil-tests.routes.d.ts +3005 -0
  35. package/dist/routes/soil-tests.routes.d.ts.map +1 -0
  36. package/dist/routes/soil-tests.routes.js +98 -0
  37. package/dist/routes/suppliers.routes.d.ts +4190 -0
  38. package/dist/routes/suppliers.routes.d.ts.map +1 -0
  39. package/dist/routes/suppliers.routes.js +146 -0
  40. package/dist/routes/tasks.routes.d.ts +4192 -0
  41. package/dist/routes/tasks.routes.d.ts.map +1 -0
  42. package/dist/routes/tasks.routes.js +138 -0
  43. package/dist/routes/team.routes.d.ts +2210 -0
  44. package/dist/routes/team.routes.d.ts.map +1 -0
  45. package/dist/routes/team.routes.js +98 -0
  46. package/dist/routes/users.routes.d.ts +721 -0
  47. package/dist/routes/users.routes.d.ts.map +1 -0
  48. package/dist/routes/users.routes.js +35 -0
  49. package/dist/routes/weather.routes.d.ts +500 -0
  50. package/dist/routes/weather.routes.d.ts.map +1 -0
  51. package/dist/routes/weather.routes.js +23 -0
  52. package/dist/schemas/analytics.schemas.d.ts +1344 -0
  53. package/dist/schemas/analytics.schemas.d.ts.map +1 -0
  54. package/dist/schemas/analytics.schemas.js +73 -0
  55. package/dist/schemas/auth.schemas.d.ts +1093 -0
  56. package/dist/schemas/auth.schemas.d.ts.map +1 -0
  57. package/dist/schemas/auth.schemas.js +159 -0
  58. package/dist/schemas/common.schemas.d.ts +562 -0
  59. package/dist/schemas/common.schemas.d.ts.map +1 -0
  60. package/dist/schemas/common.schemas.js +122 -0
  61. package/dist/schemas/documents.schemas.d.ts +850 -0
  62. package/dist/schemas/documents.schemas.d.ts.map +1 -0
  63. package/dist/schemas/documents.schemas.js +75 -0
  64. package/dist/schemas/equipment.schemas.d.ts +1618 -0
  65. package/dist/schemas/equipment.schemas.d.ts.map +1 -0
  66. package/dist/schemas/equipment.schemas.js +125 -0
  67. package/dist/schemas/farms.schemas.d.ts +1171 -0
  68. package/dist/schemas/farms.schemas.d.ts.map +1 -0
  69. package/dist/schemas/farms.schemas.js +62 -0
  70. package/dist/schemas/fields.schemas.d.ts +2508 -0
  71. package/dist/schemas/fields.schemas.d.ts.map +1 -0
  72. package/dist/schemas/fields.schemas.js +125 -0
  73. package/dist/schemas/finance.schemas.d.ts +2869 -0
  74. package/dist/schemas/finance.schemas.d.ts.map +1 -0
  75. package/dist/schemas/finance.schemas.js +196 -0
  76. package/dist/schemas/harvest.schemas.d.ts +1051 -0
  77. package/dist/schemas/harvest.schemas.d.ts.map +1 -0
  78. package/dist/schemas/harvest.schemas.js +71 -0
  79. package/dist/schemas/inventory.schemas.d.ts +1138 -0
  80. package/dist/schemas/inventory.schemas.d.ts.map +1 -0
  81. package/dist/schemas/inventory.schemas.js +89 -0
  82. package/dist/schemas/soil-tests.schemas.d.ts +1885 -0
  83. package/dist/schemas/soil-tests.schemas.d.ts.map +1 -0
  84. package/dist/schemas/soil-tests.schemas.js +102 -0
  85. package/dist/schemas/suppliers.schemas.d.ts +1774 -0
  86. package/dist/schemas/suppliers.schemas.d.ts.map +1 -0
  87. package/dist/schemas/suppliers.schemas.js +121 -0
  88. package/dist/schemas/tasks.schemas.d.ts +1761 -0
  89. package/dist/schemas/tasks.schemas.d.ts.map +1 -0
  90. package/dist/schemas/tasks.schemas.js +121 -0
  91. package/dist/schemas/team.schemas.d.ts +583 -0
  92. package/dist/schemas/team.schemas.d.ts.map +1 -0
  93. package/dist/schemas/team.schemas.js +60 -0
  94. package/dist/schemas/users.schemas.d.ts +288 -0
  95. package/dist/schemas/users.schemas.d.ts.map +1 -0
  96. package/dist/schemas/users.schemas.js +32 -0
  97. package/dist/schemas/weather.schemas.d.ts +682 -0
  98. package/dist/schemas/weather.schemas.d.ts.map +1 -0
  99. package/dist/schemas/weather.schemas.js +49 -0
  100. package/package.json +1 -1
@@ -0,0 +1,3389 @@
1
+ import { z } from 'zod';
2
+ export declare const fieldsRouter: {
3
+ listFields: {
4
+ pathParams: z.ZodObject<{
5
+ farmId: z.ZodString;
6
+ }, "strip", z.ZodTypeAny, {
7
+ farmId: string;
8
+ }, {
9
+ farmId: string;
10
+ }>;
11
+ query: z.ZodObject<{
12
+ 'page[number]': z.ZodOptional<z.ZodDefault<z.ZodNumber>>;
13
+ 'page[size]': z.ZodOptional<z.ZodDefault<z.ZodNumber>>;
14
+ } & {
15
+ sort: z.ZodOptional<z.ZodString>;
16
+ } & {
17
+ include: z.ZodOptional<z.ZodString>;
18
+ } & {
19
+ 'filter[startDate]': z.ZodOptional<z.ZodString>;
20
+ 'filter[endDate]': z.ZodOptional<z.ZodString>;
21
+ 'filter[status]': z.ZodOptional<z.ZodString>;
22
+ 'filter[crop]': z.ZodOptional<z.ZodString>;
23
+ }, "strip", z.ZodTypeAny, {
24
+ sort?: string | undefined;
25
+ 'page[number]'?: number | undefined;
26
+ 'page[size]'?: number | undefined;
27
+ 'filter[startDate]'?: string | undefined;
28
+ 'filter[endDate]'?: string | undefined;
29
+ 'filter[status]'?: string | undefined;
30
+ 'filter[crop]'?: string | undefined;
31
+ include?: string | undefined;
32
+ }, {
33
+ sort?: string | undefined;
34
+ 'page[number]'?: number | undefined;
35
+ 'page[size]'?: number | undefined;
36
+ 'filter[startDate]'?: string | undefined;
37
+ 'filter[endDate]'?: string | undefined;
38
+ 'filter[status]'?: string | undefined;
39
+ 'filter[crop]'?: string | undefined;
40
+ include?: string | undefined;
41
+ }>;
42
+ summary: "List fields for a farm";
43
+ description: "Get all fields for a specific farm with optional filtering";
44
+ method: "GET";
45
+ path: "/farms/:farmId/fields";
46
+ responses: {
47
+ 200: z.ZodObject<{
48
+ data: z.ZodArray<z.ZodObject<{
49
+ type: z.ZodLiteral<string>;
50
+ id: z.ZodString;
51
+ attributes: z.ZodObject<{
52
+ name: z.ZodString;
53
+ geometry: z.ZodNullable<z.ZodObject<{
54
+ type: z.ZodEnum<["Polygon", "MultiPolygon", "Point", "LineString"]>;
55
+ coordinates: z.ZodUnion<[z.ZodArray<z.ZodArray<z.ZodArray<z.ZodNumber, "many">, "many">, "many">, z.ZodArray<z.ZodArray<z.ZodArray<z.ZodArray<z.ZodNumber, "many">, "many">, "many">, "many">, z.ZodArray<z.ZodNumber, "many">, z.ZodArray<z.ZodArray<z.ZodNumber, "many">, "many">]>;
56
+ }, "strip", z.ZodTypeAny, {
57
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
58
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
59
+ }, {
60
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
61
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
62
+ }>>;
63
+ ndvi: z.ZodNullable<z.ZodNumber>;
64
+ moisture: z.ZodNullable<z.ZodString>;
65
+ status: z.ZodEnum<["ok", "alert", "critical"]>;
66
+ area: z.ZodNullable<z.ZodString>;
67
+ crop: z.ZodNullable<z.ZodString>;
68
+ soilType: z.ZodNullable<z.ZodString>;
69
+ currentCrop: z.ZodNullable<z.ZodString>;
70
+ plantingDate: z.ZodNullable<z.ZodString>;
71
+ expectedHarvestDate: z.ZodNullable<z.ZodString>;
72
+ cropStage: z.ZodNullable<z.ZodEnum<["planted", "growing", "flowering", "mature", "harvested"]>>;
73
+ historicalNdvi: z.ZodOptional<z.ZodArray<z.ZodObject<{
74
+ date: z.ZodString;
75
+ value: z.ZodNumber;
76
+ }, "strip", z.ZodTypeAny, {
77
+ value: number;
78
+ date: string;
79
+ }, {
80
+ value: number;
81
+ date: string;
82
+ }>, "many">>;
83
+ cropHistory: z.ZodOptional<z.ZodArray<z.ZodObject<{
84
+ id: z.ZodString;
85
+ season: z.ZodString;
86
+ crop: z.ZodString;
87
+ plantingDate: z.ZodString;
88
+ harvestDate: z.ZodNullable<z.ZodString>;
89
+ yield: z.ZodNullable<z.ZodNumber>;
90
+ yieldUnit: z.ZodNullable<z.ZodString>;
91
+ }, "strip", z.ZodTypeAny, {
92
+ id: string;
93
+ season: string;
94
+ crop: string;
95
+ plantingDate: string;
96
+ harvestDate: string | null;
97
+ yield: number | null;
98
+ yieldUnit: string | null;
99
+ }, {
100
+ id: string;
101
+ season: string;
102
+ crop: string;
103
+ plantingDate: string;
104
+ harvestDate: string | null;
105
+ yield: number | null;
106
+ yieldUnit: string | null;
107
+ }>, "many">>;
108
+ } & {
109
+ createdAt: z.ZodString;
110
+ updatedAt: z.ZodString;
111
+ }, "strip", z.ZodTypeAny, {
112
+ status: "ok" | "alert" | "critical";
113
+ createdAt: string;
114
+ updatedAt: string;
115
+ name: string;
116
+ crop: string | null;
117
+ plantingDate: string | null;
118
+ geometry: {
119
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
120
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
121
+ } | null;
122
+ ndvi: number | null;
123
+ moisture: string | null;
124
+ area: string | null;
125
+ soilType: string | null;
126
+ currentCrop: string | null;
127
+ expectedHarvestDate: string | null;
128
+ cropStage: "planted" | "growing" | "flowering" | "mature" | "harvested" | null;
129
+ historicalNdvi?: {
130
+ value: number;
131
+ date: string;
132
+ }[] | undefined;
133
+ cropHistory?: {
134
+ id: string;
135
+ season: string;
136
+ crop: string;
137
+ plantingDate: string;
138
+ harvestDate: string | null;
139
+ yield: number | null;
140
+ yieldUnit: string | null;
141
+ }[] | undefined;
142
+ }, {
143
+ status: "ok" | "alert" | "critical";
144
+ createdAt: string;
145
+ updatedAt: string;
146
+ name: string;
147
+ crop: string | null;
148
+ plantingDate: string | null;
149
+ geometry: {
150
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
151
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
152
+ } | null;
153
+ ndvi: number | null;
154
+ moisture: string | null;
155
+ area: string | null;
156
+ soilType: string | null;
157
+ currentCrop: string | null;
158
+ expectedHarvestDate: string | null;
159
+ cropStage: "planted" | "growing" | "flowering" | "mature" | "harvested" | null;
160
+ historicalNdvi?: {
161
+ value: number;
162
+ date: string;
163
+ }[] | undefined;
164
+ cropHistory?: {
165
+ id: string;
166
+ season: string;
167
+ crop: string;
168
+ plantingDate: string;
169
+ harvestDate: string | null;
170
+ yield: number | null;
171
+ yieldUnit: string | null;
172
+ }[] | undefined;
173
+ }>;
174
+ relationships: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
175
+ links: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
176
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
177
+ }, "strip", z.ZodTypeAny, {
178
+ type: string;
179
+ id: string;
180
+ attributes: {
181
+ status: "ok" | "alert" | "critical";
182
+ createdAt: string;
183
+ updatedAt: string;
184
+ name: string;
185
+ crop: string | null;
186
+ plantingDate: string | null;
187
+ geometry: {
188
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
189
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
190
+ } | null;
191
+ ndvi: number | null;
192
+ moisture: string | null;
193
+ area: string | null;
194
+ soilType: string | null;
195
+ currentCrop: string | null;
196
+ expectedHarvestDate: string | null;
197
+ cropStage: "planted" | "growing" | "flowering" | "mature" | "harvested" | null;
198
+ historicalNdvi?: {
199
+ value: number;
200
+ date: string;
201
+ }[] | undefined;
202
+ cropHistory?: {
203
+ id: string;
204
+ season: string;
205
+ crop: string;
206
+ plantingDate: string;
207
+ harvestDate: string | null;
208
+ yield: number | null;
209
+ yieldUnit: string | null;
210
+ }[] | undefined;
211
+ };
212
+ relationships?: Record<string, unknown> | undefined;
213
+ links?: Record<string, string> | undefined;
214
+ meta?: Record<string, unknown> | undefined;
215
+ }, {
216
+ type: string;
217
+ id: string;
218
+ attributes: {
219
+ status: "ok" | "alert" | "critical";
220
+ createdAt: string;
221
+ updatedAt: string;
222
+ name: string;
223
+ crop: string | null;
224
+ plantingDate: string | null;
225
+ geometry: {
226
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
227
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
228
+ } | null;
229
+ ndvi: number | null;
230
+ moisture: string | null;
231
+ area: string | null;
232
+ soilType: string | null;
233
+ currentCrop: string | null;
234
+ expectedHarvestDate: string | null;
235
+ cropStage: "planted" | "growing" | "flowering" | "mature" | "harvested" | null;
236
+ historicalNdvi?: {
237
+ value: number;
238
+ date: string;
239
+ }[] | undefined;
240
+ cropHistory?: {
241
+ id: string;
242
+ season: string;
243
+ crop: string;
244
+ plantingDate: string;
245
+ harvestDate: string | null;
246
+ yield: number | null;
247
+ yieldUnit: string | null;
248
+ }[] | undefined;
249
+ };
250
+ relationships?: Record<string, unknown> | undefined;
251
+ links?: Record<string, string> | undefined;
252
+ meta?: Record<string, unknown> | undefined;
253
+ }>, "many">;
254
+ included: z.ZodOptional<z.ZodArray<z.ZodObject<{
255
+ type: z.ZodString;
256
+ id: z.ZodString;
257
+ attributes: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
258
+ relationships: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
259
+ links: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
260
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
261
+ }, "strip", z.ZodTypeAny, {
262
+ type: string;
263
+ id: string;
264
+ attributes?: Record<string, unknown> | undefined;
265
+ relationships?: Record<string, unknown> | undefined;
266
+ links?: Record<string, string> | undefined;
267
+ meta?: Record<string, unknown> | undefined;
268
+ }, {
269
+ type: string;
270
+ id: string;
271
+ attributes?: Record<string, unknown> | undefined;
272
+ relationships?: Record<string, unknown> | undefined;
273
+ links?: Record<string, string> | undefined;
274
+ meta?: Record<string, unknown> | undefined;
275
+ }>, "many">>;
276
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
277
+ links: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
278
+ }, "strip", z.ZodTypeAny, {
279
+ data: {
280
+ type: string;
281
+ id: string;
282
+ attributes: {
283
+ status: "ok" | "alert" | "critical";
284
+ createdAt: string;
285
+ updatedAt: string;
286
+ name: string;
287
+ crop: string | null;
288
+ plantingDate: string | null;
289
+ geometry: {
290
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
291
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
292
+ } | null;
293
+ ndvi: number | null;
294
+ moisture: string | null;
295
+ area: string | null;
296
+ soilType: string | null;
297
+ currentCrop: string | null;
298
+ expectedHarvestDate: string | null;
299
+ cropStage: "planted" | "growing" | "flowering" | "mature" | "harvested" | null;
300
+ historicalNdvi?: {
301
+ value: number;
302
+ date: string;
303
+ }[] | undefined;
304
+ cropHistory?: {
305
+ id: string;
306
+ season: string;
307
+ crop: string;
308
+ plantingDate: string;
309
+ harvestDate: string | null;
310
+ yield: number | null;
311
+ yieldUnit: string | null;
312
+ }[] | undefined;
313
+ };
314
+ relationships?: Record<string, unknown> | undefined;
315
+ links?: Record<string, string> | undefined;
316
+ meta?: Record<string, unknown> | undefined;
317
+ }[];
318
+ links?: Record<string, string> | undefined;
319
+ meta?: Record<string, unknown> | undefined;
320
+ included?: {
321
+ type: string;
322
+ id: string;
323
+ attributes?: Record<string, unknown> | undefined;
324
+ relationships?: Record<string, unknown> | undefined;
325
+ links?: Record<string, string> | undefined;
326
+ meta?: Record<string, unknown> | undefined;
327
+ }[] | undefined;
328
+ }, {
329
+ data: {
330
+ type: string;
331
+ id: string;
332
+ attributes: {
333
+ status: "ok" | "alert" | "critical";
334
+ createdAt: string;
335
+ updatedAt: string;
336
+ name: string;
337
+ crop: string | null;
338
+ plantingDate: string | null;
339
+ geometry: {
340
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
341
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
342
+ } | null;
343
+ ndvi: number | null;
344
+ moisture: string | null;
345
+ area: string | null;
346
+ soilType: string | null;
347
+ currentCrop: string | null;
348
+ expectedHarvestDate: string | null;
349
+ cropStage: "planted" | "growing" | "flowering" | "mature" | "harvested" | null;
350
+ historicalNdvi?: {
351
+ value: number;
352
+ date: string;
353
+ }[] | undefined;
354
+ cropHistory?: {
355
+ id: string;
356
+ season: string;
357
+ crop: string;
358
+ plantingDate: string;
359
+ harvestDate: string | null;
360
+ yield: number | null;
361
+ yieldUnit: string | null;
362
+ }[] | undefined;
363
+ };
364
+ relationships?: Record<string, unknown> | undefined;
365
+ links?: Record<string, string> | undefined;
366
+ meta?: Record<string, unknown> | undefined;
367
+ }[];
368
+ links?: Record<string, string> | undefined;
369
+ meta?: Record<string, unknown> | undefined;
370
+ included?: {
371
+ type: string;
372
+ id: string;
373
+ attributes?: Record<string, unknown> | undefined;
374
+ relationships?: Record<string, unknown> | undefined;
375
+ links?: Record<string, string> | undefined;
376
+ meta?: Record<string, unknown> | undefined;
377
+ }[] | undefined;
378
+ }>;
379
+ 404: z.ZodObject<{
380
+ errors: z.ZodArray<z.ZodObject<{
381
+ id: z.ZodOptional<z.ZodString>;
382
+ links: z.ZodOptional<z.ZodObject<{
383
+ about: z.ZodOptional<z.ZodString>;
384
+ }, "strip", z.ZodTypeAny, {
385
+ about?: string | undefined;
386
+ }, {
387
+ about?: string | undefined;
388
+ }>>;
389
+ status: z.ZodOptional<z.ZodString>;
390
+ code: z.ZodOptional<z.ZodString>;
391
+ title: z.ZodOptional<z.ZodString>;
392
+ detail: z.ZodOptional<z.ZodString>;
393
+ source: z.ZodOptional<z.ZodObject<{
394
+ pointer: z.ZodOptional<z.ZodString>;
395
+ parameter: z.ZodOptional<z.ZodString>;
396
+ }, "strip", z.ZodTypeAny, {
397
+ pointer?: string | undefined;
398
+ parameter?: string | undefined;
399
+ }, {
400
+ pointer?: string | undefined;
401
+ parameter?: string | undefined;
402
+ }>>;
403
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
404
+ }, "strip", z.ZodTypeAny, {
405
+ status?: string | undefined;
406
+ code?: string | undefined;
407
+ id?: string | undefined;
408
+ links?: {
409
+ about?: string | undefined;
410
+ } | undefined;
411
+ meta?: Record<string, unknown> | undefined;
412
+ title?: string | undefined;
413
+ detail?: string | undefined;
414
+ source?: {
415
+ pointer?: string | undefined;
416
+ parameter?: string | undefined;
417
+ } | undefined;
418
+ }, {
419
+ status?: string | undefined;
420
+ code?: string | undefined;
421
+ id?: string | undefined;
422
+ links?: {
423
+ about?: string | undefined;
424
+ } | undefined;
425
+ meta?: Record<string, unknown> | undefined;
426
+ title?: string | undefined;
427
+ detail?: string | undefined;
428
+ source?: {
429
+ pointer?: string | undefined;
430
+ parameter?: string | undefined;
431
+ } | undefined;
432
+ }>, "many">;
433
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
434
+ }, "strip", z.ZodTypeAny, {
435
+ errors: {
436
+ status?: string | undefined;
437
+ code?: string | undefined;
438
+ id?: string | undefined;
439
+ links?: {
440
+ about?: string | undefined;
441
+ } | undefined;
442
+ meta?: Record<string, unknown> | undefined;
443
+ title?: string | undefined;
444
+ detail?: string | undefined;
445
+ source?: {
446
+ pointer?: string | undefined;
447
+ parameter?: string | undefined;
448
+ } | undefined;
449
+ }[];
450
+ meta?: Record<string, unknown> | undefined;
451
+ }, {
452
+ errors: {
453
+ status?: string | undefined;
454
+ code?: string | undefined;
455
+ id?: string | undefined;
456
+ links?: {
457
+ about?: string | undefined;
458
+ } | undefined;
459
+ meta?: Record<string, unknown> | undefined;
460
+ title?: string | undefined;
461
+ detail?: string | undefined;
462
+ source?: {
463
+ pointer?: string | undefined;
464
+ parameter?: string | undefined;
465
+ } | undefined;
466
+ }[];
467
+ meta?: Record<string, unknown> | undefined;
468
+ }>;
469
+ 401: z.ZodObject<{
470
+ errors: z.ZodArray<z.ZodObject<{
471
+ id: z.ZodOptional<z.ZodString>;
472
+ links: z.ZodOptional<z.ZodObject<{
473
+ about: z.ZodOptional<z.ZodString>;
474
+ }, "strip", z.ZodTypeAny, {
475
+ about?: string | undefined;
476
+ }, {
477
+ about?: string | undefined;
478
+ }>>;
479
+ status: z.ZodOptional<z.ZodString>;
480
+ code: z.ZodOptional<z.ZodString>;
481
+ title: z.ZodOptional<z.ZodString>;
482
+ detail: z.ZodOptional<z.ZodString>;
483
+ source: z.ZodOptional<z.ZodObject<{
484
+ pointer: z.ZodOptional<z.ZodString>;
485
+ parameter: z.ZodOptional<z.ZodString>;
486
+ }, "strip", z.ZodTypeAny, {
487
+ pointer?: string | undefined;
488
+ parameter?: string | undefined;
489
+ }, {
490
+ pointer?: string | undefined;
491
+ parameter?: string | undefined;
492
+ }>>;
493
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
494
+ }, "strip", z.ZodTypeAny, {
495
+ status?: string | undefined;
496
+ code?: string | undefined;
497
+ id?: string | undefined;
498
+ links?: {
499
+ about?: string | undefined;
500
+ } | undefined;
501
+ meta?: Record<string, unknown> | undefined;
502
+ title?: string | undefined;
503
+ detail?: string | undefined;
504
+ source?: {
505
+ pointer?: string | undefined;
506
+ parameter?: string | undefined;
507
+ } | undefined;
508
+ }, {
509
+ status?: string | undefined;
510
+ code?: string | undefined;
511
+ id?: string | undefined;
512
+ links?: {
513
+ about?: string | undefined;
514
+ } | undefined;
515
+ meta?: Record<string, unknown> | undefined;
516
+ title?: string | undefined;
517
+ detail?: string | undefined;
518
+ source?: {
519
+ pointer?: string | undefined;
520
+ parameter?: string | undefined;
521
+ } | undefined;
522
+ }>, "many">;
523
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
524
+ }, "strip", z.ZodTypeAny, {
525
+ errors: {
526
+ status?: string | undefined;
527
+ code?: string | undefined;
528
+ id?: string | undefined;
529
+ links?: {
530
+ about?: string | undefined;
531
+ } | undefined;
532
+ meta?: Record<string, unknown> | undefined;
533
+ title?: string | undefined;
534
+ detail?: string | undefined;
535
+ source?: {
536
+ pointer?: string | undefined;
537
+ parameter?: string | undefined;
538
+ } | undefined;
539
+ }[];
540
+ meta?: Record<string, unknown> | undefined;
541
+ }, {
542
+ errors: {
543
+ status?: string | undefined;
544
+ code?: string | undefined;
545
+ id?: string | undefined;
546
+ links?: {
547
+ about?: string | undefined;
548
+ } | undefined;
549
+ meta?: Record<string, unknown> | undefined;
550
+ title?: string | undefined;
551
+ detail?: string | undefined;
552
+ source?: {
553
+ pointer?: string | undefined;
554
+ parameter?: string | undefined;
555
+ } | undefined;
556
+ }[];
557
+ meta?: Record<string, unknown> | undefined;
558
+ }>;
559
+ };
560
+ };
561
+ createField: {
562
+ pathParams: z.ZodObject<{
563
+ farmId: z.ZodString;
564
+ }, "strip", z.ZodTypeAny, {
565
+ farmId: string;
566
+ }, {
567
+ farmId: string;
568
+ }>;
569
+ summary: "Create a new field";
570
+ description: "Create a new field with optional geometry";
571
+ method: "POST";
572
+ body: z.ZodObject<{
573
+ data: z.ZodObject<{
574
+ type: z.ZodLiteral<"fields">;
575
+ attributes: z.ZodObject<{
576
+ name: z.ZodString;
577
+ geometry: z.ZodOptional<z.ZodObject<{
578
+ type: z.ZodEnum<["Polygon", "MultiPolygon", "Point", "LineString"]>;
579
+ coordinates: z.ZodUnion<[z.ZodArray<z.ZodArray<z.ZodArray<z.ZodNumber, "many">, "many">, "many">, z.ZodArray<z.ZodArray<z.ZodArray<z.ZodArray<z.ZodNumber, "many">, "many">, "many">, "many">, z.ZodArray<z.ZodNumber, "many">, z.ZodArray<z.ZodArray<z.ZodNumber, "many">, "many">]>;
580
+ }, "strip", z.ZodTypeAny, {
581
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
582
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
583
+ }, {
584
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
585
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
586
+ }>>;
587
+ ndvi: z.ZodOptional<z.ZodNumber>;
588
+ moisture: z.ZodOptional<z.ZodString>;
589
+ crop: z.ZodOptional<z.ZodString>;
590
+ soilType: z.ZodOptional<z.ZodString>;
591
+ currentCrop: z.ZodOptional<z.ZodString>;
592
+ plantingDate: z.ZodOptional<z.ZodString>;
593
+ expectedHarvestDate: z.ZodOptional<z.ZodString>;
594
+ cropStage: z.ZodOptional<z.ZodEnum<["planted", "growing", "flowering", "mature", "harvested"]>>;
595
+ }, "strip", z.ZodTypeAny, {
596
+ name: string;
597
+ crop?: string | undefined;
598
+ plantingDate?: string | undefined;
599
+ geometry?: {
600
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
601
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
602
+ } | undefined;
603
+ ndvi?: number | undefined;
604
+ moisture?: string | undefined;
605
+ soilType?: string | undefined;
606
+ currentCrop?: string | undefined;
607
+ expectedHarvestDate?: string | undefined;
608
+ cropStage?: "planted" | "growing" | "flowering" | "mature" | "harvested" | undefined;
609
+ }, {
610
+ name: string;
611
+ crop?: string | undefined;
612
+ plantingDate?: string | undefined;
613
+ geometry?: {
614
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
615
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
616
+ } | undefined;
617
+ ndvi?: number | undefined;
618
+ moisture?: string | undefined;
619
+ soilType?: string | undefined;
620
+ currentCrop?: string | undefined;
621
+ expectedHarvestDate?: string | undefined;
622
+ cropStage?: "planted" | "growing" | "flowering" | "mature" | "harvested" | undefined;
623
+ }>;
624
+ relationships: z.ZodObject<{
625
+ farm: z.ZodObject<{
626
+ data: z.ZodObject<{
627
+ type: z.ZodLiteral<"farms">;
628
+ id: z.ZodString;
629
+ }, "strip", z.ZodTypeAny, {
630
+ type: "farms";
631
+ id: string;
632
+ }, {
633
+ type: "farms";
634
+ id: string;
635
+ }>;
636
+ }, "strip", z.ZodTypeAny, {
637
+ data: {
638
+ type: "farms";
639
+ id: string;
640
+ };
641
+ }, {
642
+ data: {
643
+ type: "farms";
644
+ id: string;
645
+ };
646
+ }>;
647
+ }, "strip", z.ZodTypeAny, {
648
+ farm: {
649
+ data: {
650
+ type: "farms";
651
+ id: string;
652
+ };
653
+ };
654
+ }, {
655
+ farm: {
656
+ data: {
657
+ type: "farms";
658
+ id: string;
659
+ };
660
+ };
661
+ }>;
662
+ }, "strip", z.ZodTypeAny, {
663
+ type: "fields";
664
+ attributes: {
665
+ name: string;
666
+ crop?: string | undefined;
667
+ plantingDate?: string | undefined;
668
+ geometry?: {
669
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
670
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
671
+ } | undefined;
672
+ ndvi?: number | undefined;
673
+ moisture?: string | undefined;
674
+ soilType?: string | undefined;
675
+ currentCrop?: string | undefined;
676
+ expectedHarvestDate?: string | undefined;
677
+ cropStage?: "planted" | "growing" | "flowering" | "mature" | "harvested" | undefined;
678
+ };
679
+ relationships: {
680
+ farm: {
681
+ data: {
682
+ type: "farms";
683
+ id: string;
684
+ };
685
+ };
686
+ };
687
+ }, {
688
+ type: "fields";
689
+ attributes: {
690
+ name: string;
691
+ crop?: string | undefined;
692
+ plantingDate?: string | undefined;
693
+ geometry?: {
694
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
695
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
696
+ } | undefined;
697
+ ndvi?: number | undefined;
698
+ moisture?: string | undefined;
699
+ soilType?: string | undefined;
700
+ currentCrop?: string | undefined;
701
+ expectedHarvestDate?: string | undefined;
702
+ cropStage?: "planted" | "growing" | "flowering" | "mature" | "harvested" | undefined;
703
+ };
704
+ relationships: {
705
+ farm: {
706
+ data: {
707
+ type: "farms";
708
+ id: string;
709
+ };
710
+ };
711
+ };
712
+ }>;
713
+ }, "strip", z.ZodTypeAny, {
714
+ data: {
715
+ type: "fields";
716
+ attributes: {
717
+ name: string;
718
+ crop?: string | undefined;
719
+ plantingDate?: string | undefined;
720
+ geometry?: {
721
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
722
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
723
+ } | undefined;
724
+ ndvi?: number | undefined;
725
+ moisture?: string | undefined;
726
+ soilType?: string | undefined;
727
+ currentCrop?: string | undefined;
728
+ expectedHarvestDate?: string | undefined;
729
+ cropStage?: "planted" | "growing" | "flowering" | "mature" | "harvested" | undefined;
730
+ };
731
+ relationships: {
732
+ farm: {
733
+ data: {
734
+ type: "farms";
735
+ id: string;
736
+ };
737
+ };
738
+ };
739
+ };
740
+ }, {
741
+ data: {
742
+ type: "fields";
743
+ attributes: {
744
+ name: string;
745
+ crop?: string | undefined;
746
+ plantingDate?: string | undefined;
747
+ geometry?: {
748
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
749
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
750
+ } | undefined;
751
+ ndvi?: number | undefined;
752
+ moisture?: string | undefined;
753
+ soilType?: string | undefined;
754
+ currentCrop?: string | undefined;
755
+ expectedHarvestDate?: string | undefined;
756
+ cropStage?: "planted" | "growing" | "flowering" | "mature" | "harvested" | undefined;
757
+ };
758
+ relationships: {
759
+ farm: {
760
+ data: {
761
+ type: "farms";
762
+ id: string;
763
+ };
764
+ };
765
+ };
766
+ };
767
+ }>;
768
+ path: "/farms/:farmId/fields";
769
+ responses: {
770
+ 201: z.ZodObject<{
771
+ data: z.ZodObject<{
772
+ type: z.ZodLiteral<string>;
773
+ id: z.ZodString;
774
+ attributes: z.ZodObject<{
775
+ name: z.ZodString;
776
+ geometry: z.ZodNullable<z.ZodObject<{
777
+ type: z.ZodEnum<["Polygon", "MultiPolygon", "Point", "LineString"]>;
778
+ coordinates: z.ZodUnion<[z.ZodArray<z.ZodArray<z.ZodArray<z.ZodNumber, "many">, "many">, "many">, z.ZodArray<z.ZodArray<z.ZodArray<z.ZodArray<z.ZodNumber, "many">, "many">, "many">, "many">, z.ZodArray<z.ZodNumber, "many">, z.ZodArray<z.ZodArray<z.ZodNumber, "many">, "many">]>;
779
+ }, "strip", z.ZodTypeAny, {
780
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
781
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
782
+ }, {
783
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
784
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
785
+ }>>;
786
+ ndvi: z.ZodNullable<z.ZodNumber>;
787
+ moisture: z.ZodNullable<z.ZodString>;
788
+ status: z.ZodEnum<["ok", "alert", "critical"]>;
789
+ area: z.ZodNullable<z.ZodString>;
790
+ crop: z.ZodNullable<z.ZodString>;
791
+ soilType: z.ZodNullable<z.ZodString>;
792
+ currentCrop: z.ZodNullable<z.ZodString>;
793
+ plantingDate: z.ZodNullable<z.ZodString>;
794
+ expectedHarvestDate: z.ZodNullable<z.ZodString>;
795
+ cropStage: z.ZodNullable<z.ZodEnum<["planted", "growing", "flowering", "mature", "harvested"]>>;
796
+ historicalNdvi: z.ZodOptional<z.ZodArray<z.ZodObject<{
797
+ date: z.ZodString;
798
+ value: z.ZodNumber;
799
+ }, "strip", z.ZodTypeAny, {
800
+ value: number;
801
+ date: string;
802
+ }, {
803
+ value: number;
804
+ date: string;
805
+ }>, "many">>;
806
+ cropHistory: z.ZodOptional<z.ZodArray<z.ZodObject<{
807
+ id: z.ZodString;
808
+ season: z.ZodString;
809
+ crop: z.ZodString;
810
+ plantingDate: z.ZodString;
811
+ harvestDate: z.ZodNullable<z.ZodString>;
812
+ yield: z.ZodNullable<z.ZodNumber>;
813
+ yieldUnit: z.ZodNullable<z.ZodString>;
814
+ }, "strip", z.ZodTypeAny, {
815
+ id: string;
816
+ season: string;
817
+ crop: string;
818
+ plantingDate: string;
819
+ harvestDate: string | null;
820
+ yield: number | null;
821
+ yieldUnit: string | null;
822
+ }, {
823
+ id: string;
824
+ season: string;
825
+ crop: string;
826
+ plantingDate: string;
827
+ harvestDate: string | null;
828
+ yield: number | null;
829
+ yieldUnit: string | null;
830
+ }>, "many">>;
831
+ } & {
832
+ createdAt: z.ZodString;
833
+ updatedAt: z.ZodString;
834
+ }, "strip", z.ZodTypeAny, {
835
+ status: "ok" | "alert" | "critical";
836
+ createdAt: string;
837
+ updatedAt: string;
838
+ name: string;
839
+ crop: string | null;
840
+ plantingDate: string | null;
841
+ geometry: {
842
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
843
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
844
+ } | null;
845
+ ndvi: number | null;
846
+ moisture: string | null;
847
+ area: string | null;
848
+ soilType: string | null;
849
+ currentCrop: string | null;
850
+ expectedHarvestDate: string | null;
851
+ cropStage: "planted" | "growing" | "flowering" | "mature" | "harvested" | null;
852
+ historicalNdvi?: {
853
+ value: number;
854
+ date: string;
855
+ }[] | undefined;
856
+ cropHistory?: {
857
+ id: string;
858
+ season: string;
859
+ crop: string;
860
+ plantingDate: string;
861
+ harvestDate: string | null;
862
+ yield: number | null;
863
+ yieldUnit: string | null;
864
+ }[] | undefined;
865
+ }, {
866
+ status: "ok" | "alert" | "critical";
867
+ createdAt: string;
868
+ updatedAt: string;
869
+ name: string;
870
+ crop: string | null;
871
+ plantingDate: string | null;
872
+ geometry: {
873
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
874
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
875
+ } | null;
876
+ ndvi: number | null;
877
+ moisture: string | null;
878
+ area: string | null;
879
+ soilType: string | null;
880
+ currentCrop: string | null;
881
+ expectedHarvestDate: string | null;
882
+ cropStage: "planted" | "growing" | "flowering" | "mature" | "harvested" | null;
883
+ historicalNdvi?: {
884
+ value: number;
885
+ date: string;
886
+ }[] | undefined;
887
+ cropHistory?: {
888
+ id: string;
889
+ season: string;
890
+ crop: string;
891
+ plantingDate: string;
892
+ harvestDate: string | null;
893
+ yield: number | null;
894
+ yieldUnit: string | null;
895
+ }[] | undefined;
896
+ }>;
897
+ relationships: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
898
+ links: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
899
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
900
+ }, "strip", z.ZodTypeAny, {
901
+ type: string;
902
+ id: string;
903
+ attributes: {
904
+ status: "ok" | "alert" | "critical";
905
+ createdAt: string;
906
+ updatedAt: string;
907
+ name: string;
908
+ crop: string | null;
909
+ plantingDate: string | null;
910
+ geometry: {
911
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
912
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
913
+ } | null;
914
+ ndvi: number | null;
915
+ moisture: string | null;
916
+ area: string | null;
917
+ soilType: string | null;
918
+ currentCrop: string | null;
919
+ expectedHarvestDate: string | null;
920
+ cropStage: "planted" | "growing" | "flowering" | "mature" | "harvested" | null;
921
+ historicalNdvi?: {
922
+ value: number;
923
+ date: string;
924
+ }[] | undefined;
925
+ cropHistory?: {
926
+ id: string;
927
+ season: string;
928
+ crop: string;
929
+ plantingDate: string;
930
+ harvestDate: string | null;
931
+ yield: number | null;
932
+ yieldUnit: string | null;
933
+ }[] | undefined;
934
+ };
935
+ relationships?: Record<string, unknown> | undefined;
936
+ links?: Record<string, string> | undefined;
937
+ meta?: Record<string, unknown> | undefined;
938
+ }, {
939
+ type: string;
940
+ id: string;
941
+ attributes: {
942
+ status: "ok" | "alert" | "critical";
943
+ createdAt: string;
944
+ updatedAt: string;
945
+ name: string;
946
+ crop: string | null;
947
+ plantingDate: string | null;
948
+ geometry: {
949
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
950
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
951
+ } | null;
952
+ ndvi: number | null;
953
+ moisture: string | null;
954
+ area: string | null;
955
+ soilType: string | null;
956
+ currentCrop: string | null;
957
+ expectedHarvestDate: string | null;
958
+ cropStage: "planted" | "growing" | "flowering" | "mature" | "harvested" | null;
959
+ historicalNdvi?: {
960
+ value: number;
961
+ date: string;
962
+ }[] | undefined;
963
+ cropHistory?: {
964
+ id: string;
965
+ season: string;
966
+ crop: string;
967
+ plantingDate: string;
968
+ harvestDate: string | null;
969
+ yield: number | null;
970
+ yieldUnit: string | null;
971
+ }[] | undefined;
972
+ };
973
+ relationships?: Record<string, unknown> | undefined;
974
+ links?: Record<string, string> | undefined;
975
+ meta?: Record<string, unknown> | undefined;
976
+ }>;
977
+ included: z.ZodOptional<z.ZodArray<z.ZodObject<{
978
+ type: z.ZodString;
979
+ id: z.ZodString;
980
+ attributes: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
981
+ relationships: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
982
+ links: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
983
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
984
+ }, "strip", z.ZodTypeAny, {
985
+ type: string;
986
+ id: string;
987
+ attributes?: Record<string, unknown> | undefined;
988
+ relationships?: Record<string, unknown> | undefined;
989
+ links?: Record<string, string> | undefined;
990
+ meta?: Record<string, unknown> | undefined;
991
+ }, {
992
+ type: string;
993
+ id: string;
994
+ attributes?: Record<string, unknown> | undefined;
995
+ relationships?: Record<string, unknown> | undefined;
996
+ links?: Record<string, string> | undefined;
997
+ meta?: Record<string, unknown> | undefined;
998
+ }>, "many">>;
999
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
1000
+ links: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
1001
+ }, "strip", z.ZodTypeAny, {
1002
+ data: {
1003
+ type: string;
1004
+ id: string;
1005
+ attributes: {
1006
+ status: "ok" | "alert" | "critical";
1007
+ createdAt: string;
1008
+ updatedAt: string;
1009
+ name: string;
1010
+ crop: string | null;
1011
+ plantingDate: string | null;
1012
+ geometry: {
1013
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
1014
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
1015
+ } | null;
1016
+ ndvi: number | null;
1017
+ moisture: string | null;
1018
+ area: string | null;
1019
+ soilType: string | null;
1020
+ currentCrop: string | null;
1021
+ expectedHarvestDate: string | null;
1022
+ cropStage: "planted" | "growing" | "flowering" | "mature" | "harvested" | null;
1023
+ historicalNdvi?: {
1024
+ value: number;
1025
+ date: string;
1026
+ }[] | undefined;
1027
+ cropHistory?: {
1028
+ id: string;
1029
+ season: string;
1030
+ crop: string;
1031
+ plantingDate: string;
1032
+ harvestDate: string | null;
1033
+ yield: number | null;
1034
+ yieldUnit: string | null;
1035
+ }[] | undefined;
1036
+ };
1037
+ relationships?: Record<string, unknown> | undefined;
1038
+ links?: Record<string, string> | undefined;
1039
+ meta?: Record<string, unknown> | undefined;
1040
+ };
1041
+ links?: Record<string, string> | undefined;
1042
+ meta?: Record<string, unknown> | undefined;
1043
+ included?: {
1044
+ type: string;
1045
+ id: string;
1046
+ attributes?: Record<string, unknown> | undefined;
1047
+ relationships?: Record<string, unknown> | undefined;
1048
+ links?: Record<string, string> | undefined;
1049
+ meta?: Record<string, unknown> | undefined;
1050
+ }[] | undefined;
1051
+ }, {
1052
+ data: {
1053
+ type: string;
1054
+ id: string;
1055
+ attributes: {
1056
+ status: "ok" | "alert" | "critical";
1057
+ createdAt: string;
1058
+ updatedAt: string;
1059
+ name: string;
1060
+ crop: string | null;
1061
+ plantingDate: string | null;
1062
+ geometry: {
1063
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
1064
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
1065
+ } | null;
1066
+ ndvi: number | null;
1067
+ moisture: string | null;
1068
+ area: string | null;
1069
+ soilType: string | null;
1070
+ currentCrop: string | null;
1071
+ expectedHarvestDate: string | null;
1072
+ cropStage: "planted" | "growing" | "flowering" | "mature" | "harvested" | null;
1073
+ historicalNdvi?: {
1074
+ value: number;
1075
+ date: string;
1076
+ }[] | undefined;
1077
+ cropHistory?: {
1078
+ id: string;
1079
+ season: string;
1080
+ crop: string;
1081
+ plantingDate: string;
1082
+ harvestDate: string | null;
1083
+ yield: number | null;
1084
+ yieldUnit: string | null;
1085
+ }[] | undefined;
1086
+ };
1087
+ relationships?: Record<string, unknown> | undefined;
1088
+ links?: Record<string, string> | undefined;
1089
+ meta?: Record<string, unknown> | undefined;
1090
+ };
1091
+ links?: Record<string, string> | undefined;
1092
+ meta?: Record<string, unknown> | undefined;
1093
+ included?: {
1094
+ type: string;
1095
+ id: string;
1096
+ attributes?: Record<string, unknown> | undefined;
1097
+ relationships?: Record<string, unknown> | undefined;
1098
+ links?: Record<string, string> | undefined;
1099
+ meta?: Record<string, unknown> | undefined;
1100
+ }[] | undefined;
1101
+ }>;
1102
+ 400: z.ZodObject<{
1103
+ errors: z.ZodArray<z.ZodObject<{
1104
+ id: z.ZodOptional<z.ZodString>;
1105
+ links: z.ZodOptional<z.ZodObject<{
1106
+ about: z.ZodOptional<z.ZodString>;
1107
+ }, "strip", z.ZodTypeAny, {
1108
+ about?: string | undefined;
1109
+ }, {
1110
+ about?: string | undefined;
1111
+ }>>;
1112
+ status: z.ZodOptional<z.ZodString>;
1113
+ code: z.ZodOptional<z.ZodString>;
1114
+ title: z.ZodOptional<z.ZodString>;
1115
+ detail: z.ZodOptional<z.ZodString>;
1116
+ source: z.ZodOptional<z.ZodObject<{
1117
+ pointer: z.ZodOptional<z.ZodString>;
1118
+ parameter: z.ZodOptional<z.ZodString>;
1119
+ }, "strip", z.ZodTypeAny, {
1120
+ pointer?: string | undefined;
1121
+ parameter?: string | undefined;
1122
+ }, {
1123
+ pointer?: string | undefined;
1124
+ parameter?: string | undefined;
1125
+ }>>;
1126
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
1127
+ }, "strip", z.ZodTypeAny, {
1128
+ status?: string | undefined;
1129
+ code?: string | undefined;
1130
+ id?: string | undefined;
1131
+ links?: {
1132
+ about?: string | undefined;
1133
+ } | undefined;
1134
+ meta?: Record<string, unknown> | undefined;
1135
+ title?: string | undefined;
1136
+ detail?: string | undefined;
1137
+ source?: {
1138
+ pointer?: string | undefined;
1139
+ parameter?: string | undefined;
1140
+ } | undefined;
1141
+ }, {
1142
+ status?: string | undefined;
1143
+ code?: string | undefined;
1144
+ id?: string | undefined;
1145
+ links?: {
1146
+ about?: string | undefined;
1147
+ } | undefined;
1148
+ meta?: Record<string, unknown> | undefined;
1149
+ title?: string | undefined;
1150
+ detail?: string | undefined;
1151
+ source?: {
1152
+ pointer?: string | undefined;
1153
+ parameter?: string | undefined;
1154
+ } | undefined;
1155
+ }>, "many">;
1156
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
1157
+ }, "strip", z.ZodTypeAny, {
1158
+ errors: {
1159
+ status?: string | undefined;
1160
+ code?: string | undefined;
1161
+ id?: string | undefined;
1162
+ links?: {
1163
+ about?: string | undefined;
1164
+ } | undefined;
1165
+ meta?: Record<string, unknown> | undefined;
1166
+ title?: string | undefined;
1167
+ detail?: string | undefined;
1168
+ source?: {
1169
+ pointer?: string | undefined;
1170
+ parameter?: string | undefined;
1171
+ } | undefined;
1172
+ }[];
1173
+ meta?: Record<string, unknown> | undefined;
1174
+ }, {
1175
+ errors: {
1176
+ status?: string | undefined;
1177
+ code?: string | undefined;
1178
+ id?: string | undefined;
1179
+ links?: {
1180
+ about?: string | undefined;
1181
+ } | undefined;
1182
+ meta?: Record<string, unknown> | undefined;
1183
+ title?: string | undefined;
1184
+ detail?: string | undefined;
1185
+ source?: {
1186
+ pointer?: string | undefined;
1187
+ parameter?: string | undefined;
1188
+ } | undefined;
1189
+ }[];
1190
+ meta?: Record<string, unknown> | undefined;
1191
+ }>;
1192
+ 404: z.ZodObject<{
1193
+ errors: z.ZodArray<z.ZodObject<{
1194
+ id: z.ZodOptional<z.ZodString>;
1195
+ links: z.ZodOptional<z.ZodObject<{
1196
+ about: z.ZodOptional<z.ZodString>;
1197
+ }, "strip", z.ZodTypeAny, {
1198
+ about?: string | undefined;
1199
+ }, {
1200
+ about?: string | undefined;
1201
+ }>>;
1202
+ status: z.ZodOptional<z.ZodString>;
1203
+ code: z.ZodOptional<z.ZodString>;
1204
+ title: z.ZodOptional<z.ZodString>;
1205
+ detail: z.ZodOptional<z.ZodString>;
1206
+ source: z.ZodOptional<z.ZodObject<{
1207
+ pointer: z.ZodOptional<z.ZodString>;
1208
+ parameter: z.ZodOptional<z.ZodString>;
1209
+ }, "strip", z.ZodTypeAny, {
1210
+ pointer?: string | undefined;
1211
+ parameter?: string | undefined;
1212
+ }, {
1213
+ pointer?: string | undefined;
1214
+ parameter?: string | undefined;
1215
+ }>>;
1216
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
1217
+ }, "strip", z.ZodTypeAny, {
1218
+ status?: string | undefined;
1219
+ code?: string | undefined;
1220
+ id?: string | undefined;
1221
+ links?: {
1222
+ about?: string | undefined;
1223
+ } | undefined;
1224
+ meta?: Record<string, unknown> | undefined;
1225
+ title?: string | undefined;
1226
+ detail?: string | undefined;
1227
+ source?: {
1228
+ pointer?: string | undefined;
1229
+ parameter?: string | undefined;
1230
+ } | undefined;
1231
+ }, {
1232
+ status?: string | undefined;
1233
+ code?: string | undefined;
1234
+ id?: string | undefined;
1235
+ links?: {
1236
+ about?: string | undefined;
1237
+ } | undefined;
1238
+ meta?: Record<string, unknown> | undefined;
1239
+ title?: string | undefined;
1240
+ detail?: string | undefined;
1241
+ source?: {
1242
+ pointer?: string | undefined;
1243
+ parameter?: string | undefined;
1244
+ } | undefined;
1245
+ }>, "many">;
1246
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
1247
+ }, "strip", z.ZodTypeAny, {
1248
+ errors: {
1249
+ status?: string | undefined;
1250
+ code?: string | undefined;
1251
+ id?: string | undefined;
1252
+ links?: {
1253
+ about?: string | undefined;
1254
+ } | undefined;
1255
+ meta?: Record<string, unknown> | undefined;
1256
+ title?: string | undefined;
1257
+ detail?: string | undefined;
1258
+ source?: {
1259
+ pointer?: string | undefined;
1260
+ parameter?: string | undefined;
1261
+ } | undefined;
1262
+ }[];
1263
+ meta?: Record<string, unknown> | undefined;
1264
+ }, {
1265
+ errors: {
1266
+ status?: string | undefined;
1267
+ code?: string | undefined;
1268
+ id?: string | undefined;
1269
+ links?: {
1270
+ about?: string | undefined;
1271
+ } | undefined;
1272
+ meta?: Record<string, unknown> | undefined;
1273
+ title?: string | undefined;
1274
+ detail?: string | undefined;
1275
+ source?: {
1276
+ pointer?: string | undefined;
1277
+ parameter?: string | undefined;
1278
+ } | undefined;
1279
+ }[];
1280
+ meta?: Record<string, unknown> | undefined;
1281
+ }>;
1282
+ 401: z.ZodObject<{
1283
+ errors: z.ZodArray<z.ZodObject<{
1284
+ id: z.ZodOptional<z.ZodString>;
1285
+ links: z.ZodOptional<z.ZodObject<{
1286
+ about: z.ZodOptional<z.ZodString>;
1287
+ }, "strip", z.ZodTypeAny, {
1288
+ about?: string | undefined;
1289
+ }, {
1290
+ about?: string | undefined;
1291
+ }>>;
1292
+ status: z.ZodOptional<z.ZodString>;
1293
+ code: z.ZodOptional<z.ZodString>;
1294
+ title: z.ZodOptional<z.ZodString>;
1295
+ detail: z.ZodOptional<z.ZodString>;
1296
+ source: z.ZodOptional<z.ZodObject<{
1297
+ pointer: z.ZodOptional<z.ZodString>;
1298
+ parameter: z.ZodOptional<z.ZodString>;
1299
+ }, "strip", z.ZodTypeAny, {
1300
+ pointer?: string | undefined;
1301
+ parameter?: string | undefined;
1302
+ }, {
1303
+ pointer?: string | undefined;
1304
+ parameter?: string | undefined;
1305
+ }>>;
1306
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
1307
+ }, "strip", z.ZodTypeAny, {
1308
+ status?: string | undefined;
1309
+ code?: string | undefined;
1310
+ id?: string | undefined;
1311
+ links?: {
1312
+ about?: string | undefined;
1313
+ } | undefined;
1314
+ meta?: Record<string, unknown> | undefined;
1315
+ title?: string | undefined;
1316
+ detail?: string | undefined;
1317
+ source?: {
1318
+ pointer?: string | undefined;
1319
+ parameter?: string | undefined;
1320
+ } | undefined;
1321
+ }, {
1322
+ status?: string | undefined;
1323
+ code?: string | undefined;
1324
+ id?: string | undefined;
1325
+ links?: {
1326
+ about?: string | undefined;
1327
+ } | undefined;
1328
+ meta?: Record<string, unknown> | undefined;
1329
+ title?: string | undefined;
1330
+ detail?: string | undefined;
1331
+ source?: {
1332
+ pointer?: string | undefined;
1333
+ parameter?: string | undefined;
1334
+ } | undefined;
1335
+ }>, "many">;
1336
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
1337
+ }, "strip", z.ZodTypeAny, {
1338
+ errors: {
1339
+ status?: string | undefined;
1340
+ code?: string | undefined;
1341
+ id?: string | undefined;
1342
+ links?: {
1343
+ about?: string | undefined;
1344
+ } | undefined;
1345
+ meta?: Record<string, unknown> | undefined;
1346
+ title?: string | undefined;
1347
+ detail?: string | undefined;
1348
+ source?: {
1349
+ pointer?: string | undefined;
1350
+ parameter?: string | undefined;
1351
+ } | undefined;
1352
+ }[];
1353
+ meta?: Record<string, unknown> | undefined;
1354
+ }, {
1355
+ errors: {
1356
+ status?: string | undefined;
1357
+ code?: string | undefined;
1358
+ id?: string | undefined;
1359
+ links?: {
1360
+ about?: string | undefined;
1361
+ } | undefined;
1362
+ meta?: Record<string, unknown> | undefined;
1363
+ title?: string | undefined;
1364
+ detail?: string | undefined;
1365
+ source?: {
1366
+ pointer?: string | undefined;
1367
+ parameter?: string | undefined;
1368
+ } | undefined;
1369
+ }[];
1370
+ meta?: Record<string, unknown> | undefined;
1371
+ }>;
1372
+ 422: z.ZodObject<{
1373
+ errors: z.ZodArray<z.ZodObject<{
1374
+ id: z.ZodOptional<z.ZodString>;
1375
+ links: z.ZodOptional<z.ZodObject<{
1376
+ about: z.ZodOptional<z.ZodString>;
1377
+ }, "strip", z.ZodTypeAny, {
1378
+ about?: string | undefined;
1379
+ }, {
1380
+ about?: string | undefined;
1381
+ }>>;
1382
+ status: z.ZodOptional<z.ZodString>;
1383
+ code: z.ZodOptional<z.ZodString>;
1384
+ title: z.ZodOptional<z.ZodString>;
1385
+ detail: z.ZodOptional<z.ZodString>;
1386
+ source: z.ZodOptional<z.ZodObject<{
1387
+ pointer: z.ZodOptional<z.ZodString>;
1388
+ parameter: z.ZodOptional<z.ZodString>;
1389
+ }, "strip", z.ZodTypeAny, {
1390
+ pointer?: string | undefined;
1391
+ parameter?: string | undefined;
1392
+ }, {
1393
+ pointer?: string | undefined;
1394
+ parameter?: string | undefined;
1395
+ }>>;
1396
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
1397
+ }, "strip", z.ZodTypeAny, {
1398
+ status?: string | undefined;
1399
+ code?: string | undefined;
1400
+ id?: string | undefined;
1401
+ links?: {
1402
+ about?: string | undefined;
1403
+ } | undefined;
1404
+ meta?: Record<string, unknown> | undefined;
1405
+ title?: string | undefined;
1406
+ detail?: string | undefined;
1407
+ source?: {
1408
+ pointer?: string | undefined;
1409
+ parameter?: string | undefined;
1410
+ } | undefined;
1411
+ }, {
1412
+ status?: string | undefined;
1413
+ code?: string | undefined;
1414
+ id?: string | undefined;
1415
+ links?: {
1416
+ about?: string | undefined;
1417
+ } | undefined;
1418
+ meta?: Record<string, unknown> | undefined;
1419
+ title?: string | undefined;
1420
+ detail?: string | undefined;
1421
+ source?: {
1422
+ pointer?: string | undefined;
1423
+ parameter?: string | undefined;
1424
+ } | undefined;
1425
+ }>, "many">;
1426
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
1427
+ }, "strip", z.ZodTypeAny, {
1428
+ errors: {
1429
+ status?: string | undefined;
1430
+ code?: string | undefined;
1431
+ id?: string | undefined;
1432
+ links?: {
1433
+ about?: string | undefined;
1434
+ } | undefined;
1435
+ meta?: Record<string, unknown> | undefined;
1436
+ title?: string | undefined;
1437
+ detail?: string | undefined;
1438
+ source?: {
1439
+ pointer?: string | undefined;
1440
+ parameter?: string | undefined;
1441
+ } | undefined;
1442
+ }[];
1443
+ meta?: Record<string, unknown> | undefined;
1444
+ }, {
1445
+ errors: {
1446
+ status?: string | undefined;
1447
+ code?: string | undefined;
1448
+ id?: string | undefined;
1449
+ links?: {
1450
+ about?: string | undefined;
1451
+ } | undefined;
1452
+ meta?: Record<string, unknown> | undefined;
1453
+ title?: string | undefined;
1454
+ detail?: string | undefined;
1455
+ source?: {
1456
+ pointer?: string | undefined;
1457
+ parameter?: string | undefined;
1458
+ } | undefined;
1459
+ }[];
1460
+ meta?: Record<string, unknown> | undefined;
1461
+ }>;
1462
+ };
1463
+ };
1464
+ getField: {
1465
+ pathParams: z.ZodObject<{
1466
+ farmId: z.ZodString;
1467
+ id: z.ZodString;
1468
+ }, "strip", z.ZodTypeAny, {
1469
+ id: string;
1470
+ farmId: string;
1471
+ }, {
1472
+ id: string;
1473
+ farmId: string;
1474
+ }>;
1475
+ query: z.ZodObject<{
1476
+ include: z.ZodOptional<z.ZodString>;
1477
+ }, "strip", z.ZodTypeAny, {
1478
+ include?: string | undefined;
1479
+ }, {
1480
+ include?: string | undefined;
1481
+ }>;
1482
+ summary: "Get field by ID";
1483
+ description: "Get detailed information about a specific field";
1484
+ method: "GET";
1485
+ path: "/farms/:farmId/fields/:id";
1486
+ responses: {
1487
+ 200: z.ZodObject<{
1488
+ data: z.ZodObject<{
1489
+ type: z.ZodLiteral<string>;
1490
+ id: z.ZodString;
1491
+ attributes: z.ZodObject<{
1492
+ name: z.ZodString;
1493
+ geometry: z.ZodNullable<z.ZodObject<{
1494
+ type: z.ZodEnum<["Polygon", "MultiPolygon", "Point", "LineString"]>;
1495
+ coordinates: z.ZodUnion<[z.ZodArray<z.ZodArray<z.ZodArray<z.ZodNumber, "many">, "many">, "many">, z.ZodArray<z.ZodArray<z.ZodArray<z.ZodArray<z.ZodNumber, "many">, "many">, "many">, "many">, z.ZodArray<z.ZodNumber, "many">, z.ZodArray<z.ZodArray<z.ZodNumber, "many">, "many">]>;
1496
+ }, "strip", z.ZodTypeAny, {
1497
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
1498
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
1499
+ }, {
1500
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
1501
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
1502
+ }>>;
1503
+ ndvi: z.ZodNullable<z.ZodNumber>;
1504
+ moisture: z.ZodNullable<z.ZodString>;
1505
+ status: z.ZodEnum<["ok", "alert", "critical"]>;
1506
+ area: z.ZodNullable<z.ZodString>;
1507
+ crop: z.ZodNullable<z.ZodString>;
1508
+ soilType: z.ZodNullable<z.ZodString>;
1509
+ currentCrop: z.ZodNullable<z.ZodString>;
1510
+ plantingDate: z.ZodNullable<z.ZodString>;
1511
+ expectedHarvestDate: z.ZodNullable<z.ZodString>;
1512
+ cropStage: z.ZodNullable<z.ZodEnum<["planted", "growing", "flowering", "mature", "harvested"]>>;
1513
+ historicalNdvi: z.ZodOptional<z.ZodArray<z.ZodObject<{
1514
+ date: z.ZodString;
1515
+ value: z.ZodNumber;
1516
+ }, "strip", z.ZodTypeAny, {
1517
+ value: number;
1518
+ date: string;
1519
+ }, {
1520
+ value: number;
1521
+ date: string;
1522
+ }>, "many">>;
1523
+ cropHistory: z.ZodOptional<z.ZodArray<z.ZodObject<{
1524
+ id: z.ZodString;
1525
+ season: z.ZodString;
1526
+ crop: z.ZodString;
1527
+ plantingDate: z.ZodString;
1528
+ harvestDate: z.ZodNullable<z.ZodString>;
1529
+ yield: z.ZodNullable<z.ZodNumber>;
1530
+ yieldUnit: z.ZodNullable<z.ZodString>;
1531
+ }, "strip", z.ZodTypeAny, {
1532
+ id: string;
1533
+ season: string;
1534
+ crop: string;
1535
+ plantingDate: string;
1536
+ harvestDate: string | null;
1537
+ yield: number | null;
1538
+ yieldUnit: string | null;
1539
+ }, {
1540
+ id: string;
1541
+ season: string;
1542
+ crop: string;
1543
+ plantingDate: string;
1544
+ harvestDate: string | null;
1545
+ yield: number | null;
1546
+ yieldUnit: string | null;
1547
+ }>, "many">>;
1548
+ } & {
1549
+ createdAt: z.ZodString;
1550
+ updatedAt: z.ZodString;
1551
+ }, "strip", z.ZodTypeAny, {
1552
+ status: "ok" | "alert" | "critical";
1553
+ createdAt: string;
1554
+ updatedAt: string;
1555
+ name: string;
1556
+ crop: string | null;
1557
+ plantingDate: string | null;
1558
+ geometry: {
1559
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
1560
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
1561
+ } | null;
1562
+ ndvi: number | null;
1563
+ moisture: string | null;
1564
+ area: string | null;
1565
+ soilType: string | null;
1566
+ currentCrop: string | null;
1567
+ expectedHarvestDate: string | null;
1568
+ cropStage: "planted" | "growing" | "flowering" | "mature" | "harvested" | null;
1569
+ historicalNdvi?: {
1570
+ value: number;
1571
+ date: string;
1572
+ }[] | undefined;
1573
+ cropHistory?: {
1574
+ id: string;
1575
+ season: string;
1576
+ crop: string;
1577
+ plantingDate: string;
1578
+ harvestDate: string | null;
1579
+ yield: number | null;
1580
+ yieldUnit: string | null;
1581
+ }[] | undefined;
1582
+ }, {
1583
+ status: "ok" | "alert" | "critical";
1584
+ createdAt: string;
1585
+ updatedAt: string;
1586
+ name: string;
1587
+ crop: string | null;
1588
+ plantingDate: string | null;
1589
+ geometry: {
1590
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
1591
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
1592
+ } | null;
1593
+ ndvi: number | null;
1594
+ moisture: string | null;
1595
+ area: string | null;
1596
+ soilType: string | null;
1597
+ currentCrop: string | null;
1598
+ expectedHarvestDate: string | null;
1599
+ cropStage: "planted" | "growing" | "flowering" | "mature" | "harvested" | null;
1600
+ historicalNdvi?: {
1601
+ value: number;
1602
+ date: string;
1603
+ }[] | undefined;
1604
+ cropHistory?: {
1605
+ id: string;
1606
+ season: string;
1607
+ crop: string;
1608
+ plantingDate: string;
1609
+ harvestDate: string | null;
1610
+ yield: number | null;
1611
+ yieldUnit: string | null;
1612
+ }[] | undefined;
1613
+ }>;
1614
+ links: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
1615
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
1616
+ } & {
1617
+ relationships: z.ZodOptional<z.ZodObject<{
1618
+ farm: z.ZodObject<{
1619
+ data: z.ZodObject<{
1620
+ type: z.ZodLiteral<"farms">;
1621
+ id: z.ZodString;
1622
+ }, "strip", z.ZodTypeAny, {
1623
+ type: "farms";
1624
+ id: string;
1625
+ }, {
1626
+ type: "farms";
1627
+ id: string;
1628
+ }>;
1629
+ links: z.ZodObject<{
1630
+ related: z.ZodString;
1631
+ }, "strip", z.ZodTypeAny, {
1632
+ related: string;
1633
+ }, {
1634
+ related: string;
1635
+ }>;
1636
+ }, "strip", z.ZodTypeAny, {
1637
+ links: {
1638
+ related: string;
1639
+ };
1640
+ data: {
1641
+ type: "farms";
1642
+ id: string;
1643
+ };
1644
+ }, {
1645
+ links: {
1646
+ related: string;
1647
+ };
1648
+ data: {
1649
+ type: "farms";
1650
+ id: string;
1651
+ };
1652
+ }>;
1653
+ tasks: z.ZodOptional<z.ZodObject<{
1654
+ meta: z.ZodObject<{
1655
+ count: z.ZodNumber;
1656
+ }, "strip", z.ZodTypeAny, {
1657
+ count: number;
1658
+ }, {
1659
+ count: number;
1660
+ }>;
1661
+ links: z.ZodObject<{
1662
+ related: z.ZodString;
1663
+ }, "strip", z.ZodTypeAny, {
1664
+ related: string;
1665
+ }, {
1666
+ related: string;
1667
+ }>;
1668
+ }, "strip", z.ZodTypeAny, {
1669
+ links: {
1670
+ related: string;
1671
+ };
1672
+ meta: {
1673
+ count: number;
1674
+ };
1675
+ }, {
1676
+ links: {
1677
+ related: string;
1678
+ };
1679
+ meta: {
1680
+ count: number;
1681
+ };
1682
+ }>>;
1683
+ harvests: z.ZodOptional<z.ZodObject<{
1684
+ meta: z.ZodObject<{
1685
+ count: z.ZodNumber;
1686
+ }, "strip", z.ZodTypeAny, {
1687
+ count: number;
1688
+ }, {
1689
+ count: number;
1690
+ }>;
1691
+ links: z.ZodObject<{
1692
+ related: z.ZodString;
1693
+ }, "strip", z.ZodTypeAny, {
1694
+ related: string;
1695
+ }, {
1696
+ related: string;
1697
+ }>;
1698
+ }, "strip", z.ZodTypeAny, {
1699
+ links: {
1700
+ related: string;
1701
+ };
1702
+ meta: {
1703
+ count: number;
1704
+ };
1705
+ }, {
1706
+ links: {
1707
+ related: string;
1708
+ };
1709
+ meta: {
1710
+ count: number;
1711
+ };
1712
+ }>>;
1713
+ soilTests: z.ZodOptional<z.ZodObject<{
1714
+ meta: z.ZodObject<{
1715
+ count: z.ZodNumber;
1716
+ }, "strip", z.ZodTypeAny, {
1717
+ count: number;
1718
+ }, {
1719
+ count: number;
1720
+ }>;
1721
+ links: z.ZodObject<{
1722
+ related: z.ZodString;
1723
+ }, "strip", z.ZodTypeAny, {
1724
+ related: string;
1725
+ }, {
1726
+ related: string;
1727
+ }>;
1728
+ }, "strip", z.ZodTypeAny, {
1729
+ links: {
1730
+ related: string;
1731
+ };
1732
+ meta: {
1733
+ count: number;
1734
+ };
1735
+ }, {
1736
+ links: {
1737
+ related: string;
1738
+ };
1739
+ meta: {
1740
+ count: number;
1741
+ };
1742
+ }>>;
1743
+ }, "strip", z.ZodTypeAny, {
1744
+ farm: {
1745
+ links: {
1746
+ related: string;
1747
+ };
1748
+ data: {
1749
+ type: "farms";
1750
+ id: string;
1751
+ };
1752
+ };
1753
+ tasks?: {
1754
+ links: {
1755
+ related: string;
1756
+ };
1757
+ meta: {
1758
+ count: number;
1759
+ };
1760
+ } | undefined;
1761
+ harvests?: {
1762
+ links: {
1763
+ related: string;
1764
+ };
1765
+ meta: {
1766
+ count: number;
1767
+ };
1768
+ } | undefined;
1769
+ soilTests?: {
1770
+ links: {
1771
+ related: string;
1772
+ };
1773
+ meta: {
1774
+ count: number;
1775
+ };
1776
+ } | undefined;
1777
+ }, {
1778
+ farm: {
1779
+ links: {
1780
+ related: string;
1781
+ };
1782
+ data: {
1783
+ type: "farms";
1784
+ id: string;
1785
+ };
1786
+ };
1787
+ tasks?: {
1788
+ links: {
1789
+ related: string;
1790
+ };
1791
+ meta: {
1792
+ count: number;
1793
+ };
1794
+ } | undefined;
1795
+ harvests?: {
1796
+ links: {
1797
+ related: string;
1798
+ };
1799
+ meta: {
1800
+ count: number;
1801
+ };
1802
+ } | undefined;
1803
+ soilTests?: {
1804
+ links: {
1805
+ related: string;
1806
+ };
1807
+ meta: {
1808
+ count: number;
1809
+ };
1810
+ } | undefined;
1811
+ }>>;
1812
+ }, "strip", z.ZodTypeAny, {
1813
+ type: string;
1814
+ id: string;
1815
+ attributes: {
1816
+ status: "ok" | "alert" | "critical";
1817
+ createdAt: string;
1818
+ updatedAt: string;
1819
+ name: string;
1820
+ crop: string | null;
1821
+ plantingDate: string | null;
1822
+ geometry: {
1823
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
1824
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
1825
+ } | null;
1826
+ ndvi: number | null;
1827
+ moisture: string | null;
1828
+ area: string | null;
1829
+ soilType: string | null;
1830
+ currentCrop: string | null;
1831
+ expectedHarvestDate: string | null;
1832
+ cropStage: "planted" | "growing" | "flowering" | "mature" | "harvested" | null;
1833
+ historicalNdvi?: {
1834
+ value: number;
1835
+ date: string;
1836
+ }[] | undefined;
1837
+ cropHistory?: {
1838
+ id: string;
1839
+ season: string;
1840
+ crop: string;
1841
+ plantingDate: string;
1842
+ harvestDate: string | null;
1843
+ yield: number | null;
1844
+ yieldUnit: string | null;
1845
+ }[] | undefined;
1846
+ };
1847
+ relationships?: {
1848
+ farm: {
1849
+ links: {
1850
+ related: string;
1851
+ };
1852
+ data: {
1853
+ type: "farms";
1854
+ id: string;
1855
+ };
1856
+ };
1857
+ tasks?: {
1858
+ links: {
1859
+ related: string;
1860
+ };
1861
+ meta: {
1862
+ count: number;
1863
+ };
1864
+ } | undefined;
1865
+ harvests?: {
1866
+ links: {
1867
+ related: string;
1868
+ };
1869
+ meta: {
1870
+ count: number;
1871
+ };
1872
+ } | undefined;
1873
+ soilTests?: {
1874
+ links: {
1875
+ related: string;
1876
+ };
1877
+ meta: {
1878
+ count: number;
1879
+ };
1880
+ } | undefined;
1881
+ } | undefined;
1882
+ links?: Record<string, string> | undefined;
1883
+ meta?: Record<string, unknown> | undefined;
1884
+ }, {
1885
+ type: string;
1886
+ id: string;
1887
+ attributes: {
1888
+ status: "ok" | "alert" | "critical";
1889
+ createdAt: string;
1890
+ updatedAt: string;
1891
+ name: string;
1892
+ crop: string | null;
1893
+ plantingDate: string | null;
1894
+ geometry: {
1895
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
1896
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
1897
+ } | null;
1898
+ ndvi: number | null;
1899
+ moisture: string | null;
1900
+ area: string | null;
1901
+ soilType: string | null;
1902
+ currentCrop: string | null;
1903
+ expectedHarvestDate: string | null;
1904
+ cropStage: "planted" | "growing" | "flowering" | "mature" | "harvested" | null;
1905
+ historicalNdvi?: {
1906
+ value: number;
1907
+ date: string;
1908
+ }[] | undefined;
1909
+ cropHistory?: {
1910
+ id: string;
1911
+ season: string;
1912
+ crop: string;
1913
+ plantingDate: string;
1914
+ harvestDate: string | null;
1915
+ yield: number | null;
1916
+ yieldUnit: string | null;
1917
+ }[] | undefined;
1918
+ };
1919
+ relationships?: {
1920
+ farm: {
1921
+ links: {
1922
+ related: string;
1923
+ };
1924
+ data: {
1925
+ type: "farms";
1926
+ id: string;
1927
+ };
1928
+ };
1929
+ tasks?: {
1930
+ links: {
1931
+ related: string;
1932
+ };
1933
+ meta: {
1934
+ count: number;
1935
+ };
1936
+ } | undefined;
1937
+ harvests?: {
1938
+ links: {
1939
+ related: string;
1940
+ };
1941
+ meta: {
1942
+ count: number;
1943
+ };
1944
+ } | undefined;
1945
+ soilTests?: {
1946
+ links: {
1947
+ related: string;
1948
+ };
1949
+ meta: {
1950
+ count: number;
1951
+ };
1952
+ } | undefined;
1953
+ } | undefined;
1954
+ links?: Record<string, string> | undefined;
1955
+ meta?: Record<string, unknown> | undefined;
1956
+ }>;
1957
+ included: z.ZodOptional<z.ZodArray<z.ZodObject<{
1958
+ type: z.ZodString;
1959
+ id: z.ZodString;
1960
+ attributes: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
1961
+ relationships: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
1962
+ links: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
1963
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
1964
+ }, "strip", z.ZodTypeAny, {
1965
+ type: string;
1966
+ id: string;
1967
+ attributes?: Record<string, unknown> | undefined;
1968
+ relationships?: Record<string, unknown> | undefined;
1969
+ links?: Record<string, string> | undefined;
1970
+ meta?: Record<string, unknown> | undefined;
1971
+ }, {
1972
+ type: string;
1973
+ id: string;
1974
+ attributes?: Record<string, unknown> | undefined;
1975
+ relationships?: Record<string, unknown> | undefined;
1976
+ links?: Record<string, string> | undefined;
1977
+ meta?: Record<string, unknown> | undefined;
1978
+ }>, "many">>;
1979
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
1980
+ links: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
1981
+ }, "strip", z.ZodTypeAny, {
1982
+ data: {
1983
+ type: string;
1984
+ id: string;
1985
+ attributes: {
1986
+ status: "ok" | "alert" | "critical";
1987
+ createdAt: string;
1988
+ updatedAt: string;
1989
+ name: string;
1990
+ crop: string | null;
1991
+ plantingDate: string | null;
1992
+ geometry: {
1993
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
1994
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
1995
+ } | null;
1996
+ ndvi: number | null;
1997
+ moisture: string | null;
1998
+ area: string | null;
1999
+ soilType: string | null;
2000
+ currentCrop: string | null;
2001
+ expectedHarvestDate: string | null;
2002
+ cropStage: "planted" | "growing" | "flowering" | "mature" | "harvested" | null;
2003
+ historicalNdvi?: {
2004
+ value: number;
2005
+ date: string;
2006
+ }[] | undefined;
2007
+ cropHistory?: {
2008
+ id: string;
2009
+ season: string;
2010
+ crop: string;
2011
+ plantingDate: string;
2012
+ harvestDate: string | null;
2013
+ yield: number | null;
2014
+ yieldUnit: string | null;
2015
+ }[] | undefined;
2016
+ };
2017
+ relationships?: {
2018
+ farm: {
2019
+ links: {
2020
+ related: string;
2021
+ };
2022
+ data: {
2023
+ type: "farms";
2024
+ id: string;
2025
+ };
2026
+ };
2027
+ tasks?: {
2028
+ links: {
2029
+ related: string;
2030
+ };
2031
+ meta: {
2032
+ count: number;
2033
+ };
2034
+ } | undefined;
2035
+ harvests?: {
2036
+ links: {
2037
+ related: string;
2038
+ };
2039
+ meta: {
2040
+ count: number;
2041
+ };
2042
+ } | undefined;
2043
+ soilTests?: {
2044
+ links: {
2045
+ related: string;
2046
+ };
2047
+ meta: {
2048
+ count: number;
2049
+ };
2050
+ } | undefined;
2051
+ } | undefined;
2052
+ links?: Record<string, string> | undefined;
2053
+ meta?: Record<string, unknown> | undefined;
2054
+ };
2055
+ links?: Record<string, string> | undefined;
2056
+ meta?: Record<string, unknown> | undefined;
2057
+ included?: {
2058
+ type: string;
2059
+ id: string;
2060
+ attributes?: Record<string, unknown> | undefined;
2061
+ relationships?: Record<string, unknown> | undefined;
2062
+ links?: Record<string, string> | undefined;
2063
+ meta?: Record<string, unknown> | undefined;
2064
+ }[] | undefined;
2065
+ }, {
2066
+ data: {
2067
+ type: string;
2068
+ id: string;
2069
+ attributes: {
2070
+ status: "ok" | "alert" | "critical";
2071
+ createdAt: string;
2072
+ updatedAt: string;
2073
+ name: string;
2074
+ crop: string | null;
2075
+ plantingDate: string | null;
2076
+ geometry: {
2077
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
2078
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
2079
+ } | null;
2080
+ ndvi: number | null;
2081
+ moisture: string | null;
2082
+ area: string | null;
2083
+ soilType: string | null;
2084
+ currentCrop: string | null;
2085
+ expectedHarvestDate: string | null;
2086
+ cropStage: "planted" | "growing" | "flowering" | "mature" | "harvested" | null;
2087
+ historicalNdvi?: {
2088
+ value: number;
2089
+ date: string;
2090
+ }[] | undefined;
2091
+ cropHistory?: {
2092
+ id: string;
2093
+ season: string;
2094
+ crop: string;
2095
+ plantingDate: string;
2096
+ harvestDate: string | null;
2097
+ yield: number | null;
2098
+ yieldUnit: string | null;
2099
+ }[] | undefined;
2100
+ };
2101
+ relationships?: {
2102
+ farm: {
2103
+ links: {
2104
+ related: string;
2105
+ };
2106
+ data: {
2107
+ type: "farms";
2108
+ id: string;
2109
+ };
2110
+ };
2111
+ tasks?: {
2112
+ links: {
2113
+ related: string;
2114
+ };
2115
+ meta: {
2116
+ count: number;
2117
+ };
2118
+ } | undefined;
2119
+ harvests?: {
2120
+ links: {
2121
+ related: string;
2122
+ };
2123
+ meta: {
2124
+ count: number;
2125
+ };
2126
+ } | undefined;
2127
+ soilTests?: {
2128
+ links: {
2129
+ related: string;
2130
+ };
2131
+ meta: {
2132
+ count: number;
2133
+ };
2134
+ } | undefined;
2135
+ } | undefined;
2136
+ links?: Record<string, string> | undefined;
2137
+ meta?: Record<string, unknown> | undefined;
2138
+ };
2139
+ links?: Record<string, string> | undefined;
2140
+ meta?: Record<string, unknown> | undefined;
2141
+ included?: {
2142
+ type: string;
2143
+ id: string;
2144
+ attributes?: Record<string, unknown> | undefined;
2145
+ relationships?: Record<string, unknown> | undefined;
2146
+ links?: Record<string, string> | undefined;
2147
+ meta?: Record<string, unknown> | undefined;
2148
+ }[] | undefined;
2149
+ }>;
2150
+ 404: z.ZodObject<{
2151
+ errors: z.ZodArray<z.ZodObject<{
2152
+ id: z.ZodOptional<z.ZodString>;
2153
+ links: z.ZodOptional<z.ZodObject<{
2154
+ about: z.ZodOptional<z.ZodString>;
2155
+ }, "strip", z.ZodTypeAny, {
2156
+ about?: string | undefined;
2157
+ }, {
2158
+ about?: string | undefined;
2159
+ }>>;
2160
+ status: z.ZodOptional<z.ZodString>;
2161
+ code: z.ZodOptional<z.ZodString>;
2162
+ title: z.ZodOptional<z.ZodString>;
2163
+ detail: z.ZodOptional<z.ZodString>;
2164
+ source: z.ZodOptional<z.ZodObject<{
2165
+ pointer: z.ZodOptional<z.ZodString>;
2166
+ parameter: z.ZodOptional<z.ZodString>;
2167
+ }, "strip", z.ZodTypeAny, {
2168
+ pointer?: string | undefined;
2169
+ parameter?: string | undefined;
2170
+ }, {
2171
+ pointer?: string | undefined;
2172
+ parameter?: string | undefined;
2173
+ }>>;
2174
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
2175
+ }, "strip", z.ZodTypeAny, {
2176
+ status?: string | undefined;
2177
+ code?: string | undefined;
2178
+ id?: string | undefined;
2179
+ links?: {
2180
+ about?: string | undefined;
2181
+ } | undefined;
2182
+ meta?: Record<string, unknown> | undefined;
2183
+ title?: string | undefined;
2184
+ detail?: string | undefined;
2185
+ source?: {
2186
+ pointer?: string | undefined;
2187
+ parameter?: string | undefined;
2188
+ } | undefined;
2189
+ }, {
2190
+ status?: string | undefined;
2191
+ code?: string | undefined;
2192
+ id?: string | undefined;
2193
+ links?: {
2194
+ about?: string | undefined;
2195
+ } | undefined;
2196
+ meta?: Record<string, unknown> | undefined;
2197
+ title?: string | undefined;
2198
+ detail?: string | undefined;
2199
+ source?: {
2200
+ pointer?: string | undefined;
2201
+ parameter?: string | undefined;
2202
+ } | undefined;
2203
+ }>, "many">;
2204
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
2205
+ }, "strip", z.ZodTypeAny, {
2206
+ errors: {
2207
+ status?: string | undefined;
2208
+ code?: string | undefined;
2209
+ id?: string | undefined;
2210
+ links?: {
2211
+ about?: string | undefined;
2212
+ } | undefined;
2213
+ meta?: Record<string, unknown> | undefined;
2214
+ title?: string | undefined;
2215
+ detail?: string | undefined;
2216
+ source?: {
2217
+ pointer?: string | undefined;
2218
+ parameter?: string | undefined;
2219
+ } | undefined;
2220
+ }[];
2221
+ meta?: Record<string, unknown> | undefined;
2222
+ }, {
2223
+ errors: {
2224
+ status?: string | undefined;
2225
+ code?: string | undefined;
2226
+ id?: string | undefined;
2227
+ links?: {
2228
+ about?: string | undefined;
2229
+ } | undefined;
2230
+ meta?: Record<string, unknown> | undefined;
2231
+ title?: string | undefined;
2232
+ detail?: string | undefined;
2233
+ source?: {
2234
+ pointer?: string | undefined;
2235
+ parameter?: string | undefined;
2236
+ } | undefined;
2237
+ }[];
2238
+ meta?: Record<string, unknown> | undefined;
2239
+ }>;
2240
+ 401: z.ZodObject<{
2241
+ errors: z.ZodArray<z.ZodObject<{
2242
+ id: z.ZodOptional<z.ZodString>;
2243
+ links: z.ZodOptional<z.ZodObject<{
2244
+ about: z.ZodOptional<z.ZodString>;
2245
+ }, "strip", z.ZodTypeAny, {
2246
+ about?: string | undefined;
2247
+ }, {
2248
+ about?: string | undefined;
2249
+ }>>;
2250
+ status: z.ZodOptional<z.ZodString>;
2251
+ code: z.ZodOptional<z.ZodString>;
2252
+ title: z.ZodOptional<z.ZodString>;
2253
+ detail: z.ZodOptional<z.ZodString>;
2254
+ source: z.ZodOptional<z.ZodObject<{
2255
+ pointer: z.ZodOptional<z.ZodString>;
2256
+ parameter: z.ZodOptional<z.ZodString>;
2257
+ }, "strip", z.ZodTypeAny, {
2258
+ pointer?: string | undefined;
2259
+ parameter?: string | undefined;
2260
+ }, {
2261
+ pointer?: string | undefined;
2262
+ parameter?: string | undefined;
2263
+ }>>;
2264
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
2265
+ }, "strip", z.ZodTypeAny, {
2266
+ status?: string | undefined;
2267
+ code?: string | undefined;
2268
+ id?: string | undefined;
2269
+ links?: {
2270
+ about?: string | undefined;
2271
+ } | undefined;
2272
+ meta?: Record<string, unknown> | undefined;
2273
+ title?: string | undefined;
2274
+ detail?: string | undefined;
2275
+ source?: {
2276
+ pointer?: string | undefined;
2277
+ parameter?: string | undefined;
2278
+ } | undefined;
2279
+ }, {
2280
+ status?: string | undefined;
2281
+ code?: string | undefined;
2282
+ id?: string | undefined;
2283
+ links?: {
2284
+ about?: string | undefined;
2285
+ } | undefined;
2286
+ meta?: Record<string, unknown> | undefined;
2287
+ title?: string | undefined;
2288
+ detail?: string | undefined;
2289
+ source?: {
2290
+ pointer?: string | undefined;
2291
+ parameter?: string | undefined;
2292
+ } | undefined;
2293
+ }>, "many">;
2294
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
2295
+ }, "strip", z.ZodTypeAny, {
2296
+ errors: {
2297
+ status?: string | undefined;
2298
+ code?: string | undefined;
2299
+ id?: string | undefined;
2300
+ links?: {
2301
+ about?: string | undefined;
2302
+ } | undefined;
2303
+ meta?: Record<string, unknown> | undefined;
2304
+ title?: string | undefined;
2305
+ detail?: string | undefined;
2306
+ source?: {
2307
+ pointer?: string | undefined;
2308
+ parameter?: string | undefined;
2309
+ } | undefined;
2310
+ }[];
2311
+ meta?: Record<string, unknown> | undefined;
2312
+ }, {
2313
+ errors: {
2314
+ status?: string | undefined;
2315
+ code?: string | undefined;
2316
+ id?: string | undefined;
2317
+ links?: {
2318
+ about?: string | undefined;
2319
+ } | undefined;
2320
+ meta?: Record<string, unknown> | undefined;
2321
+ title?: string | undefined;
2322
+ detail?: string | undefined;
2323
+ source?: {
2324
+ pointer?: string | undefined;
2325
+ parameter?: string | undefined;
2326
+ } | undefined;
2327
+ }[];
2328
+ meta?: Record<string, unknown> | undefined;
2329
+ }>;
2330
+ };
2331
+ };
2332
+ updateField: {
2333
+ pathParams: z.ZodObject<{
2334
+ farmId: z.ZodString;
2335
+ id: z.ZodString;
2336
+ }, "strip", z.ZodTypeAny, {
2337
+ id: string;
2338
+ farmId: string;
2339
+ }, {
2340
+ id: string;
2341
+ farmId: string;
2342
+ }>;
2343
+ summary: "Update field";
2344
+ description: "Update field information including geometry and crop lifecycle";
2345
+ method: "PATCH";
2346
+ body: z.ZodObject<{
2347
+ data: z.ZodObject<{
2348
+ type: z.ZodLiteral<"fields">;
2349
+ id: z.ZodString;
2350
+ attributes: z.ZodObject<{
2351
+ name: z.ZodOptional<z.ZodString>;
2352
+ geometry: z.ZodOptional<z.ZodOptional<z.ZodObject<{
2353
+ type: z.ZodEnum<["Polygon", "MultiPolygon", "Point", "LineString"]>;
2354
+ coordinates: z.ZodUnion<[z.ZodArray<z.ZodArray<z.ZodArray<z.ZodNumber, "many">, "many">, "many">, z.ZodArray<z.ZodArray<z.ZodArray<z.ZodArray<z.ZodNumber, "many">, "many">, "many">, "many">, z.ZodArray<z.ZodNumber, "many">, z.ZodArray<z.ZodArray<z.ZodNumber, "many">, "many">]>;
2355
+ }, "strip", z.ZodTypeAny, {
2356
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
2357
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
2358
+ }, {
2359
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
2360
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
2361
+ }>>>;
2362
+ ndvi: z.ZodOptional<z.ZodOptional<z.ZodNumber>>;
2363
+ moisture: z.ZodOptional<z.ZodOptional<z.ZodString>>;
2364
+ crop: z.ZodOptional<z.ZodOptional<z.ZodString>>;
2365
+ soilType: z.ZodOptional<z.ZodOptional<z.ZodString>>;
2366
+ currentCrop: z.ZodOptional<z.ZodOptional<z.ZodString>>;
2367
+ plantingDate: z.ZodOptional<z.ZodOptional<z.ZodString>>;
2368
+ expectedHarvestDate: z.ZodOptional<z.ZodOptional<z.ZodString>>;
2369
+ cropStage: z.ZodOptional<z.ZodOptional<z.ZodEnum<["planted", "growing", "flowering", "mature", "harvested"]>>>;
2370
+ }, "strip", z.ZodTypeAny, {
2371
+ name?: string | undefined;
2372
+ crop?: string | undefined;
2373
+ plantingDate?: string | undefined;
2374
+ geometry?: {
2375
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
2376
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
2377
+ } | undefined;
2378
+ ndvi?: number | undefined;
2379
+ moisture?: string | undefined;
2380
+ soilType?: string | undefined;
2381
+ currentCrop?: string | undefined;
2382
+ expectedHarvestDate?: string | undefined;
2383
+ cropStage?: "planted" | "growing" | "flowering" | "mature" | "harvested" | undefined;
2384
+ }, {
2385
+ name?: string | undefined;
2386
+ crop?: string | undefined;
2387
+ plantingDate?: string | undefined;
2388
+ geometry?: {
2389
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
2390
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
2391
+ } | undefined;
2392
+ ndvi?: number | undefined;
2393
+ moisture?: string | undefined;
2394
+ soilType?: string | undefined;
2395
+ currentCrop?: string | undefined;
2396
+ expectedHarvestDate?: string | undefined;
2397
+ cropStage?: "planted" | "growing" | "flowering" | "mature" | "harvested" | undefined;
2398
+ }>;
2399
+ }, "strip", z.ZodTypeAny, {
2400
+ type: "fields";
2401
+ id: string;
2402
+ attributes: {
2403
+ name?: string | undefined;
2404
+ crop?: string | undefined;
2405
+ plantingDate?: string | undefined;
2406
+ geometry?: {
2407
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
2408
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
2409
+ } | undefined;
2410
+ ndvi?: number | undefined;
2411
+ moisture?: string | undefined;
2412
+ soilType?: string | undefined;
2413
+ currentCrop?: string | undefined;
2414
+ expectedHarvestDate?: string | undefined;
2415
+ cropStage?: "planted" | "growing" | "flowering" | "mature" | "harvested" | undefined;
2416
+ };
2417
+ }, {
2418
+ type: "fields";
2419
+ id: string;
2420
+ attributes: {
2421
+ name?: string | undefined;
2422
+ crop?: string | undefined;
2423
+ plantingDate?: string | undefined;
2424
+ geometry?: {
2425
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
2426
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
2427
+ } | undefined;
2428
+ ndvi?: number | undefined;
2429
+ moisture?: string | undefined;
2430
+ soilType?: string | undefined;
2431
+ currentCrop?: string | undefined;
2432
+ expectedHarvestDate?: string | undefined;
2433
+ cropStage?: "planted" | "growing" | "flowering" | "mature" | "harvested" | undefined;
2434
+ };
2435
+ }>;
2436
+ }, "strip", z.ZodTypeAny, {
2437
+ data: {
2438
+ type: "fields";
2439
+ id: string;
2440
+ attributes: {
2441
+ name?: string | undefined;
2442
+ crop?: string | undefined;
2443
+ plantingDate?: string | undefined;
2444
+ geometry?: {
2445
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
2446
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
2447
+ } | undefined;
2448
+ ndvi?: number | undefined;
2449
+ moisture?: string | undefined;
2450
+ soilType?: string | undefined;
2451
+ currentCrop?: string | undefined;
2452
+ expectedHarvestDate?: string | undefined;
2453
+ cropStage?: "planted" | "growing" | "flowering" | "mature" | "harvested" | undefined;
2454
+ };
2455
+ };
2456
+ }, {
2457
+ data: {
2458
+ type: "fields";
2459
+ id: string;
2460
+ attributes: {
2461
+ name?: string | undefined;
2462
+ crop?: string | undefined;
2463
+ plantingDate?: string | undefined;
2464
+ geometry?: {
2465
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
2466
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
2467
+ } | undefined;
2468
+ ndvi?: number | undefined;
2469
+ moisture?: string | undefined;
2470
+ soilType?: string | undefined;
2471
+ currentCrop?: string | undefined;
2472
+ expectedHarvestDate?: string | undefined;
2473
+ cropStage?: "planted" | "growing" | "flowering" | "mature" | "harvested" | undefined;
2474
+ };
2475
+ };
2476
+ }>;
2477
+ path: "/farms/:farmId/fields/:id";
2478
+ responses: {
2479
+ 200: z.ZodObject<{
2480
+ data: z.ZodObject<{
2481
+ type: z.ZodLiteral<string>;
2482
+ id: z.ZodString;
2483
+ attributes: z.ZodObject<{
2484
+ name: z.ZodString;
2485
+ geometry: z.ZodNullable<z.ZodObject<{
2486
+ type: z.ZodEnum<["Polygon", "MultiPolygon", "Point", "LineString"]>;
2487
+ coordinates: z.ZodUnion<[z.ZodArray<z.ZodArray<z.ZodArray<z.ZodNumber, "many">, "many">, "many">, z.ZodArray<z.ZodArray<z.ZodArray<z.ZodArray<z.ZodNumber, "many">, "many">, "many">, "many">, z.ZodArray<z.ZodNumber, "many">, z.ZodArray<z.ZodArray<z.ZodNumber, "many">, "many">]>;
2488
+ }, "strip", z.ZodTypeAny, {
2489
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
2490
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
2491
+ }, {
2492
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
2493
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
2494
+ }>>;
2495
+ ndvi: z.ZodNullable<z.ZodNumber>;
2496
+ moisture: z.ZodNullable<z.ZodString>;
2497
+ status: z.ZodEnum<["ok", "alert", "critical"]>;
2498
+ area: z.ZodNullable<z.ZodString>;
2499
+ crop: z.ZodNullable<z.ZodString>;
2500
+ soilType: z.ZodNullable<z.ZodString>;
2501
+ currentCrop: z.ZodNullable<z.ZodString>;
2502
+ plantingDate: z.ZodNullable<z.ZodString>;
2503
+ expectedHarvestDate: z.ZodNullable<z.ZodString>;
2504
+ cropStage: z.ZodNullable<z.ZodEnum<["planted", "growing", "flowering", "mature", "harvested"]>>;
2505
+ historicalNdvi: z.ZodOptional<z.ZodArray<z.ZodObject<{
2506
+ date: z.ZodString;
2507
+ value: z.ZodNumber;
2508
+ }, "strip", z.ZodTypeAny, {
2509
+ value: number;
2510
+ date: string;
2511
+ }, {
2512
+ value: number;
2513
+ date: string;
2514
+ }>, "many">>;
2515
+ cropHistory: z.ZodOptional<z.ZodArray<z.ZodObject<{
2516
+ id: z.ZodString;
2517
+ season: z.ZodString;
2518
+ crop: z.ZodString;
2519
+ plantingDate: z.ZodString;
2520
+ harvestDate: z.ZodNullable<z.ZodString>;
2521
+ yield: z.ZodNullable<z.ZodNumber>;
2522
+ yieldUnit: z.ZodNullable<z.ZodString>;
2523
+ }, "strip", z.ZodTypeAny, {
2524
+ id: string;
2525
+ season: string;
2526
+ crop: string;
2527
+ plantingDate: string;
2528
+ harvestDate: string | null;
2529
+ yield: number | null;
2530
+ yieldUnit: string | null;
2531
+ }, {
2532
+ id: string;
2533
+ season: string;
2534
+ crop: string;
2535
+ plantingDate: string;
2536
+ harvestDate: string | null;
2537
+ yield: number | null;
2538
+ yieldUnit: string | null;
2539
+ }>, "many">>;
2540
+ } & {
2541
+ createdAt: z.ZodString;
2542
+ updatedAt: z.ZodString;
2543
+ }, "strip", z.ZodTypeAny, {
2544
+ status: "ok" | "alert" | "critical";
2545
+ createdAt: string;
2546
+ updatedAt: string;
2547
+ name: string;
2548
+ crop: string | null;
2549
+ plantingDate: string | null;
2550
+ geometry: {
2551
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
2552
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
2553
+ } | null;
2554
+ ndvi: number | null;
2555
+ moisture: string | null;
2556
+ area: string | null;
2557
+ soilType: string | null;
2558
+ currentCrop: string | null;
2559
+ expectedHarvestDate: string | null;
2560
+ cropStage: "planted" | "growing" | "flowering" | "mature" | "harvested" | null;
2561
+ historicalNdvi?: {
2562
+ value: number;
2563
+ date: string;
2564
+ }[] | undefined;
2565
+ cropHistory?: {
2566
+ id: string;
2567
+ season: string;
2568
+ crop: string;
2569
+ plantingDate: string;
2570
+ harvestDate: string | null;
2571
+ yield: number | null;
2572
+ yieldUnit: string | null;
2573
+ }[] | undefined;
2574
+ }, {
2575
+ status: "ok" | "alert" | "critical";
2576
+ createdAt: string;
2577
+ updatedAt: string;
2578
+ name: string;
2579
+ crop: string | null;
2580
+ plantingDate: string | null;
2581
+ geometry: {
2582
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
2583
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
2584
+ } | null;
2585
+ ndvi: number | null;
2586
+ moisture: string | null;
2587
+ area: string | null;
2588
+ soilType: string | null;
2589
+ currentCrop: string | null;
2590
+ expectedHarvestDate: string | null;
2591
+ cropStage: "planted" | "growing" | "flowering" | "mature" | "harvested" | null;
2592
+ historicalNdvi?: {
2593
+ value: number;
2594
+ date: string;
2595
+ }[] | undefined;
2596
+ cropHistory?: {
2597
+ id: string;
2598
+ season: string;
2599
+ crop: string;
2600
+ plantingDate: string;
2601
+ harvestDate: string | null;
2602
+ yield: number | null;
2603
+ yieldUnit: string | null;
2604
+ }[] | undefined;
2605
+ }>;
2606
+ relationships: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
2607
+ links: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
2608
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
2609
+ }, "strip", z.ZodTypeAny, {
2610
+ type: string;
2611
+ id: string;
2612
+ attributes: {
2613
+ status: "ok" | "alert" | "critical";
2614
+ createdAt: string;
2615
+ updatedAt: string;
2616
+ name: string;
2617
+ crop: string | null;
2618
+ plantingDate: string | null;
2619
+ geometry: {
2620
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
2621
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
2622
+ } | null;
2623
+ ndvi: number | null;
2624
+ moisture: string | null;
2625
+ area: string | null;
2626
+ soilType: string | null;
2627
+ currentCrop: string | null;
2628
+ expectedHarvestDate: string | null;
2629
+ cropStage: "planted" | "growing" | "flowering" | "mature" | "harvested" | null;
2630
+ historicalNdvi?: {
2631
+ value: number;
2632
+ date: string;
2633
+ }[] | undefined;
2634
+ cropHistory?: {
2635
+ id: string;
2636
+ season: string;
2637
+ crop: string;
2638
+ plantingDate: string;
2639
+ harvestDate: string | null;
2640
+ yield: number | null;
2641
+ yieldUnit: string | null;
2642
+ }[] | undefined;
2643
+ };
2644
+ relationships?: Record<string, unknown> | undefined;
2645
+ links?: Record<string, string> | undefined;
2646
+ meta?: Record<string, unknown> | undefined;
2647
+ }, {
2648
+ type: string;
2649
+ id: string;
2650
+ attributes: {
2651
+ status: "ok" | "alert" | "critical";
2652
+ createdAt: string;
2653
+ updatedAt: string;
2654
+ name: string;
2655
+ crop: string | null;
2656
+ plantingDate: string | null;
2657
+ geometry: {
2658
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
2659
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
2660
+ } | null;
2661
+ ndvi: number | null;
2662
+ moisture: string | null;
2663
+ area: string | null;
2664
+ soilType: string | null;
2665
+ currentCrop: string | null;
2666
+ expectedHarvestDate: string | null;
2667
+ cropStage: "planted" | "growing" | "flowering" | "mature" | "harvested" | null;
2668
+ historicalNdvi?: {
2669
+ value: number;
2670
+ date: string;
2671
+ }[] | undefined;
2672
+ cropHistory?: {
2673
+ id: string;
2674
+ season: string;
2675
+ crop: string;
2676
+ plantingDate: string;
2677
+ harvestDate: string | null;
2678
+ yield: number | null;
2679
+ yieldUnit: string | null;
2680
+ }[] | undefined;
2681
+ };
2682
+ relationships?: Record<string, unknown> | undefined;
2683
+ links?: Record<string, string> | undefined;
2684
+ meta?: Record<string, unknown> | undefined;
2685
+ }>;
2686
+ included: z.ZodOptional<z.ZodArray<z.ZodObject<{
2687
+ type: z.ZodString;
2688
+ id: z.ZodString;
2689
+ attributes: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
2690
+ relationships: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
2691
+ links: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
2692
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
2693
+ }, "strip", z.ZodTypeAny, {
2694
+ type: string;
2695
+ id: string;
2696
+ attributes?: Record<string, unknown> | undefined;
2697
+ relationships?: Record<string, unknown> | undefined;
2698
+ links?: Record<string, string> | undefined;
2699
+ meta?: Record<string, unknown> | undefined;
2700
+ }, {
2701
+ type: string;
2702
+ id: string;
2703
+ attributes?: Record<string, unknown> | undefined;
2704
+ relationships?: Record<string, unknown> | undefined;
2705
+ links?: Record<string, string> | undefined;
2706
+ meta?: Record<string, unknown> | undefined;
2707
+ }>, "many">>;
2708
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
2709
+ links: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
2710
+ }, "strip", z.ZodTypeAny, {
2711
+ data: {
2712
+ type: string;
2713
+ id: string;
2714
+ attributes: {
2715
+ status: "ok" | "alert" | "critical";
2716
+ createdAt: string;
2717
+ updatedAt: string;
2718
+ name: string;
2719
+ crop: string | null;
2720
+ plantingDate: string | null;
2721
+ geometry: {
2722
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
2723
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
2724
+ } | null;
2725
+ ndvi: number | null;
2726
+ moisture: string | null;
2727
+ area: string | null;
2728
+ soilType: string | null;
2729
+ currentCrop: string | null;
2730
+ expectedHarvestDate: string | null;
2731
+ cropStage: "planted" | "growing" | "flowering" | "mature" | "harvested" | null;
2732
+ historicalNdvi?: {
2733
+ value: number;
2734
+ date: string;
2735
+ }[] | undefined;
2736
+ cropHistory?: {
2737
+ id: string;
2738
+ season: string;
2739
+ crop: string;
2740
+ plantingDate: string;
2741
+ harvestDate: string | null;
2742
+ yield: number | null;
2743
+ yieldUnit: string | null;
2744
+ }[] | undefined;
2745
+ };
2746
+ relationships?: Record<string, unknown> | undefined;
2747
+ links?: Record<string, string> | undefined;
2748
+ meta?: Record<string, unknown> | undefined;
2749
+ };
2750
+ links?: Record<string, string> | undefined;
2751
+ meta?: Record<string, unknown> | undefined;
2752
+ included?: {
2753
+ type: string;
2754
+ id: string;
2755
+ attributes?: Record<string, unknown> | undefined;
2756
+ relationships?: Record<string, unknown> | undefined;
2757
+ links?: Record<string, string> | undefined;
2758
+ meta?: Record<string, unknown> | undefined;
2759
+ }[] | undefined;
2760
+ }, {
2761
+ data: {
2762
+ type: string;
2763
+ id: string;
2764
+ attributes: {
2765
+ status: "ok" | "alert" | "critical";
2766
+ createdAt: string;
2767
+ updatedAt: string;
2768
+ name: string;
2769
+ crop: string | null;
2770
+ plantingDate: string | null;
2771
+ geometry: {
2772
+ type: "Polygon" | "MultiPolygon" | "Point" | "LineString";
2773
+ coordinates: number[] | number[][] | number[][][] | number[][][][];
2774
+ } | null;
2775
+ ndvi: number | null;
2776
+ moisture: string | null;
2777
+ area: string | null;
2778
+ soilType: string | null;
2779
+ currentCrop: string | null;
2780
+ expectedHarvestDate: string | null;
2781
+ cropStage: "planted" | "growing" | "flowering" | "mature" | "harvested" | null;
2782
+ historicalNdvi?: {
2783
+ value: number;
2784
+ date: string;
2785
+ }[] | undefined;
2786
+ cropHistory?: {
2787
+ id: string;
2788
+ season: string;
2789
+ crop: string;
2790
+ plantingDate: string;
2791
+ harvestDate: string | null;
2792
+ yield: number | null;
2793
+ yieldUnit: string | null;
2794
+ }[] | undefined;
2795
+ };
2796
+ relationships?: Record<string, unknown> | undefined;
2797
+ links?: Record<string, string> | undefined;
2798
+ meta?: Record<string, unknown> | undefined;
2799
+ };
2800
+ links?: Record<string, string> | undefined;
2801
+ meta?: Record<string, unknown> | undefined;
2802
+ included?: {
2803
+ type: string;
2804
+ id: string;
2805
+ attributes?: Record<string, unknown> | undefined;
2806
+ relationships?: Record<string, unknown> | undefined;
2807
+ links?: Record<string, string> | undefined;
2808
+ meta?: Record<string, unknown> | undefined;
2809
+ }[] | undefined;
2810
+ }>;
2811
+ 400: z.ZodObject<{
2812
+ errors: z.ZodArray<z.ZodObject<{
2813
+ id: z.ZodOptional<z.ZodString>;
2814
+ links: z.ZodOptional<z.ZodObject<{
2815
+ about: z.ZodOptional<z.ZodString>;
2816
+ }, "strip", z.ZodTypeAny, {
2817
+ about?: string | undefined;
2818
+ }, {
2819
+ about?: string | undefined;
2820
+ }>>;
2821
+ status: z.ZodOptional<z.ZodString>;
2822
+ code: z.ZodOptional<z.ZodString>;
2823
+ title: z.ZodOptional<z.ZodString>;
2824
+ detail: z.ZodOptional<z.ZodString>;
2825
+ source: z.ZodOptional<z.ZodObject<{
2826
+ pointer: z.ZodOptional<z.ZodString>;
2827
+ parameter: z.ZodOptional<z.ZodString>;
2828
+ }, "strip", z.ZodTypeAny, {
2829
+ pointer?: string | undefined;
2830
+ parameter?: string | undefined;
2831
+ }, {
2832
+ pointer?: string | undefined;
2833
+ parameter?: string | undefined;
2834
+ }>>;
2835
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
2836
+ }, "strip", z.ZodTypeAny, {
2837
+ status?: string | undefined;
2838
+ code?: string | undefined;
2839
+ id?: string | undefined;
2840
+ links?: {
2841
+ about?: string | undefined;
2842
+ } | undefined;
2843
+ meta?: Record<string, unknown> | undefined;
2844
+ title?: string | undefined;
2845
+ detail?: string | undefined;
2846
+ source?: {
2847
+ pointer?: string | undefined;
2848
+ parameter?: string | undefined;
2849
+ } | undefined;
2850
+ }, {
2851
+ status?: string | undefined;
2852
+ code?: string | undefined;
2853
+ id?: string | undefined;
2854
+ links?: {
2855
+ about?: string | undefined;
2856
+ } | undefined;
2857
+ meta?: Record<string, unknown> | undefined;
2858
+ title?: string | undefined;
2859
+ detail?: string | undefined;
2860
+ source?: {
2861
+ pointer?: string | undefined;
2862
+ parameter?: string | undefined;
2863
+ } | undefined;
2864
+ }>, "many">;
2865
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
2866
+ }, "strip", z.ZodTypeAny, {
2867
+ errors: {
2868
+ status?: string | undefined;
2869
+ code?: string | undefined;
2870
+ id?: string | undefined;
2871
+ links?: {
2872
+ about?: string | undefined;
2873
+ } | undefined;
2874
+ meta?: Record<string, unknown> | undefined;
2875
+ title?: string | undefined;
2876
+ detail?: string | undefined;
2877
+ source?: {
2878
+ pointer?: string | undefined;
2879
+ parameter?: string | undefined;
2880
+ } | undefined;
2881
+ }[];
2882
+ meta?: Record<string, unknown> | undefined;
2883
+ }, {
2884
+ errors: {
2885
+ status?: string | undefined;
2886
+ code?: string | undefined;
2887
+ id?: string | undefined;
2888
+ links?: {
2889
+ about?: string | undefined;
2890
+ } | undefined;
2891
+ meta?: Record<string, unknown> | undefined;
2892
+ title?: string | undefined;
2893
+ detail?: string | undefined;
2894
+ source?: {
2895
+ pointer?: string | undefined;
2896
+ parameter?: string | undefined;
2897
+ } | undefined;
2898
+ }[];
2899
+ meta?: Record<string, unknown> | undefined;
2900
+ }>;
2901
+ 404: z.ZodObject<{
2902
+ errors: z.ZodArray<z.ZodObject<{
2903
+ id: z.ZodOptional<z.ZodString>;
2904
+ links: z.ZodOptional<z.ZodObject<{
2905
+ about: z.ZodOptional<z.ZodString>;
2906
+ }, "strip", z.ZodTypeAny, {
2907
+ about?: string | undefined;
2908
+ }, {
2909
+ about?: string | undefined;
2910
+ }>>;
2911
+ status: z.ZodOptional<z.ZodString>;
2912
+ code: z.ZodOptional<z.ZodString>;
2913
+ title: z.ZodOptional<z.ZodString>;
2914
+ detail: z.ZodOptional<z.ZodString>;
2915
+ source: z.ZodOptional<z.ZodObject<{
2916
+ pointer: z.ZodOptional<z.ZodString>;
2917
+ parameter: z.ZodOptional<z.ZodString>;
2918
+ }, "strip", z.ZodTypeAny, {
2919
+ pointer?: string | undefined;
2920
+ parameter?: string | undefined;
2921
+ }, {
2922
+ pointer?: string | undefined;
2923
+ parameter?: string | undefined;
2924
+ }>>;
2925
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
2926
+ }, "strip", z.ZodTypeAny, {
2927
+ status?: string | undefined;
2928
+ code?: string | undefined;
2929
+ id?: string | undefined;
2930
+ links?: {
2931
+ about?: string | undefined;
2932
+ } | undefined;
2933
+ meta?: Record<string, unknown> | undefined;
2934
+ title?: string | undefined;
2935
+ detail?: string | undefined;
2936
+ source?: {
2937
+ pointer?: string | undefined;
2938
+ parameter?: string | undefined;
2939
+ } | undefined;
2940
+ }, {
2941
+ status?: string | undefined;
2942
+ code?: string | undefined;
2943
+ id?: string | undefined;
2944
+ links?: {
2945
+ about?: string | undefined;
2946
+ } | undefined;
2947
+ meta?: Record<string, unknown> | undefined;
2948
+ title?: string | undefined;
2949
+ detail?: string | undefined;
2950
+ source?: {
2951
+ pointer?: string | undefined;
2952
+ parameter?: string | undefined;
2953
+ } | undefined;
2954
+ }>, "many">;
2955
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
2956
+ }, "strip", z.ZodTypeAny, {
2957
+ errors: {
2958
+ status?: string | undefined;
2959
+ code?: string | undefined;
2960
+ id?: string | undefined;
2961
+ links?: {
2962
+ about?: string | undefined;
2963
+ } | undefined;
2964
+ meta?: Record<string, unknown> | undefined;
2965
+ title?: string | undefined;
2966
+ detail?: string | undefined;
2967
+ source?: {
2968
+ pointer?: string | undefined;
2969
+ parameter?: string | undefined;
2970
+ } | undefined;
2971
+ }[];
2972
+ meta?: Record<string, unknown> | undefined;
2973
+ }, {
2974
+ errors: {
2975
+ status?: string | undefined;
2976
+ code?: string | undefined;
2977
+ id?: string | undefined;
2978
+ links?: {
2979
+ about?: string | undefined;
2980
+ } | undefined;
2981
+ meta?: Record<string, unknown> | undefined;
2982
+ title?: string | undefined;
2983
+ detail?: string | undefined;
2984
+ source?: {
2985
+ pointer?: string | undefined;
2986
+ parameter?: string | undefined;
2987
+ } | undefined;
2988
+ }[];
2989
+ meta?: Record<string, unknown> | undefined;
2990
+ }>;
2991
+ 401: z.ZodObject<{
2992
+ errors: z.ZodArray<z.ZodObject<{
2993
+ id: z.ZodOptional<z.ZodString>;
2994
+ links: z.ZodOptional<z.ZodObject<{
2995
+ about: z.ZodOptional<z.ZodString>;
2996
+ }, "strip", z.ZodTypeAny, {
2997
+ about?: string | undefined;
2998
+ }, {
2999
+ about?: string | undefined;
3000
+ }>>;
3001
+ status: z.ZodOptional<z.ZodString>;
3002
+ code: z.ZodOptional<z.ZodString>;
3003
+ title: z.ZodOptional<z.ZodString>;
3004
+ detail: z.ZodOptional<z.ZodString>;
3005
+ source: z.ZodOptional<z.ZodObject<{
3006
+ pointer: z.ZodOptional<z.ZodString>;
3007
+ parameter: z.ZodOptional<z.ZodString>;
3008
+ }, "strip", z.ZodTypeAny, {
3009
+ pointer?: string | undefined;
3010
+ parameter?: string | undefined;
3011
+ }, {
3012
+ pointer?: string | undefined;
3013
+ parameter?: string | undefined;
3014
+ }>>;
3015
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
3016
+ }, "strip", z.ZodTypeAny, {
3017
+ status?: string | undefined;
3018
+ code?: string | undefined;
3019
+ id?: string | undefined;
3020
+ links?: {
3021
+ about?: string | undefined;
3022
+ } | undefined;
3023
+ meta?: Record<string, unknown> | undefined;
3024
+ title?: string | undefined;
3025
+ detail?: string | undefined;
3026
+ source?: {
3027
+ pointer?: string | undefined;
3028
+ parameter?: string | undefined;
3029
+ } | undefined;
3030
+ }, {
3031
+ status?: string | undefined;
3032
+ code?: string | undefined;
3033
+ id?: string | undefined;
3034
+ links?: {
3035
+ about?: string | undefined;
3036
+ } | undefined;
3037
+ meta?: Record<string, unknown> | undefined;
3038
+ title?: string | undefined;
3039
+ detail?: string | undefined;
3040
+ source?: {
3041
+ pointer?: string | undefined;
3042
+ parameter?: string | undefined;
3043
+ } | undefined;
3044
+ }>, "many">;
3045
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
3046
+ }, "strip", z.ZodTypeAny, {
3047
+ errors: {
3048
+ status?: string | undefined;
3049
+ code?: string | undefined;
3050
+ id?: string | undefined;
3051
+ links?: {
3052
+ about?: string | undefined;
3053
+ } | undefined;
3054
+ meta?: Record<string, unknown> | undefined;
3055
+ title?: string | undefined;
3056
+ detail?: string | undefined;
3057
+ source?: {
3058
+ pointer?: string | undefined;
3059
+ parameter?: string | undefined;
3060
+ } | undefined;
3061
+ }[];
3062
+ meta?: Record<string, unknown> | undefined;
3063
+ }, {
3064
+ errors: {
3065
+ status?: string | undefined;
3066
+ code?: string | undefined;
3067
+ id?: string | undefined;
3068
+ links?: {
3069
+ about?: string | undefined;
3070
+ } | undefined;
3071
+ meta?: Record<string, unknown> | undefined;
3072
+ title?: string | undefined;
3073
+ detail?: string | undefined;
3074
+ source?: {
3075
+ pointer?: string | undefined;
3076
+ parameter?: string | undefined;
3077
+ } | undefined;
3078
+ }[];
3079
+ meta?: Record<string, unknown> | undefined;
3080
+ }>;
3081
+ 422: z.ZodObject<{
3082
+ errors: z.ZodArray<z.ZodObject<{
3083
+ id: z.ZodOptional<z.ZodString>;
3084
+ links: z.ZodOptional<z.ZodObject<{
3085
+ about: z.ZodOptional<z.ZodString>;
3086
+ }, "strip", z.ZodTypeAny, {
3087
+ about?: string | undefined;
3088
+ }, {
3089
+ about?: string | undefined;
3090
+ }>>;
3091
+ status: z.ZodOptional<z.ZodString>;
3092
+ code: z.ZodOptional<z.ZodString>;
3093
+ title: z.ZodOptional<z.ZodString>;
3094
+ detail: z.ZodOptional<z.ZodString>;
3095
+ source: z.ZodOptional<z.ZodObject<{
3096
+ pointer: z.ZodOptional<z.ZodString>;
3097
+ parameter: z.ZodOptional<z.ZodString>;
3098
+ }, "strip", z.ZodTypeAny, {
3099
+ pointer?: string | undefined;
3100
+ parameter?: string | undefined;
3101
+ }, {
3102
+ pointer?: string | undefined;
3103
+ parameter?: string | undefined;
3104
+ }>>;
3105
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
3106
+ }, "strip", z.ZodTypeAny, {
3107
+ status?: string | undefined;
3108
+ code?: string | undefined;
3109
+ id?: string | undefined;
3110
+ links?: {
3111
+ about?: string | undefined;
3112
+ } | undefined;
3113
+ meta?: Record<string, unknown> | undefined;
3114
+ title?: string | undefined;
3115
+ detail?: string | undefined;
3116
+ source?: {
3117
+ pointer?: string | undefined;
3118
+ parameter?: string | undefined;
3119
+ } | undefined;
3120
+ }, {
3121
+ status?: string | undefined;
3122
+ code?: string | undefined;
3123
+ id?: string | undefined;
3124
+ links?: {
3125
+ about?: string | undefined;
3126
+ } | undefined;
3127
+ meta?: Record<string, unknown> | undefined;
3128
+ title?: string | undefined;
3129
+ detail?: string | undefined;
3130
+ source?: {
3131
+ pointer?: string | undefined;
3132
+ parameter?: string | undefined;
3133
+ } | undefined;
3134
+ }>, "many">;
3135
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
3136
+ }, "strip", z.ZodTypeAny, {
3137
+ errors: {
3138
+ status?: string | undefined;
3139
+ code?: string | undefined;
3140
+ id?: string | undefined;
3141
+ links?: {
3142
+ about?: string | undefined;
3143
+ } | undefined;
3144
+ meta?: Record<string, unknown> | undefined;
3145
+ title?: string | undefined;
3146
+ detail?: string | undefined;
3147
+ source?: {
3148
+ pointer?: string | undefined;
3149
+ parameter?: string | undefined;
3150
+ } | undefined;
3151
+ }[];
3152
+ meta?: Record<string, unknown> | undefined;
3153
+ }, {
3154
+ errors: {
3155
+ status?: string | undefined;
3156
+ code?: string | undefined;
3157
+ id?: string | undefined;
3158
+ links?: {
3159
+ about?: string | undefined;
3160
+ } | undefined;
3161
+ meta?: Record<string, unknown> | undefined;
3162
+ title?: string | undefined;
3163
+ detail?: string | undefined;
3164
+ source?: {
3165
+ pointer?: string | undefined;
3166
+ parameter?: string | undefined;
3167
+ } | undefined;
3168
+ }[];
3169
+ meta?: Record<string, unknown> | undefined;
3170
+ }>;
3171
+ };
3172
+ };
3173
+ deleteField: {
3174
+ pathParams: z.ZodObject<{
3175
+ farmId: z.ZodString;
3176
+ id: z.ZodString;
3177
+ }, "strip", z.ZodTypeAny, {
3178
+ id: string;
3179
+ farmId: string;
3180
+ }, {
3181
+ id: string;
3182
+ farmId: string;
3183
+ }>;
3184
+ summary: "Delete field";
3185
+ description: "Delete a field and all associated data";
3186
+ method: "DELETE";
3187
+ path: "/farms/:farmId/fields/:id";
3188
+ responses: {
3189
+ 204: z.ZodObject<{
3190
+ meta: z.ZodObject<{
3191
+ message: z.ZodString;
3192
+ }, "strip", z.ZodTypeAny, {
3193
+ message: string;
3194
+ }, {
3195
+ message: string;
3196
+ }>;
3197
+ }, "strip", z.ZodTypeAny, {
3198
+ meta: {
3199
+ message: string;
3200
+ };
3201
+ }, {
3202
+ meta: {
3203
+ message: string;
3204
+ };
3205
+ }>;
3206
+ 404: z.ZodObject<{
3207
+ errors: z.ZodArray<z.ZodObject<{
3208
+ id: z.ZodOptional<z.ZodString>;
3209
+ links: z.ZodOptional<z.ZodObject<{
3210
+ about: z.ZodOptional<z.ZodString>;
3211
+ }, "strip", z.ZodTypeAny, {
3212
+ about?: string | undefined;
3213
+ }, {
3214
+ about?: string | undefined;
3215
+ }>>;
3216
+ status: z.ZodOptional<z.ZodString>;
3217
+ code: z.ZodOptional<z.ZodString>;
3218
+ title: z.ZodOptional<z.ZodString>;
3219
+ detail: z.ZodOptional<z.ZodString>;
3220
+ source: z.ZodOptional<z.ZodObject<{
3221
+ pointer: z.ZodOptional<z.ZodString>;
3222
+ parameter: z.ZodOptional<z.ZodString>;
3223
+ }, "strip", z.ZodTypeAny, {
3224
+ pointer?: string | undefined;
3225
+ parameter?: string | undefined;
3226
+ }, {
3227
+ pointer?: string | undefined;
3228
+ parameter?: string | undefined;
3229
+ }>>;
3230
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
3231
+ }, "strip", z.ZodTypeAny, {
3232
+ status?: string | undefined;
3233
+ code?: string | undefined;
3234
+ id?: string | undefined;
3235
+ links?: {
3236
+ about?: string | undefined;
3237
+ } | undefined;
3238
+ meta?: Record<string, unknown> | undefined;
3239
+ title?: string | undefined;
3240
+ detail?: string | undefined;
3241
+ source?: {
3242
+ pointer?: string | undefined;
3243
+ parameter?: string | undefined;
3244
+ } | undefined;
3245
+ }, {
3246
+ status?: string | undefined;
3247
+ code?: string | undefined;
3248
+ id?: string | undefined;
3249
+ links?: {
3250
+ about?: string | undefined;
3251
+ } | undefined;
3252
+ meta?: Record<string, unknown> | undefined;
3253
+ title?: string | undefined;
3254
+ detail?: string | undefined;
3255
+ source?: {
3256
+ pointer?: string | undefined;
3257
+ parameter?: string | undefined;
3258
+ } | undefined;
3259
+ }>, "many">;
3260
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
3261
+ }, "strip", z.ZodTypeAny, {
3262
+ errors: {
3263
+ status?: string | undefined;
3264
+ code?: string | undefined;
3265
+ id?: string | undefined;
3266
+ links?: {
3267
+ about?: string | undefined;
3268
+ } | undefined;
3269
+ meta?: Record<string, unknown> | undefined;
3270
+ title?: string | undefined;
3271
+ detail?: string | undefined;
3272
+ source?: {
3273
+ pointer?: string | undefined;
3274
+ parameter?: string | undefined;
3275
+ } | undefined;
3276
+ }[];
3277
+ meta?: Record<string, unknown> | undefined;
3278
+ }, {
3279
+ errors: {
3280
+ status?: string | undefined;
3281
+ code?: string | undefined;
3282
+ id?: string | undefined;
3283
+ links?: {
3284
+ about?: string | undefined;
3285
+ } | undefined;
3286
+ meta?: Record<string, unknown> | undefined;
3287
+ title?: string | undefined;
3288
+ detail?: string | undefined;
3289
+ source?: {
3290
+ pointer?: string | undefined;
3291
+ parameter?: string | undefined;
3292
+ } | undefined;
3293
+ }[];
3294
+ meta?: Record<string, unknown> | undefined;
3295
+ }>;
3296
+ 401: z.ZodObject<{
3297
+ errors: z.ZodArray<z.ZodObject<{
3298
+ id: z.ZodOptional<z.ZodString>;
3299
+ links: z.ZodOptional<z.ZodObject<{
3300
+ about: z.ZodOptional<z.ZodString>;
3301
+ }, "strip", z.ZodTypeAny, {
3302
+ about?: string | undefined;
3303
+ }, {
3304
+ about?: string | undefined;
3305
+ }>>;
3306
+ status: z.ZodOptional<z.ZodString>;
3307
+ code: z.ZodOptional<z.ZodString>;
3308
+ title: z.ZodOptional<z.ZodString>;
3309
+ detail: z.ZodOptional<z.ZodString>;
3310
+ source: z.ZodOptional<z.ZodObject<{
3311
+ pointer: z.ZodOptional<z.ZodString>;
3312
+ parameter: z.ZodOptional<z.ZodString>;
3313
+ }, "strip", z.ZodTypeAny, {
3314
+ pointer?: string | undefined;
3315
+ parameter?: string | undefined;
3316
+ }, {
3317
+ pointer?: string | undefined;
3318
+ parameter?: string | undefined;
3319
+ }>>;
3320
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
3321
+ }, "strip", z.ZodTypeAny, {
3322
+ status?: string | undefined;
3323
+ code?: string | undefined;
3324
+ id?: string | undefined;
3325
+ links?: {
3326
+ about?: string | undefined;
3327
+ } | undefined;
3328
+ meta?: Record<string, unknown> | undefined;
3329
+ title?: string | undefined;
3330
+ detail?: string | undefined;
3331
+ source?: {
3332
+ pointer?: string | undefined;
3333
+ parameter?: string | undefined;
3334
+ } | undefined;
3335
+ }, {
3336
+ status?: string | undefined;
3337
+ code?: string | undefined;
3338
+ id?: string | undefined;
3339
+ links?: {
3340
+ about?: string | undefined;
3341
+ } | undefined;
3342
+ meta?: Record<string, unknown> | undefined;
3343
+ title?: string | undefined;
3344
+ detail?: string | undefined;
3345
+ source?: {
3346
+ pointer?: string | undefined;
3347
+ parameter?: string | undefined;
3348
+ } | undefined;
3349
+ }>, "many">;
3350
+ meta: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
3351
+ }, "strip", z.ZodTypeAny, {
3352
+ errors: {
3353
+ status?: string | undefined;
3354
+ code?: string | undefined;
3355
+ id?: string | undefined;
3356
+ links?: {
3357
+ about?: string | undefined;
3358
+ } | undefined;
3359
+ meta?: Record<string, unknown> | undefined;
3360
+ title?: string | undefined;
3361
+ detail?: string | undefined;
3362
+ source?: {
3363
+ pointer?: string | undefined;
3364
+ parameter?: string | undefined;
3365
+ } | undefined;
3366
+ }[];
3367
+ meta?: Record<string, unknown> | undefined;
3368
+ }, {
3369
+ errors: {
3370
+ status?: string | undefined;
3371
+ code?: string | undefined;
3372
+ id?: string | undefined;
3373
+ links?: {
3374
+ about?: string | undefined;
3375
+ } | undefined;
3376
+ meta?: Record<string, unknown> | undefined;
3377
+ title?: string | undefined;
3378
+ detail?: string | undefined;
3379
+ source?: {
3380
+ pointer?: string | undefined;
3381
+ parameter?: string | undefined;
3382
+ } | undefined;
3383
+ }[];
3384
+ meta?: Record<string, unknown> | undefined;
3385
+ }>;
3386
+ };
3387
+ };
3388
+ };
3389
+ //# sourceMappingURL=fields.routes.d.ts.map