@driveflux/api-functions 1.0.151 → 1.0.153

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.
@@ -21,8 +21,8 @@ declare const SendVerificationSMSBody: z.ZodObject<{
21
21
  }, z.core.$strip>;
22
22
  declare const VerifyOtpBody: z.ZodObject<{
23
23
  scope: z.ZodEnum<{
24
- "verify-phone": "verify-phone";
25
24
  "verify-email": "verify-email";
25
+ "verify-phone": "verify-phone";
26
26
  }>;
27
27
  email: z.ZodPipe<z.ZodOptional<z.ZodEmail>, z.ZodTransform<string | undefined, string | undefined>>;
28
28
  phoneNumber: z.ZodOptional<z.ZodString>;
@@ -9,13 +9,13 @@ type VerifyTokenOptions = {
9
9
  };
10
10
  export declare const createToken: (userId: string | null, type: "email" | "phoneNumber", value: string, providedExpiresAt?: Date) => Promise<{
11
11
  object: import("@driveflux/db").TokenObject;
12
- value: string | null;
13
12
  id: string;
13
+ metadata: PrismaJson.AnyMetadata | null;
14
14
  createdAt: Date;
15
15
  updatedAt: Date;
16
- metadata: PrismaJson.AnyMetadata | null;
17
- client: string | null;
18
16
  userId: string | null;
17
+ value: string | null;
18
+ client: string | null;
19
19
  identifier: string | null;
20
20
  expiresAt: Date | null;
21
21
  redirectUrl: string | null;
@@ -25,13 +25,13 @@ export declare const createToken: (userId: string | null, type: "email" | "phone
25
25
  } | undefined>;
26
26
  export declare const createEmailToken: (userId: string, email: string) => Promise<{
27
27
  object: import("@driveflux/db").TokenObject;
28
- value: string | null;
29
28
  id: string;
29
+ metadata: PrismaJson.AnyMetadata | null;
30
30
  createdAt: Date;
31
31
  updatedAt: Date;
32
- metadata: PrismaJson.AnyMetadata | null;
33
- client: string | null;
34
32
  userId: string | null;
33
+ value: string | null;
34
+ client: string | null;
35
35
  identifier: string | null;
36
36
  expiresAt: Date | null;
37
37
  redirectUrl: string | null;
@@ -41,13 +41,13 @@ export declare const createEmailToken: (userId: string, email: string) => Promis
41
41
  } | undefined>;
42
42
  export declare const createSMSToken: (userId: string | null, phoneNumber: string) => Promise<{
43
43
  object: import("@driveflux/db").TokenObject;
44
- value: string | null;
45
44
  id: string;
45
+ metadata: PrismaJson.AnyMetadata | null;
46
46
  createdAt: Date;
47
47
  updatedAt: Date;
48
- metadata: PrismaJson.AnyMetadata | null;
49
- client: string | null;
50
48
  userId: string | null;
49
+ value: string | null;
50
+ client: string | null;
51
51
  identifier: string | null;
52
52
  expiresAt: Date | null;
53
53
  redirectUrl: string | null;
@@ -3,5 +3,5 @@ export type ResponseBase<T> = {
3
3
  Data?: T[];
4
4
  Total?: number;
5
5
  };
6
- export declare const callMailjet: <T>(path: string, data: any, method?: string) => Promise<import("@driveflux/fetch").EnhandedFetchResult<T, import("@driveflux/problem").Problem>>;
6
+ export declare const callMailjet: <T>(path: string, data: any, method?: string) => Promise<import("@driveflux/fetch").EnhandedFetchResult<T, import("../../../../../packages/problem/dist").Problem>>;
7
7
  //# sourceMappingURL=request-service.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"request-service.d.ts","sourceRoot":"","sources":["../../../src/mailjet/calls/request-service.ts"],"names":[],"mappings":"AAGA,MAAM,MAAM,YAAY,CAAC,CAAC,IAAI;IAC7B,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,IAAI,CAAC,EAAE,CAAC,EAAE,CAAA;IACV,KAAK,CAAC,EAAE,MAAM,CAAA;CACd,CAAA;AAgBD,eAAO,MAAM,WAAW,GAAU,CAAC,EAClC,MAAM,MAAM,EACZ,MAAM,GAAG,EACT,eAAe,qGAaf,CAAA"}
1
+ {"version":3,"file":"request-service.d.ts","sourceRoot":"","sources":["../../../src/mailjet/calls/request-service.ts"],"names":[],"mappings":"AAGA,MAAM,MAAM,YAAY,CAAC,CAAC,IAAI;IAC7B,KAAK,CAAC,EAAE,MAAM,CAAA;IACd,IAAI,CAAC,EAAE,CAAC,EAAE,CAAA;IACV,KAAK,CAAC,EAAE,MAAM,CAAA;CACd,CAAA;AAgBD,eAAO,MAAM,WAAW,GAAU,CAAC,EAClC,MAAM,MAAM,EACZ,MAAM,GAAG,EACT,eAAe,uHAaf,CAAA"}
@@ -64,22 +64,22 @@ export declare const notionRichTextSchema: z.ZodObject<{
64
64
  color: z.ZodEnum<{
65
65
  default: "default";
66
66
  blue: "blue";
67
- blue_background: "blue_background";
68
67
  brown: "brown";
69
- brown_background: "brown_background";
70
68
  gray: "gray";
71
- gray_background: "gray_background";
72
69
  green: "green";
73
- green_background: "green_background";
74
70
  orange: "orange";
75
- orange_background: "orange_background";
76
71
  pink: "pink";
77
- pink_background: "pink_background";
78
72
  purple: "purple";
79
- purple_background: "purple_background";
80
73
  red: "red";
81
- red_background: "red_background";
82
74
  yellow: "yellow";
75
+ blue_background: "blue_background";
76
+ brown_background: "brown_background";
77
+ gray_background: "gray_background";
78
+ green_background: "green_background";
79
+ orange_background: "orange_background";
80
+ pink_background: "pink_background";
81
+ purple_background: "purple_background";
82
+ red_background: "red_background";
83
83
  yellow_background: "yellow_background";
84
84
  }>;
85
85
  }, z.core.$strip>;
@@ -190,8 +190,8 @@ export declare const notionDatabasePropertyRollupSchema: ZodObject<{
190
190
  type: z.ZodEnum<{
191
191
  number: "number";
192
192
  date: "date";
193
- array: "array";
194
193
  incomplete: "incomplete";
194
+ array: "array";
195
195
  unsupported: "unsupported";
196
196
  }>;
197
197
  }, z.core.$strip>;
@@ -364,22 +364,22 @@ export declare const notionDatabaseSchema: <T extends ZodObject<any>>(properties
364
364
  color: z.ZodEnum<{
365
365
  default: "default";
366
366
  blue: "blue";
367
- blue_background: "blue_background";
368
367
  brown: "brown";
369
- brown_background: "brown_background";
370
368
  gray: "gray";
371
- gray_background: "gray_background";
372
369
  green: "green";
373
- green_background: "green_background";
374
370
  orange: "orange";
375
- orange_background: "orange_background";
376
371
  pink: "pink";
377
- pink_background: "pink_background";
378
372
  purple: "purple";
379
- purple_background: "purple_background";
380
373
  red: "red";
381
- red_background: "red_background";
382
374
  yellow: "yellow";
375
+ blue_background: "blue_background";
376
+ brown_background: "brown_background";
377
+ gray_background: "gray_background";
378
+ green_background: "green_background";
379
+ orange_background: "orange_background";
380
+ pink_background: "pink_background";
381
+ purple_background: "purple_background";
382
+ red_background: "red_background";
383
383
  yellow_background: "yellow_background";
384
384
  }>;
385
385
  }, z.core.$strip>;
@@ -451,22 +451,22 @@ export declare const notionDatabaseSchema: <T extends ZodObject<any>>(properties
451
451
  color: z.ZodEnum<{
452
452
  default: "default";
453
453
  blue: "blue";
454
- blue_background: "blue_background";
455
454
  brown: "brown";
456
- brown_background: "brown_background";
457
455
  gray: "gray";
458
- gray_background: "gray_background";
459
456
  green: "green";
460
- green_background: "green_background";
461
457
  orange: "orange";
462
- orange_background: "orange_background";
463
458
  pink: "pink";
464
- pink_background: "pink_background";
465
459
  purple: "purple";
466
- purple_background: "purple_background";
467
460
  red: "red";
468
- red_background: "red_background";
469
461
  yellow: "yellow";
462
+ blue_background: "blue_background";
463
+ brown_background: "brown_background";
464
+ gray_background: "gray_background";
465
+ green_background: "green_background";
466
+ orange_background: "orange_background";
467
+ pink_background: "pink_background";
468
+ purple_background: "purple_background";
469
+ red_background: "red_background";
470
470
  yellow_background: "yellow_background";
471
471
  }>;
472
472
  }, z.core.$strip>;
@@ -475,8 +475,8 @@ export declare const notionDatabaseSchema: <T extends ZodObject<any>>(properties
475
475
  }, z.core.$strip>>;
476
476
  icon: z.ZodUnion<[ZodObject<{
477
477
  type: z.ZodEnum<{
478
- file: "file";
479
478
  external: "external";
479
+ file: "file";
480
480
  }>;
481
481
  name: z.ZodOptional<z.ZodString>;
482
482
  file: z.ZodOptional<ZodObject<{
@@ -492,8 +492,8 @@ export declare const notionDatabaseSchema: <T extends ZodObject<any>>(properties
492
492
  }, z.core.$strip>]>;
493
493
  cover: z.ZodNullable<ZodObject<{
494
494
  type: z.ZodEnum<{
495
- file: "file";
496
495
  external: "external";
496
+ file: "file";
497
497
  }>;
498
498
  name: z.ZodOptional<z.ZodString>;
499
499
  file: z.ZodOptional<ZodObject<{
@@ -77,22 +77,22 @@ export declare const knowledgeBaseRetrieveDatabaseSchema: z.ZodObject<{
77
77
  color: z.ZodEnum<{
78
78
  default: "default";
79
79
  blue: "blue";
80
- blue_background: "blue_background";
81
80
  brown: "brown";
82
- brown_background: "brown_background";
83
81
  gray: "gray";
84
- gray_background: "gray_background";
85
82
  green: "green";
86
- green_background: "green_background";
87
83
  orange: "orange";
88
- orange_background: "orange_background";
89
84
  pink: "pink";
90
- pink_background: "pink_background";
91
85
  purple: "purple";
92
- purple_background: "purple_background";
93
86
  red: "red";
94
- red_background: "red_background";
95
87
  yellow: "yellow";
88
+ blue_background: "blue_background";
89
+ brown_background: "brown_background";
90
+ gray_background: "gray_background";
91
+ green_background: "green_background";
92
+ orange_background: "orange_background";
93
+ pink_background: "pink_background";
94
+ purple_background: "purple_background";
95
+ red_background: "red_background";
96
96
  yellow_background: "yellow_background";
97
97
  }>;
98
98
  }, z.core.$strip>;
@@ -164,22 +164,22 @@ export declare const knowledgeBaseRetrieveDatabaseSchema: z.ZodObject<{
164
164
  color: z.ZodEnum<{
165
165
  default: "default";
166
166
  blue: "blue";
167
- blue_background: "blue_background";
168
167
  brown: "brown";
169
- brown_background: "brown_background";
170
168
  gray: "gray";
171
- gray_background: "gray_background";
172
169
  green: "green";
173
- green_background: "green_background";
174
170
  orange: "orange";
175
- orange_background: "orange_background";
176
171
  pink: "pink";
177
- pink_background: "pink_background";
178
172
  purple: "purple";
179
- purple_background: "purple_background";
180
173
  red: "red";
181
- red_background: "red_background";
182
174
  yellow: "yellow";
175
+ blue_background: "blue_background";
176
+ brown_background: "brown_background";
177
+ gray_background: "gray_background";
178
+ green_background: "green_background";
179
+ orange_background: "orange_background";
180
+ pink_background: "pink_background";
181
+ purple_background: "purple_background";
182
+ red_background: "red_background";
183
183
  yellow_background: "yellow_background";
184
184
  }>;
185
185
  }, z.core.$strip>;
@@ -188,8 +188,8 @@ export declare const knowledgeBaseRetrieveDatabaseSchema: z.ZodObject<{
188
188
  }, z.core.$strip>>;
189
189
  icon: z.ZodUnion<[z.ZodObject<{
190
190
  type: z.ZodEnum<{
191
- file: "file";
192
191
  external: "external";
192
+ file: "file";
193
193
  }>;
194
194
  name: z.ZodOptional<z.ZodString>;
195
195
  file: z.ZodOptional<z.ZodObject<{
@@ -205,8 +205,8 @@ export declare const knowledgeBaseRetrieveDatabaseSchema: z.ZodObject<{
205
205
  }, z.core.$strip>]>;
206
206
  cover: z.ZodNullable<z.ZodObject<{
207
207
  type: z.ZodEnum<{
208
- file: "file";
209
208
  external: "external";
209
+ file: "file";
210
210
  }>;
211
211
  name: z.ZodOptional<z.ZodString>;
212
212
  file: z.ZodOptional<z.ZodObject<{
@@ -611,8 +611,8 @@ export declare const knowledgeBaseRetrievePageSchema: z.ZodObject<{
611
611
  archived: z.ZodBoolean;
612
612
  icon: z.ZodNullable<z.ZodUnion<[z.ZodObject<{
613
613
  type: z.ZodEnum<{
614
- file: "file";
615
614
  external: "external";
615
+ file: "file";
616
616
  }>;
617
617
  name: z.ZodOptional<z.ZodString>;
618
618
  file: z.ZodOptional<z.ZodObject<{
@@ -693,22 +693,22 @@ export declare const knowledgeBaseRetrievePageSchema: z.ZodObject<{
693
693
  color: z.ZodEnum<{
694
694
  default: "default";
695
695
  blue: "blue";
696
- blue_background: "blue_background";
697
696
  brown: "brown";
698
- brown_background: "brown_background";
699
697
  gray: "gray";
700
- gray_background: "gray_background";
701
698
  green: "green";
702
- green_background: "green_background";
703
699
  orange: "orange";
704
- orange_background: "orange_background";
705
700
  pink: "pink";
706
- pink_background: "pink_background";
707
701
  purple: "purple";
708
- purple_background: "purple_background";
709
702
  red: "red";
710
- red_background: "red_background";
711
703
  yellow: "yellow";
704
+ blue_background: "blue_background";
705
+ brown_background: "brown_background";
706
+ gray_background: "gray_background";
707
+ green_background: "green_background";
708
+ orange_background: "orange_background";
709
+ pink_background: "pink_background";
710
+ purple_background: "purple_background";
711
+ red_background: "red_background";
712
712
  yellow_background: "yellow_background";
713
713
  }>;
714
714
  }, z.core.$strip>;
@@ -785,22 +785,22 @@ export declare const knowledgeBaseRetrievePageSchema: z.ZodObject<{
785
785
  color: z.ZodEnum<{
786
786
  default: "default";
787
787
  blue: "blue";
788
- blue_background: "blue_background";
789
788
  brown: "brown";
790
- brown_background: "brown_background";
791
789
  gray: "gray";
792
- gray_background: "gray_background";
793
790
  green: "green";
794
- green_background: "green_background";
795
791
  orange: "orange";
796
- orange_background: "orange_background";
797
792
  pink: "pink";
798
- pink_background: "pink_background";
799
793
  purple: "purple";
800
- purple_background: "purple_background";
801
794
  red: "red";
802
- red_background: "red_background";
803
795
  yellow: "yellow";
796
+ blue_background: "blue_background";
797
+ brown_background: "brown_background";
798
+ gray_background: "gray_background";
799
+ green_background: "green_background";
800
+ orange_background: "orange_background";
801
+ pink_background: "pink_background";
802
+ purple_background: "purple_background";
803
+ red_background: "red_background";
804
804
  yellow_background: "yellow_background";
805
805
  }>;
806
806
  }, z.core.$strip>;
@@ -1123,8 +1123,8 @@ export declare const knowledgeBaseQueryDatabaseSchema: z.ZodObject<{
1123
1123
  archived: z.ZodBoolean;
1124
1124
  icon: z.ZodNullable<z.ZodUnion<[z.ZodObject<{
1125
1125
  type: z.ZodEnum<{
1126
- file: "file";
1127
1126
  external: "external";
1127
+ file: "file";
1128
1128
  }>;
1129
1129
  name: z.ZodOptional<z.ZodString>;
1130
1130
  file: z.ZodOptional<z.ZodObject<{
@@ -1205,22 +1205,22 @@ export declare const knowledgeBaseQueryDatabaseSchema: z.ZodObject<{
1205
1205
  color: z.ZodEnum<{
1206
1206
  default: "default";
1207
1207
  blue: "blue";
1208
- blue_background: "blue_background";
1209
1208
  brown: "brown";
1210
- brown_background: "brown_background";
1211
1209
  gray: "gray";
1212
- gray_background: "gray_background";
1213
1210
  green: "green";
1214
- green_background: "green_background";
1215
1211
  orange: "orange";
1216
- orange_background: "orange_background";
1217
1212
  pink: "pink";
1218
- pink_background: "pink_background";
1219
1213
  purple: "purple";
1220
- purple_background: "purple_background";
1221
1214
  red: "red";
1222
- red_background: "red_background";
1223
1215
  yellow: "yellow";
1216
+ blue_background: "blue_background";
1217
+ brown_background: "brown_background";
1218
+ gray_background: "gray_background";
1219
+ green_background: "green_background";
1220
+ orange_background: "orange_background";
1221
+ pink_background: "pink_background";
1222
+ purple_background: "purple_background";
1223
+ red_background: "red_background";
1224
1224
  yellow_background: "yellow_background";
1225
1225
  }>;
1226
1226
  }, z.core.$strip>;
@@ -58,8 +58,8 @@ export declare const notionPagePropertyEmailSchema: ZodObject<{
58
58
  export declare const notionPagePropertyFilesSchema: ZodObject<{
59
59
  files: z.ZodArray<ZodObject<{
60
60
  type: z.ZodEnum<{
61
- file: "file";
62
61
  external: "external";
62
+ file: "file";
63
63
  }>;
64
64
  name: z.ZodOptional<z.ZodString>;
65
65
  file: z.ZodOptional<ZodObject<{
@@ -231,8 +231,8 @@ export declare const notionPagePropertyRollupSchema: ZodObject<{
231
231
  type: z.ZodEnum<{
232
232
  number: "number";
233
233
  date: "date";
234
- array: "array";
235
234
  incomplete: "incomplete";
235
+ array: "array";
236
236
  unsupported: "unsupported";
237
237
  }>;
238
238
  }, z.core.$strip>;
@@ -306,22 +306,22 @@ export declare const notionPagePropertyRichTextSchema: ZodObject<{
306
306
  color: z.ZodEnum<{
307
307
  default: "default";
308
308
  blue: "blue";
309
- blue_background: "blue_background";
310
309
  brown: "brown";
311
- brown_background: "brown_background";
312
310
  gray: "gray";
313
- gray_background: "gray_background";
314
311
  green: "green";
315
- green_background: "green_background";
316
312
  orange: "orange";
317
- orange_background: "orange_background";
318
313
  pink: "pink";
319
- pink_background: "pink_background";
320
314
  purple: "purple";
321
- purple_background: "purple_background";
322
315
  red: "red";
323
- red_background: "red_background";
324
316
  yellow: "yellow";
317
+ blue_background: "blue_background";
318
+ brown_background: "brown_background";
319
+ gray_background: "gray_background";
320
+ green_background: "green_background";
321
+ orange_background: "orange_background";
322
+ pink_background: "pink_background";
323
+ purple_background: "purple_background";
324
+ red_background: "red_background";
325
325
  yellow_background: "yellow_background";
326
326
  }>;
327
327
  }, z.core.$strip>;
@@ -440,22 +440,22 @@ export declare const notionPagePropertyTitleSchema: ZodObject<{
440
440
  color: z.ZodEnum<{
441
441
  default: "default";
442
442
  blue: "blue";
443
- blue_background: "blue_background";
444
443
  brown: "brown";
445
- brown_background: "brown_background";
446
444
  gray: "gray";
447
- gray_background: "gray_background";
448
445
  green: "green";
449
- green_background: "green_background";
450
446
  orange: "orange";
451
- orange_background: "orange_background";
452
447
  pink: "pink";
453
- pink_background: "pink_background";
454
448
  purple: "purple";
455
- purple_background: "purple_background";
456
449
  red: "red";
457
- red_background: "red_background";
458
450
  yellow: "yellow";
451
+ blue_background: "blue_background";
452
+ brown_background: "brown_background";
453
+ gray_background: "gray_background";
454
+ green_background: "green_background";
455
+ orange_background: "orange_background";
456
+ pink_background: "pink_background";
457
+ purple_background: "purple_background";
458
+ red_background: "red_background";
459
459
  yellow_background: "yellow_background";
460
460
  }>;
461
461
  }, z.core.$strip>;
@@ -536,8 +536,8 @@ export declare const notionPageSchema: <T extends ZodObject<any>>(properties: T)
536
536
  archived: z.ZodBoolean;
537
537
  icon: z.ZodNullable<z.ZodUnion<[ZodObject<{
538
538
  type: z.ZodEnum<{
539
- file: "file";
540
539
  external: "external";
540
+ file: "file";
541
541
  }>;
542
542
  name: z.ZodOptional<z.ZodString>;
543
543
  file: z.ZodOptional<ZodObject<{
@@ -581,8 +581,8 @@ export declare const notionPagesSchema: <T extends ZodObject<any>>(properties: T
581
581
  archived: z.ZodBoolean;
582
582
  icon: z.ZodNullable<z.ZodUnion<[ZodObject<{
583
583
  type: z.ZodEnum<{
584
- file: "file";
585
584
  external: "external";
585
+ file: "file";
586
586
  }>;
587
587
  name: z.ZodOptional<z.ZodString>;
588
588
  file: z.ZodOptional<ZodObject<{
@@ -1,7 +1,6 @@
1
1
  import { type DisplayVehicle, type MileagePackage, type PlanType, type UltraTier, type Vehicle, type VehicleType } from '@driveflux/db';
2
2
  export declare const fetchDisplayVehicle: (displayVehicle: DisplayVehicle | string) => Promise<{
3
3
  object: import("@driveflux/db").DisplayVehicleObject;
4
- type: VehicleType;
5
4
  id: string;
6
5
  createdAt: Date;
7
6
  updatedAt: Date;
@@ -10,6 +9,7 @@ export declare const fetchDisplayVehicle: (displayVehicle: DisplayVehicle | stri
10
9
  vehicleModel: string;
11
10
  variant: string;
12
11
  year: number;
12
+ type: VehicleType;
13
13
  brandSlug: string;
14
14
  brandId: string;
15
15
  defaultHostId: string;
@@ -198,24 +198,24 @@ export declare const fetchDisplayVehicle: (displayVehicle: DisplayVehicle | stri
198
198
  export declare const createVehicleFromDisplayVehicle: (displayVehicle: DisplayVehicle | string, selectedColor?: string) => Promise<({
199
199
  host: {
200
200
  object: import("@driveflux/db").HostObject;
201
- type: import("@driveflux/db").HostType | null;
202
201
  name: string;
203
- email: string | null;
204
- phoneNumber: string | null;
205
202
  id: string;
203
+ metadata: PrismaJson.AnyMetadata | null;
206
204
  createdAt: Date;
207
205
  updatedAt: Date;
208
- metadata: PrismaJson.AnyMetadata | null;
206
+ registrationNumber: string | null;
207
+ type: import("@driveflux/db").HostType | null;
208
+ active: boolean;
209
+ email: string | null;
210
+ phoneNumber: string | null;
209
211
  race: import("@driveflux/db").Race | null;
210
212
  emergencyContactName: string | null;
211
213
  emergencyPhoneNumber: string | null;
212
214
  companyName: string | null;
213
- active: boolean;
215
+ faxNumber: string | null;
214
216
  sstNumber: string | null;
215
217
  tinNumber: string | null;
216
218
  commencementDate: Date | null;
217
- registrationNumber: string | null;
218
- faxNumber: string | null;
219
219
  stripeAccountId: string | null;
220
220
  isStripeConnected: boolean;
221
221
  serviceCenterIds: string[];
@@ -275,15 +275,11 @@ export declare const createVehicleFromDisplayVehicle: (displayVehicle: DisplayVe
275
275
  };
276
276
  } & {
277
277
  object: import("@driveflux/db").VehicleObject;
278
- type: VehicleType;
279
278
  id: string;
279
+ status: import("@driveflux/db").VehicleStatus;
280
+ metadata: PrismaJson.AnyMetadata | null;
280
281
  createdAt: Date;
281
282
  updatedAt: Date;
282
- metadata: PrismaJson.AnyMetadata | null;
283
- hostId: string;
284
- status: import("@driveflux/db").VehicleStatus;
285
- temporary: boolean;
286
- registrationNumber: string | null;
287
283
  make: string;
288
284
  vehicleModel: string;
289
285
  variant: string;
@@ -295,6 +291,7 @@ export declare const createVehicleFromDisplayVehicle: (displayVehicle: DisplayVe
295
291
  lastSearchIndexedAt: Date | null;
296
292
  registrationDate: Date | null;
297
293
  mileage: number | null;
294
+ registrationNumber: string | null;
298
295
  vin: string | null;
299
296
  engineNumber: string | null;
300
297
  availability: import("@driveflux/db").VehicleAvailablity | null;
@@ -309,6 +306,8 @@ export declare const createVehicleFromDisplayVehicle: (displayVehicle: DisplayVe
309
306
  delistedAt: Date | null;
310
307
  imagesNotActual: boolean;
311
308
  imagesNotActualMessage: string | null;
309
+ hostId: string;
310
+ type: VehicleType;
312
311
  allowedServiceCenterIds: string[];
313
312
  displayVehicleId: string | null;
314
313
  isHostConfirmed: boolean | null;
@@ -321,6 +320,7 @@ export declare const createVehicleFromDisplayVehicle: (displayVehicle: DisplayVe
321
320
  featureOnLandingPage: boolean;
322
321
  lastMileageRecordedAt: Date | null;
323
322
  locationAvailability: string[];
323
+ temporary: boolean;
324
324
  hotDeal: boolean | null;
325
325
  activeSubscriptionId: string | null;
326
326
  addresses: {
@@ -704,15 +704,11 @@ export declare const createVehicleFromDisplayVehicle: (displayVehicle: DisplayVe
704
704
  }) | undefined>;
705
705
  export declare const transfromVehicleDisplayToVehicle: (displayVehicle: DisplayVehicle | string, selectedColor: string) => Promise<({
706
706
  object: import("@driveflux/db").VehicleObject;
707
- type: VehicleType;
708
707
  id: string;
708
+ status: import("@driveflux/db").VehicleStatus;
709
+ metadata: PrismaJson.AnyMetadata | null;
709
710
  createdAt: Date;
710
711
  updatedAt: Date;
711
- metadata: PrismaJson.AnyMetadata | null;
712
- hostId: string;
713
- status: import("@driveflux/db").VehicleStatus;
714
- temporary: boolean;
715
- registrationNumber: string | null;
716
712
  make: string;
717
713
  vehicleModel: string;
718
714
  variant: string;
@@ -724,6 +720,7 @@ export declare const transfromVehicleDisplayToVehicle: (displayVehicle: DisplayV
724
720
  lastSearchIndexedAt: Date | null;
725
721
  registrationDate: Date | null;
726
722
  mileage: number | null;
723
+ registrationNumber: string | null;
727
724
  vin: string | null;
728
725
  engineNumber: string | null;
729
726
  availability: import("@driveflux/db").VehicleAvailablity | null;
@@ -738,6 +735,8 @@ export declare const transfromVehicleDisplayToVehicle: (displayVehicle: DisplayV
738
735
  delistedAt: Date | null;
739
736
  imagesNotActual: boolean;
740
737
  imagesNotActualMessage: string | null;
738
+ hostId: string;
739
+ type: VehicleType;
741
740
  allowedServiceCenterIds: string[];
742
741
  displayVehicleId: string | null;
743
742
  isHostConfirmed: boolean | null;
@@ -750,6 +749,7 @@ export declare const transfromVehicleDisplayToVehicle: (displayVehicle: DisplayV
750
749
  featureOnLandingPage: boolean;
751
750
  lastMileageRecordedAt: Date | null;
752
751
  locationAvailability: string[];
752
+ temporary: boolean;
753
753
  hotDeal: boolean | null;
754
754
  activeSubscriptionId: string | null;
755
755
  addresses: {
package/dist/slack.d.ts CHANGED
@@ -6,7 +6,7 @@ declare global {
6
6
  *
7
7
  * @deprecated Use slackLater instead and commitSlack to commit
8
8
  */
9
- export declare const slack: (message: string, channel?: string) => Promise<import("@driveflux/fetch").EnhandedFetchResult<object, import("@driveflux/problem").Problem>>;
9
+ export declare const slack: (message: string, channel?: string) => Promise<import("@driveflux/fetch").EnhandedFetchResult<object, import("../../../packages/problem/dist/index.js").Problem>>;
10
10
  export declare const getSlackBlocks: (channel?: string) => Set<KnownBlock> | Map<string, Set<KnownBlock>> | undefined;
11
11
  /**
12
12
  * Naive implementation, however, for now (uncrowded serverless env), this works
@@ -14,6 +14,6 @@ export declare const getSlackBlocks: (channel?: string) => Set<KnownBlock> | Map
14
14
  * @param channel
15
15
  */
16
16
  export declare function slackLater(blocks: string | KnownBlock | KnownBlock[], channel?: string): void;
17
- export declare function sendSlackMessages(channel: string, blocks: KnownBlock[]): Promise<import("@driveflux/fetch").EnhandedFetchResult<object, import("@driveflux/problem").Problem>>;
17
+ export declare function sendSlackMessages(channel: string, blocks: KnownBlock[]): Promise<import("@driveflux/fetch").EnhandedFetchResult<object, import("../../../packages/problem/dist/index.js").Problem>>;
18
18
  export declare const commitSlack: () => void;
19
19
  //# sourceMappingURL=slack.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"slack.d.ts","sourceRoot":"","sources":["../src/slack.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,cAAc,CAAA;AAI9C,OAAO,CAAC,MAAM,CAAC;IAEd,IAAI,aAAa,EAAE,GAAG,CAAC,MAAM,EAAE,GAAG,CAAC,UAAU,CAAC,CAAC,CAAA;CAC/C;AAOD;;;GAGG;AACH,eAAO,MAAM,KAAK,GACjB,SAAS,MAAM,EACf,gBAAuC,0GAoBvC,CAAA;AAED,eAAO,MAAM,cAAc,GAAI,UAAU,MAAM,+DACE,CAAA;AAEjD;;;;GAIG;AAEH,wBAAgB,UAAU,CACzB,MAAM,EAAE,MAAM,GAAG,UAAU,GAAG,UAAU,EAAE,EAC1C,OAAO,CAAC,EAAE,MAAM,GACd,IAAI,CA4BN;AAED,wBAAsB,iBAAiB,CAAC,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,UAAU,EAAE,yGAc5E;AAED,eAAO,MAAM,WAAW,YA0BvB,CAAA"}
1
+ {"version":3,"file":"slack.d.ts","sourceRoot":"","sources":["../src/slack.ts"],"names":[],"mappings":"AAGA,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,cAAc,CAAA;AAI9C,OAAO,CAAC,MAAM,CAAC;IAEd,IAAI,aAAa,EAAE,GAAG,CAAC,MAAM,EAAE,GAAG,CAAC,UAAU,CAAC,CAAC,CAAA;CAC/C;AAOD;;;GAGG;AACH,eAAO,MAAM,KAAK,GACjB,SAAS,MAAM,EACf,gBAAuC,+HAoBvC,CAAA;AAED,eAAO,MAAM,cAAc,GAAI,UAAU,MAAM,+DACE,CAAA;AAEjD;;;;GAIG;AAEH,wBAAgB,UAAU,CACzB,MAAM,EAAE,MAAM,GAAG,UAAU,GAAG,UAAU,EAAE,EAC1C,OAAO,CAAC,EAAE,MAAM,GACd,IAAI,CA4BN;AAED,wBAAsB,iBAAiB,CAAC,OAAO,EAAE,MAAM,EAAE,MAAM,EAAE,UAAU,EAAE,8HAc5E;AAED,eAAO,MAAM,WAAW,YA0BvB,CAAA"}
@@ -1,16 +1,16 @@
1
1
  import { type StandardResult } from '@driveflux/result';
2
- import { z, type ZodArray, type ZodCodec, type ZodDate, type ZodEnum, type ZodError, type ZodNumber, type ZodUnion } from 'zod';
2
+ import { type ZodArray, type ZodCodec, type ZodDate, type ZodEnum, type ZodError, type ZodNumber, type ZodUnion, z } from 'zod';
3
3
  export declare const makeValidationErrorResult: (zodError: ZodError<unknown>) => StandardResult<never>;
4
- export declare const getIdOrObjectValidation: <ObjectName extends string, ExtendObjectValidation extends z.ZodRawShape>(object: ObjectName, extendObjectValidation?: ExtendObjectValidation) => z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
4
+ export declare const getIdOrObjectValidation: <ObjectName extends string, ExtendObjectValidation extends z.ZodRawShape>(object: ObjectName, extendObjectValidation?: ExtendObjectValidation) => ZodUnion<readonly [z.ZodString, z.ZodObject<{
5
5
  object: z.ZodLiteral<ObjectName>;
6
6
  }, z.core.$catchall<z.ZodAny>>]>;
7
7
  export declare const nonEmptyStringValidator: z.ZodString;
8
- export declare const metadataValidation: z.ZodObject<{}, z.core.$catchall<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodArray<z.ZodString>, z.ZodArray<z.ZodNumber>, z.ZodArray<z.ZodBoolean>, z.ZodNull, z.ZodUndefined]>>>;
8
+ export declare const metadataValidation: z.ZodObject<{}, z.core.$catchall<ZodUnion<readonly [z.ZodString, ZodNumber, z.ZodBoolean, ZodArray<z.ZodString>, ZodArray<ZodNumber>, ZodArray<z.ZodBoolean>, z.ZodNull, z.ZodUndefined]>>>;
9
9
  export declare const addressValidation: z.ZodObject<{
10
10
  name: z.ZodNullable<z.ZodOptional<z.ZodString>>;
11
11
  coordinates: z.ZodOptional<z.ZodNullable<z.ZodObject<{
12
- lat: z.ZodNumber;
13
- lng: z.ZodNumber;
12
+ lat: ZodNumber;
13
+ lng: ZodNumber;
14
14
  }, z.core.$strip>>>;
15
15
  street1: z.ZodString;
16
16
  street2: z.ZodOptional<z.ZodNullable<z.ZodString>>;
@@ -19,8 +19,8 @@ export declare const addressValidation: z.ZodObject<{
19
19
  postalCode: z.ZodString;
20
20
  country: z.ZodString;
21
21
  }, z.core.$strip>;
22
- export declare const getIsoDatetimeToDate: (dateValidation?: ZodDate) => z.ZodCodec<z.ZodString, z.ZodDate>;
23
- export declare const dateValidation: z.ZodCodec<z.ZodString, z.ZodDate>;
22
+ export declare const getIsoDatetimeToDate: (dateValidation?: ZodDate) => ZodCodec<z.ZodString, ZodDate>;
23
+ export declare const dateValidation: ZodCodec<z.ZodString, ZodDate>;
24
24
  export declare const enhancedImageValidation: z.ZodObject<{
25
25
  default: z.ZodString;
26
26
  blurBase64: z.ZodOptional<z.ZodString>;
@@ -30,7 +30,7 @@ export declare const enhancedImageValidation: z.ZodObject<{
30
30
  large: z.ZodOptional<z.ZodString>;
31
31
  description: z.ZodOptional<z.ZodString>;
32
32
  }, z.core.$strip>;
33
- export declare const getObjectValidation: <T extends string>(o: T) => z.ZodOptional<z.ZodEnum<{ [k_1 in T]: k_1; } extends infer T_1 ? { [k in keyof T_1]: T_1[k]; } : never>>;
33
+ export declare const getObjectValidation: <T extends string>(o: T) => z.ZodOptional<ZodEnum<{ [k_1 in T]: k_1; } extends infer T_1 ? { [k in keyof T_1]: T_1[k]; } : never>>;
34
34
  export declare const contactValidation: z.ZodObject<{
35
35
  id: z.ZodString;
36
36
  firstName: z.ZodString;
@@ -45,23 +45,23 @@ export declare const documentFileValidation: z.ZodObject<{
45
45
  name: z.ZodString;
46
46
  description: z.ZodOptional<z.ZodNullable<z.ZodString>>;
47
47
  url: z.ZodString;
48
- fileType: z.ZodPipe<z.ZodTransform<unknown, unknown>, z.ZodOptional<z.ZodEnum<{
48
+ fileType: z.ZodPreprocess<z.ZodOptional<ZodEnum<{
49
+ image: "image";
49
50
  jpg: "jpg";
50
51
  jpeg: "jpeg";
51
52
  png: "png";
52
53
  pdf: "pdf";
53
- image: "image";
54
54
  }>>>;
55
55
  mimeType: z.ZodOptional<z.ZodString>;
56
56
  uploaded: z.ZodDefault<z.ZodBoolean>;
57
- createdAt: z.ZodOptional<z.ZodNullable<z.ZodCodec<z.ZodString, z.ZodDate>>>;
58
- updatedAt: z.ZodOptional<z.ZodNullable<z.ZodCodec<z.ZodString, z.ZodDate>>>;
59
- metadata: z.ZodOptional<z.ZodNullable<z.ZodObject<{}, z.core.$catchall<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodArray<z.ZodString>, z.ZodArray<z.ZodNumber>, z.ZodArray<z.ZodBoolean>, z.ZodNull, z.ZodUndefined]>>>>>;
57
+ createdAt: z.ZodOptional<z.ZodNullable<ZodCodec<z.ZodString, ZodDate>>>;
58
+ updatedAt: z.ZodOptional<z.ZodNullable<ZodCodec<z.ZodString, ZodDate>>>;
59
+ metadata: z.ZodOptional<z.ZodNullable<z.ZodObject<{}, z.core.$catchall<ZodUnion<readonly [z.ZodString, ZodNumber, z.ZodBoolean, ZodArray<z.ZodString>, ZodArray<ZodNumber>, ZodArray<z.ZodBoolean>, z.ZodNull, z.ZodUndefined]>>>>>;
60
60
  }, z.core.$strip>;
61
- export declare const queryBooleanValidator: z.ZodCodec<z.ZodString, z.ZodBoolean>;
62
- export declare const getStringToNumberValidator: (numberValidation?: ZodNumber) => z.ZodCodec<z.ZodString, z.ZodNumber>;
63
- export declare const queryNumberValidator: z.ZodCodec<z.ZodString, z.ZodNumber>;
64
- export declare const queryStringArrayValidator: z.ZodUnion<[z.ZodCodec<z.ZodString, z.ZodArray<z.ZodString>>, z.ZodArray<z.ZodString>]>;
61
+ export declare const queryBooleanValidator: ZodCodec<z.ZodString, z.ZodBoolean>;
62
+ export declare const getStringToNumberValidator: (numberValidation?: ZodNumber) => ZodCodec<z.ZodString, ZodNumber>;
63
+ export declare const queryNumberValidator: ZodCodec<z.ZodString, ZodNumber>;
64
+ export declare const queryStringArrayValidator: ZodUnion<[ZodCodec<z.ZodString, ZodArray<z.ZodString>>, ZodArray<z.ZodString>]>;
65
65
  export declare function queryEnumArrayValidator<const T extends readonly string[]>(enumValue: T): ZodUnion<[
66
66
  ZodCodec<z.ZodString, ZodArray<ZodEnum<z.util.ToEnum<T[number]>>>>,
67
67
  ZodArray<ZodEnum<z.util.ToEnum<T[number]>>>
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@driveflux/api-functions",
3
- "version": "1.0.151",
3
+ "version": "1.0.153",
4
4
  "type": "module",
5
5
  "exports": {
6
6
  "./notion": {
@@ -72,42 +72,42 @@
72
72
  "dist"
73
73
  ],
74
74
  "dependencies": {
75
- "@casl/ability": "^6.7.3",
76
- "@driveflux/auth": "4.0.87",
75
+ "@casl/ability": "^6.8.1",
76
+ "@driveflux/auth": "4.0.88",
77
77
  "@driveflux/billing": "8.1.6",
78
- "@driveflux/config": "3.0.10",
78
+ "@driveflux/config": "3.0.11",
79
79
  "@driveflux/coupon": "9.1.20",
80
80
  "@driveflux/db": "4.1.19",
81
81
  "@driveflux/email": "7.1.20",
82
82
  "@driveflux/email-templates": "1.2.20",
83
- "@driveflux/engine": "1.1.42",
84
- "@driveflux/fetch": "8.0.1",
85
- "@driveflux/format-money": "7.0.0",
83
+ "@driveflux/engine": "1.1.46",
84
+ "@driveflux/fetch": "8.0.2",
85
+ "@driveflux/format-money": "7.0.1",
86
86
  "@driveflux/logger": "1.1.3",
87
- "@driveflux/problem": "6.0.1",
88
- "@driveflux/reporter": "7.0.2",
89
- "@driveflux/result": "6.0.1",
87
+ "@driveflux/problem": "6.0.2",
88
+ "@driveflux/reporter": "7.0.3",
89
+ "@driveflux/result": "6.0.2",
90
90
  "@driveflux/scheduler": "8.1.20",
91
- "@driveflux/singleton": "3.0.0",
91
+ "@driveflux/singleton": "3.0.1",
92
92
  "@driveflux/subscription": "9.1.9",
93
- "@driveflux/time": "6.0.2",
94
- "@driveflux/utils": "6.0.0",
95
- "@notionhq/client": "^5.3.0",
96
- "bcryptjs": "^3.0.2",
93
+ "@driveflux/time": "6.0.3",
94
+ "@driveflux/utils": "6.0.1",
95
+ "@notionhq/client": "^5.21.0",
96
+ "bcryptjs": "^3.0.3",
97
97
  "currency.js": "^2.0.4",
98
98
  "date-fns": "^4.1.0",
99
- "lodash": "^4.17.21",
100
- "nanoid": "^5.1.6",
101
- "zod": "^4.1.12"
99
+ "lodash": "^4.18.1",
100
+ "nanoid": "^5.1.11",
101
+ "zod": "^4.4.3"
102
102
  },
103
103
  "devDependencies": {
104
- "@driveflux/fab": "4.0.0",
105
- "@driveflux/tsconfig": "3.0.0",
106
- "@slack/types": "^2.17.0",
107
- "@types/lodash": "^4.17.20",
108
- "@types/node": "^24.9.1",
104
+ "@driveflux/fab": "4.0.1",
105
+ "@driveflux/tsconfig": "3.0.1",
106
+ "@slack/types": "^2.21.1",
107
+ "@types/lodash": "^4.17.24",
108
+ "@types/node": "^25.7.0",
109
109
  "del-cli": "^7.0.0",
110
- "typescript": "^5.9.3"
110
+ "typescript": "^6.0.3"
111
111
  },
112
112
  "scripts": {
113
113
  "build": "fab",