@bikefinder/api-client 0.3.0 → 0.5.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.
Files changed (46) hide show
  1. package/README.md +3 -1
  2. package/dist/admin/generated/index.d.ts +1 -1
  3. package/dist/admin/generated/index.d.ts.map +1 -1
  4. package/dist/admin/generated/sdk.gen.d.ts +173 -19
  5. package/dist/admin/generated/sdk.gen.d.ts.map +1 -1
  6. package/dist/admin/generated/sdk.gen.js +377 -125
  7. package/dist/admin/generated/sdk.gen.js.map +1 -1
  8. package/dist/admin/generated/types.gen.d.ts +1468 -431
  9. package/dist/admin/generated/types.gen.d.ts.map +1 -1
  10. package/dist/admin/generated/zod.gen.d.ts +2726 -1638
  11. package/dist/admin/generated/zod.gen.d.ts.map +1 -1
  12. package/dist/admin/generated/zod.gen.js +410 -270
  13. package/dist/admin/generated/zod.gen.js.map +1 -1
  14. package/dist/generated/index.d.ts +1 -1
  15. package/dist/generated/index.d.ts.map +1 -1
  16. package/dist/generated/sdk.gen.d.ts +80 -45
  17. package/dist/generated/sdk.gen.d.ts.map +1 -1
  18. package/dist/generated/sdk.gen.js +192 -157
  19. package/dist/generated/sdk.gen.js.map +1 -1
  20. package/dist/generated/types.gen.d.ts +887 -453
  21. package/dist/generated/types.gen.d.ts.map +1 -1
  22. package/dist/generated/zod.gen.d.ts +468 -286
  23. package/dist/generated/zod.gen.d.ts.map +1 -1
  24. package/dist/generated/zod.gen.js +188 -201
  25. package/dist/generated/zod.gen.js.map +1 -1
  26. package/dist/realtime/api-stream-error.d.ts +2 -1
  27. package/dist/realtime/api-stream-error.d.ts.map +1 -1
  28. package/dist/realtime/api-stream-error.js +8 -1
  29. package/dist/realtime/api-stream-error.js.map +1 -1
  30. package/dist/realtime/watch.d.ts.map +1 -1
  31. package/dist/realtime/watch.js +1 -1
  32. package/dist/realtime/watch.js.map +1 -1
  33. package/dist/transport.js +10 -1
  34. package/dist/transport.js.map +1 -1
  35. package/package.json +1 -1
  36. package/src/admin/generated/index.ts +65 -7
  37. package/src/admin/generated/sdk.gen.ts +720 -300
  38. package/src/admin/generated/types.gen.ts +1646 -513
  39. package/src/admin/generated/zod.gen.ts +474 -286
  40. package/src/generated/index.ts +6 -2
  41. package/src/generated/sdk.gen.ts +408 -373
  42. package/src/generated/types.gen.ts +956 -516
  43. package/src/generated/zod.gen.ts +217 -231
  44. package/src/realtime/api-stream-error.ts +12 -1
  45. package/src/realtime/watch.ts +6 -1
  46. package/src/transport.ts +10 -1
@@ -1,8 +1,8 @@
1
1
  // This file is auto-generated by @hey-api/openapi-ts
2
2
  import * as z from "zod";
3
3
  export const zAdminAddMemberRequest = z.object({
4
- email: z.string(),
5
- description: z.string().optional().default(""),
4
+ email: z.string().max(320),
5
+ description: z.string().max(1000).optional().default(""),
6
6
  });
