@junobuild/functions 0.1.3 → 0.2.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.
@@ -1,4 +1,4 @@
1
- import * as z from 'zod';
1
+ import * as z from 'zod/v4';
2
2
  import { type ListParams } from '../../schemas/list';
3
3
  import { type Collection, type RawUserId, type UserId } from '../../schemas/satellite';
4
4
  /**
@@ -6,11 +6,7 @@ import { type Collection, type RawUserId, type UserId } from '../../schemas/sate
6
6
  */
7
7
  export declare const CollectionParamsSchema: z.ZodObject<{
8
8
  collection: z.ZodString;
9
- }, "strict", z.ZodTypeAny, {
10
- collection: string;
11
- }, {
12
- collection: string;
13
- }>;
9
+ }, z.core.$strict>;
14
10
  /**
15
11
  * The parameters required to scope an operation to a collection.
16
12
  */
@@ -25,264 +21,45 @@ export interface CollectionParams {
25
21
  */
26
22
  export declare const ListStoreParamsSchema: z.ZodObject<{
27
23
  collection: z.ZodString;
28
- } & {
29
- caller: z.ZodUnion<[z.ZodType<Uint8Array<ArrayBufferLike>, z.ZodTypeDef, Uint8Array<ArrayBufferLike>>, z.ZodType<import("@dfinity/principal").Principal, z.ZodTypeDef, import("@dfinity/principal").Principal>]>;
24
+ caller: z.ZodUnion<[z.ZodCustom<Uint8Array<ArrayBufferLike>, Uint8Array<ArrayBufferLike>>, z.ZodCustom<import("@dfinity/principal").Principal, import("@dfinity/principal").Principal>]>;
30
25
  params: z.ZodObject<{
31
26
  matcher: z.ZodOptional<z.ZodObject<{
32
27
  key: z.ZodOptional<z.ZodString>;
33
28
  description: z.ZodOptional<z.ZodString>;
34
- created_at: z.ZodOptional<z.ZodUnion<[z.ZodObject<{
29
+ created_at: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
35
30
  equal: z.ZodBigInt;
36
- }, "strip", z.ZodTypeAny, {
37
- equal: bigint;
38
- }, {
39
- equal: bigint;
40
- }>, z.ZodObject<{
31
+ }, z.core.$strip>, z.ZodObject<{
41
32
  greater_than: z.ZodBigInt;
42
- }, "strip", z.ZodTypeAny, {
43
- greater_than: bigint;
44
- }, {
45
- greater_than: bigint;
46
- }>, z.ZodObject<{
33
+ }, z.core.$strip>, z.ZodObject<{
47
34
  less_than: z.ZodBigInt;
48
- }, "strip", z.ZodTypeAny, {
49
- less_than: bigint;
50
- }, {
51
- less_than: bigint;
52
- }>, z.ZodObject<{
35
+ }, z.core.$strip>, z.ZodObject<{
53
36
  between: z.ZodTuple<[z.ZodBigInt, z.ZodBigInt], null>;
54
- }, "strip", z.ZodTypeAny, {
55
- between: [bigint, bigint];
56
- }, {
57
- between: [bigint, bigint];
58
- }>]>>;
59
- updated_at: z.ZodOptional<z.ZodUnion<[z.ZodObject<{
37
+ }, z.core.$strip>]>>;
38
+ updated_at: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
60
39
  equal: z.ZodBigInt;
61
- }, "strip", z.ZodTypeAny, {
62
- equal: bigint;
63
- }, {
64
- equal: bigint;
65
- }>, z.ZodObject<{
40
+ }, z.core.$strip>, z.ZodObject<{
66
41
  greater_than: z.ZodBigInt;
67
- }, "strip", z.ZodTypeAny, {
68
- greater_than: bigint;
69
- }, {
70
- greater_than: bigint;
71
- }>, z.ZodObject<{
42
+ }, z.core.$strip>, z.ZodObject<{
72
43
  less_than: z.ZodBigInt;
73
- }, "strip", z.ZodTypeAny, {
74
- less_than: bigint;
75
- }, {
76
- less_than: bigint;
77
- }>, z.ZodObject<{
44
+ }, z.core.$strip>, z.ZodObject<{
78
45
  between: z.ZodTuple<[z.ZodBigInt, z.ZodBigInt], null>;
79
- }, "strip", z.ZodTypeAny, {
80
- between: [bigint, bigint];
81
- }, {
82
- between: [bigint, bigint];
83
- }>]>>;
84
- }, "strict", z.ZodTypeAny, {
85
- description?: string | undefined;
86
- created_at?: {
87
- equal: bigint;
88
- } | {
89
- greater_than: bigint;
90
- } | {
91
- less_than: bigint;
92
- } | {
93
- between: [bigint, bigint];
94
- } | undefined;
95
- updated_at?: {
96
- equal: bigint;
97
- } | {
98
- greater_than: bigint;
99
- } | {
100
- less_than: bigint;
101
- } | {
102
- between: [bigint, bigint];
103
- } | undefined;
104
- key?: string | undefined;
105
- }, {
106
- description?: string | undefined;
107
- created_at?: {
108
- equal: bigint;
109
- } | {
110
- greater_than: bigint;
111
- } | {
112
- less_than: bigint;
113
- } | {
114
- between: [bigint, bigint];
115
- } | undefined;
116
- updated_at?: {
117
- equal: bigint;
118
- } | {
119
- greater_than: bigint;
120
- } | {
121
- less_than: bigint;
122
- } | {
123
- between: [bigint, bigint];
124
- } | undefined;
125
- key?: string | undefined;
126
- }>>;
46
+ }, z.core.$strip>]>>;
47
+ }, z.core.$strict>>;
127
48
  paginate: z.ZodOptional<z.ZodObject<{
128
49
  start_after: z.ZodOptional<z.ZodString>;
129
50
  limit: z.ZodOptional<z.ZodBigInt>;
130
- }, "strict", z.ZodTypeAny, {
131
- start_after?: string | undefined;
132
- limit?: bigint | undefined;
133
- }, {
134
- start_after?: string | undefined;
135
- limit?: bigint | undefined;
136
- }>>;
51
+ }, z.core.$strict>>;
137
52
  order: z.ZodOptional<z.ZodObject<{
138
53
  desc: z.ZodBoolean;
139
- field: z.ZodEnum<["keys", "created_at", "updated_at"]>;
140
- }, "strict", z.ZodTypeAny, {
141
- desc: boolean;
142
- field: "keys" | "created_at" | "updated_at";
143
- }, {
144
- desc: boolean;
145
- field: "keys" | "created_at" | "updated_at";
146
- }>>;
147
- owner: z.ZodOptional<z.ZodType<Uint8Array<ArrayBufferLike>, z.ZodTypeDef, Uint8Array<ArrayBufferLike>>>;
148
- }, "strict", z.ZodTypeAny, {
149
- owner?: Uint8Array<ArrayBufferLike> | undefined;
150
- matcher?: {
151
- description?: string | undefined;
152
- created_at?: {
153
- equal: bigint;
154
- } | {
155
- greater_than: bigint;
156
- } | {
157
- less_than: bigint;
158
- } | {
159
- between: [bigint, bigint];
160
- } | undefined;
161
- updated_at?: {
162
- equal: bigint;
163
- } | {
164
- greater_than: bigint;
165
- } | {
166
- less_than: bigint;
167
- } | {
168
- between: [bigint, bigint];
169
- } | undefined;
170
- key?: string | undefined;
171
- } | undefined;
172
- paginate?: {
173
- start_after?: string | undefined;
174
- limit?: bigint | undefined;
175
- } | undefined;
176
- order?: {
177
- desc: boolean;
178
- field: "keys" | "created_at" | "updated_at";
179
- } | undefined;
180
- }, {
181
- owner?: Uint8Array<ArrayBufferLike> | undefined;
182
- matcher?: {
183
- description?: string | undefined;
184
- created_at?: {
185
- equal: bigint;
186
- } | {
187
- greater_than: bigint;
188
- } | {
189
- less_than: bigint;
190
- } | {
191
- between: [bigint, bigint];
192
- } | undefined;
193
- updated_at?: {
194
- equal: bigint;
195
- } | {
196
- greater_than: bigint;
197
- } | {
198
- less_than: bigint;
199
- } | {
200
- between: [bigint, bigint];
201
- } | undefined;
202
- key?: string | undefined;
203
- } | undefined;
204
- paginate?: {
205
- start_after?: string | undefined;
206
- limit?: bigint | undefined;
207
- } | undefined;
208
- order?: {
209
- desc: boolean;
210
- field: "keys" | "created_at" | "updated_at";
211
- } | undefined;
212
- }>;
213
- }, "strict", z.ZodTypeAny, {
214
- params: {
215
- owner?: Uint8Array<ArrayBufferLike> | undefined;
216
- matcher?: {
217
- description?: string | undefined;
218
- created_at?: {
219
- equal: bigint;
220
- } | {
221
- greater_than: bigint;
222
- } | {
223
- less_than: bigint;
224
- } | {
225
- between: [bigint, bigint];
226
- } | undefined;
227
- updated_at?: {
228
- equal: bigint;
229
- } | {
230
- greater_than: bigint;
231
- } | {
232
- less_than: bigint;
233
- } | {
234
- between: [bigint, bigint];
235
- } | undefined;
236
- key?: string | undefined;
237
- } | undefined;
238
- paginate?: {
239
- start_after?: string | undefined;
240
- limit?: bigint | undefined;
241
- } | undefined;
242
- order?: {
243
- desc: boolean;
244
- field: "keys" | "created_at" | "updated_at";
245
- } | undefined;
246
- };
247
- caller: Uint8Array<ArrayBufferLike> | import("@dfinity/principal").Principal;
248
- collection: string;
249
- }, {
250
- params: {
251
- owner?: Uint8Array<ArrayBufferLike> | undefined;
252
- matcher?: {
253
- description?: string | undefined;
254
- created_at?: {
255
- equal: bigint;
256
- } | {
257
- greater_than: bigint;
258
- } | {
259
- less_than: bigint;
260
- } | {
261
- between: [bigint, bigint];
262
- } | undefined;
263
- updated_at?: {
264
- equal: bigint;
265
- } | {
266
- greater_than: bigint;
267
- } | {
268
- less_than: bigint;
269
- } | {
270
- between: [bigint, bigint];
271
- } | undefined;
272
- key?: string | undefined;
273
- } | undefined;
274
- paginate?: {
275
- start_after?: string | undefined;
276
- limit?: bigint | undefined;
277
- } | undefined;
278
- order?: {
279
- desc: boolean;
280
- field: "keys" | "created_at" | "updated_at";
281
- } | undefined;
282
- };
283
- caller: Uint8Array<ArrayBufferLike> | import("@dfinity/principal").Principal;
284
- collection: string;
285
- }>;
54
+ field: z.ZodEnum<{
55
+ created_at: "created_at";
56
+ updated_at: "updated_at";
57
+ keys: "keys";
58
+ }>;
59
+ }, z.core.$strict>>;
60
+ owner: z.ZodOptional<z.ZodCustom<Uint8Array<ArrayBufferLike>, Uint8Array<ArrayBufferLike>>>;
61
+ }, z.core.$strict>;
62
+ }, z.core.$strict>;
286
63
  /**
287
64
  * The parameters required to list documents from the datastore respectively assets from the storage.
288
65
  */