@deepintel-ltd/farmpro-contracts 1.5.25 → 1.5.26
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/routes/files.routes.d.ts +5 -2
- package/dist/routes/files.routes.d.ts.map +1 -1
- package/dist/routes/files.routes.js +4 -3
- package/dist/routes/invoices.routes.d.ts +1 -1
- package/dist/routes/invoices.routes.js +1 -1
- package/dist/routes/waybills.routes.d.ts +1 -1
- package/dist/routes/waybills.routes.js +1 -1
- package/package.json +1 -1
|
@@ -416,16 +416,19 @@ export declare const filesRouter: {
|
|
|
416
416
|
};
|
|
417
417
|
viewFile: {
|
|
418
418
|
pathParams: z.ZodObject<{
|
|
419
|
+
prefix: z.ZodString;
|
|
419
420
|
fileId: z.ZodString;
|
|
420
421
|
}, "strip", z.ZodTypeAny, {
|
|
422
|
+
prefix: string;
|
|
421
423
|
fileId: string;
|
|
422
424
|
}, {
|
|
425
|
+
prefix: string;
|
|
423
426
|
fileId: string;
|
|
424
427
|
}>;
|
|
425
428
|
summary: "View file";
|
|
426
|
-
description: "Stream or download a file by its UUID.
|
|
429
|
+
description: "Stream or download a file by its prefix and UUID. URL format: /files/view/{prefix}/{uuid}.{ext}. The storage path is constructed as {prefix}/{uuid}.{ext}. Requires authentication and validates that the requesting user has permission to access the file.";
|
|
427
430
|
method: "GET";
|
|
428
|
-
path: "/files/view/:fileId";
|
|
431
|
+
path: "/files/view/:prefix/:fileId";
|
|
429
432
|
responses: {
|
|
430
433
|
200: z.ZodAny;
|
|
431
434
|
400: z.ZodObject<{
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"files.routes.d.ts","sourceRoot":"","sources":["../../src/routes/files.routes.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AASxB,eAAO,MAAM,WAAW
|
|
1
|
+
{"version":3,"file":"files.routes.d.ts","sourceRoot":"","sources":["../../src/routes/files.routes.ts"],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Params: z.object({
|
|
26
|
-
|
|
26
|
+
prefix: z.string().describe('Storage prefix (e.g., waybills, invoices, documents, organizations, uploads)'),
|
|
27
|
+
fileId: z.string().describe('File identifier in format {uuid}.{ext} (e.g., 550e8400-e29b-41d4-a716-446655440000.pdf)'),
|
|
27
28
|
}),
|
|
28
29
|
responses: {
|
|
29
30
|
200: z.any(), // File stream response
|
|
@@ -33,6 +34,6 @@ export const filesRouter = c.router({
|
|
|
33
34
|
404: jsonApiErrorResponseSchema,
|
|
34
35
|
},
|
|
35
36
|
summary: 'View file',
|
|
36
|
-
description: 'Stream or download a file by its UUID.
|
|
37
|
+
description: 'Stream or download a file by its prefix and UUID. URL format: /files/view/{prefix}/{uuid}.{ext}. The storage path is constructed as {prefix}/{uuid}.{ext}. Requires authentication and validates that the requesting user has permission to access the file.',
|
|
37
38
|
},
|
|
38
39
|
});
|
|
@@ -3217,7 +3217,7 @@ export declare const invoicesRouter: {
|
|
|
3217
3217
|
summary: "Generate invoice PDF";
|
|
3218
3218
|
description: "Generate and save PDF for an invoice with organization logo";
|
|
3219
3219
|
method: "POST";
|
|
3220
|
-
body: z.
|
|
3220
|
+
body: z.ZodOptional<z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>>;
|
|
3221
3221
|
path: "/organizations/:organizationId/invoices/:id/generate-pdf";
|
|
3222
3222
|
responses: {
|
|
3223
3223
|
200: z.ZodObject<{
|
|
@@ -3013,7 +3013,7 @@ export declare const waybillsRouter: {
|
|
|
3013
3013
|
summary: "Generate waybill PDF";
|
|
3014
3014
|
description: "Generate and save PDF for a waybill with organization logo";
|
|
3015
3015
|
method: "POST";
|
|
3016
|
-
body: z.
|
|
3016
|
+
body: z.ZodOptional<z.ZodObject<{}, "strip", z.ZodTypeAny, {}, {}>>;
|
|
3017
3017
|
path: "/organizations/:organizationId/waybills/:id/generate-pdf";
|
|
3018
3018
|
responses: {
|
|
3019
3019
|
200: z.ZodObject<{
|