7
7
  export const zAdminB2bSubscriptionResult = z.object({
8
8
  success: z.boolean(),
@@ -19,18 +19,18 @@ export const zAdminB2bTier = z.enum([
19
19
  "b2b_7",
20
20
  ]);
21
21
  export const zAdminB2bSubscriptionRequest = z.object({
22
- company: z.string(),
23
- streetName: z.string(),
24
- postalArea: z.string(),
22
+ requestId: z.string().regex(/^[A-Za-z0-9_-]{16,128}$/),
23
+ company: z.string().max(128),
24
+ streetName: z.string().max(123),
25
+ postalArea: z.string().max(32),
25
26
  tier: zAdminB2bTier,
26
- country: z.string(),
27
- email: z.string(),
28
- quantity: z.int().gte(-9007199254740991).lte(9007199254740991),
29
- date: z.string(),
30
- nextPaymentDate: z.string(),
31
- tierInfo: z.string(),
32
- description: z.string().optional().default(""),
33
- requestId: z.string().nullish(),
27
+ country: z.string().regex(/^[A-Z]{2}$/),
28
+ email: z.string().max(125),
29
+ quantity: z.int().gte(1).lte(2147483647),
30
+ startsAt: z.iso.datetime({ offset: true }),
31
+ nextPaymentAt: z.iso.datetime({ offset: true }),
32
+ tierInfo: z.string().max(4000),
33
+ description: z.string().max(4000).optional().default(""),
34
34
  });
35
35
  export const zAdminBikeRequest = z.object({
36
36
  changes: z.record(z.string(), z.string()),
@@ -39,39 +39,56 @@ export const zAdminConfigurationRequest = z.object({
39
39
  values: z.record(z.string(), z.unknown()),
40
40
  });
41
41
  export const zAdminDenylistRequest = z.object({
42
- requestId: z.string(),
42
+ requestId: z
43
+ .string()
44
+ .regex(/^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][a-f0-9]{3}-[a-f0-9]{12}$/),
43
45
  value: z.boolean(),
44
46
  expected: z.boolean(),
45
- reason: z.string().nullish(),
46
- });
47
- export const zAdminDeviceCommandResult = z.object({
48
- success: z.boolean(),
49
- commandId: z.string(),
50
- jobIds: z.array(z.string()),
47
+ reason: z.string().max(1000).nullish(),
51
48
  });
52
- export const zAdminFavoriteRequest = z.object({
53
- comment: z.string(),
49
+ export const zAdminEvidenceAccountsRequest = z.object({
50
+ accountIds: z.array(z.string()).min(1).max(20),
54
51
  });
55
- export const zAdminGeneration = z.enum(["g1", "gen2"]);
56
- export const zAdminHistoryCollection = z.enum([
52
+ export const zAdminEvidenceDomain = z.enum([
53
+ "battery",
54
+ "versions",
55
+ "reporting",
56
+ "configuration",
57
+ "membershipReference",
58
+ "membershipState",
59
+ "commerceReference",
60
+ "plan",
61
+ "availability",
62
+ "bindingCount",
63
+ ]);
64
+ export const zAdminEvidenceHistoryGroup = z.enum([
65
+ "battery",
66
+ "versions",
67
+ "reporting",
68
+ "diagnostics",
69
+ ]);
70
+ export const zAdminEvidenceHistorySource = z.enum([
57
71
  "data",
58
- "images",
59
- "logs",
60
- "productionData",
61
72
  "sanitizedData",
73
+ "bluetooth",
74
+ "audit",
75
+ "commandPackets",
62
76
  ]);
63
- export const zAdminInsuranceProvider = z.enum(["cycler", "hepster", "tryg"]);
77
+ export const zAdminFavoriteRequest = z.object({
78
+ comment: z.string().max(4000),
79
+ });
80
+ export const zAdminGeneration = z.enum(["gen1", "gen2"]);
64
81
  export const zAdminLinkSubscriptionRequest = z.object({
65
82
  subscriptionId: z.string(),
66
83
  });
67
84
  export const zAdminLookupRequest = z.object({
68
- uids: z.array(z.string()).nullish(),
69
- emails: z.array(z.string()).nullish(),
85
+ uids: z.array(z.string()).max(100).nullish(),
86
+ emails: z.array(z.string()).max(100).nullish(),
70
87
  });
71
88
  export const zAdminLookupUser = z.object({
72
89
  userId: z.string(),
73
- email: z.string().nullish(),
74
- nickname: z.string().nullish(),
90
+ email: z.string().nullable(),
91
+ nickname: z.string().nullable(),
75
92
  });
76
93
  export const zAdminLookupResult = z.object({
77
94
  uidsLookup: z.array(zAdminLookupUser),
@@ -87,26 +104,43 @@ export const zAdminModeRequest = z.object({
87
104
  mode: zAdminMode,
88
105
  });
89
106
  export const zAdminNotificationRequest = z.object({
90
- requestId: z.string(),
91
- title: z.string(),
92
- message: z.string(),
107
+ requestId: z
108
+ .string()
109
+ .regex(/^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][a-f0-9]{3}-[a-f0-9]{12}$/),
110
+ title: z.string().max(200),
111
+ message: z.string().max(4000),
93
112
  supportTimestamp: z.boolean().nullish(),
94
- log: z.string().nullish(),
113
+ log: z.string().max(1000).nullish(),
95
114
  });
96
- export const zAdminPrivateDomain = z.enum([
97
- "battery",
98
- "firmware",
99
- "runtime",
100
- "statistics",
101
- ]);
102
- export const zAdminPublicDomain = z.enum([
103
- "battery",
104
- "configuration",
105
- "contact",
106
- "location",
115
+ export const zAdminRelationshipKind = z.enum([
116
+ "subscriptionBinding",
117
+ "deviceAccount",
107
118
  ]);
119
+ export const zAdminRelationshipChangeRequest = z.object({
120
+ accountIds: z.array(z.string()).min(1).max(20),
121
+ kind: zAdminRelationshipKind,
122
+ accountId: z.string().min(1).max(128),
123
+ expectedVersion: z.string().regex(/^[a-f0-9]{64}$/),
124
+ subscriptionId: z.string().nullish(),
125
+ allowLastAccountCleanup: z.boolean().optional().default(false),
126
+ });
127
+ export const zAdminRelationshipRequest = z.object({
128
+ accountIds: z.array(z.string()).min(1).max(20),
129
+ kind: zAdminRelationshipKind,
130
+ });
131
+ export const zAdminRelationshipVerification = z.object({
132
+ verified: z.boolean(),
133
+ });
134
+ export const zAdminRelationshipVerificationRequest = z.object({
135
+ kind: zAdminRelationshipKind,
136
+ accountId: z.string().min(1).max(128),
137
+ remainingAccountIds: z.array(z.string()).max(100),
138
+ subscriptionId: z.string().nullish(),
139
+ });
108
140
  export const zAdminRequestId = z.object({
109
- requestId: z.string(),
141
+ requestId: z
142
+ .string()
143
+ .regex(/^[a-f0-9]{8}-[a-f0-9]{4}-4[a-f0-9]{3}-[89ab][a-f0-9]{3}-[a-f0-9]{12}$/),
110
144
  });
111
145
  export const zAdminSession = z.object({
112
146
  uid: z.string(),
@@ -114,7 +148,6 @@ export const zAdminSession = z.object({
114
148
  canWrite: z.boolean(),
115
149
  isSalesUser: z.boolean(),
116
150
  });
117
- export const zAdminSubscriptionSearchKind = z.enum(["b2b", "uid", "wooId"]);
118
151
  export const zAdminSupportValue = z
119
152
  .union([
120
153
  z.boolean(),
@@ -154,15 +187,15 @@ export const zAdminDocument = z.object({
154
187
  fields: zAdminSupportValue,
155
188
  });
156
189
  export const zAdminPublicStates = z.object({
157
- contact: zAdminDocument.nullish(),
158
- battery: zAdminDocument.nullish(),
159
- location: zAdminDocument.nullish(),
160
- configuration: zAdminDocument.nullish(),
190
+ contact: zAdminDocument.nullable(),
191
+ battery: zAdminDocument.nullable(),
192
+ location: zAdminDocument.nullable(),
193
+ configuration: zAdminDocument.nullable(),
161
194
  });
162
195
  export const zAdminReadResult = z.object({
163
196
  documents: z.array(zAdminDocument),
164
197
  nextCursor: z.string().nullable(),
165
- states: zAdminPublicStates.nullish(),
198
+ states: zAdminPublicStates.nullable(),
166
199
  });
167
200
  export const zAdminTimestamp = z.object({
168
201
  seconds: z.int().gte(-9007199254740991).lte(9007199254740991),
@@ -175,6 +208,32 @@ export const zAdminTimestamp = z.object({
175
208
  error: "Invalid value: Expected int32 to be <= 2147483647",
176
209
  }),
177
210
  });
211
+ export const zAdminEvidenceCursor = z.object({
212
+ timestamp: zAdminTimestamp,
213
+ id: z.string().min(1).max(254),
214
+ });
215
+ export const zAdminEvidenceDocument = z.object({
216
+ id: z.string(),
217
+ path: z.string(),
218
+ exists: z.boolean(),
219
+ fields: zAdminSupportValue.nullable(),
220
+ updatedAt: zAdminTimestamp.nullable(),
221
+ createdAt: zAdminTimestamp.nullable(),
222
+ readAt: zAdminTimestamp,
223
+ });
224
+ export const zAdminEvidenceHistoryRequest = z.object({
225
+ accountId: z.string().min(1).max(128),
226
+ source: zAdminEvidenceHistorySource,
227
+ from: z.iso.datetime({ offset: true }),
228
+ to: z.iso.datetime({ offset: true }),
229
+ after: zAdminEvidenceCursor.nullish(),
230
+ fields: z.array(zAdminEvidenceHistoryGroup).min(1).max(4).nullish(),
231
+ });
232
+ export const zAdminEvidenceSnapshot = z.object({
233
+ documents: z.array(zAdminEvidenceDocument),
234
+ relatedDocuments: z.array(zAdminEvidenceDocument),
235
+ readAt: zAdminTimestamp,
236
+ });
178
237
  export const zAdminTrackerCommand = z.enum([
179
238
  "changeEncryptionKey",
180
239
  "changeRareConfigs",
@@ -190,12 +249,16 @@ export const zAdminTrackerCommandRequest = z.object({
190
249
  command: zAdminTrackerCommand.nullable(),
191
250
  expectedCommand: z.string().nullable(),
192
251
  });
193
- export const zAdminTrackerSearchKind = z.enum([
194
- "iccid",
195
- "imei",
196
- "subscriptionId",
197
- "uid",
198
- ]);
252
+ export const zAdminTrackerCommandResult = z.object({
253
+ success: z.boolean(),
254
+ commandId: z.string(),
255
+ jobIds: z.array(z.string()),
256
+ });
257
+ export const zAdminTrackerFactsRequest = z.object({
258
+ target: z.string().min(1).max(254),
259
+ accountIds: z.array(z.string()).min(1).max(20),
260
+ domain: zAdminEvidenceDomain,
261
+ });
199
262
  export const zCommandSuccess = z.object({
200
263
  success: z.boolean(),
201
264
  });
@@ -206,10 +269,10 @@ export const zAdminOperationalDomain = z.object({
206
269
  updatedAt: zAdminTimestamp,
207
270
  });
208
271
  export const zAdminOperationalDomains = z.object({
209
- battery: zAdminOperationalDomain.nullish(),
210
- runtime: zAdminOperationalDomain.nullish(),
211
- statistics: zAdminOperationalDomain.nullish(),
212
- firmware: zAdminOperationalDomain.nullish(),
272
+ battery: zAdminOperationalDomain.nullable(),
273
+ runtime: zAdminOperationalDomain.nullable(),
274
+ statistics: zAdminOperationalDomain.nullable(),
275
+ firmware: zAdminOperationalDomain.nullable(),
213
276
  });
214
277
  export const zAdminOperationalState = z.object({
215
278
  schemaVersion: z
@@ -246,226 +309,188 @@ export const zProblemDetails = z.object({
246
309
  .nullish(),
247
310
  detail: z.string().nullish(),
248
311
  instance: z.string().nullish(),
312
+ code: z.string(),
313
+ traceId: z.string(),
314
+ errors: z.record(z.string(), z.array(z.string())).optional(),
249
315
  });
250
- export const zAdminUploadTrackerPhotoBody = z
251
- .object({
252
- file: zIFormFile,
253
- })
254
- .and(z.object({
255
- kind: z.string(),
256
- }))
257
- .and(z.object({
258
- width: z
259
- .int()
260
- .min(-2147483648, {
261
- error: "Invalid value: Expected int32 to be >= -2147483648",
262
- })
263
- .max(2147483647, {
264
- error: "Invalid value: Expected int32 to be <= 2147483647",
265
- }),
266
- }))
267
- .and(z.object({
268
- height: z
269
- .int()
270
- .min(-2147483648, {
271
- error: "Invalid value: Expected int32 to be >= -2147483648",
272
- })
273
- .max(2147483647, {
274
- error: "Invalid value: Expected int32 to be <= 2147483647",
275
- }),
276
- }));
277
- export const zAdminUploadTrackerPhotoPath = z.object({
278
- trackerId: z
279
- .string()
280
- .min(1)
281
- .max(128)
282
- .regex(/^[A-Za-z0-9_-]+$/),
316
+ export const zAdminListAccountTrackerEvidencePath = z.object({
317
+ accountId: z.string(),
283
318
  });
284
- /**
285
- * OK
286
- */
287
- export const zAdminUploadTrackerPhotoResponse = zPhotoUploadResult;
288
- export const zAdminGetTrackerPath = z.object({
289
- trackerId: z
290
- .string()
291
- .min(1)
292
- .max(128)
293
- .regex(/^[A-Za-z0-9_-]+$/),
294
- });
295
- export const zAdminGetTrackerQuery = z.object({
296
- domains: z.array(zAdminPublicDomain).optional(),
319
+ export const zAdminListAccountTrackerEvidenceQuery = z.object({
320
+ after: z.string().optional(),
297
321
  });
298
322
  /**
299
323
  * OK
300
324
  */
301
- export const zAdminGetTrackerResponse = zAdminReadResult;
302
- export const zAdminSearchTrackersQuery = z.object({
303
- kind: zAdminTrackerSearchKind,
304
- value: z.string(),
305
- cursor: z.string().optional(),
325
+ export const zAdminListAccountTrackerEvidenceResponse = zAdminEvidenceSnapshot;
326
+ export const zAdminListAccountSubscriptionEvidencePath = z.object({
327
+ accountId: z.string(),
328
+ });
329
+ export const zAdminListAccountSubscriptionEvidenceQuery = z.object({
330
+ after: z.string().optional(),
306
331
  });
307
332
  /**
308
333
  * OK
309
334
  */
310
- export const zAdminSearchTrackersResponse = zAdminReadResult;
311
- export const zAdminGetUserPath = z.object({
312
- uid: z.string(),
313
- });
335
+ export const zAdminListAccountSubscriptionEvidenceResponse = zAdminEvidenceSnapshot;
336
+ export const zAdminQueryTrackerFactEvidenceBody = zAdminTrackerFactsRequest;
314
337
  /**
315
338
  * OK
316
339
  */
317
- export const zAdminGetUserResponse = zAdminReadResult;
318
- export const zAdminGetSubscriptionPath = z.object({
340
+ export const zAdminQueryTrackerFactEvidenceResponse = zAdminEvidenceSnapshot;
341
+ export const zAdminGetSubscriptionFactEvidencePath = z.object({
319
342
  subscriptionId: z.string(),
320
343
  });
321
- /**
322
- * OK
323
- */
324
- export const zAdminGetSubscriptionResponse = zAdminReadResult;
325
- export const zAdminSearchSubscriptionsQuery = z.object({
326
- kind: zAdminSubscriptionSearchKind,
327
- value: z.string().optional().default(""),
328
- cursor: z.string().optional(),
344
+ export const zAdminGetSubscriptionFactEvidenceQuery = z.object({
345
+ domain: z.enum([
346
+ "battery",
347
+ "versions",
348
+ "reporting",
349
+ "configuration",
350
+ "membershipReference",
351
+ "membershipState",
352
+ "commerceReference",
353
+ "plan",
354
+ "availability",
355
+ "bindingCount",
356
+ ]),
329
357
  });
330
358
  /**
331
359
  * OK
332
360
  */
333
- export const zAdminSearchSubscriptionsResponse = zAdminReadResult;
334
- export const zAdminListInsurancePath = z.object({
335
- subscriptionId: z.string(),
336
- provider: zAdminInsuranceProvider,
337
- });
338
- export const zAdminListInsuranceQuery = z.object({
339
- cursor: z.string().optional(),
361
+ export const zAdminGetSubscriptionFactEvidenceResponse = zAdminEvidenceSnapshot;
362
+ export const zAdminQueryTrackerSubscriptionEvidenceBody = zAdminEvidenceAccountsRequest;
363
+ export const zAdminQueryTrackerSubscriptionEvidencePath = z.object({
364
+ trackerId: z
365
+ .string()
366
+ .length(32)
367
+ .regex(/^[a-f0-9]{32}$/),
340
368
  });
341
369
  /**
342
370
  * OK
343
371
  */
344
- export const zAdminListInsuranceResponse = zAdminReadResult;
345
- export const zAdminListFavoritesQuery = z.object({
346
- cursor: z.string().optional(),
372
+ export const zAdminQueryTrackerSubscriptionEvidenceResponse = zAdminEvidenceSnapshot;
373
+ export const zAdminQueryCommerceBindingEvidenceBody = zAdminEvidenceAccountsRequest;
374
+ export const zAdminQueryCommerceBindingEvidencePath = z.object({
375
+ wooId: z.int().gte(-9007199254740991).lte(9007199254740991),
347
376
  });
348
377
  /**
349
378
  * OK
350
379
  */
351
- export const zAdminListFavoritesResponse = zAdminReadResult;
352
- export const zAdminDeleteFavoritePath = z.object({
380
+ export const zAdminQueryCommerceBindingEvidenceResponse = zAdminEvidenceSnapshot;
381
+ export const zAdminQueryTrackerHistoryEvidenceBody = zAdminEvidenceHistoryRequest;
382
+ export const zAdminQueryTrackerHistoryEvidencePath = z.object({
353
383
  trackerId: z
354
384
  .string()
355
- .min(1)
356
- .max(128)
357
- .regex(/^[A-Za-z0-9_-]+$/),
385
+ .length(32)
386
+ .regex(/^[a-f0-9]{32}$/),
358
387
  });
359
388
  /**
360
389
  * OK
361
390
  */
362
- export const zAdminDeleteFavoriteResponse = zCommandSuccess;
363
- export const zAdminGetFavoritePath = z.object({
391
+ export const zAdminQueryTrackerHistoryEvidenceResponse = zAdminEvidenceSnapshot;
392
+ export const zAdminQueryTrackerRelationshipEvidenceBody = zAdminRelationshipRequest;
393
+ export const zAdminQueryTrackerRelationshipEvidencePath = z.object({
364
394
  trackerId: z
365
395
  .string()
366
- .min(1)
367
- .max(128)
368
- .regex(/^[A-Za-z0-9_-]+$/),
396
+ .length(32)
397
+ .regex(/^[a-f0-9]{32}$/),
369
398
  });
370
399
  /**
371
400
  * OK
372
401
  */
373
- export const zAdminGetFavoriteResponse = zAdminReadResult;
374
- export const zAdminUpdateFavoriteCommentBody = zAdminFavoriteRequest;
375
- export const zAdminUpdateFavoriteCommentPath = z.object({
402
+ export const zAdminQueryTrackerRelationshipEvidenceResponse = zAdminEvidenceSnapshot;
403
+ export const zAdminChangeTrackerRelationshipBody = zAdminRelationshipChangeRequest;
404
+ export const zAdminChangeTrackerRelationshipPath = z.object({
376
405
  trackerId: z
377
406
  .string()
378
- .min(1)
379
- .max(128)
380
- .regex(/^[A-Za-z0-9_-]+$/),
407
+ .length(32)
408
+ .regex(/^[a-f0-9]{32}$/),
381
409
  });
382
410
  /**
383
411
  * OK
384
412
  */
385
- export const zAdminUpdateFavoriteCommentResponse = zCommandSuccess;
386
- export const zAdminPutFavoriteBody = zAdminFavoriteRequest;
387
- export const zAdminPutFavoritePath = z.object({
413
+ export const zAdminChangeTrackerRelationshipResponse = zCommandSuccess;
414
+ export const zAdminVerifyTrackerRelationshipBody = zAdminRelationshipVerificationRequest;
415
+ export const zAdminVerifyTrackerRelationshipPath = z.object({
388
416
  trackerId: z
389
417
  .string()
390
- .min(1)
391
- .max(128)
392
- .regex(/^[A-Za-z0-9_-]+$/),
418
+ .length(32)
419
+ .regex(/^[a-f0-9]{32}$/),
393
420
  });
394
421
  /**
395
422
  * OK
396
423
  */
397
- export const zAdminPutFavoriteResponse = zCommandSuccess;
398
- export const zAdminListTrackerHistoryPath = z.object({
399
- trackerId: z
400
- .string()
401
- .min(1)
402
- .max(128)
403
- .regex(/^[A-Za-z0-9_-]+$/),
404
- collection: zAdminHistoryCollection,
405
- });
406
- export const zAdminListTrackerHistoryQuery = z.object({
407
- from: z.int().gte(-9007199254740991).lte(9007199254740991).optional(),
408
- to: z.int().gte(-9007199254740991).lte(9007199254740991).optional(),
409
- cursor: z.string().optional(),
410
- });
424
+ export const zAdminVerifyTrackerRelationshipResponse = zAdminRelationshipVerification;
411
425
  /**
412
426
  * OK
413
427
  */
414
- export const zAdminListTrackerHistoryResponse = zAdminReadResult;
415
- export const zAdminGetTrackerOperationalStatePath = z.object({
428
+ export const zAdminGetSessionResponse = zAdminSession;
429
+ export const zAdminGetTrackerPath = z.object({
416
430
  trackerId: z
417
431
  .string()
418
- .min(1)
419
- .max(128)
420
- .regex(/^[A-Za-z0-9_-]+$/),
432
+ .length(32)
433
+ .regex(/^[a-f0-9]{32}$/),
421
434
  });
422
- export const zAdminGetTrackerOperationalStateQuery = z.object({
423
- domains: z.array(zAdminPrivateDomain),
435
+ export const zAdminGetTrackerQuery = z.object({
436
+ domains: z
437
+ .array(z.enum(["battery", "configuration", "contact", "location"]))
438
+ .optional(),
424
439
  });
425
440
  /**
426
441
  * OK
427
442
  */
428
- export const zAdminGetTrackerOperationalStateResponse = zAdminOperationalState;
429
- /**
430
- * OK
431
- */
432
- export const zAdminGetSessionResponse = zAdminSession;
433
- export const zAdminLookupUsersBody = zAdminLookupRequest;
443
+ export const zAdminGetTrackerResponse = zAdminReadResult;
444
+ export const zAdminSearchTrackersQuery = z.object({
445
+ kind: z.enum(["iccid", "imei", "subscriptionId", "uid"]),
446
+ value: z.string(),
447
+ cursor: z.string().optional(),
448
+ });
434
449
  /**
435
450
  * OK
436
451
  */
437
- export const zAdminLookupUsersResponse = zAdminLookupResult;
438
- export const zAdminAddTrackerMemberBody = zAdminAddMemberRequest;
439
- export const zAdminAddTrackerMemberPath = z.object({
452
+ export const zAdminSearchTrackersResponse = zAdminReadResult;
453
+ export const zAdminListTrackerHistoryPath = z.object({
440
454
  trackerId: z
441
455
  .string()
442
- .min(1)
443
- .max(128)
444
- .regex(/^[A-Za-z0-9_-]+$/),
456
+ .length(32)
457
+ .regex(/^[a-f0-9]{32}$/),
458
+ collection: z.enum([
459
+ "data",
460
+ "images",
461
+ "logs",
462
+ "productionData",
463
+ "sanitizedData",
464
+ ]),
465
+ });
466
+ export const zAdminListTrackerHistoryQuery = z.object({
467
+ from: z.iso.datetime({ offset: true }).optional(),
468
+ to: z.iso.datetime({ offset: true }).optional(),
469
+ cursor: z.string().optional(),
445
470
  });
446
471
  /**
447
472
  * OK
448
473
  */
449
- export const zAdminAddTrackerMemberResponse = zCommandSuccess;
450
- export const zAdminRemoveTrackerMemberPath = z.object({
474
+ export const zAdminListTrackerHistoryResponse = zAdminReadResult;
475
+ export const zAdminGetTrackerOperationalStatePath = z.object({
451
476
  trackerId: z
452
477
  .string()
453
- .min(1)
454
- .max(128)
455
- .regex(/^[A-Za-z0-9_-]+$/),
456
- uid: z.string(),
478
+ .length(32)
479
+ .regex(/^[a-f0-9]{32}$/),
480
+ });
481
+ export const zAdminGetTrackerOperationalStateQuery = z.object({
482
+ domains: z.array(z.enum(["battery", "firmware", "runtime", "statistics"])),
457
483
  });
458
484
  /**
459
485
  * OK
460
486
  */
461
- export const zAdminRemoveTrackerMemberResponse = zCommandSuccess;
487
+ export const zAdminGetTrackerOperationalStateResponse = zAdminOperationalState;
462
488
  export const zAdminRequestTrackerModeBody = zAdminModeRequest;
463
489
  export const zAdminRequestTrackerModePath = z.object({
464
490
  trackerId: z
465
491
  .string()
466
- .min(1)
467
- .max(128)
468
- .regex(/^[A-Za-z0-9_-]+$/),
492
+ .length(32)
493
+ .regex(/^[a-f0-9]{32}$/),
469
494
  });
470
495
  /**
471
496
  * OK
@@ -475,9 +500,8 @@ export const zAdminRequestTrackerCommandBody = zAdminTrackerCommandRequest;
475
500
  export const zAdminRequestTrackerCommandPath = z.object({
476
501
  trackerId: z
477
502
  .string()
478
- .min(1)
479
- .max(128)
480
- .regex(/^[A-Za-z0-9_-]+$/),
503
+ .length(32)
504
+ .regex(/^[a-f0-9]{32}$/),
481
505
  });
482
506
  /**
483
507
  * OK
@@ -487,9 +511,8 @@ export const zAdminUpdateTrackerConfigurationBody = zAdminConfigurationRequest;
487
511
  export const zAdminUpdateTrackerConfigurationPath = z.object({
488
512
  trackerId: z
489
513
  .string()
490
- .min(1)
491
- .max(128)
492
- .regex(/^[A-Za-z0-9_-]+$/),
514
+ .length(32)
515
+ .regex(/^[a-f0-9]{32}$/),
493
516
  });
494
517
  /**
495
518
  * OK
@@ -499,9 +522,8 @@ export const zAdminUpdateTrackerBikeBody = zAdminBikeRequest;
499
522
  export const zAdminUpdateTrackerBikePath = z.object({
500
523
  trackerId: z
501
524
  .string()
502
- .min(1)
503
- .max(128)
504
- .regex(/^[A-Za-z0-9_-]+$/),
525
+ .length(32)
526
+ .regex(/^[a-f0-9]{32}$/),
505
527
  });
506
528
  /**
507
529
  * OK
@@ -511,109 +533,146 @@ export const zAdminCleanTrackerBody = zAdminRequestId;
511
533
  export const zAdminCleanTrackerPath = z.object({
512
534
  trackerId: z
513
535
  .string()
514
- .min(1)
515
- .max(128)
516
- .regex(/^[A-Za-z0-9_-]+$/),
536
+ .length(32)
537
+ .regex(/^[a-f0-9]{32}$/),
517
538
  });
518
539
  /**
519
- * OK
540
+ * Accepted
520
541
  */
521
- export const zAdminCleanTrackerResponse = zAdminDeviceCommandResult;
542
+ export const zAdminCleanTrackerResponse = zAdminTrackerCommandResult;
522
543
  export const zAdminSetTrackerDenylistBody = zAdminDenylistRequest;
523
544
  export const zAdminSetTrackerDenylistPath = z.object({
524
545
  trackerId: z
525
546
  .string()
526
- .min(1)
527
- .max(128)
528
- .regex(/^[A-Za-z0-9_-]+$/),
547
+ .length(32)
548
+ .regex(/^[a-f0-9]{32}$/),
529
549
  });
530
550
  /**
531
551
  * OK
532
552
  */
533
- export const zAdminSetTrackerDenylistResponse = zAdminDeviceCommandResult;
553
+ export const zAdminSetTrackerDenylistResponse = zAdminTrackerCommandResult;
534
554
  export const zAdminNotifyTrackerBody = zAdminNotificationRequest;
535
555
  export const zAdminNotifyTrackerPath = z.object({
536
556
  trackerId: z
537
557
  .string()
538
- .min(1)
539
- .max(128)
540
- .regex(/^[A-Za-z0-9_-]+$/),
558
+ .length(32)
559
+ .regex(/^[a-f0-9]{32}$/),
541
560
  });
542
561
  /**
543
- * OK
562
+ * Accepted
544
563
  */
545
- export const zAdminNotifyTrackerResponse = zAdminDeviceCommandResult;
546
- export const zAdminUnlinkTrackerSubscriptionPath = z.object({
564
+ export const zAdminNotifyTrackerResponse = zAdminTrackerCommandResult;
565
+ export const zAdminAddTrackerMemberBody = zAdminAddMemberRequest;
566
+ export const zAdminAddTrackerMemberPath = z.object({
547
567
  trackerId: z
548
568
  .string()
549
- .min(1)
550
- .max(128)
551
- .regex(/^[A-Za-z0-9_-]+$/),
569
+ .length(32)
570
+ .regex(/^[a-f0-9]{32}$/),
552
571
  });
553
572
  /**
554
573
  * OK
555
574
  */
556
- export const zAdminUnlinkTrackerSubscriptionResponse = zCommandSuccess;
557
- export const zAdminLinkTrackerSubscriptionBody = zAdminLinkSubscriptionRequest;
558
- export const zAdminLinkTrackerSubscriptionPath = z.object({
575
+ export const zAdminAddTrackerMemberResponse = zCommandSuccess;
576
+ export const zAdminRemoveTrackerMemberPath = z.object({
559
577
  trackerId: z
560
578
  .string()
561
- .min(1)
562
- .max(128)
563
- .regex(/^[A-Za-z0-9_-]+$/),
579
+ .length(32)
580
+ .regex(/^[a-f0-9]{32}$/),
581
+ uid: z.string(),
564
582
  });
565
583
  /**
566
584
  * OK
567
585
  */
568
- export const zAdminLinkTrackerSubscriptionResponse = zCommandSuccess;
569
- export const zAdminRequestSubscriptionInsuranceBody = zAdminRequestId;
570
- export const zAdminRequestSubscriptionInsurancePath = z.object({
571
- subscriptionId: z.string(),
586
+ export const zAdminRemoveTrackerMemberResponse = zCommandSuccess;
587
+ export const zAdminUnlinkTrackerSubscriptionPath = z.object({
588
+ trackerId: z
589
+ .string()
590
+ .length(32)
591
+ .regex(/^[a-f0-9]{32}$/),
572
592
  });
573
593
  /**
574
594
  * OK
575
595
  */
576
- export const zAdminRequestSubscriptionInsuranceResponse = zCommandSuccess;
577
- export const zAdminRequestUserInsuranceBody = zAdminRequestId;
578
- export const zAdminRequestUserInsurancePath = z.object({
579
- uid: z.string(),
596
+ export const zAdminUnlinkTrackerSubscriptionResponse = zCommandSuccess;
597
+ export const zAdminLinkTrackerSubscriptionBody = zAdminLinkSubscriptionRequest;
598
+ export const zAdminLinkTrackerSubscriptionPath = z.object({
599
+ trackerId: z
600
+ .string()
601
+ .length(32)
602
+ .regex(/^[a-f0-9]{32}$/),
580
603
  });
581
604
  /**
582
605
  * OK
583
606
  */
584
- export const zAdminRequestUserInsuranceResponse = zCommandSuccess;
607
+ export const zAdminLinkTrackerSubscriptionResponse = zCommandSuccess;
585
608
  export const zAdminRequestTrackerInsuranceBody = zAdminRequestId;
586
609
  export const zAdminRequestTrackerInsurancePath = z.object({
587
610
  trackerId: z
588
611
  .string()
589
- .min(1)
590
- .max(128)
591
- .regex(/^[A-Za-z0-9_-]+$/),
612
+ .length(32)
613
+ .regex(/^[a-f0-9]{32}$/),
592
614
  });
593
615
  /**
594
- * OK
616
+ * Accepted
595
617
  */
596
618
  export const zAdminRequestTrackerInsuranceResponse = zCommandSuccess;
597
619
  export const zAdminReconcileTrackerSubscriptionBody = zAdminRequestId;
598
620
  export const zAdminReconcileTrackerSubscriptionPath = z.object({
599
621
  trackerId: z
600
622
  .string()
601
- .min(1)
602
- .max(128)
603
- .regex(/^[A-Za-z0-9_-]+$/),
623
+ .length(32)
624
+ .regex(/^[a-f0-9]{32}$/),
604
625
  });
605
626
  /**
606
- * OK
627
+ * Accepted
607
628
  */
608
629
  export const zAdminReconcileTrackerSubscriptionResponse = zCommandSuccess;
609
- export const zAdminRefreshSubscriptionBody = zAdminRequestId;
610
- export const zAdminRefreshSubscriptionPath = z.object({
611
- subscriptionId: z.string(),
630
+ export const zAdminUploadTrackerPhotoBody = z.object({
631
+ file: z.string().max(10485760),
632
+ kind: z.enum(["bike", "installation", "receipt"]),
633
+ width: z.int().gte(1).lte(16384),
634
+ height: z.int().gte(1).lte(16384),
635
+ });
636
+ export const zAdminUploadTrackerPhotoPath = z.object({
637
+ trackerId: z
638
+ .string()
639
+ .length(32)
640
+ .regex(/^[a-f0-9]{32}$/),
612
641
  });
613
642
  /**
614
643
  * OK
615
644
  */
616
- export const zAdminRefreshSubscriptionResponse = zCommandSuccess;
645
+ export const zAdminUploadTrackerPhotoResponse = zPhotoUploadResult;
646
+ export const zAdminSubscribeTrackerPath = z.object({
647
+ trackerId: z
648
+ .string()
649
+ .length(32)
650
+ .regex(/^[a-f0-9]{32}$/),
651
+ });
652
+ /**
653
+ * OK
654
+ */
655
+ export const zAdminSubscribeTrackerResponse = zAdminTrackerView.nullable();
656
+ export const zAdminGetUserPath = z.object({
657
+ uid: z.string(),
658
+ });
659
+ /**
660
+ * OK
661
+ */
662
+ export const zAdminGetUserResponse = zAdminReadResult;
663
+ export const zAdminLookupUsersBody = zAdminLookupRequest;
664
+ /**
665
+ * OK
666
+ */
667
+ export const zAdminLookupUsersResponse = zAdminLookupResult;
668
+ export const zAdminRequestUserInsuranceBody = zAdminRequestId;
669
+ export const zAdminRequestUserInsurancePath = z.object({
670
+ uid: z.string(),
671
+ });
672
+ /**
673
+ * Accepted
674
+ */
675
+ export const zAdminRequestUserInsuranceResponse = zCommandSuccess;
617
676
  export const zAdminLinkSingleSubscriptionBody = zAdminRequestId;
618
677
  export const zAdminLinkSingleSubscriptionPath = z.object({
619
678
  uid: z.string(),
@@ -622,38 +681,119 @@ export const zAdminLinkSingleSubscriptionPath = z.object({
622
681
  * OK
623
682
  */
624
683
  export const zAdminLinkSingleSubscriptionResponse = zCommandSuccess;
625
- export const zAdminCreateB2bSubscriptionBody = zAdminB2bSubscriptionRequest;
684
+ export const zAdminGetSubscriptionPath = z.object({
685
+ subscriptionId: z.string(),
686
+ });
626
687
  /**
627
688
  * OK
628
689
  */
629
- export const zAdminCreateB2bSubscriptionResponse = zAdminB2bSubscriptionResult;
630
- export const zAdminCancelB2bSubscriptionPath = z.object({
690
+ export const zAdminGetSubscriptionResponse = zAdminReadResult;
691
+ export const zAdminSearchSubscriptionsQuery = z.object({
692
+ kind: z.enum(["b2b", "uid", "wooId"]),
693
+ value: z.string().optional().default(""),
694
+ cursor: z.string().optional(),
695
+ });
696
+ /**
697
+ * OK
698
+ */
699
+ export const zAdminSearchSubscriptionsResponse = zAdminReadResult;
700
+ export const zAdminListInsurancePath = z.object({
631
701
  subscriptionId: z.string(),
702
+ provider: z.enum(["cycler", "hepster", "tryg"]),
703
+ });
704
+ export const zAdminListInsuranceQuery = z.object({
705
+ cursor: z.string().optional(),
632
706
  });
633
707
  /**
634
708
  * OK
635
709
  */
636
- export const zAdminCancelB2bSubscriptionResponse = zCommandSuccess;
637
- export const zAdminSyncB2bInsurancePath = z.object({
710
+ export const zAdminListInsuranceResponse = zAdminReadResult;
711
+ export const zAdminRequestSubscriptionInsuranceBody = zAdminRequestId;
712
+ export const zAdminRequestSubscriptionInsurancePath = z.object({
638
713
  subscriptionId: z.string(),
639
714
  });
715
+ /**
716
+ * Accepted
717
+ */
718
+ export const zAdminRequestSubscriptionInsuranceResponse = zCommandSuccess;
719
+ export const zAdminRefreshSubscriptionBody = zAdminRequestId;
720
+ export const zAdminRefreshSubscriptionPath = z.object({
721
+ subscriptionId: z.string(),
722
+ });
723
+ /**
724
+ * Accepted
725
+ */
726
+ export const zAdminRefreshSubscriptionResponse = zCommandSuccess;
727
+ export const zAdminListFavoritesQuery = z.object({
728
+ cursor: z.string().optional(),
729
+ });
640
730
  /**
641
731
  * OK
642
732
  */
643
- export const zAdminSyncB2bInsuranceResponse = zCommandSuccess;
733
+ export const zAdminListFavoritesResponse = zAdminReadResult;
734
+ export const zAdminDeleteFavoritePath = z.object({
735
+ trackerId: z
736
+ .string()
737
+ .length(32)
738
+ .regex(/^[a-f0-9]{32}$/),
739
+ });
644
740
  /**
645
741
  * OK
646
742
  */
647
- export const zAdminSyncAllB2bInsuranceResponse = zCommandSuccess;
648
- export const zAdminSubscribeTrackerPath = z.object({
743
+ export const zAdminDeleteFavoriteResponse = zCommandSuccess;
744
+ export const zAdminGetFavoritePath = z.object({
649
745
  trackerId: z
650
746
  .string()
651
- .min(1)
652
- .max(128)
653
- .regex(/^[A-Za-z0-9_-]+$/),
747
+ .length(32)
748
+ .regex(/^[a-f0-9]{32}$/),
654
749
  });
655
750
  /**
656
751
  * OK
657
752
  */
658
- export const zAdminSubscribeTrackerResponse = zAdminTrackerView.nullable();
753
+ export const zAdminGetFavoriteResponse = zAdminReadResult;
754
+ export const zAdminUpdateFavoriteCommentBody = zAdminFavoriteRequest;
755
+ export const zAdminUpdateFavoriteCommentPath = z.object({
756
+ trackerId: z
757
+ .string()
758
+ .length(32)
759
+ .regex(/^[a-f0-9]{32}$/),
760
+ });
761
+ /**
762
+ * OK
763
+ */
764
+ export const zAdminUpdateFavoriteCommentResponse = zCommandSuccess;
765
+ export const zAdminPutFavoriteBody = zAdminFavoriteRequest;
766
+ export const zAdminPutFavoritePath = z.object({
767
+ trackerId: z
768
+ .string()
769
+ .length(32)
770
+ .regex(/^[a-f0-9]{32}$/),
771
+ });
772
+ /**
773
+ * OK
774
+ */
775
+ export const zAdminPutFavoriteResponse = zCommandSuccess;
776
+ export const zAdminCreateB2bSubscriptionBody = zAdminB2bSubscriptionRequest;
777
+ /**
778
+ * Created
779
+ */
780
+ export const zAdminCreateB2bSubscriptionResponse = zAdminB2bSubscriptionResult;
781
+ export const zAdminCancelB2bSubscriptionPath = z.object({
782
+ subscriptionId: z.string(),
783
+ });
784
+ /**
785
+ * OK
786
+ */
787
+ export const zAdminCancelB2bSubscriptionResponse = zCommandSuccess;
788
+ export const zAdminSyncB2bInsurancePath = z.object({
789
+ subscriptionId: z.string(),
790
+ });
791
+ /**
792
+ * Accepted
793
+ */
794
+ export const zAdminSyncB2bInsuranceResponse = zCommandSuccess;
795
+ /**
796
+ * Accepted
797
+ */
798
+ export const zAdminSyncAllB2bInsuranceResponse = zCommandSuccess;
659
799
  //# sourceMappingURL=zod.gen.js.map