@driveflux/api-functions 1.0.153 → 1.0.154

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.
@@ -13,8 +13,8 @@ export declare const createToken: (userId: string | null, type: "email" | "phone
13
13
  metadata: PrismaJson.AnyMetadata | null;
14
14
  createdAt: Date;
15
15
  updatedAt: Date;
16
- userId: string | null;
17
16
  value: string | null;
17
+ userId: string | null;
18
18
  client: string | null;
19
19
  identifier: string | null;
20
20
  expiresAt: Date | null;
@@ -29,8 +29,8 @@ export declare const createEmailToken: (userId: string, email: string) => Promis
29
29
  metadata: PrismaJson.AnyMetadata | null;
30
30
  createdAt: Date;
31
31
  updatedAt: Date;
32
- userId: string | null;
33
32
  value: string | null;
33
+ userId: string | null;
34
34
  client: string | null;
35
35
  identifier: string | null;
36
36
  expiresAt: Date | null;
@@ -45,8 +45,8 @@ export declare const createSMSToken: (userId: string | null, phoneNumber: string
45
45
  metadata: PrismaJson.AnyMetadata | null;
46
46
  createdAt: Date;
47
47
  updatedAt: Date;
48
- userId: string | null;
49
48
  value: string | null;
49
+ userId: string | null;
50
50
  client: string | null;
51
51
  identifier: string | null;
52
52
  expiresAt: Date | 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("../../../../../packages/problem/dist").Problem>>;
6
+ export declare const callMailjet: <T>(path: string, data: any, method?: string) => Promise<import("@driveflux/fetch").EnhandedFetchResult<T, import("@driveflux/problem").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,uHAaf,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,qGAaf,CAAA"}
@@ -190,8 +190,8 @@ export declare const notionDatabasePropertyRollupSchema: ZodObject<{
190
190
  type: z.ZodEnum<{
191
191
  number: "number";
192
192
  date: "date";
193
- incomplete: "incomplete";
194
193
  array: "array";
194
+ incomplete: "incomplete";
195
195
  unsupported: "unsupported";
196
196
  }>;
197
197
  }, 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
- external: "external";
479
478
  file: "file";
479
+ external: "external";
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
- external: "external";
496
495
  file: "file";
496
+ external: "external";
497
497
  }>;
498
498
  name: z.ZodOptional<z.ZodString>;
499
499
  file: z.ZodOptional<ZodObject<{
@@ -1,8 +1,8 @@
1
1
  import { z } from 'zod';
2
2
  export declare const notionFileSchema: z.ZodObject<{
3
3
  type: z.ZodEnum<{
4
- external: "external";
5
4
  file: "file";
5
+ external: "external";
6
6
  }>;
7
7
  name: z.ZodOptional<z.ZodString>;
8
8
  file: z.ZodOptional<z.ZodObject<{
@@ -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
- external: "external";
192
191
  file: "file";
192
+ external: "external";
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
- external: "external";
209
208
  file: "file";
209
+ external: "external";
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
- external: "external";
615
614
  file: "file";
615
+ external: "external";
616
616
  }>;
617
617
  name: z.ZodOptional<z.ZodString>;
618
618
  file: z.ZodOptional<z.ZodObject<{
@@ -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
- external: "external";
1127
1126
  file: "file";
1127
+ external: "external";
1128
1128
  }>;
1129
1129
  name: z.ZodOptional<z.ZodString>;
1130
1130
  file: z.ZodOptional<z.ZodObject<{
@@ -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
- external: "external";
62
61
  file: "file";
62
+ external: "external";
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
- incomplete: "incomplete";
235
234
  array: "array";
235
+ incomplete: "incomplete";
236
236
  unsupported: "unsupported";
237
237
  }>;
238
238
  }, 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
- external: "external";
540
539
  file: "file";
540
+ external: "external";
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
- external: "external";
585
584
  file: "file";
585
+ external: "external";
586
586
  }>;
587
587
  name: z.ZodOptional<z.ZodString>;
588
588
  file: z.ZodOptional<ZodObject<{
@@ -1,6 +1,7 @@
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;
4
5
  id: string;
5
6
  createdAt: Date;
6
7
  updatedAt: Date;
@@ -9,7 +10,6 @@ export declare const fetchDisplayVehicle: (displayVehicle: DisplayVehicle | stri
9
10
  vehicleModel: string;
10
11
  variant: string;
11
12
  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
- name: string;
201
+ phoneNumber: string | null;
202
+ type: import("@driveflux/db").HostType | null;
202
203
  id: string;
203
204
  metadata: PrismaJson.AnyMetadata | null;
205
+ name: string;
204
206
  createdAt: Date;
205
207
  updatedAt: Date;
206
- registrationNumber: string | null;
207
- type: import("@driveflux/db").HostType | null;
208
- active: boolean;
209
208
  email: string | null;
210
- phoneNumber: string | null;
211
209
  race: import("@driveflux/db").Race | null;
212
210
  emergencyContactName: string | null;
213
211
  emergencyPhoneNumber: string | null;
214
212
  companyName: string | null;
215
- faxNumber: string | null;
213
+ active: boolean;
216
214
  sstNumber: string | null;
217
215
  tinNumber: string | null;
218
216
  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,11 +275,15 @@ export declare const createVehicleFromDisplayVehicle: (displayVehicle: DisplayVe
275
275
  };
276
276
  } & {
277
277
  object: import("@driveflux/db").VehicleObject;
278
+ type: VehicleType;
278
279
  id: string;
279
- status: import("@driveflux/db").VehicleStatus;
280
280
  metadata: PrismaJson.AnyMetadata | null;
281
281
  createdAt: Date;
282
282
  updatedAt: Date;
283
+ hostId: string;
284
+ status: import("@driveflux/db").VehicleStatus;
285
+ temporary: boolean;
286
+ registrationNumber: string | null;
283
287
  make: string;
284
288
  vehicleModel: string;
285
289
  variant: string;
@@ -291,7 +295,6 @@ export declare const createVehicleFromDisplayVehicle: (displayVehicle: DisplayVe
291
295
  lastSearchIndexedAt: Date | null;
292
296
  registrationDate: Date | null;
293
297
  mileage: number | null;
294
- registrationNumber: string | null;
295
298
  vin: string | null;
296
299
  engineNumber: string | null;
297
300
  availability: import("@driveflux/db").VehicleAvailablity | null;
@@ -306,8 +309,6 @@ export declare const createVehicleFromDisplayVehicle: (displayVehicle: DisplayVe
306
309
  delistedAt: Date | null;
307
310
  imagesNotActual: boolean;
308
311
  imagesNotActualMessage: string | null;
309
- hostId: string;
310
- type: VehicleType;
311
312
  allowedServiceCenterIds: string[];
312
313
  displayVehicleId: string | null;
313
314
  isHostConfirmed: boolean | null;
@@ -320,7 +321,6 @@ export declare const createVehicleFromDisplayVehicle: (displayVehicle: DisplayVe
320
321
  featureOnLandingPage: boolean;
321
322
  lastMileageRecordedAt: Date | null;
322
323
  locationAvailability: string[];
323
- temporary: boolean;
324
324
  hotDeal: boolean | null;
325
325
  activeSubscriptionId: string | null;
326
326
  addresses: {
@@ -704,11 +704,15 @@ 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;
707
708
  id: string;
708
- status: import("@driveflux/db").VehicleStatus;
709
709
  metadata: PrismaJson.AnyMetadata | null;
710
710
  createdAt: Date;
711
711
  updatedAt: Date;
712
+ hostId: string;
713
+ status: import("@driveflux/db").VehicleStatus;
714
+ temporary: boolean;
715
+ registrationNumber: string | null;
712
716
  make: string;
713
717
  vehicleModel: string;
714
718
  variant: string;
@@ -720,7 +724,6 @@ export declare const transfromVehicleDisplayToVehicle: (displayVehicle: DisplayV
720
724
  lastSearchIndexedAt: Date | null;
721
725
  registrationDate: Date | null;
722
726
  mileage: number | null;
723
- registrationNumber: string | null;
724
727
  vin: string | null;
725
728
  engineNumber: string | null;
726
729
  availability: import("@driveflux/db").VehicleAvailablity | null;
@@ -735,8 +738,6 @@ export declare const transfromVehicleDisplayToVehicle: (displayVehicle: DisplayV
735
738
  delistedAt: Date | null;
736
739
  imagesNotActual: boolean;
737
740
  imagesNotActualMessage: string | null;
738
- hostId: string;
739
- type: VehicleType;
740
741
  allowedServiceCenterIds: string[];
741
742
  displayVehicleId: string | null;
742
743
  isHostConfirmed: boolean | null;
@@ -749,7 +750,6 @@ export declare const transfromVehicleDisplayToVehicle: (displayVehicle: DisplayV
749
750
  featureOnLandingPage: boolean;
750
751
  lastMileageRecordedAt: Date | null;
751
752
  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("../../../packages/problem/dist/index.js").Problem>>;
9
+ export declare const slack: (message: string, channel?: string) => Promise<import("@driveflux/fetch").EnhandedFetchResult<object, import("@driveflux/problem").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("../../../packages/problem/dist/index.js").Problem>>;
17
+ export declare function sendSlackMessages(channel: string, blocks: KnownBlock[]): Promise<import("@driveflux/fetch").EnhandedFetchResult<object, import("@driveflux/problem").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,+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
+ {"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"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@driveflux/api-functions",
3
- "version": "1.0.153",
3
+ "version": "1.0.154",
4
4
  "type": "module",
5
5
  "exports": {
6
6
  "./notion": {
@@ -73,21 +73,21 @@
73
73
  ],
74
74
  "dependencies": {
75
75
  "@casl/ability": "^6.8.1",
76
- "@driveflux/auth": "4.0.88",
76
+ "@driveflux/auth": "4.0.89",
77
77
  "@driveflux/billing": "8.1.6",
78
78
  "@driveflux/config": "3.0.11",
79
- "@driveflux/coupon": "9.1.20",
80
- "@driveflux/db": "4.1.19",
81
- "@driveflux/email": "7.1.20",
82
- "@driveflux/email-templates": "1.2.20",
83
- "@driveflux/engine": "1.1.46",
79
+ "@driveflux/coupon": "9.1.21",
80
+ "@driveflux/db": "4.1.20",
81
+ "@driveflux/email": "7.1.21",
82
+ "@driveflux/email-templates": "1.2.21",
83
+ "@driveflux/engine": "1.1.49",
84
84
  "@driveflux/fetch": "8.0.2",
85
85
  "@driveflux/format-money": "7.0.1",
86
86
  "@driveflux/logger": "1.1.3",
87
87
  "@driveflux/problem": "6.0.2",
88
88
  "@driveflux/reporter": "7.0.3",
89
89
  "@driveflux/result": "6.0.2",
90
- "@driveflux/scheduler": "8.1.20",
90
+ "@driveflux/scheduler": "8.1.21",
91
91
  "@driveflux/singleton": "3.0.1",
92
92
  "@driveflux/subscription": "9.1.9",
93
93
  "@driveflux/time": "6.0.3",