@deepintel-ltd/farmpro-contracts 1.5.24 → 1.5.25
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/invoices.routes.d.ts +44 -100
- package/dist/routes/invoices.routes.d.ts.map +1 -1
- package/dist/routes/organizations.routes.d.ts +377 -1
- package/dist/routes/organizations.routes.d.ts.map +1 -1
- package/dist/routes/organizations.routes.js +16 -1
- package/dist/routes/suppliers.routes.d.ts +76 -76
- package/dist/routes/suppliers.routes.js +18 -18
- package/dist/routes/waybills.routes.d.ts +44 -86
- package/dist/routes/waybills.routes.d.ts.map +1 -1
- package/dist/schemas/invoices.schemas.d.ts +34 -98
- package/dist/schemas/invoices.schemas.d.ts.map +1 -1
- package/dist/schemas/invoices.schemas.js +1 -5
- package/dist/schemas/suppliers.schemas.d.ts +44 -44
- package/dist/schemas/suppliers.schemas.js +2 -2
- package/dist/schemas/waybills.schemas.d.ts +34 -82
- package/dist/schemas/waybills.schemas.d.ts.map +1 -1
- package/dist/schemas/waybills.schemas.js +1 -4
- package/package.json +1 -1
|
@@ -7,8 +7,8 @@ export const suppliersRouter = c.router({
|
|
|
7
7
|
// Supplier routes
|
|
8
8
|
listSuppliers: {
|
|
9
9
|
method: 'GET',
|
|
10
|
-
path: '/
|
|
11
|
-
pathParams: z.object({
|
|
10
|
+
path: '/organizations/:organizationId/suppliers',
|
|
11
|
+
pathParams: z.object({ organizationId: z.string().uuid() }),
|
|
12
12
|
query: jsonApiPaginationQuerySchema
|
|
13
13
|
.merge(jsonApiSortQuerySchema)
|
|
14
14
|
.merge(jsonApiIncludeQuerySchema)
|
|
@@ -22,12 +22,12 @@ export const suppliersRouter = c.router({
|
|
|
22
22
|
401: jsonApiErrorResponseSchema,
|
|
23
23
|
},
|
|
24
24
|
summary: 'List suppliers',
|
|
25
|
-
description: 'Get all suppliers for
|
|
25
|
+
description: 'Get all suppliers for an organization with optional filtering',
|
|
26
26
|
},
|
|
27
27
|
createSupplier: {
|
|
28
28
|
method: 'POST',
|
|
29
|
-
path: '/
|
|
30
|
-
pathParams: z.object({
|
|
29
|
+
path: '/organizations/:organizationId/suppliers',
|
|
30
|
+
pathParams: z.object({ organizationId: z.string().uuid() }),
|
|
31
31
|
body: z.object({ data: createSupplierSchema }),
|
|
32
32
|
responses: {
|
|
33
33
|
201: supplierResponseSchema,
|
|
@@ -41,9 +41,9 @@ export const suppliersRouter = c.router({
|
|
|
41
41
|
},
|
|
42
42
|
updateSupplier: {
|
|
43
43
|
method: 'PATCH',
|
|
44
|
-
path: '/
|
|
44
|
+
path: '/organizations/:organizationId/suppliers/:id',
|
|
45
45
|
pathParams: z.object({
|
|
46
|
-
|
|
46
|
+
organizationId: z.string().uuid(),
|
|
47
47
|
id: z.string().uuid(),
|
|
48
48
|
}),
|
|
49
49
|
body: z.object({ data: updateSupplierSchema }),
|
|
@@ -59,9 +59,9 @@ export const suppliersRouter = c.router({
|
|
|
59
59
|
},
|
|
60
60
|
deleteSupplier: {
|
|
61
61
|
method: 'DELETE',
|
|
62
|
-
path: '/
|
|
62
|
+
path: '/organizations/:organizationId/suppliers/:id',
|
|
63
63
|
pathParams: z.object({
|
|
64
|
-
|
|
64
|
+
organizationId: z.string().uuid(),
|
|
65
65
|
id: z.string().uuid(),
|
|
66
66
|
}),
|
|
67
67
|
responses: {
|
|
@@ -75,8 +75,8 @@ export const suppliersRouter = c.router({
|
|
|
75
75
|
// Buyer routes
|
|
76
76
|
listBuyers: {
|
|
77
77
|
method: 'GET',
|
|
78
|
-
path: '/
|
|
79
|
-
pathParams: z.object({
|
|
78
|
+
path: '/organizations/:organizationId/buyers',
|
|
79
|
+
pathParams: z.object({ organizationId: z.string().uuid() }),
|
|
80
80
|
query: jsonApiPaginationQuerySchema
|
|
81
81
|
.merge(jsonApiSortQuerySchema)
|
|
82
82
|
.merge(jsonApiIncludeQuerySchema)
|
|
@@ -90,12 +90,12 @@ export const suppliersRouter = c.router({
|
|
|
90
90
|
401: jsonApiErrorResponseSchema,
|
|
91
91
|
},
|
|
92
92
|
summary: 'List buyers',
|
|
93
|
-
description: 'Get all buyers for
|
|
93
|
+
description: 'Get all buyers for an organization with optional filtering',
|
|
94
94
|
},
|
|
95
95
|
createBuyer: {
|
|
96
96
|
method: 'POST',
|
|
97
|
-
path: '/
|
|
98
|
-
pathParams: z.object({
|
|
97
|
+
path: '/organizations/:organizationId/buyers',
|
|
98
|
+
pathParams: z.object({ organizationId: z.string().uuid() }),
|
|
99
99
|
body: z.object({ data: createBuyerSchema }),
|
|
100
100
|
responses: {
|
|
101
101
|
201: buyerResponseSchema,
|
|
@@ -109,9 +109,9 @@ export const suppliersRouter = c.router({
|
|
|
109
109
|
},
|
|
110
110
|
updateBuyer: {
|
|
111
111
|
method: 'PATCH',
|
|
112
|
-
path: '/
|
|
112
|
+
path: '/organizations/:organizationId/buyers/:id',
|
|
113
113
|
pathParams: z.object({
|
|
114
|
-
|
|
114
|
+
organizationId: z.string().uuid(),
|
|
115
115
|
id: z.string().uuid(),
|
|
116
116
|
}),
|
|
117
117
|
body: z.object({ data: updateBuyerSchema }),
|
|
@@ -127,9 +127,9 @@ export const suppliersRouter = c.router({
|
|
|
127
127
|
},
|
|
128
128
|
deleteBuyer: {
|
|
129
129
|
method: 'DELETE',
|
|
130
|
-
path: '/
|
|
130
|
+
path: '/organizations/:organizationId/buyers/:id',
|
|
131
131
|
pathParams: z.object({
|
|
132
|
-
|
|
132
|
+
organizationId: z.string().uuid(),
|
|
133
133
|
id: z.string().uuid(),
|
|
134
134
|
}),
|
|
135
135
|
responses: {
|