@awarevue/api-types 1.0.80 → 1.0.82
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/api/query.d.ts +7 -13
- package/dist/api/query.js +1 -1
- package/dist/bookmarks.d.ts +23 -6
- package/dist/bookmarks.js +5 -4
- package/dist/package.json +1 -1
- package/package.json +1 -1
package/dist/api/query.d.ts
CHANGED
|
@@ -8,19 +8,13 @@ export interface PaginatedQueryResponse<T> {
|
|
|
8
8
|
items: T[];
|
|
9
9
|
total: number;
|
|
10
10
|
}
|
|
11
|
-
export declare const sPaginatedQueryRequestOf: <T extends z.AnyZodObject>(criteriaSchema: T) => z.ZodObject<
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
},
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
limit: z.ZodOptional<z.ZodNumber>;
|
|
19
|
-
}, T["shape"]>, T["_def"]["catchall"], T["_def"]["unknownKeys"]>, z.objectInputType<z.objectUtil.extendShape<{
|
|
20
|
-
q: z.ZodOptional<z.ZodString>;
|
|
21
|
-
offset: z.ZodOptional<z.ZodNumber>;
|
|
22
|
-
limit: z.ZodOptional<z.ZodNumber>;
|
|
23
|
-
}, T["shape"]>, T["_def"]["catchall"], T["_def"]["unknownKeys"]>>;
|
|
11
|
+
export declare const sPaginatedQueryRequestOf: <T extends z.AnyZodObject>(criteriaSchema: T) => z.ZodObject<{} & {
|
|
12
|
+
[x: string]: z.ZodOptional<any>;
|
|
13
|
+
}, any, any, {
|
|
14
|
+
[x: string]: any;
|
|
15
|
+
}, {
|
|
16
|
+
[x: string]: any;
|
|
17
|
+
}>;
|
|
24
18
|
export declare const sPaginatedQueryResponseOf: <T extends ZodTypeAny>(itemSchema: T) => z.ZodObject<{
|
|
25
19
|
items: z.ZodArray<T, "many">;
|
|
26
20
|
total: z.ZodNumber;
|
package/dist/api/query.js
CHANGED
|
@@ -14,7 +14,7 @@ const sPaginatedQueryRequestOf = (criteriaSchema) => zod_1.z
|
|
|
14
14
|
.optional()
|
|
15
15
|
.describe('Maximum number of items to return'),
|
|
16
16
|
})
|
|
17
|
-
.merge(criteriaSchema);
|
|
17
|
+
.merge(criteriaSchema.partial());
|
|
18
18
|
exports.sPaginatedQueryRequestOf = sPaginatedQueryRequestOf;
|
|
19
19
|
const sPaginatedQueryResponseOf = (itemSchema) => zod_1.z.object({
|
|
20
20
|
items: zod_1.z.array(itemSchema).describe('Array of items matching the query'),
|
package/dist/bookmarks.d.ts
CHANGED
|
@@ -31,6 +31,22 @@ export declare const sCreateBookmarkRq: z.ZodObject<{
|
|
|
31
31
|
timestamp: number;
|
|
32
32
|
deviceId: string;
|
|
33
33
|
}>;
|
|
34
|
+
export declare const sUpdateBookmarkBody: z.ZodObject<{
|
|
35
|
+
timestamp: z.ZodOptional<z.ZodNumber>;
|
|
36
|
+
label: z.ZodOptional<z.ZodString>;
|
|
37
|
+
deviceId: z.ZodOptional<z.ZodString>;
|
|
38
|
+
metadata: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
39
|
+
}, "strip", z.ZodTypeAny, {
|
|
40
|
+
label?: string | undefined;
|
|
41
|
+
metadata?: Record<string, unknown> | undefined;
|
|
42
|
+
timestamp?: number | undefined;
|
|
43
|
+
deviceId?: string | undefined;
|
|
44
|
+
}, {
|
|
45
|
+
label?: string | undefined;
|
|
46
|
+
metadata?: Record<string, unknown> | undefined;
|
|
47
|
+
timestamp?: number | undefined;
|
|
48
|
+
deviceId?: string | undefined;
|
|
49
|
+
}>;
|
|
34
50
|
export declare const sUpdateBookmarkRq: z.ZodIntersection<z.ZodObject<{
|
|
35
51
|
id: z.ZodString;
|
|
36
52
|
}, "strip", z.ZodTypeAny, {
|
|
@@ -92,24 +108,25 @@ export declare const sBookmarkDto: z.ZodIntersection<z.ZodObject<{
|
|
|
92
108
|
createdBy: string;
|
|
93
109
|
}>>;
|
|
94
110
|
export declare const sBookmarkSearchCriteria: z.ZodObject<{
|
|
95
|
-
deviceId: z.ZodString
|
|
96
|
-
createdBy: z.ZodString
|
|
111
|
+
deviceId: z.ZodArray<z.ZodString, "many">;
|
|
112
|
+
createdBy: z.ZodArray<z.ZodString, "many">;
|
|
97
113
|
timeFrom: z.ZodNumber;
|
|
98
114
|
timeTo: z.ZodNumber;
|
|
99
115
|
}, "strip", z.ZodTypeAny, {
|
|
100
|
-
deviceId: string;
|
|
101
|
-
createdBy: string;
|
|
116
|
+
deviceId: string[];
|
|
117
|
+
createdBy: string[];
|
|
102
118
|
timeFrom: number;
|
|
103
119
|
timeTo: number;
|
|
104
120
|
}, {
|
|
105
|
-
deviceId: string;
|
|
106
|
-
createdBy: string;
|
|
121
|
+
deviceId: string[];
|
|
122
|
+
createdBy: string[];
|
|
107
123
|
timeFrom: number;
|
|
108
124
|
timeTo: number;
|
|
109
125
|
}>;
|
|
110
126
|
export type BookmarkProps = z.infer<typeof sBookmarkProps>;
|
|
111
127
|
export type CreateBookmarkRq = z.infer<typeof sCreateBookmarkRq>;
|
|
112
128
|
export type UpdateBookmarkRq = z.infer<typeof sUpdateBookmarkRq>;
|
|
129
|
+
export type UpdateBookmarkBody = z.infer<typeof sUpdateBookmarkBody>;
|
|
113
130
|
export type DeleteBookmarkRq = z.infer<typeof sDeleteBookmarkRq>;
|
|
114
131
|
export type BookmarkDto = z.infer<typeof sBookmarkDto>;
|
|
115
132
|
export type BookmarkSearchCriteria = z.infer<typeof sBookmarkSearchCriteria>;
|
package/dist/bookmarks.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
-
exports.sBookmarkSearchCriteria = exports.sBookmarkDto = exports.sDeleteBookmarkRq = exports.sUpdateBookmarkRq = exports.sCreateBookmarkRq = exports.sBookmarkProps = void 0;
|
|
3
|
+
exports.sBookmarkSearchCriteria = exports.sBookmarkDto = exports.sDeleteBookmarkRq = exports.sUpdateBookmarkRq = exports.sUpdateBookmarkBody = exports.sCreateBookmarkRq = exports.sBookmarkProps = void 0;
|
|
4
4
|
const zod_1 = require("zod");
|
|
5
5
|
exports.sBookmarkProps = zod_1.z.object({
|
|
6
6
|
timestamp: zod_1.z.number().min(0),
|
|
@@ -9,11 +9,12 @@ exports.sBookmarkProps = zod_1.z.object({
|
|
|
9
9
|
metadata: zod_1.z.record(zod_1.z.unknown()),
|
|
10
10
|
});
|
|
11
11
|
exports.sCreateBookmarkRq = exports.sBookmarkProps;
|
|
12
|
+
exports.sUpdateBookmarkBody = exports.sBookmarkProps.partial();
|
|
12
13
|
exports.sUpdateBookmarkRq = zod_1.z
|
|
13
14
|
.object({
|
|
14
15
|
id: zod_1.z.string().nonempty(),
|
|
15
16
|
})
|
|
16
|
-
.and(exports.
|
|
17
|
+
.and(exports.sUpdateBookmarkBody);
|
|
17
18
|
exports.sDeleteBookmarkRq = zod_1.z.object({
|
|
18
19
|
id: zod_1.z.string().nonempty(),
|
|
19
20
|
});
|
|
@@ -24,8 +25,8 @@ exports.sBookmarkDto = exports.sBookmarkProps.and(zod_1.z.object({
|
|
|
24
25
|
lastModifiedOn: zod_1.z.string().datetime(),
|
|
25
26
|
}));
|
|
26
27
|
exports.sBookmarkSearchCriteria = zod_1.z.object({
|
|
27
|
-
deviceId: zod_1.z.string(),
|
|
28
|
-
createdBy: zod_1.z.string(),
|
|
28
|
+
deviceId: zod_1.z.array(zod_1.z.string()),
|
|
29
|
+
createdBy: zod_1.z.array(zod_1.z.string()),
|
|
29
30
|
timeFrom: zod_1.z.number().min(0),
|
|
30
31
|
timeTo: zod_1.z.number().min(0),
|
|
31
32
|
});
|
package/dist/package.json
CHANGED