@deliverart/sdk-js-user 0.2.6 → 0.3.0
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/CHANGELOG.md +12 -0
- package/dist/index.cjs +25 -34
- package/dist/index.d.cts +86 -59
- package/dist/index.d.ts +86 -59
- package/dist/index.js +18 -27
- package/package.json +3 -3
- package/src/models.ts +12 -1
- package/src/requests/CreateUser.ts +8 -5
- package/src/requests/DeleteUser.ts +5 -2
- package/src/requests/GetMe.ts +5 -4
- package/src/requests/GetUserDetails.ts +8 -4
- package/src/requests/GetUsers.ts +11 -15
- package/src/requests/UpdateUser.ts +9 -5
- package/src/types.ts +3 -20
package/CHANGELOG.md
CHANGED
package/dist/index.cjs
CHANGED
|
@@ -41,20 +41,21 @@ __export(index_exports, {
|
|
|
41
41
|
securityRoles: () => securityRoles,
|
|
42
42
|
updateUserInputSchema: () => updateUserInputSchema,
|
|
43
43
|
updateUserResponseSchema: () => updateUserResponseSchema,
|
|
44
|
-
|
|
45
|
-
userPathSchema: () => userPathSchema,
|
|
44
|
+
userIriSchema: () => userIriSchema,
|
|
46
45
|
userSchema: () => userSchema,
|
|
47
46
|
userStepSchema: () => userStepSchema,
|
|
48
47
|
userSteps: () => userSteps,
|
|
48
|
+
usersQuerySchema: () => usersQuerySchema,
|
|
49
49
|
writableUserSchema: () => writableUserSchema
|
|
50
50
|
});
|
|
51
51
|
module.exports = __toCommonJS(index_exports);
|
|
52
52
|
|
|
53
53
|
// src/models.ts
|
|
54
|
-
var
|
|
54
|
+
var import_sdk_js_global_types2 = require("@deliverart/sdk-js-global-types");
|
|
55
55
|
var import_zod2 = require("zod");
|
|
56
56
|
|
|
57
57
|
// src/types.ts
|
|
58
|
+
var import_sdk_js_global_types = require("@deliverart/sdk-js-global-types");
|
|
58
59
|
var import_zod = require("zod");
|
|
59
60
|
var securityRoles = [
|
|
60
61
|
// Role used for describe single operations
|
|
@@ -102,18 +103,7 @@ var userSteps = [
|
|
|
102
103
|
"create_point_of_sale"
|
|
103
104
|
];
|
|
104
105
|
var userStepSchema = import_zod.z.enum(userSteps);
|
|
105
|
-
var
|
|
106
|
-
message: "Invalid user path format"
|
|
107
|
-
});
|
|
108
|
-
var userNullablePathSchema = import_zod.z.string().nullable().refine(
|
|
109
|
-
(val) => {
|
|
110
|
-
if (!val) return true;
|
|
111
|
-
return /^\/users\/[a-z_]+\/[0-9a-fA-F-]{36}$/.test(val);
|
|
112
|
-
},
|
|
113
|
-
{
|
|
114
|
-
message: "Invalid user path format"
|
|
115
|
-
}
|
|
116
|
-
);
|
|
106
|
+
var userIriSchema = (0, import_sdk_js_global_types.iriSchema)("/users/:id");
|
|
117
107
|
|
|
118
108
|
// src/models.ts
|
|
119
109
|
var userSchema = import_zod2.z.object({
|
|
@@ -125,8 +115,8 @@ var userSchema = import_zod2.z.object({
|
|
|
125
115
|
completedSteps: userStepSchema.array(),
|
|
126
116
|
emailVerified: import_zod2.z.boolean(),
|
|
127
117
|
suspended: import_zod2.z.boolean(),
|
|
128
|
-
createdAt:
|
|
129
|
-
updatedAt:
|
|
118
|
+
createdAt: import_sdk_js_global_types2.datetimeSchema,
|
|
119
|
+
updatedAt: import_sdk_js_global_types2.datetimeSchema
|
|
130
120
|
});
|
|
131
121
|
var writableUserSchema = userSchema.pick({
|
|
132
122
|
firstName: true,
|
|
@@ -136,6 +126,15 @@ var writableUserSchema = userSchema.pick({
|
|
|
136
126
|
}).extend({
|
|
137
127
|
plainPassword: import_zod2.z.string().optional()
|
|
138
128
|
}).partial();
|
|
129
|
+
var usersQuerySchema = import_zod2.z.object({
|
|
130
|
+
email: import_zod2.z.string().optional(),
|
|
131
|
+
firstName: import_zod2.z.string().optional(),
|
|
132
|
+
lastName: import_zod2.z.string().optional(),
|
|
133
|
+
suspended: import_zod2.z.string().optional(),
|
|
134
|
+
"order[createdAt]": import_zod2.z.enum(["asc", "desc"]).optional(),
|
|
135
|
+
page: import_zod2.z.coerce.number().optional(),
|
|
136
|
+
"roles[]": import_zod2.z.array(import_zod2.z.enum(securityRoles)).optional()
|
|
137
|
+
});
|
|
139
138
|
|
|
140
139
|
// src/requests/CreateUser.ts
|
|
141
140
|
var import_sdk_js_core = require("@deliverart/sdk-js-core");
|
|
@@ -172,7 +171,7 @@ var DeleteUser = class extends import_sdk_js_core2.AbstractApiRequest {
|
|
|
172
171
|
headersSchema = void 0;
|
|
173
172
|
userId;
|
|
174
173
|
constructor(userId) {
|
|
175
|
-
super();
|
|
174
|
+
super(void 0);
|
|
176
175
|
this.userId = userId;
|
|
177
176
|
}
|
|
178
177
|
getPath() {
|
|
@@ -194,7 +193,7 @@ var GetMe = class extends import_sdk_js_core3.AbstractApiRequest {
|
|
|
194
193
|
querySchema = void 0;
|
|
195
194
|
headersSchema = void 0;
|
|
196
195
|
constructor() {
|
|
197
|
-
super();
|
|
196
|
+
super(void 0);
|
|
198
197
|
}
|
|
199
198
|
getPath() {
|
|
200
199
|
return "/me";
|
|
@@ -216,7 +215,7 @@ var GetUserDetails = class extends import_sdk_js_core4.AbstractApiRequest {
|
|
|
216
215
|
headersSchema = void 0;
|
|
217
216
|
userId;
|
|
218
217
|
constructor(userId) {
|
|
219
|
-
super();
|
|
218
|
+
super(void 0);
|
|
220
219
|
this.userId = userId;
|
|
221
220
|
}
|
|
222
221
|
getPath() {
|
|
@@ -226,19 +225,11 @@ var GetUserDetails = class extends import_sdk_js_core4.AbstractApiRequest {
|
|
|
226
225
|
|
|
227
226
|
// src/requests/GetUsers.ts
|
|
228
227
|
var import_sdk_js_core5 = require("@deliverart/sdk-js-core");
|
|
229
|
-
var
|
|
228
|
+
var import_sdk_js_global_types3 = require("@deliverart/sdk-js-global-types");
|
|
230
229
|
var import_zod6 = require("zod");
|
|
231
|
-
var getUsersQuerySchema =
|
|
232
|
-
email: import_zod6.z.string().optional(),
|
|
233
|
-
firstName: import_zod6.z.string().optional(),
|
|
234
|
-
lastName: import_zod6.z.string().optional(),
|
|
235
|
-
suspended: import_zod6.z.string().optional(),
|
|
236
|
-
"order[createdAt]": import_zod6.z.enum(["asc", "desc"]).optional(),
|
|
237
|
-
page: import_zod6.z.coerce.number().optional(),
|
|
238
|
-
"roles[]": import_zod6.z.array(import_zod6.z.enum(securityRoles)).optional()
|
|
239
|
-
});
|
|
240
|
-
var getUsersResponseSchema = (0, import_sdk_js_global_types2.createPaginatedSchema)(userSchema);
|
|
230
|
+
var getUsersQuerySchema = usersQuerySchema;
|
|
241
231
|
var getUsersInputSchema = import_zod6.z.undefined();
|
|
232
|
+
var getUsersResponseSchema = (0, import_sdk_js_global_types3.createPaginatedSchema)(userSchema);
|
|
242
233
|
var GetUsers = class extends import_sdk_js_core5.AbstractApiRequest {
|
|
243
234
|
method = "GET";
|
|
244
235
|
contentType = "application/json";
|
|
@@ -255,7 +246,7 @@ var GetUsers = class extends import_sdk_js_core5.AbstractApiRequest {
|
|
|
255
246
|
}
|
|
256
247
|
parseResponse(data, rawResponse) {
|
|
257
248
|
const users = import_zod6.z.array(userSchema).parse(data);
|
|
258
|
-
return this.validateOutput({ data: users, pagination: (0,
|
|
249
|
+
return this.validateOutput({ data: users, pagination: (0, import_sdk_js_global_types3.responseToPagination)(rawResponse) });
|
|
259
250
|
}
|
|
260
251
|
};
|
|
261
252
|
|
|
@@ -303,10 +294,10 @@ var UpdateUser = class extends import_sdk_js_core6.AbstractApiRequest {
|
|
|
303
294
|
securityRoles,
|
|
304
295
|
updateUserInputSchema,
|
|
305
296
|
updateUserResponseSchema,
|
|
306
|
-
|
|
307
|
-
userPathSchema,
|
|
297
|
+
userIriSchema,
|
|
308
298
|
userSchema,
|
|
309
299
|
userStepSchema,
|
|
310
300
|
userSteps,
|
|
301
|
+
usersQuerySchema,
|
|
311
302
|
writableUserSchema
|
|
312
303
|
});
|
package/dist/index.d.cts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import * as zod from 'zod';
|
|
2
1
|
import { z } from 'zod';
|
|
3
2
|
import { AbstractApiRequest } from '@deliverart/sdk-js-core';
|
|
3
|
+
import * as _deliverart_sdk_js_global_types from '@deliverart/sdk-js-global-types';
|
|
4
4
|
import { Paginated } from '@deliverart/sdk-js-global-types';
|
|
5
5
|
import { AxiosResponse } from 'axios';
|
|
6
6
|
|
|
@@ -59,6 +59,32 @@ declare const writableUserSchema: z.ZodObject<{
|
|
|
59
59
|
plainPassword?: string | undefined;
|
|
60
60
|
}>;
|
|
61
61
|
type WritableUser = z.infer<typeof writableUserSchema>;
|
|
62
|
+
declare const usersQuerySchema: z.ZodObject<{
|
|
63
|
+
email: z.ZodOptional<z.ZodString>;
|
|
64
|
+
firstName: z.ZodOptional<z.ZodString>;
|
|
65
|
+
lastName: z.ZodOptional<z.ZodString>;
|
|
66
|
+
suspended: z.ZodOptional<z.ZodString>;
|
|
67
|
+
'order[createdAt]': z.ZodOptional<z.ZodEnum<["asc", "desc"]>>;
|
|
68
|
+
page: z.ZodOptional<z.ZodNumber>;
|
|
69
|
+
'roles[]': z.ZodOptional<z.ZodArray<z.ZodEnum<["ROLE_CUSTOMER_ACCESS", "ROLE_BUNDLE_ACCESS", "ROLE_DELIVERY_ACCESS", "ROLE_POINT_OF_SALE_ACCESS", "ROLE_MENU_ACCESS", "ROLE_INTEGRATION_ACCESS", "ROLE_ORDER_ACCESS", "ROLE_LEAD_ACCESS", "ROLE_COMPANY_ACCESS", "ROLE_USER_ACCESS", "ROLE_SUBSCRIPTION_ACCESS", "ROLE_PAYMENT_ACCESS", "ROLE_PAYMENT_CONFIG_ACCESS", "ROLE_CUSTOMER_ADMIN", "ROLE_BUNDLE_ADMIN", "ROLE_DELIVERY_ADMIN", "ROLE_POINT_OF_SALE_ADMIN", "ROLE_MENU_ADMIN", "ROLE_INTEGRATION_ADMIN", "ROLE_ORDER_ADMIN", "ROLE_LEAD_ADMIN", "ROLE_COMPANY_ADMIN", "ROLE_USER_ADMIN", "ROLE_SUBSCRIPTION_ADMIN", "ROLE_PAYMENT_ADMIN", "ROLE_PAYMENT_CONFIG_ADMIN", "ROLE_COURIER", "ROLE_CUSTOMER", "ROLE_MANAGER", "ROLE_SUPER_ADMIN", "ROLE_KITCHEN", "ROLE_USER"]>, "many">>;
|
|
70
|
+
}, "strip", z.ZodTypeAny, {
|
|
71
|
+
firstName?: string | undefined;
|
|
72
|
+
lastName?: string | undefined;
|
|
73
|
+
email?: string | undefined;
|
|
74
|
+
suspended?: string | undefined;
|
|
75
|
+
'order[createdAt]'?: "asc" | "desc" | undefined;
|
|
76
|
+
page?: number | undefined;
|
|
77
|
+
'roles[]'?: ("ROLE_CUSTOMER_ACCESS" | "ROLE_BUNDLE_ACCESS" | "ROLE_DELIVERY_ACCESS" | "ROLE_POINT_OF_SALE_ACCESS" | "ROLE_MENU_ACCESS" | "ROLE_INTEGRATION_ACCESS" | "ROLE_ORDER_ACCESS" | "ROLE_LEAD_ACCESS" | "ROLE_COMPANY_ACCESS" | "ROLE_USER_ACCESS" | "ROLE_SUBSCRIPTION_ACCESS" | "ROLE_PAYMENT_ACCESS" | "ROLE_PAYMENT_CONFIG_ACCESS" | "ROLE_CUSTOMER_ADMIN" | "ROLE_BUNDLE_ADMIN" | "ROLE_DELIVERY_ADMIN" | "ROLE_POINT_OF_SALE_ADMIN" | "ROLE_MENU_ADMIN" | "ROLE_INTEGRATION_ADMIN" | "ROLE_ORDER_ADMIN" | "ROLE_LEAD_ADMIN" | "ROLE_COMPANY_ADMIN" | "ROLE_USER_ADMIN" | "ROLE_SUBSCRIPTION_ADMIN" | "ROLE_PAYMENT_ADMIN" | "ROLE_PAYMENT_CONFIG_ADMIN" | "ROLE_COURIER" | "ROLE_CUSTOMER" | "ROLE_MANAGER" | "ROLE_SUPER_ADMIN" | "ROLE_KITCHEN" | "ROLE_USER")[] | undefined;
|
|
78
|
+
}, {
|
|
79
|
+
firstName?: string | undefined;
|
|
80
|
+
lastName?: string | undefined;
|
|
81
|
+
email?: string | undefined;
|
|
82
|
+
suspended?: string | undefined;
|
|
83
|
+
'order[createdAt]'?: "asc" | "desc" | undefined;
|
|
84
|
+
page?: number | undefined;
|
|
85
|
+
'roles[]'?: ("ROLE_CUSTOMER_ACCESS" | "ROLE_BUNDLE_ACCESS" | "ROLE_DELIVERY_ACCESS" | "ROLE_POINT_OF_SALE_ACCESS" | "ROLE_MENU_ACCESS" | "ROLE_INTEGRATION_ACCESS" | "ROLE_ORDER_ACCESS" | "ROLE_LEAD_ACCESS" | "ROLE_COMPANY_ACCESS" | "ROLE_USER_ACCESS" | "ROLE_SUBSCRIPTION_ACCESS" | "ROLE_PAYMENT_ACCESS" | "ROLE_PAYMENT_CONFIG_ACCESS" | "ROLE_CUSTOMER_ADMIN" | "ROLE_BUNDLE_ADMIN" | "ROLE_DELIVERY_ADMIN" | "ROLE_POINT_OF_SALE_ADMIN" | "ROLE_MENU_ADMIN" | "ROLE_INTEGRATION_ADMIN" | "ROLE_ORDER_ADMIN" | "ROLE_LEAD_ADMIN" | "ROLE_COMPANY_ADMIN" | "ROLE_USER_ADMIN" | "ROLE_SUBSCRIPTION_ADMIN" | "ROLE_PAYMENT_ADMIN" | "ROLE_PAYMENT_CONFIG_ADMIN" | "ROLE_COURIER" | "ROLE_CUSTOMER" | "ROLE_MANAGER" | "ROLE_SUPER_ADMIN" | "ROLE_KITCHEN" | "ROLE_USER")[] | undefined;
|
|
86
|
+
}>;
|
|
87
|
+
type UsersQueryParams = z.infer<typeof usersQuerySchema>;
|
|
62
88
|
|
|
63
89
|
declare const createUserInputSchema: z.ZodObject<{
|
|
64
90
|
firstName: z.ZodString;
|
|
@@ -79,7 +105,7 @@ declare const createUserInputSchema: z.ZodObject<{
|
|
|
79
105
|
roles: ("ROLE_CUSTOMER_ACCESS" | "ROLE_BUNDLE_ACCESS" | "ROLE_DELIVERY_ACCESS" | "ROLE_POINT_OF_SALE_ACCESS" | "ROLE_MENU_ACCESS" | "ROLE_INTEGRATION_ACCESS" | "ROLE_ORDER_ACCESS" | "ROLE_LEAD_ACCESS" | "ROLE_COMPANY_ACCESS" | "ROLE_USER_ACCESS" | "ROLE_SUBSCRIPTION_ACCESS" | "ROLE_PAYMENT_ACCESS" | "ROLE_PAYMENT_CONFIG_ACCESS" | "ROLE_CUSTOMER_ADMIN" | "ROLE_BUNDLE_ADMIN" | "ROLE_DELIVERY_ADMIN" | "ROLE_POINT_OF_SALE_ADMIN" | "ROLE_MENU_ADMIN" | "ROLE_INTEGRATION_ADMIN" | "ROLE_ORDER_ADMIN" | "ROLE_LEAD_ADMIN" | "ROLE_COMPANY_ADMIN" | "ROLE_USER_ADMIN" | "ROLE_SUBSCRIPTION_ADMIN" | "ROLE_PAYMENT_ADMIN" | "ROLE_PAYMENT_CONFIG_ADMIN" | "ROLE_COURIER" | "ROLE_CUSTOMER" | "ROLE_MANAGER" | "ROLE_SUPER_ADMIN" | "ROLE_KITCHEN" | "ROLE_USER")[];
|
|
80
106
|
plainPassword: string;
|
|
81
107
|
}>;
|
|
82
|
-
type CreateUserInput = z.
|
|
108
|
+
type CreateUserInput = z.input<typeof createUserInputSchema>;
|
|
83
109
|
declare const createUserResponseSchema: z.ZodObject<{
|
|
84
110
|
id: z.ZodString;
|
|
85
111
|
firstName: z.ZodString;
|
|
@@ -114,8 +140,8 @@ declare const createUserResponseSchema: z.ZodObject<{
|
|
|
114
140
|
createdAt: string;
|
|
115
141
|
updatedAt: string;
|
|
116
142
|
}>;
|
|
117
|
-
type CreateUserResponse =
|
|
118
|
-
declare class CreateUser extends AbstractApiRequest<
|
|
143
|
+
type CreateUserResponse = z.output<typeof createUserResponseSchema>;
|
|
144
|
+
declare class CreateUser extends AbstractApiRequest<typeof createUserInputSchema, typeof createUserResponseSchema> {
|
|
119
145
|
readonly method = "POST";
|
|
120
146
|
readonly contentType = "application/json";
|
|
121
147
|
readonly accept = "application/json";
|
|
@@ -174,13 +200,13 @@ declare class CreateUser extends AbstractApiRequest<CreateUserInput, CreateUserR
|
|
|
174
200
|
}>;
|
|
175
201
|
readonly querySchema: undefined;
|
|
176
202
|
readonly headersSchema: undefined;
|
|
177
|
-
constructor(input:
|
|
203
|
+
constructor(input: z.input<typeof createUserInputSchema>);
|
|
178
204
|
getPath(): string;
|
|
179
205
|
}
|
|
180
206
|
|
|
181
207
|
declare const deleteUserInputSchema: z.ZodUndefined;
|
|
182
208
|
declare const deleteUserResponseSchema: z.ZodUndefined;
|
|
183
|
-
declare class DeleteUser extends AbstractApiRequest<
|
|
209
|
+
declare class DeleteUser extends AbstractApiRequest<typeof deleteUserInputSchema, typeof deleteUserResponseSchema> {
|
|
184
210
|
readonly method = "DELETE";
|
|
185
211
|
readonly contentType = "application/json";
|
|
186
212
|
readonly accept = "application/json";
|
|
@@ -194,6 +220,7 @@ declare class DeleteUser extends AbstractApiRequest<void, void> {
|
|
|
194
220
|
}
|
|
195
221
|
|
|
196
222
|
declare const getMeInputSchema: z.ZodUndefined;
|
|
223
|
+
type GetMeInput = z.input<typeof getMeInputSchema>;
|
|
197
224
|
declare const getMeResponseSchema: z.ZodObject<{
|
|
198
225
|
id: z.ZodString;
|
|
199
226
|
firstName: z.ZodString;
|
|
@@ -228,8 +255,8 @@ declare const getMeResponseSchema: z.ZodObject<{
|
|
|
228
255
|
createdAt: string;
|
|
229
256
|
updatedAt: string;
|
|
230
257
|
}>;
|
|
231
|
-
type GetMeResponse =
|
|
232
|
-
declare class GetMe extends AbstractApiRequest<
|
|
258
|
+
type GetMeResponse = z.output<typeof getMeResponseSchema>;
|
|
259
|
+
declare class GetMe extends AbstractApiRequest<typeof getMeInputSchema, typeof getMeResponseSchema> {
|
|
233
260
|
readonly method = "GET";
|
|
234
261
|
readonly contentType = "application/json";
|
|
235
262
|
readonly accept = "application/json";
|
|
@@ -275,6 +302,7 @@ declare class GetMe extends AbstractApiRequest<void, GetMeResponse> {
|
|
|
275
302
|
}
|
|
276
303
|
|
|
277
304
|
declare const getUserDetailsInputSchema: z.ZodUndefined;
|
|
305
|
+
type GetUserDetailsInput = z.input<typeof getUserDetailsInputSchema>;
|
|
278
306
|
declare const getUserDetailsResponseSchema: z.ZodObject<{
|
|
279
307
|
id: z.ZodString;
|
|
280
308
|
firstName: z.ZodString;
|
|
@@ -309,8 +337,8 @@ declare const getUserDetailsResponseSchema: z.ZodObject<{
|
|
|
309
337
|
createdAt: string;
|
|
310
338
|
updatedAt: string;
|
|
311
339
|
}>;
|
|
312
|
-
type GetUserDetailsResponse =
|
|
313
|
-
declare class GetUserDetails extends AbstractApiRequest<
|
|
340
|
+
type GetUserDetailsResponse = z.infer<typeof getUserDetailsResponseSchema>;
|
|
341
|
+
declare class GetUserDetails extends AbstractApiRequest<typeof getUserDetailsInputSchema, typeof getUserDetailsResponseSchema> {
|
|
314
342
|
readonly method = "GET";
|
|
315
343
|
readonly contentType = "application/json";
|
|
316
344
|
readonly accept = "application/json";
|
|
@@ -382,6 +410,8 @@ declare const getUsersQuerySchema: z.ZodObject<{
|
|
|
382
410
|
'roles[]'?: ("ROLE_CUSTOMER_ACCESS" | "ROLE_BUNDLE_ACCESS" | "ROLE_DELIVERY_ACCESS" | "ROLE_POINT_OF_SALE_ACCESS" | "ROLE_MENU_ACCESS" | "ROLE_INTEGRATION_ACCESS" | "ROLE_ORDER_ACCESS" | "ROLE_LEAD_ACCESS" | "ROLE_COMPANY_ACCESS" | "ROLE_USER_ACCESS" | "ROLE_SUBSCRIPTION_ACCESS" | "ROLE_PAYMENT_ACCESS" | "ROLE_PAYMENT_CONFIG_ACCESS" | "ROLE_CUSTOMER_ADMIN" | "ROLE_BUNDLE_ADMIN" | "ROLE_DELIVERY_ADMIN" | "ROLE_POINT_OF_SALE_ADMIN" | "ROLE_MENU_ADMIN" | "ROLE_INTEGRATION_ADMIN" | "ROLE_ORDER_ADMIN" | "ROLE_LEAD_ADMIN" | "ROLE_COMPANY_ADMIN" | "ROLE_USER_ADMIN" | "ROLE_SUBSCRIPTION_ADMIN" | "ROLE_PAYMENT_ADMIN" | "ROLE_PAYMENT_CONFIG_ADMIN" | "ROLE_COURIER" | "ROLE_CUSTOMER" | "ROLE_MANAGER" | "ROLE_SUPER_ADMIN" | "ROLE_KITCHEN" | "ROLE_USER")[] | undefined;
|
|
383
411
|
}>;
|
|
384
412
|
type GetUsersQueryParams = z.infer<typeof getUsersQuerySchema>;
|
|
413
|
+
declare const getUsersInputSchema: z.ZodUndefined;
|
|
414
|
+
type GetUsersInput = z.input<typeof getUsersInputSchema>;
|
|
385
415
|
declare const getUsersResponseSchema: z.ZodObject<{
|
|
386
416
|
data: z.ZodArray<z.ZodObject<{
|
|
387
417
|
id: z.ZodString;
|
|
@@ -483,8 +513,7 @@ declare const getUsersResponseSchema: z.ZodObject<{
|
|
|
483
513
|
};
|
|
484
514
|
}>;
|
|
485
515
|
type GetUsersResponse = z.infer<typeof getUsersResponseSchema>;
|
|
486
|
-
declare
|
|
487
|
-
declare class GetUsers extends AbstractApiRequest<void, GetUsersResponse, GetUsersQueryParams> {
|
|
516
|
+
declare class GetUsers extends AbstractApiRequest<typeof getUsersInputSchema, typeof getUsersResponseSchema, GetUsersQueryParams> {
|
|
488
517
|
readonly method = "GET";
|
|
489
518
|
readonly contentType = "application/json";
|
|
490
519
|
readonly accept = "application/json";
|
|
@@ -622,13 +651,13 @@ declare class GetUsers extends AbstractApiRequest<void, GetUsersResponse, GetUse
|
|
|
622
651
|
parseResponse(data: unknown, rawResponse: AxiosResponse): Paginated<User>;
|
|
623
652
|
}
|
|
624
653
|
|
|
625
|
-
declare const updateUserInputSchema:
|
|
626
|
-
firstName:
|
|
627
|
-
lastName:
|
|
628
|
-
email:
|
|
629
|
-
roles:
|
|
630
|
-
plainPassword:
|
|
631
|
-
}, "strip",
|
|
654
|
+
declare const updateUserInputSchema: z.ZodObject<{
|
|
655
|
+
firstName: z.ZodOptional<z.ZodString>;
|
|
656
|
+
lastName: z.ZodOptional<z.ZodString>;
|
|
657
|
+
email: z.ZodOptional<z.ZodString>;
|
|
658
|
+
roles: z.ZodOptional<z.ZodArray<z.ZodEnum<["ROLE_CUSTOMER_ACCESS", "ROLE_BUNDLE_ACCESS", "ROLE_DELIVERY_ACCESS", "ROLE_POINT_OF_SALE_ACCESS", "ROLE_MENU_ACCESS", "ROLE_INTEGRATION_ACCESS", "ROLE_ORDER_ACCESS", "ROLE_LEAD_ACCESS", "ROLE_COMPANY_ACCESS", "ROLE_USER_ACCESS", "ROLE_SUBSCRIPTION_ACCESS", "ROLE_PAYMENT_ACCESS", "ROLE_PAYMENT_CONFIG_ACCESS", "ROLE_CUSTOMER_ADMIN", "ROLE_BUNDLE_ADMIN", "ROLE_DELIVERY_ADMIN", "ROLE_POINT_OF_SALE_ADMIN", "ROLE_MENU_ADMIN", "ROLE_INTEGRATION_ADMIN", "ROLE_ORDER_ADMIN", "ROLE_LEAD_ADMIN", "ROLE_COMPANY_ADMIN", "ROLE_USER_ADMIN", "ROLE_SUBSCRIPTION_ADMIN", "ROLE_PAYMENT_ADMIN", "ROLE_PAYMENT_CONFIG_ADMIN", "ROLE_COURIER", "ROLE_CUSTOMER", "ROLE_MANAGER", "ROLE_SUPER_ADMIN", "ROLE_KITCHEN", "ROLE_USER"]>, "many">>;
|
|
659
|
+
plainPassword: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
660
|
+
}, "strip", z.ZodTypeAny, {
|
|
632
661
|
firstName?: string | undefined;
|
|
633
662
|
lastName?: string | undefined;
|
|
634
663
|
email?: string | undefined;
|
|
@@ -641,19 +670,19 @@ declare const updateUserInputSchema: zod.ZodObject<{
|
|
|
641
670
|
roles?: ("ROLE_CUSTOMER_ACCESS" | "ROLE_BUNDLE_ACCESS" | "ROLE_DELIVERY_ACCESS" | "ROLE_POINT_OF_SALE_ACCESS" | "ROLE_MENU_ACCESS" | "ROLE_INTEGRATION_ACCESS" | "ROLE_ORDER_ACCESS" | "ROLE_LEAD_ACCESS" | "ROLE_COMPANY_ACCESS" | "ROLE_USER_ACCESS" | "ROLE_SUBSCRIPTION_ACCESS" | "ROLE_PAYMENT_ACCESS" | "ROLE_PAYMENT_CONFIG_ACCESS" | "ROLE_CUSTOMER_ADMIN" | "ROLE_BUNDLE_ADMIN" | "ROLE_DELIVERY_ADMIN" | "ROLE_POINT_OF_SALE_ADMIN" | "ROLE_MENU_ADMIN" | "ROLE_INTEGRATION_ADMIN" | "ROLE_ORDER_ADMIN" | "ROLE_LEAD_ADMIN" | "ROLE_COMPANY_ADMIN" | "ROLE_USER_ADMIN" | "ROLE_SUBSCRIPTION_ADMIN" | "ROLE_PAYMENT_ADMIN" | "ROLE_PAYMENT_CONFIG_ADMIN" | "ROLE_COURIER" | "ROLE_CUSTOMER" | "ROLE_MANAGER" | "ROLE_SUPER_ADMIN" | "ROLE_KITCHEN" | "ROLE_USER")[] | undefined;
|
|
642
671
|
plainPassword?: string | undefined;
|
|
643
672
|
}>;
|
|
644
|
-
type UpdateUserInput =
|
|
645
|
-
declare const updateUserResponseSchema:
|
|
646
|
-
id:
|
|
647
|
-
firstName:
|
|
648
|
-
lastName:
|
|
649
|
-
email:
|
|
650
|
-
roles:
|
|
651
|
-
completedSteps:
|
|
652
|
-
emailVerified:
|
|
653
|
-
suspended:
|
|
654
|
-
createdAt:
|
|
655
|
-
updatedAt:
|
|
656
|
-
}, "strip",
|
|
673
|
+
type UpdateUserInput = z.input<typeof updateUserInputSchema>;
|
|
674
|
+
declare const updateUserResponseSchema: z.ZodObject<{
|
|
675
|
+
id: z.ZodString;
|
|
676
|
+
firstName: z.ZodString;
|
|
677
|
+
lastName: z.ZodString;
|
|
678
|
+
email: z.ZodString;
|
|
679
|
+
roles: z.ZodArray<z.ZodEnum<["ROLE_CUSTOMER_ACCESS", "ROLE_BUNDLE_ACCESS", "ROLE_DELIVERY_ACCESS", "ROLE_POINT_OF_SALE_ACCESS", "ROLE_MENU_ACCESS", "ROLE_INTEGRATION_ACCESS", "ROLE_ORDER_ACCESS", "ROLE_LEAD_ACCESS", "ROLE_COMPANY_ACCESS", "ROLE_USER_ACCESS", "ROLE_SUBSCRIPTION_ACCESS", "ROLE_PAYMENT_ACCESS", "ROLE_PAYMENT_CONFIG_ACCESS", "ROLE_CUSTOMER_ADMIN", "ROLE_BUNDLE_ADMIN", "ROLE_DELIVERY_ADMIN", "ROLE_POINT_OF_SALE_ADMIN", "ROLE_MENU_ADMIN", "ROLE_INTEGRATION_ADMIN", "ROLE_ORDER_ADMIN", "ROLE_LEAD_ADMIN", "ROLE_COMPANY_ADMIN", "ROLE_USER_ADMIN", "ROLE_SUBSCRIPTION_ADMIN", "ROLE_PAYMENT_ADMIN", "ROLE_PAYMENT_CONFIG_ADMIN", "ROLE_COURIER", "ROLE_CUSTOMER", "ROLE_MANAGER", "ROLE_SUPER_ADMIN", "ROLE_KITCHEN", "ROLE_USER"]>, "many">;
|
|
680
|
+
completedSteps: z.ZodArray<z.ZodEnum<["registration", "verify_email", "create_company", "create_point_of_sale"]>, "many">;
|
|
681
|
+
emailVerified: z.ZodBoolean;
|
|
682
|
+
suspended: z.ZodBoolean;
|
|
683
|
+
createdAt: z.ZodEffects<z.ZodString, string, string>;
|
|
684
|
+
updatedAt: z.ZodEffects<z.ZodString, string, string>;
|
|
685
|
+
}, "strip", z.ZodTypeAny, {
|
|
657
686
|
id: string;
|
|
658
687
|
firstName: string;
|
|
659
688
|
lastName: string;
|
|
@@ -676,18 +705,18 @@ declare const updateUserResponseSchema: zod.ZodObject<{
|
|
|
676
705
|
createdAt: string;
|
|
677
706
|
updatedAt: string;
|
|
678
707
|
}>;
|
|
679
|
-
type UpdateUserResponse =
|
|
680
|
-
declare class UpdateUser extends AbstractApiRequest<
|
|
708
|
+
type UpdateUserResponse = z.infer<typeof updateUserResponseSchema>;
|
|
709
|
+
declare class UpdateUser extends AbstractApiRequest<typeof updateUserInputSchema, typeof updateUserResponseSchema> {
|
|
681
710
|
readonly method = "PATCH";
|
|
682
711
|
readonly contentType = "application/merge-patch+json";
|
|
683
712
|
readonly accept = "application/json";
|
|
684
|
-
readonly inputSchema:
|
|
685
|
-
firstName:
|
|
686
|
-
lastName:
|
|
687
|
-
email:
|
|
688
|
-
roles:
|
|
689
|
-
plainPassword:
|
|
690
|
-
}, "strip",
|
|
713
|
+
readonly inputSchema: z.ZodObject<{
|
|
714
|
+
firstName: z.ZodOptional<z.ZodString>;
|
|
715
|
+
lastName: z.ZodOptional<z.ZodString>;
|
|
716
|
+
email: z.ZodOptional<z.ZodString>;
|
|
717
|
+
roles: z.ZodOptional<z.ZodArray<z.ZodEnum<["ROLE_CUSTOMER_ACCESS", "ROLE_BUNDLE_ACCESS", "ROLE_DELIVERY_ACCESS", "ROLE_POINT_OF_SALE_ACCESS", "ROLE_MENU_ACCESS", "ROLE_INTEGRATION_ACCESS", "ROLE_ORDER_ACCESS", "ROLE_LEAD_ACCESS", "ROLE_COMPANY_ACCESS", "ROLE_USER_ACCESS", "ROLE_SUBSCRIPTION_ACCESS", "ROLE_PAYMENT_ACCESS", "ROLE_PAYMENT_CONFIG_ACCESS", "ROLE_CUSTOMER_ADMIN", "ROLE_BUNDLE_ADMIN", "ROLE_DELIVERY_ADMIN", "ROLE_POINT_OF_SALE_ADMIN", "ROLE_MENU_ADMIN", "ROLE_INTEGRATION_ADMIN", "ROLE_ORDER_ADMIN", "ROLE_LEAD_ADMIN", "ROLE_COMPANY_ADMIN", "ROLE_USER_ADMIN", "ROLE_SUBSCRIPTION_ADMIN", "ROLE_PAYMENT_ADMIN", "ROLE_PAYMENT_CONFIG_ADMIN", "ROLE_COURIER", "ROLE_CUSTOMER", "ROLE_MANAGER", "ROLE_SUPER_ADMIN", "ROLE_KITCHEN", "ROLE_USER"]>, "many">>;
|
|
718
|
+
plainPassword: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
719
|
+
}, "strip", z.ZodTypeAny, {
|
|
691
720
|
firstName?: string | undefined;
|
|
692
721
|
lastName?: string | undefined;
|
|
693
722
|
email?: string | undefined;
|
|
@@ -700,18 +729,18 @@ declare class UpdateUser extends AbstractApiRequest<UpdateUserInput, UpdateUserR
|
|
|
700
729
|
roles?: ("ROLE_CUSTOMER_ACCESS" | "ROLE_BUNDLE_ACCESS" | "ROLE_DELIVERY_ACCESS" | "ROLE_POINT_OF_SALE_ACCESS" | "ROLE_MENU_ACCESS" | "ROLE_INTEGRATION_ACCESS" | "ROLE_ORDER_ACCESS" | "ROLE_LEAD_ACCESS" | "ROLE_COMPANY_ACCESS" | "ROLE_USER_ACCESS" | "ROLE_SUBSCRIPTION_ACCESS" | "ROLE_PAYMENT_ACCESS" | "ROLE_PAYMENT_CONFIG_ACCESS" | "ROLE_CUSTOMER_ADMIN" | "ROLE_BUNDLE_ADMIN" | "ROLE_DELIVERY_ADMIN" | "ROLE_POINT_OF_SALE_ADMIN" | "ROLE_MENU_ADMIN" | "ROLE_INTEGRATION_ADMIN" | "ROLE_ORDER_ADMIN" | "ROLE_LEAD_ADMIN" | "ROLE_COMPANY_ADMIN" | "ROLE_USER_ADMIN" | "ROLE_SUBSCRIPTION_ADMIN" | "ROLE_PAYMENT_ADMIN" | "ROLE_PAYMENT_CONFIG_ADMIN" | "ROLE_COURIER" | "ROLE_CUSTOMER" | "ROLE_MANAGER" | "ROLE_SUPER_ADMIN" | "ROLE_KITCHEN" | "ROLE_USER")[] | undefined;
|
|
701
730
|
plainPassword?: string | undefined;
|
|
702
731
|
}>;
|
|
703
|
-
readonly outputSchema:
|
|
704
|
-
id:
|
|
705
|
-
firstName:
|
|
706
|
-
lastName:
|
|
707
|
-
email:
|
|
708
|
-
roles:
|
|
709
|
-
completedSteps:
|
|
710
|
-
emailVerified:
|
|
711
|
-
suspended:
|
|
712
|
-
createdAt:
|
|
713
|
-
updatedAt:
|
|
714
|
-
}, "strip",
|
|
732
|
+
readonly outputSchema: z.ZodObject<{
|
|
733
|
+
id: z.ZodString;
|
|
734
|
+
firstName: z.ZodString;
|
|
735
|
+
lastName: z.ZodString;
|
|
736
|
+
email: z.ZodString;
|
|
737
|
+
roles: z.ZodArray<z.ZodEnum<["ROLE_CUSTOMER_ACCESS", "ROLE_BUNDLE_ACCESS", "ROLE_DELIVERY_ACCESS", "ROLE_POINT_OF_SALE_ACCESS", "ROLE_MENU_ACCESS", "ROLE_INTEGRATION_ACCESS", "ROLE_ORDER_ACCESS", "ROLE_LEAD_ACCESS", "ROLE_COMPANY_ACCESS", "ROLE_USER_ACCESS", "ROLE_SUBSCRIPTION_ACCESS", "ROLE_PAYMENT_ACCESS", "ROLE_PAYMENT_CONFIG_ACCESS", "ROLE_CUSTOMER_ADMIN", "ROLE_BUNDLE_ADMIN", "ROLE_DELIVERY_ADMIN", "ROLE_POINT_OF_SALE_ADMIN", "ROLE_MENU_ADMIN", "ROLE_INTEGRATION_ADMIN", "ROLE_ORDER_ADMIN", "ROLE_LEAD_ADMIN", "ROLE_COMPANY_ADMIN", "ROLE_USER_ADMIN", "ROLE_SUBSCRIPTION_ADMIN", "ROLE_PAYMENT_ADMIN", "ROLE_PAYMENT_CONFIG_ADMIN", "ROLE_COURIER", "ROLE_CUSTOMER", "ROLE_MANAGER", "ROLE_SUPER_ADMIN", "ROLE_KITCHEN", "ROLE_USER"]>, "many">;
|
|
738
|
+
completedSteps: z.ZodArray<z.ZodEnum<["registration", "verify_email", "create_company", "create_point_of_sale"]>, "many">;
|
|
739
|
+
emailVerified: z.ZodBoolean;
|
|
740
|
+
suspended: z.ZodBoolean;
|
|
741
|
+
createdAt: z.ZodEffects<z.ZodString, string, string>;
|
|
742
|
+
updatedAt: z.ZodEffects<z.ZodString, string, string>;
|
|
743
|
+
}, "strip", z.ZodTypeAny, {
|
|
715
744
|
id: string;
|
|
716
745
|
firstName: string;
|
|
717
746
|
lastName: string;
|
|
@@ -737,7 +766,7 @@ declare class UpdateUser extends AbstractApiRequest<UpdateUserInput, UpdateUserR
|
|
|
737
766
|
readonly querySchema: undefined;
|
|
738
767
|
readonly headersSchema: undefined;
|
|
739
768
|
private readonly userId;
|
|
740
|
-
constructor(userId: string, input:
|
|
769
|
+
constructor(userId: string, input: z.input<typeof updateUserInputSchema>);
|
|
741
770
|
getPath(): string;
|
|
742
771
|
}
|
|
743
772
|
|
|
@@ -747,9 +776,7 @@ type SecurityRole = z.infer<typeof securityRoleSchema>;
|
|
|
747
776
|
declare const userSteps: readonly ["registration", "verify_email", "create_company", "create_point_of_sale"];
|
|
748
777
|
declare const userStepSchema: z.ZodEnum<["registration", "verify_email", "create_company", "create_point_of_sale"]>;
|
|
749
778
|
type UserStep = z.infer<typeof userStepSchema>;
|
|
750
|
-
declare const
|
|
751
|
-
type
|
|
752
|
-
declare const userNullablePathSchema: z.ZodEffects<z.ZodNullable<z.ZodString>, string | null, string | null>;
|
|
753
|
-
type UserNullablePath = z.infer<typeof userNullablePathSchema>;
|
|
779
|
+
declare const userIriSchema: z.ZodEffects<z.ZodString, _deliverart_sdk_js_global_types.IriObject<"/users/:id">, string>;
|
|
780
|
+
type UserIri = z.infer<typeof userIriSchema>;
|
|
754
781
|
|
|
755
|
-
export { CreateUser, type CreateUserInput, type CreateUserResponse, DeleteUser, GetMe, type GetMeResponse, GetUserDetails, type GetUserDetailsResponse, GetUsers, type GetUsersQueryParams, type GetUsersResponse, type SecurityRole, UpdateUser, type UpdateUserInput, type UpdateUserResponse, type User, type
|
|
782
|
+
export { CreateUser, type CreateUserInput, type CreateUserResponse, DeleteUser, GetMe, type GetMeInput, type GetMeResponse, GetUserDetails, type GetUserDetailsInput, type GetUserDetailsResponse, GetUsers, type GetUsersInput, type GetUsersQueryParams, type GetUsersResponse, type SecurityRole, UpdateUser, type UpdateUserInput, type UpdateUserResponse, type User, type UserIri, type UserStep, type UsersQueryParams, type WritableUser, createUserInputSchema, createUserResponseSchema, deleteUserInputSchema, deleteUserResponseSchema, getMeInputSchema, getMeResponseSchema, getUserDetailsInputSchema, getUserDetailsResponseSchema, getUsersInputSchema, getUsersQuerySchema, getUsersResponseSchema, securityRoleSchema, securityRoles, updateUserInputSchema, updateUserResponseSchema, userIriSchema, userSchema, userStepSchema, userSteps, usersQuerySchema, writableUserSchema };
|
package/dist/index.d.ts
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import * as zod from 'zod';
|
|
2
1
|
import { z } from 'zod';
|
|
3
2
|
import { AbstractApiRequest } from '@deliverart/sdk-js-core';
|
|
3
|
+
import * as _deliverart_sdk_js_global_types from '@deliverart/sdk-js-global-types';
|
|
4
4
|
import { Paginated } from '@deliverart/sdk-js-global-types';
|
|
5
5
|
import { AxiosResponse } from 'axios';
|
|
6
6
|
|
|
@@ -59,6 +59,32 @@ declare const writableUserSchema: z.ZodObject<{
|
|
|
59
59
|
plainPassword?: string | undefined;
|
|
60
60
|
}>;
|
|
61
61
|
type WritableUser = z.infer<typeof writableUserSchema>;
|
|
62
|
+
declare const usersQuerySchema: z.ZodObject<{
|
|
63
|
+
email: z.ZodOptional<z.ZodString>;
|
|
64
|
+
firstName: z.ZodOptional<z.ZodString>;
|
|
65
|
+
lastName: z.ZodOptional<z.ZodString>;
|
|
66
|
+
suspended: z.ZodOptional<z.ZodString>;
|
|
67
|
+
'order[createdAt]': z.ZodOptional<z.ZodEnum<["asc", "desc"]>>;
|
|
68
|
+
page: z.ZodOptional<z.ZodNumber>;
|
|
69
|
+
'roles[]': z.ZodOptional<z.ZodArray<z.ZodEnum<["ROLE_CUSTOMER_ACCESS", "ROLE_BUNDLE_ACCESS", "ROLE_DELIVERY_ACCESS", "ROLE_POINT_OF_SALE_ACCESS", "ROLE_MENU_ACCESS", "ROLE_INTEGRATION_ACCESS", "ROLE_ORDER_ACCESS", "ROLE_LEAD_ACCESS", "ROLE_COMPANY_ACCESS", "ROLE_USER_ACCESS", "ROLE_SUBSCRIPTION_ACCESS", "ROLE_PAYMENT_ACCESS", "ROLE_PAYMENT_CONFIG_ACCESS", "ROLE_CUSTOMER_ADMIN", "ROLE_BUNDLE_ADMIN", "ROLE_DELIVERY_ADMIN", "ROLE_POINT_OF_SALE_ADMIN", "ROLE_MENU_ADMIN", "ROLE_INTEGRATION_ADMIN", "ROLE_ORDER_ADMIN", "ROLE_LEAD_ADMIN", "ROLE_COMPANY_ADMIN", "ROLE_USER_ADMIN", "ROLE_SUBSCRIPTION_ADMIN", "ROLE_PAYMENT_ADMIN", "ROLE_PAYMENT_CONFIG_ADMIN", "ROLE_COURIER", "ROLE_CUSTOMER", "ROLE_MANAGER", "ROLE_SUPER_ADMIN", "ROLE_KITCHEN", "ROLE_USER"]>, "many">>;
|
|
70
|
+
}, "strip", z.ZodTypeAny, {
|
|
71
|
+
firstName?: string | undefined;
|
|
72
|
+
lastName?: string | undefined;
|
|
73
|
+
email?: string | undefined;
|
|
74
|
+
suspended?: string | undefined;
|
|
75
|
+
'order[createdAt]'?: "asc" | "desc" | undefined;
|
|
76
|
+
page?: number | undefined;
|
|
77
|
+
'roles[]'?: ("ROLE_CUSTOMER_ACCESS" | "ROLE_BUNDLE_ACCESS" | "ROLE_DELIVERY_ACCESS" | "ROLE_POINT_OF_SALE_ACCESS" | "ROLE_MENU_ACCESS" | "ROLE_INTEGRATION_ACCESS" | "ROLE_ORDER_ACCESS" | "ROLE_LEAD_ACCESS" | "ROLE_COMPANY_ACCESS" | "ROLE_USER_ACCESS" | "ROLE_SUBSCRIPTION_ACCESS" | "ROLE_PAYMENT_ACCESS" | "ROLE_PAYMENT_CONFIG_ACCESS" | "ROLE_CUSTOMER_ADMIN" | "ROLE_BUNDLE_ADMIN" | "ROLE_DELIVERY_ADMIN" | "ROLE_POINT_OF_SALE_ADMIN" | "ROLE_MENU_ADMIN" | "ROLE_INTEGRATION_ADMIN" | "ROLE_ORDER_ADMIN" | "ROLE_LEAD_ADMIN" | "ROLE_COMPANY_ADMIN" | "ROLE_USER_ADMIN" | "ROLE_SUBSCRIPTION_ADMIN" | "ROLE_PAYMENT_ADMIN" | "ROLE_PAYMENT_CONFIG_ADMIN" | "ROLE_COURIER" | "ROLE_CUSTOMER" | "ROLE_MANAGER" | "ROLE_SUPER_ADMIN" | "ROLE_KITCHEN" | "ROLE_USER")[] | undefined;
|
|
78
|
+
}, {
|
|
79
|
+
firstName?: string | undefined;
|
|
80
|
+
lastName?: string | undefined;
|
|
81
|
+
email?: string | undefined;
|
|
82
|
+
suspended?: string | undefined;
|
|
83
|
+
'order[createdAt]'?: "asc" | "desc" | undefined;
|
|
84
|
+
page?: number | undefined;
|
|
85
|
+
'roles[]'?: ("ROLE_CUSTOMER_ACCESS" | "ROLE_BUNDLE_ACCESS" | "ROLE_DELIVERY_ACCESS" | "ROLE_POINT_OF_SALE_ACCESS" | "ROLE_MENU_ACCESS" | "ROLE_INTEGRATION_ACCESS" | "ROLE_ORDER_ACCESS" | "ROLE_LEAD_ACCESS" | "ROLE_COMPANY_ACCESS" | "ROLE_USER_ACCESS" | "ROLE_SUBSCRIPTION_ACCESS" | "ROLE_PAYMENT_ACCESS" | "ROLE_PAYMENT_CONFIG_ACCESS" | "ROLE_CUSTOMER_ADMIN" | "ROLE_BUNDLE_ADMIN" | "ROLE_DELIVERY_ADMIN" | "ROLE_POINT_OF_SALE_ADMIN" | "ROLE_MENU_ADMIN" | "ROLE_INTEGRATION_ADMIN" | "ROLE_ORDER_ADMIN" | "ROLE_LEAD_ADMIN" | "ROLE_COMPANY_ADMIN" | "ROLE_USER_ADMIN" | "ROLE_SUBSCRIPTION_ADMIN" | "ROLE_PAYMENT_ADMIN" | "ROLE_PAYMENT_CONFIG_ADMIN" | "ROLE_COURIER" | "ROLE_CUSTOMER" | "ROLE_MANAGER" | "ROLE_SUPER_ADMIN" | "ROLE_KITCHEN" | "ROLE_USER")[] | undefined;
|
|
86
|
+
}>;
|
|
87
|
+
type UsersQueryParams = z.infer<typeof usersQuerySchema>;
|
|
62
88
|
|
|
63
89
|
declare const createUserInputSchema: z.ZodObject<{
|
|
64
90
|
firstName: z.ZodString;
|
|
@@ -79,7 +105,7 @@ declare const createUserInputSchema: z.ZodObject<{
|
|
|
79
105
|
roles: ("ROLE_CUSTOMER_ACCESS" | "ROLE_BUNDLE_ACCESS" | "ROLE_DELIVERY_ACCESS" | "ROLE_POINT_OF_SALE_ACCESS" | "ROLE_MENU_ACCESS" | "ROLE_INTEGRATION_ACCESS" | "ROLE_ORDER_ACCESS" | "ROLE_LEAD_ACCESS" | "ROLE_COMPANY_ACCESS" | "ROLE_USER_ACCESS" | "ROLE_SUBSCRIPTION_ACCESS" | "ROLE_PAYMENT_ACCESS" | "ROLE_PAYMENT_CONFIG_ACCESS" | "ROLE_CUSTOMER_ADMIN" | "ROLE_BUNDLE_ADMIN" | "ROLE_DELIVERY_ADMIN" | "ROLE_POINT_OF_SALE_ADMIN" | "ROLE_MENU_ADMIN" | "ROLE_INTEGRATION_ADMIN" | "ROLE_ORDER_ADMIN" | "ROLE_LEAD_ADMIN" | "ROLE_COMPANY_ADMIN" | "ROLE_USER_ADMIN" | "ROLE_SUBSCRIPTION_ADMIN" | "ROLE_PAYMENT_ADMIN" | "ROLE_PAYMENT_CONFIG_ADMIN" | "ROLE_COURIER" | "ROLE_CUSTOMER" | "ROLE_MANAGER" | "ROLE_SUPER_ADMIN" | "ROLE_KITCHEN" | "ROLE_USER")[];
|
|
80
106
|
plainPassword: string;
|
|
81
107
|
}>;
|
|
82
|
-
type CreateUserInput = z.
|
|
108
|
+
type CreateUserInput = z.input<typeof createUserInputSchema>;
|
|
83
109
|
declare const createUserResponseSchema: z.ZodObject<{
|
|
84
110
|
id: z.ZodString;
|
|
85
111
|
firstName: z.ZodString;
|
|
@@ -114,8 +140,8 @@ declare const createUserResponseSchema: z.ZodObject<{
|
|
|
114
140
|
createdAt: string;
|
|
115
141
|
updatedAt: string;
|
|
116
142
|
}>;
|
|
117
|
-
type CreateUserResponse =
|
|
118
|
-
declare class CreateUser extends AbstractApiRequest<
|
|
143
|
+
type CreateUserResponse = z.output<typeof createUserResponseSchema>;
|
|
144
|
+
declare class CreateUser extends AbstractApiRequest<typeof createUserInputSchema, typeof createUserResponseSchema> {
|
|
119
145
|
readonly method = "POST";
|
|
120
146
|
readonly contentType = "application/json";
|
|
121
147
|
readonly accept = "application/json";
|
|
@@ -174,13 +200,13 @@ declare class CreateUser extends AbstractApiRequest<CreateUserInput, CreateUserR
|
|
|
174
200
|
}>;
|
|
175
201
|
readonly querySchema: undefined;
|
|
176
202
|
readonly headersSchema: undefined;
|
|
177
|
-
constructor(input:
|
|
203
|
+
constructor(input: z.input<typeof createUserInputSchema>);
|
|
178
204
|
getPath(): string;
|
|
179
205
|
}
|
|
180
206
|
|
|
181
207
|
declare const deleteUserInputSchema: z.ZodUndefined;
|
|
182
208
|
declare const deleteUserResponseSchema: z.ZodUndefined;
|
|
183
|
-
declare class DeleteUser extends AbstractApiRequest<
|
|
209
|
+
declare class DeleteUser extends AbstractApiRequest<typeof deleteUserInputSchema, typeof deleteUserResponseSchema> {
|
|
184
210
|
readonly method = "DELETE";
|
|
185
211
|
readonly contentType = "application/json";
|
|
186
212
|
readonly accept = "application/json";
|
|
@@ -194,6 +220,7 @@ declare class DeleteUser extends AbstractApiRequest<void, void> {
|
|
|
194
220
|
}
|
|
195
221
|
|
|
196
222
|
declare const getMeInputSchema: z.ZodUndefined;
|
|
223
|
+
type GetMeInput = z.input<typeof getMeInputSchema>;
|
|
197
224
|
declare const getMeResponseSchema: z.ZodObject<{
|
|
198
225
|
id: z.ZodString;
|
|
199
226
|
firstName: z.ZodString;
|
|
@@ -228,8 +255,8 @@ declare const getMeResponseSchema: z.ZodObject<{
|
|
|
228
255
|
createdAt: string;
|
|
229
256
|
updatedAt: string;
|
|
230
257
|
}>;
|
|
231
|
-
type GetMeResponse =
|
|
232
|
-
declare class GetMe extends AbstractApiRequest<
|
|
258
|
+
type GetMeResponse = z.output<typeof getMeResponseSchema>;
|
|
259
|
+
declare class GetMe extends AbstractApiRequest<typeof getMeInputSchema, typeof getMeResponseSchema> {
|
|
233
260
|
readonly method = "GET";
|
|
234
261
|
readonly contentType = "application/json";
|
|
235
262
|
readonly accept = "application/json";
|
|
@@ -275,6 +302,7 @@ declare class GetMe extends AbstractApiRequest<void, GetMeResponse> {
|
|
|
275
302
|
}
|
|
276
303
|
|
|
277
304
|
declare const getUserDetailsInputSchema: z.ZodUndefined;
|
|
305
|
+
type GetUserDetailsInput = z.input<typeof getUserDetailsInputSchema>;
|
|
278
306
|
declare const getUserDetailsResponseSchema: z.ZodObject<{
|
|
279
307
|
id: z.ZodString;
|
|
280
308
|
firstName: z.ZodString;
|
|
@@ -309,8 +337,8 @@ declare const getUserDetailsResponseSchema: z.ZodObject<{
|
|
|
309
337
|
createdAt: string;
|
|
310
338
|
updatedAt: string;
|
|
311
339
|
}>;
|
|
312
|
-
type GetUserDetailsResponse =
|
|
313
|
-
declare class GetUserDetails extends AbstractApiRequest<
|
|
340
|
+
type GetUserDetailsResponse = z.infer<typeof getUserDetailsResponseSchema>;
|
|
341
|
+
declare class GetUserDetails extends AbstractApiRequest<typeof getUserDetailsInputSchema, typeof getUserDetailsResponseSchema> {
|
|
314
342
|
readonly method = "GET";
|
|
315
343
|
readonly contentType = "application/json";
|
|
316
344
|
readonly accept = "application/json";
|
|
@@ -382,6 +410,8 @@ declare const getUsersQuerySchema: z.ZodObject<{
|
|
|
382
410
|
'roles[]'?: ("ROLE_CUSTOMER_ACCESS" | "ROLE_BUNDLE_ACCESS" | "ROLE_DELIVERY_ACCESS" | "ROLE_POINT_OF_SALE_ACCESS" | "ROLE_MENU_ACCESS" | "ROLE_INTEGRATION_ACCESS" | "ROLE_ORDER_ACCESS" | "ROLE_LEAD_ACCESS" | "ROLE_COMPANY_ACCESS" | "ROLE_USER_ACCESS" | "ROLE_SUBSCRIPTION_ACCESS" | "ROLE_PAYMENT_ACCESS" | "ROLE_PAYMENT_CONFIG_ACCESS" | "ROLE_CUSTOMER_ADMIN" | "ROLE_BUNDLE_ADMIN" | "ROLE_DELIVERY_ADMIN" | "ROLE_POINT_OF_SALE_ADMIN" | "ROLE_MENU_ADMIN" | "ROLE_INTEGRATION_ADMIN" | "ROLE_ORDER_ADMIN" | "ROLE_LEAD_ADMIN" | "ROLE_COMPANY_ADMIN" | "ROLE_USER_ADMIN" | "ROLE_SUBSCRIPTION_ADMIN" | "ROLE_PAYMENT_ADMIN" | "ROLE_PAYMENT_CONFIG_ADMIN" | "ROLE_COURIER" | "ROLE_CUSTOMER" | "ROLE_MANAGER" | "ROLE_SUPER_ADMIN" | "ROLE_KITCHEN" | "ROLE_USER")[] | undefined;
|
|
383
411
|
}>;
|
|
384
412
|
type GetUsersQueryParams = z.infer<typeof getUsersQuerySchema>;
|
|
413
|
+
declare const getUsersInputSchema: z.ZodUndefined;
|
|
414
|
+
type GetUsersInput = z.input<typeof getUsersInputSchema>;
|
|
385
415
|
declare const getUsersResponseSchema: z.ZodObject<{
|
|
386
416
|
data: z.ZodArray<z.ZodObject<{
|
|
387
417
|
id: z.ZodString;
|
|
@@ -483,8 +513,7 @@ declare const getUsersResponseSchema: z.ZodObject<{
|
|
|
483
513
|
};
|
|
484
514
|
}>;
|
|
485
515
|
type GetUsersResponse = z.infer<typeof getUsersResponseSchema>;
|
|
486
|
-
declare
|
|
487
|
-
declare class GetUsers extends AbstractApiRequest<void, GetUsersResponse, GetUsersQueryParams> {
|
|
516
|
+
declare class GetUsers extends AbstractApiRequest<typeof getUsersInputSchema, typeof getUsersResponseSchema, GetUsersQueryParams> {
|
|
488
517
|
readonly method = "GET";
|
|
489
518
|
readonly contentType = "application/json";
|
|
490
519
|
readonly accept = "application/json";
|
|
@@ -622,13 +651,13 @@ declare class GetUsers extends AbstractApiRequest<void, GetUsersResponse, GetUse
|
|
|
622
651
|
parseResponse(data: unknown, rawResponse: AxiosResponse): Paginated<User>;
|
|
623
652
|
}
|
|
624
653
|
|
|
625
|
-
declare const updateUserInputSchema:
|
|
626
|
-
firstName:
|
|
627
|
-
lastName:
|
|
628
|
-
email:
|
|
629
|
-
roles:
|
|
630
|
-
plainPassword:
|
|
631
|
-
}, "strip",
|
|
654
|
+
declare const updateUserInputSchema: z.ZodObject<{
|
|
655
|
+
firstName: z.ZodOptional<z.ZodString>;
|
|
656
|
+
lastName: z.ZodOptional<z.ZodString>;
|
|
657
|
+
email: z.ZodOptional<z.ZodString>;
|
|
658
|
+
roles: z.ZodOptional<z.ZodArray<z.ZodEnum<["ROLE_CUSTOMER_ACCESS", "ROLE_BUNDLE_ACCESS", "ROLE_DELIVERY_ACCESS", "ROLE_POINT_OF_SALE_ACCESS", "ROLE_MENU_ACCESS", "ROLE_INTEGRATION_ACCESS", "ROLE_ORDER_ACCESS", "ROLE_LEAD_ACCESS", "ROLE_COMPANY_ACCESS", "ROLE_USER_ACCESS", "ROLE_SUBSCRIPTION_ACCESS", "ROLE_PAYMENT_ACCESS", "ROLE_PAYMENT_CONFIG_ACCESS", "ROLE_CUSTOMER_ADMIN", "ROLE_BUNDLE_ADMIN", "ROLE_DELIVERY_ADMIN", "ROLE_POINT_OF_SALE_ADMIN", "ROLE_MENU_ADMIN", "ROLE_INTEGRATION_ADMIN", "ROLE_ORDER_ADMIN", "ROLE_LEAD_ADMIN", "ROLE_COMPANY_ADMIN", "ROLE_USER_ADMIN", "ROLE_SUBSCRIPTION_ADMIN", "ROLE_PAYMENT_ADMIN", "ROLE_PAYMENT_CONFIG_ADMIN", "ROLE_COURIER", "ROLE_CUSTOMER", "ROLE_MANAGER", "ROLE_SUPER_ADMIN", "ROLE_KITCHEN", "ROLE_USER"]>, "many">>;
|
|
659
|
+
plainPassword: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
660
|
+
}, "strip", z.ZodTypeAny, {
|
|
632
661
|
firstName?: string | undefined;
|
|
633
662
|
lastName?: string | undefined;
|
|
634
663
|
email?: string | undefined;
|
|
@@ -641,19 +670,19 @@ declare const updateUserInputSchema: zod.ZodObject<{
|
|
|
641
670
|
roles?: ("ROLE_CUSTOMER_ACCESS" | "ROLE_BUNDLE_ACCESS" | "ROLE_DELIVERY_ACCESS" | "ROLE_POINT_OF_SALE_ACCESS" | "ROLE_MENU_ACCESS" | "ROLE_INTEGRATION_ACCESS" | "ROLE_ORDER_ACCESS" | "ROLE_LEAD_ACCESS" | "ROLE_COMPANY_ACCESS" | "ROLE_USER_ACCESS" | "ROLE_SUBSCRIPTION_ACCESS" | "ROLE_PAYMENT_ACCESS" | "ROLE_PAYMENT_CONFIG_ACCESS" | "ROLE_CUSTOMER_ADMIN" | "ROLE_BUNDLE_ADMIN" | "ROLE_DELIVERY_ADMIN" | "ROLE_POINT_OF_SALE_ADMIN" | "ROLE_MENU_ADMIN" | "ROLE_INTEGRATION_ADMIN" | "ROLE_ORDER_ADMIN" | "ROLE_LEAD_ADMIN" | "ROLE_COMPANY_ADMIN" | "ROLE_USER_ADMIN" | "ROLE_SUBSCRIPTION_ADMIN" | "ROLE_PAYMENT_ADMIN" | "ROLE_PAYMENT_CONFIG_ADMIN" | "ROLE_COURIER" | "ROLE_CUSTOMER" | "ROLE_MANAGER" | "ROLE_SUPER_ADMIN" | "ROLE_KITCHEN" | "ROLE_USER")[] | undefined;
|
|
642
671
|
plainPassword?: string | undefined;
|
|
643
672
|
}>;
|
|
644
|
-
type UpdateUserInput =
|
|
645
|
-
declare const updateUserResponseSchema:
|
|
646
|
-
id:
|
|
647
|
-
firstName:
|
|
648
|
-
lastName:
|
|
649
|
-
email:
|
|
650
|
-
roles:
|
|
651
|
-
completedSteps:
|
|
652
|
-
emailVerified:
|
|
653
|
-
suspended:
|
|
654
|
-
createdAt:
|
|
655
|
-
updatedAt:
|
|
656
|
-
}, "strip",
|
|
673
|
+
type UpdateUserInput = z.input<typeof updateUserInputSchema>;
|
|
674
|
+
declare const updateUserResponseSchema: z.ZodObject<{
|
|
675
|
+
id: z.ZodString;
|
|
676
|
+
firstName: z.ZodString;
|
|
677
|
+
lastName: z.ZodString;
|
|
678
|
+
email: z.ZodString;
|
|
679
|
+
roles: z.ZodArray<z.ZodEnum<["ROLE_CUSTOMER_ACCESS", "ROLE_BUNDLE_ACCESS", "ROLE_DELIVERY_ACCESS", "ROLE_POINT_OF_SALE_ACCESS", "ROLE_MENU_ACCESS", "ROLE_INTEGRATION_ACCESS", "ROLE_ORDER_ACCESS", "ROLE_LEAD_ACCESS", "ROLE_COMPANY_ACCESS", "ROLE_USER_ACCESS", "ROLE_SUBSCRIPTION_ACCESS", "ROLE_PAYMENT_ACCESS", "ROLE_PAYMENT_CONFIG_ACCESS", "ROLE_CUSTOMER_ADMIN", "ROLE_BUNDLE_ADMIN", "ROLE_DELIVERY_ADMIN", "ROLE_POINT_OF_SALE_ADMIN", "ROLE_MENU_ADMIN", "ROLE_INTEGRATION_ADMIN", "ROLE_ORDER_ADMIN", "ROLE_LEAD_ADMIN", "ROLE_COMPANY_ADMIN", "ROLE_USER_ADMIN", "ROLE_SUBSCRIPTION_ADMIN", "ROLE_PAYMENT_ADMIN", "ROLE_PAYMENT_CONFIG_ADMIN", "ROLE_COURIER", "ROLE_CUSTOMER", "ROLE_MANAGER", "ROLE_SUPER_ADMIN", "ROLE_KITCHEN", "ROLE_USER"]>, "many">;
|
|
680
|
+
completedSteps: z.ZodArray<z.ZodEnum<["registration", "verify_email", "create_company", "create_point_of_sale"]>, "many">;
|
|
681
|
+
emailVerified: z.ZodBoolean;
|
|
682
|
+
suspended: z.ZodBoolean;
|
|
683
|
+
createdAt: z.ZodEffects<z.ZodString, string, string>;
|
|
684
|
+
updatedAt: z.ZodEffects<z.ZodString, string, string>;
|
|
685
|
+
}, "strip", z.ZodTypeAny, {
|
|
657
686
|
id: string;
|
|
658
687
|
firstName: string;
|
|
659
688
|
lastName: string;
|
|
@@ -676,18 +705,18 @@ declare const updateUserResponseSchema: zod.ZodObject<{
|
|
|
676
705
|
createdAt: string;
|
|
677
706
|
updatedAt: string;
|
|
678
707
|
}>;
|
|
679
|
-
type UpdateUserResponse =
|
|
680
|
-
declare class UpdateUser extends AbstractApiRequest<
|
|
708
|
+
type UpdateUserResponse = z.infer<typeof updateUserResponseSchema>;
|
|
709
|
+
declare class UpdateUser extends AbstractApiRequest<typeof updateUserInputSchema, typeof updateUserResponseSchema> {
|
|
681
710
|
readonly method = "PATCH";
|
|
682
711
|
readonly contentType = "application/merge-patch+json";
|
|
683
712
|
readonly accept = "application/json";
|
|
684
|
-
readonly inputSchema:
|
|
685
|
-
firstName:
|
|
686
|
-
lastName:
|
|
687
|
-
email:
|
|
688
|
-
roles:
|
|
689
|
-
plainPassword:
|
|
690
|
-
}, "strip",
|
|
713
|
+
readonly inputSchema: z.ZodObject<{
|
|
714
|
+
firstName: z.ZodOptional<z.ZodString>;
|
|
715
|
+
lastName: z.ZodOptional<z.ZodString>;
|
|
716
|
+
email: z.ZodOptional<z.ZodString>;
|
|
717
|
+
roles: z.ZodOptional<z.ZodArray<z.ZodEnum<["ROLE_CUSTOMER_ACCESS", "ROLE_BUNDLE_ACCESS", "ROLE_DELIVERY_ACCESS", "ROLE_POINT_OF_SALE_ACCESS", "ROLE_MENU_ACCESS", "ROLE_INTEGRATION_ACCESS", "ROLE_ORDER_ACCESS", "ROLE_LEAD_ACCESS", "ROLE_COMPANY_ACCESS", "ROLE_USER_ACCESS", "ROLE_SUBSCRIPTION_ACCESS", "ROLE_PAYMENT_ACCESS", "ROLE_PAYMENT_CONFIG_ACCESS", "ROLE_CUSTOMER_ADMIN", "ROLE_BUNDLE_ADMIN", "ROLE_DELIVERY_ADMIN", "ROLE_POINT_OF_SALE_ADMIN", "ROLE_MENU_ADMIN", "ROLE_INTEGRATION_ADMIN", "ROLE_ORDER_ADMIN", "ROLE_LEAD_ADMIN", "ROLE_COMPANY_ADMIN", "ROLE_USER_ADMIN", "ROLE_SUBSCRIPTION_ADMIN", "ROLE_PAYMENT_ADMIN", "ROLE_PAYMENT_CONFIG_ADMIN", "ROLE_COURIER", "ROLE_CUSTOMER", "ROLE_MANAGER", "ROLE_SUPER_ADMIN", "ROLE_KITCHEN", "ROLE_USER"]>, "many">>;
|
|
718
|
+
plainPassword: z.ZodOptional<z.ZodOptional<z.ZodString>>;
|
|
719
|
+
}, "strip", z.ZodTypeAny, {
|
|
691
720
|
firstName?: string | undefined;
|
|
692
721
|
lastName?: string | undefined;
|
|
693
722
|
email?: string | undefined;
|
|
@@ -700,18 +729,18 @@ declare class UpdateUser extends AbstractApiRequest<UpdateUserInput, UpdateUserR
|
|
|
700
729
|
roles?: ("ROLE_CUSTOMER_ACCESS" | "ROLE_BUNDLE_ACCESS" | "ROLE_DELIVERY_ACCESS" | "ROLE_POINT_OF_SALE_ACCESS" | "ROLE_MENU_ACCESS" | "ROLE_INTEGRATION_ACCESS" | "ROLE_ORDER_ACCESS" | "ROLE_LEAD_ACCESS" | "ROLE_COMPANY_ACCESS" | "ROLE_USER_ACCESS" | "ROLE_SUBSCRIPTION_ACCESS" | "ROLE_PAYMENT_ACCESS" | "ROLE_PAYMENT_CONFIG_ACCESS" | "ROLE_CUSTOMER_ADMIN" | "ROLE_BUNDLE_ADMIN" | "ROLE_DELIVERY_ADMIN" | "ROLE_POINT_OF_SALE_ADMIN" | "ROLE_MENU_ADMIN" | "ROLE_INTEGRATION_ADMIN" | "ROLE_ORDER_ADMIN" | "ROLE_LEAD_ADMIN" | "ROLE_COMPANY_ADMIN" | "ROLE_USER_ADMIN" | "ROLE_SUBSCRIPTION_ADMIN" | "ROLE_PAYMENT_ADMIN" | "ROLE_PAYMENT_CONFIG_ADMIN" | "ROLE_COURIER" | "ROLE_CUSTOMER" | "ROLE_MANAGER" | "ROLE_SUPER_ADMIN" | "ROLE_KITCHEN" | "ROLE_USER")[] | undefined;
|
|
701
730
|
plainPassword?: string | undefined;
|
|
702
731
|
}>;
|
|
703
|
-
readonly outputSchema:
|
|
704
|
-
id:
|
|
705
|
-
firstName:
|
|
706
|
-
lastName:
|
|
707
|
-
email:
|
|
708
|
-
roles:
|
|
709
|
-
completedSteps:
|
|
710
|
-
emailVerified:
|
|
711
|
-
suspended:
|
|
712
|
-
createdAt:
|
|
713
|
-
updatedAt:
|
|
714
|
-
}, "strip",
|
|
732
|
+
readonly outputSchema: z.ZodObject<{
|
|
733
|
+
id: z.ZodString;
|
|
734
|
+
firstName: z.ZodString;
|
|
735
|
+
lastName: z.ZodString;
|
|
736
|
+
email: z.ZodString;
|
|
737
|
+
roles: z.ZodArray<z.ZodEnum<["ROLE_CUSTOMER_ACCESS", "ROLE_BUNDLE_ACCESS", "ROLE_DELIVERY_ACCESS", "ROLE_POINT_OF_SALE_ACCESS", "ROLE_MENU_ACCESS", "ROLE_INTEGRATION_ACCESS", "ROLE_ORDER_ACCESS", "ROLE_LEAD_ACCESS", "ROLE_COMPANY_ACCESS", "ROLE_USER_ACCESS", "ROLE_SUBSCRIPTION_ACCESS", "ROLE_PAYMENT_ACCESS", "ROLE_PAYMENT_CONFIG_ACCESS", "ROLE_CUSTOMER_ADMIN", "ROLE_BUNDLE_ADMIN", "ROLE_DELIVERY_ADMIN", "ROLE_POINT_OF_SALE_ADMIN", "ROLE_MENU_ADMIN", "ROLE_INTEGRATION_ADMIN", "ROLE_ORDER_ADMIN", "ROLE_LEAD_ADMIN", "ROLE_COMPANY_ADMIN", "ROLE_USER_ADMIN", "ROLE_SUBSCRIPTION_ADMIN", "ROLE_PAYMENT_ADMIN", "ROLE_PAYMENT_CONFIG_ADMIN", "ROLE_COURIER", "ROLE_CUSTOMER", "ROLE_MANAGER", "ROLE_SUPER_ADMIN", "ROLE_KITCHEN", "ROLE_USER"]>, "many">;
|
|
738
|
+
completedSteps: z.ZodArray<z.ZodEnum<["registration", "verify_email", "create_company", "create_point_of_sale"]>, "many">;
|
|
739
|
+
emailVerified: z.ZodBoolean;
|
|
740
|
+
suspended: z.ZodBoolean;
|
|
741
|
+
createdAt: z.ZodEffects<z.ZodString, string, string>;
|
|
742
|
+
updatedAt: z.ZodEffects<z.ZodString, string, string>;
|
|
743
|
+
}, "strip", z.ZodTypeAny, {
|
|
715
744
|
id: string;
|
|
716
745
|
firstName: string;
|
|
717
746
|
lastName: string;
|
|
@@ -737,7 +766,7 @@ declare class UpdateUser extends AbstractApiRequest<UpdateUserInput, UpdateUserR
|
|
|
737
766
|
readonly querySchema: undefined;
|
|
738
767
|
readonly headersSchema: undefined;
|
|
739
768
|
private readonly userId;
|
|
740
|
-
constructor(userId: string, input:
|
|
769
|
+
constructor(userId: string, input: z.input<typeof updateUserInputSchema>);
|
|
741
770
|
getPath(): string;
|
|
742
771
|
}
|
|
743
772
|
|
|
@@ -747,9 +776,7 @@ type SecurityRole = z.infer<typeof securityRoleSchema>;
|
|
|
747
776
|
declare const userSteps: readonly ["registration", "verify_email", "create_company", "create_point_of_sale"];
|
|
748
777
|
declare const userStepSchema: z.ZodEnum<["registration", "verify_email", "create_company", "create_point_of_sale"]>;
|
|
749
778
|
type UserStep = z.infer<typeof userStepSchema>;
|
|
750
|
-
declare const
|
|
751
|
-
type
|
|
752
|
-
declare const userNullablePathSchema: z.ZodEffects<z.ZodNullable<z.ZodString>, string | null, string | null>;
|
|
753
|
-
type UserNullablePath = z.infer<typeof userNullablePathSchema>;
|
|
779
|
+
declare const userIriSchema: z.ZodEffects<z.ZodString, _deliverart_sdk_js_global_types.IriObject<"/users/:id">, string>;
|
|
780
|
+
type UserIri = z.infer<typeof userIriSchema>;
|
|
754
781
|
|
|
755
|
-
export { CreateUser, type CreateUserInput, type CreateUserResponse, DeleteUser, GetMe, type GetMeResponse, GetUserDetails, type GetUserDetailsResponse, GetUsers, type GetUsersQueryParams, type GetUsersResponse, type SecurityRole, UpdateUser, type UpdateUserInput, type UpdateUserResponse, type User, type
|
|
782
|
+
export { CreateUser, type CreateUserInput, type CreateUserResponse, DeleteUser, GetMe, type GetMeInput, type GetMeResponse, GetUserDetails, type GetUserDetailsInput, type GetUserDetailsResponse, GetUsers, type GetUsersInput, type GetUsersQueryParams, type GetUsersResponse, type SecurityRole, UpdateUser, type UpdateUserInput, type UpdateUserResponse, type User, type UserIri, type UserStep, type UsersQueryParams, type WritableUser, createUserInputSchema, createUserResponseSchema, deleteUserInputSchema, deleteUserResponseSchema, getMeInputSchema, getMeResponseSchema, getUserDetailsInputSchema, getUserDetailsResponseSchema, getUsersInputSchema, getUsersQuerySchema, getUsersResponseSchema, securityRoleSchema, securityRoles, updateUserInputSchema, updateUserResponseSchema, userIriSchema, userSchema, userStepSchema, userSteps, usersQuerySchema, writableUserSchema };
|
package/dist/index.js
CHANGED
|
@@ -3,6 +3,7 @@ import { datetimeSchema } from "@deliverart/sdk-js-global-types";
|
|
|
3
3
|
import { z as z2 } from "zod";
|
|
4
4
|
|
|
5
5
|
// src/types.ts
|
|
6
|
+
import { iriSchema } from "@deliverart/sdk-js-global-types";
|
|
6
7
|
import { z } from "zod";
|
|
7
8
|
var securityRoles = [
|
|
8
9
|
// Role used for describe single operations
|
|
@@ -50,18 +51,7 @@ var userSteps = [
|
|
|
50
51
|
"create_point_of_sale"
|
|
51
52
|
];
|
|
52
53
|
var userStepSchema = z.enum(userSteps);
|
|
53
|
-
var
|
|
54
|
-
message: "Invalid user path format"
|
|
55
|
-
});
|
|
56
|
-
var userNullablePathSchema = z.string().nullable().refine(
|
|
57
|
-
(val) => {
|
|
58
|
-
if (!val) return true;
|
|
59
|
-
return /^\/users\/[a-z_]+\/[0-9a-fA-F-]{36}$/.test(val);
|
|
60
|
-
},
|
|
61
|
-
{
|
|
62
|
-
message: "Invalid user path format"
|
|
63
|
-
}
|
|
64
|
-
);
|
|
54
|
+
var userIriSchema = iriSchema("/users/:id");
|
|
65
55
|
|
|
66
56
|
// src/models.ts
|
|
67
57
|
var userSchema = z2.object({
|
|
@@ -84,6 +74,15 @@ var writableUserSchema = userSchema.pick({
|
|
|
84
74
|
}).extend({
|
|
85
75
|
plainPassword: z2.string().optional()
|
|
86
76
|
}).partial();
|
|
77
|
+
var usersQuerySchema = z2.object({
|
|
78
|
+
email: z2.string().optional(),
|
|
79
|
+
firstName: z2.string().optional(),
|
|
80
|
+
lastName: z2.string().optional(),
|
|
81
|
+
suspended: z2.string().optional(),
|
|
82
|
+
"order[createdAt]": z2.enum(["asc", "desc"]).optional(),
|
|
83
|
+
page: z2.coerce.number().optional(),
|
|
84
|
+
"roles[]": z2.array(z2.enum(securityRoles)).optional()
|
|
85
|
+
});
|
|
87
86
|
|
|
88
87
|
// src/requests/CreateUser.ts
|
|
89
88
|
import { AbstractApiRequest } from "@deliverart/sdk-js-core";
|
|
@@ -120,7 +119,7 @@ var DeleteUser = class extends AbstractApiRequest2 {
|
|
|
120
119
|
headersSchema = void 0;
|
|
121
120
|
userId;
|
|
122
121
|
constructor(userId) {
|
|
123
|
-
super();
|
|
122
|
+
super(void 0);
|
|
124
123
|
this.userId = userId;
|
|
125
124
|
}
|
|
126
125
|
getPath() {
|
|
@@ -142,7 +141,7 @@ var GetMe = class extends AbstractApiRequest3 {
|
|
|
142
141
|
querySchema = void 0;
|
|
143
142
|
headersSchema = void 0;
|
|
144
143
|
constructor() {
|
|
145
|
-
super();
|
|
144
|
+
super(void 0);
|
|
146
145
|
}
|
|
147
146
|
getPath() {
|
|
148
147
|
return "/me";
|
|
@@ -164,7 +163,7 @@ var GetUserDetails = class extends AbstractApiRequest4 {
|
|
|
164
163
|
headersSchema = void 0;
|
|
165
164
|
userId;
|
|
166
165
|
constructor(userId) {
|
|
167
|
-
super();
|
|
166
|
+
super(void 0);
|
|
168
167
|
this.userId = userId;
|
|
169
168
|
}
|
|
170
169
|
getPath() {
|
|
@@ -179,17 +178,9 @@ import {
|
|
|
179
178
|
responseToPagination
|
|
180
179
|
} from "@deliverart/sdk-js-global-types";
|
|
181
180
|
import { z as z6 } from "zod";
|
|
182
|
-
var getUsersQuerySchema =
|
|
183
|
-
email: z6.string().optional(),
|
|
184
|
-
firstName: z6.string().optional(),
|
|
185
|
-
lastName: z6.string().optional(),
|
|
186
|
-
suspended: z6.string().optional(),
|
|
187
|
-
"order[createdAt]": z6.enum(["asc", "desc"]).optional(),
|
|
188
|
-
page: z6.coerce.number().optional(),
|
|
189
|
-
"roles[]": z6.array(z6.enum(securityRoles)).optional()
|
|
190
|
-
});
|
|
191
|
-
var getUsersResponseSchema = createPaginatedSchema(userSchema);
|
|
181
|
+
var getUsersQuerySchema = usersQuerySchema;
|
|
192
182
|
var getUsersInputSchema = z6.undefined();
|
|
183
|
+
var getUsersResponseSchema = createPaginatedSchema(userSchema);
|
|
193
184
|
var GetUsers = class extends AbstractApiRequest5 {
|
|
194
185
|
method = "GET";
|
|
195
186
|
contentType = "application/json";
|
|
@@ -253,10 +244,10 @@ export {
|
|
|
253
244
|
securityRoles,
|
|
254
245
|
updateUserInputSchema,
|
|
255
246
|
updateUserResponseSchema,
|
|
256
|
-
|
|
257
|
-
userPathSchema,
|
|
247
|
+
userIriSchema,
|
|
258
248
|
userSchema,
|
|
259
249
|
userStepSchema,
|
|
260
250
|
userSteps,
|
|
251
|
+
usersQuerySchema,
|
|
261
252
|
writableUserSchema
|
|
262
253
|
};
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@deliverart/sdk-js-user",
|
|
3
3
|
"description": "Deliverart JavaScript SDK for User Management",
|
|
4
|
-
"version": "0.
|
|
4
|
+
"version": "0.3.0",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"main": "dist/index.js",
|
|
7
7
|
"types": "dist/index.d.ts",
|
|
@@ -14,8 +14,8 @@
|
|
|
14
14
|
"dependencies": {
|
|
15
15
|
"zod": "3.25.67",
|
|
16
16
|
"axios": "1.9.0",
|
|
17
|
-
"@deliverart/sdk-js-core": "0.
|
|
18
|
-
"@deliverart/sdk-js-global-types": "0.0.
|
|
17
|
+
"@deliverart/sdk-js-core": "0.2.0",
|
|
18
|
+
"@deliverart/sdk-js-global-types": "0.0.17"
|
|
19
19
|
},
|
|
20
20
|
"devDependencies": {
|
|
21
21
|
"@changesets/cli": "^2.29.4",
|
package/src/models.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { datetimeSchema } from '@deliverart/sdk-js-global-types'
|
|
2
2
|
import { z } from 'zod'
|
|
3
3
|
|
|
4
|
-
import { securityRoleSchema, userStepSchema } from './types'
|
|
4
|
+
import { securityRoles, securityRoleSchema, userStepSchema } from './types'
|
|
5
5
|
|
|
6
6
|
export const userSchema = z.object({
|
|
7
7
|
id: z.string(),
|
|
@@ -29,3 +29,14 @@ export const writableUserSchema = userSchema
|
|
|
29
29
|
})
|
|
30
30
|
.partial()
|
|
31
31
|
export type WritableUser = z.infer<typeof writableUserSchema>
|
|
32
|
+
|
|
33
|
+
export const usersQuerySchema = z.object({
|
|
34
|
+
email: z.string().optional(),
|
|
35
|
+
firstName: z.string().optional(),
|
|
36
|
+
lastName: z.string().optional(),
|
|
37
|
+
suspended: z.string().optional(),
|
|
38
|
+
'order[createdAt]': z.enum(['asc', 'desc']).optional(),
|
|
39
|
+
page: z.coerce.number().optional(),
|
|
40
|
+
'roles[]': z.array(z.enum(securityRoles)).optional(),
|
|
41
|
+
})
|
|
42
|
+
export type UsersQueryParams = z.infer<typeof usersQuerySchema>
|
|
@@ -1,15 +1,18 @@
|
|
|
1
1
|
import { AbstractApiRequest } from '@deliverart/sdk-js-core'
|
|
2
2
|
import { z } from 'zod'
|
|
3
3
|
|
|
4
|
-
import {
|
|
4
|
+
import { userSchema, writableUserSchema } from '../models'
|
|
5
5
|
|
|
6
6
|
export const createUserInputSchema = writableUserSchema.required()
|
|
7
|
-
export type CreateUserInput = z.
|
|
7
|
+
export type CreateUserInput = z.input<typeof createUserInputSchema>
|
|
8
8
|
|
|
9
9
|
export const createUserResponseSchema = userSchema
|
|
10
|
-
export type CreateUserResponse =
|
|
10
|
+
export type CreateUserResponse = z.output<typeof createUserResponseSchema>
|
|
11
11
|
|
|
12
|
-
export class CreateUser extends AbstractApiRequest<
|
|
12
|
+
export class CreateUser extends AbstractApiRequest<
|
|
13
|
+
typeof createUserInputSchema,
|
|
14
|
+
typeof createUserResponseSchema
|
|
15
|
+
> {
|
|
13
16
|
readonly method = 'POST'
|
|
14
17
|
readonly contentType = 'application/json'
|
|
15
18
|
readonly accept = 'application/json'
|
|
@@ -19,7 +22,7 @@ export class CreateUser extends AbstractApiRequest<CreateUserInput, CreateUserRe
|
|
|
19
22
|
readonly querySchema = undefined
|
|
20
23
|
readonly headersSchema = undefined
|
|
21
24
|
|
|
22
|
-
constructor(input:
|
|
25
|
+
constructor(input: z.input<typeof createUserInputSchema>) {
|
|
23
26
|
super(input)
|
|
24
27
|
}
|
|
25
28
|
|
|
@@ -4,7 +4,10 @@ import { z } from 'zod'
|
|
|
4
4
|
export const deleteUserInputSchema = z.undefined()
|
|
5
5
|
export const deleteUserResponseSchema = z.undefined()
|
|
6
6
|
|
|
7
|
-
export class DeleteUser extends AbstractApiRequest<
|
|
7
|
+
export class DeleteUser extends AbstractApiRequest<
|
|
8
|
+
typeof deleteUserInputSchema,
|
|
9
|
+
typeof deleteUserResponseSchema
|
|
10
|
+
> {
|
|
8
11
|
readonly method = 'DELETE'
|
|
9
12
|
readonly contentType = 'application/json'
|
|
10
13
|
readonly accept = 'application/json'
|
|
@@ -17,7 +20,7 @@ export class DeleteUser extends AbstractApiRequest<void, void> {
|
|
|
17
20
|
private readonly userId: string
|
|
18
21
|
|
|
19
22
|
constructor(userId: string) {
|
|
20
|
-
super()
|
|
23
|
+
super(undefined)
|
|
21
24
|
this.userId = userId
|
|
22
25
|
}
|
|
23
26
|
|
package/src/requests/GetMe.ts
CHANGED
|
@@ -1,14 +1,15 @@
|
|
|
1
1
|
import { AbstractApiRequest } from '@deliverart/sdk-js-core'
|
|
2
2
|
import { z } from 'zod'
|
|
3
3
|
|
|
4
|
-
import {
|
|
4
|
+
import { userSchema } from '../models'
|
|
5
5
|
|
|
6
6
|
export const getMeInputSchema = z.undefined()
|
|
7
|
+
export type GetMeInput = z.input<typeof getMeInputSchema>
|
|
7
8
|
|
|
8
9
|
export const getMeResponseSchema = userSchema
|
|
9
|
-
export type GetMeResponse =
|
|
10
|
+
export type GetMeResponse = z.output<typeof getMeResponseSchema>
|
|
10
11
|
|
|
11
|
-
export class GetMe extends AbstractApiRequest<
|
|
12
|
+
export class GetMe extends AbstractApiRequest<typeof getMeInputSchema, typeof getMeResponseSchema> {
|
|
12
13
|
readonly method = 'GET'
|
|
13
14
|
readonly contentType = 'application/json'
|
|
14
15
|
readonly accept = 'application/json'
|
|
@@ -18,7 +19,7 @@ export class GetMe extends AbstractApiRequest<void, GetMeResponse> {
|
|
|
18
19
|
readonly headersSchema = undefined
|
|
19
20
|
|
|
20
21
|
constructor() {
|
|
21
|
-
super()
|
|
22
|
+
super(undefined)
|
|
22
23
|
}
|
|
23
24
|
|
|
24
25
|
getPath(): string {
|
|
@@ -1,14 +1,18 @@
|
|
|
1
1
|
import { AbstractApiRequest } from '@deliverart/sdk-js-core'
|
|
2
2
|
import { z } from 'zod'
|
|
3
3
|
|
|
4
|
-
import {
|
|
4
|
+
import { userSchema } from '../models'
|
|
5
5
|
|
|
6
6
|
export const getUserDetailsInputSchema = z.undefined()
|
|
7
|
+
export type GetUserDetailsInput = z.input<typeof getUserDetailsInputSchema>
|
|
7
8
|
|
|
8
9
|
export const getUserDetailsResponseSchema = userSchema
|
|
9
|
-
export type GetUserDetailsResponse =
|
|
10
|
+
export type GetUserDetailsResponse = z.infer<typeof getUserDetailsResponseSchema>
|
|
10
11
|
|
|
11
|
-
export class GetUserDetails extends AbstractApiRequest<
|
|
12
|
+
export class GetUserDetails extends AbstractApiRequest<
|
|
13
|
+
typeof getUserDetailsInputSchema,
|
|
14
|
+
typeof getUserDetailsResponseSchema
|
|
15
|
+
> {
|
|
12
16
|
readonly method = 'GET'
|
|
13
17
|
readonly contentType = 'application/json'
|
|
14
18
|
readonly accept = 'application/json'
|
|
@@ -20,7 +24,7 @@ export class GetUserDetails extends AbstractApiRequest<void, GetUserDetailsRespo
|
|
|
20
24
|
private readonly userId: string
|
|
21
25
|
|
|
22
26
|
constructor(userId: string) {
|
|
23
|
-
super()
|
|
27
|
+
super(undefined)
|
|
24
28
|
this.userId = userId
|
|
25
29
|
}
|
|
26
30
|
|
package/src/requests/GetUsers.ts
CHANGED
|
@@ -7,26 +7,22 @@ import {
|
|
|
7
7
|
import { AxiosResponse } from 'axios'
|
|
8
8
|
import { z } from 'zod'
|
|
9
9
|
|
|
10
|
-
import { User, userSchema } from '../models'
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
export const getUsersQuerySchema = z.object({
|
|
14
|
-
email: z.string().optional(),
|
|
15
|
-
firstName: z.string().optional(),
|
|
16
|
-
lastName: z.string().optional(),
|
|
17
|
-
suspended: z.string().optional(),
|
|
18
|
-
'order[createdAt]': z.enum(['asc', 'desc']).optional(),
|
|
19
|
-
page: z.coerce.number().optional(),
|
|
20
|
-
'roles[]': z.array(z.enum(securityRoles)).optional(),
|
|
21
|
-
})
|
|
10
|
+
import { User, userSchema, usersQuerySchema } from '../models'
|
|
11
|
+
|
|
12
|
+
export const getUsersQuerySchema = usersQuerySchema
|
|
22
13
|
export type GetUsersQueryParams = z.infer<typeof getUsersQuerySchema>
|
|
23
14
|
|
|
15
|
+
export const getUsersInputSchema = z.undefined()
|
|
16
|
+
export type GetUsersInput = z.input<typeof getUsersInputSchema>
|
|
17
|
+
|
|
24
18
|
export const getUsersResponseSchema = createPaginatedSchema(userSchema)
|
|
25
19
|
export type GetUsersResponse = z.infer<typeof getUsersResponseSchema>
|
|
26
20
|
|
|
27
|
-
export
|
|
28
|
-
|
|
29
|
-
|
|
21
|
+
export class GetUsers extends AbstractApiRequest<
|
|
22
|
+
typeof getUsersInputSchema,
|
|
23
|
+
typeof getUsersResponseSchema,
|
|
24
|
+
GetUsersQueryParams
|
|
25
|
+
> {
|
|
30
26
|
readonly method = 'GET'
|
|
31
27
|
readonly contentType = 'application/json'
|
|
32
28
|
readonly accept = 'application/json'
|
|
@@ -1,14 +1,18 @@
|
|
|
1
1
|
import { AbstractApiRequest } from '@deliverart/sdk-js-core'
|
|
2
|
+
import { z } from 'zod'
|
|
2
3
|
|
|
3
|
-
import {
|
|
4
|
+
import { userSchema, writableUserSchema } from '../models'
|
|
4
5
|
|
|
5
6
|
export const updateUserInputSchema = writableUserSchema
|
|
6
|
-
export type UpdateUserInput =
|
|
7
|
+
export type UpdateUserInput = z.input<typeof updateUserInputSchema>
|
|
7
8
|
|
|
8
9
|
export const updateUserResponseSchema = userSchema
|
|
9
|
-
export type UpdateUserResponse =
|
|
10
|
+
export type UpdateUserResponse = z.infer<typeof updateUserResponseSchema>
|
|
10
11
|
|
|
11
|
-
export class UpdateUser extends AbstractApiRequest<
|
|
12
|
+
export class UpdateUser extends AbstractApiRequest<
|
|
13
|
+
typeof updateUserInputSchema,
|
|
14
|
+
typeof updateUserResponseSchema
|
|
15
|
+
> {
|
|
12
16
|
readonly method = 'PATCH'
|
|
13
17
|
readonly contentType = 'application/merge-patch+json'
|
|
14
18
|
readonly accept = 'application/json'
|
|
@@ -20,7 +24,7 @@ export class UpdateUser extends AbstractApiRequest<UpdateUserInput, UpdateUserRe
|
|
|
20
24
|
|
|
21
25
|
private readonly userId: string
|
|
22
26
|
|
|
23
|
-
constructor(userId: string, input:
|
|
27
|
+
constructor(userId: string, input: z.input<typeof updateUserInputSchema>) {
|
|
24
28
|
super(input)
|
|
25
29
|
this.userId = userId
|
|
26
30
|
}
|
package/src/types.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import { iriSchema } from '@deliverart/sdk-js-global-types'
|
|
1
2
|
import { z } from 'zod'
|
|
2
3
|
|
|
3
4
|
export const securityRoles = [
|
|
@@ -50,23 +51,5 @@ export const userSteps = [
|
|
|
50
51
|
export const userStepSchema = z.enum(userSteps)
|
|
51
52
|
export type UserStep = z.infer<typeof userStepSchema>
|
|
52
53
|
|
|
53
|
-
export const
|
|
54
|
-
|
|
55
|
-
.refine(val => /^\/users\/[a-z_]+\/[0-9a-fA-F-]{36}$/.test(val), {
|
|
56
|
-
message: 'Invalid user path format',
|
|
57
|
-
})
|
|
58
|
-
export type UserPath = z.infer<typeof userPathSchema>
|
|
59
|
-
|
|
60
|
-
export const userNullablePathSchema = z
|
|
61
|
-
.string()
|
|
62
|
-
.nullable()
|
|
63
|
-
.refine(
|
|
64
|
-
val => {
|
|
65
|
-
if (!val) return true
|
|
66
|
-
return /^\/users\/[a-z_]+\/[0-9a-fA-F-]{36}$/.test(val)
|
|
67
|
-
},
|
|
68
|
-
{
|
|
69
|
-
message: 'Invalid user path format',
|
|
70
|
-
},
|
|
71
|
-
)
|
|
72
|
-
export type UserNullablePath = z.infer<typeof userNullablePathSchema>
|
|
54
|
+
export const userIriSchema = iriSchema('/users/:id')
|
|
55
|
+
export type UserIri = z.infer<typeof userIriSchema>
|