@talkpilot/core-db 1.2.1 → 1.3.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 (147) hide show
  1. package/README.md +117 -108
  2. package/README_OLD.md +160 -0
  3. package/dist/municipal/tickets/index.d.ts +2 -1
  4. package/dist/municipal/tickets/index.d.ts.map +1 -1
  5. package/dist/municipal/tickets/index.js +1 -0
  6. package/dist/municipal/tickets/index.js.map +1 -1
  7. package/dist/municipal/tickets/tickets.constants.d.ts +7 -0
  8. package/dist/municipal/tickets/tickets.constants.d.ts.map +1 -0
  9. package/dist/municipal/tickets/tickets.constants.js +10 -0
  10. package/dist/municipal/tickets/tickets.constants.js.map +1 -0
  11. package/dist/municipal/tickets/tickets.deprecated.getters.d.ts +12 -0
  12. package/dist/municipal/tickets/tickets.deprecated.getters.d.ts.map +1 -0
  13. package/dist/municipal/tickets/tickets.deprecated.getters.js +131 -0
  14. package/dist/municipal/tickets/tickets.deprecated.getters.js.map +1 -0
  15. package/dist/municipal/tickets/tickets.getters.d.ts +0 -11
  16. package/dist/municipal/tickets/tickets.getters.d.ts.map +1 -1
  17. package/dist/municipal/tickets/tickets.getters.js +0 -128
  18. package/dist/municipal/tickets/tickets.getters.js.map +1 -1
  19. package/dist/municipal/tickets/tickets.statistics.aggregation.d.ts +45 -0
  20. package/dist/municipal/tickets/tickets.statistics.aggregation.d.ts.map +1 -0
  21. package/dist/municipal/tickets/tickets.statistics.aggregation.js +98 -0
  22. package/dist/municipal/tickets/tickets.statistics.aggregation.js.map +1 -0
  23. package/dist/municipal/tickets/tickets.statistics.dates.d.ts +7 -0
  24. package/dist/municipal/tickets/tickets.statistics.dates.d.ts.map +1 -0
  25. package/dist/municipal/tickets/tickets.statistics.dates.js +40 -0
  26. package/dist/municipal/tickets/tickets.statistics.dates.js.map +1 -0
  27. package/dist/municipal/tickets/tickets.statistics.getters.d.ts +9 -0
  28. package/dist/municipal/tickets/tickets.statistics.getters.d.ts.map +1 -0
  29. package/dist/municipal/tickets/tickets.statistics.getters.js +55 -0
  30. package/dist/municipal/tickets/tickets.statistics.getters.js.map +1 -0
  31. package/dist/municipal/tickets/tickets.statistics.pipeline.d.ts +53 -0
  32. package/dist/municipal/tickets/tickets.statistics.pipeline.d.ts.map +1 -0
  33. package/dist/municipal/tickets/tickets.statistics.pipeline.js +112 -0
  34. package/dist/municipal/tickets/tickets.statistics.pipeline.js.map +1 -0
  35. package/dist/municipal/tickets/tickets.statistics.utils.d.ts +7 -0
  36. package/dist/municipal/tickets/tickets.statistics.utils.d.ts.map +1 -0
  37. package/dist/municipal/tickets/tickets.statistics.utils.js +40 -0
  38. package/dist/municipal/tickets/tickets.statistics.utils.js.map +1 -0
  39. package/dist/municipal/tickets/tickets.types.d.ts +10 -5
  40. package/dist/municipal/tickets/tickets.types.d.ts.map +1 -1
  41. package/dist/talkpilot/calls/calls.constants.d.ts +17 -0
  42. package/dist/talkpilot/calls/calls.constants.d.ts.map +1 -0
  43. package/dist/talkpilot/calls/calls.constants.js +20 -0
  44. package/dist/talkpilot/calls/calls.constants.js.map +1 -0
  45. package/dist/talkpilot/calls/calls.getters.d.ts +3 -2
  46. package/dist/talkpilot/calls/calls.getters.d.ts.map +1 -1
  47. package/dist/talkpilot/calls/calls.getters.js +1 -2
  48. package/dist/talkpilot/calls/calls.getters.js.map +1 -1
  49. package/dist/talkpilot/calls/calls.statistics.getters.d.ts +19 -0
  50. package/dist/talkpilot/calls/calls.statistics.getters.d.ts.map +1 -0
  51. package/dist/talkpilot/calls/calls.statistics.getters.js +375 -0
  52. package/dist/talkpilot/calls/calls.statistics.getters.js.map +1 -0
  53. package/dist/talkpilot/calls/calls.statistics.ticketScope.d.ts +12 -0
  54. package/dist/talkpilot/calls/calls.statistics.ticketScope.d.ts.map +1 -0
  55. package/dist/talkpilot/calls/calls.statistics.ticketScope.js +37 -0
  56. package/dist/talkpilot/calls/calls.statistics.ticketScope.js.map +1 -0
  57. package/dist/talkpilot/calls/calls.statistics.tickets.d.ts +17 -0
  58. package/dist/talkpilot/calls/calls.statistics.tickets.d.ts.map +1 -0
  59. package/dist/talkpilot/calls/calls.statistics.tickets.js +33 -0
  60. package/dist/talkpilot/calls/calls.statistics.tickets.js.map +1 -0
  61. package/dist/talkpilot/calls/calls.statistics.types.d.ts +39 -0
  62. package/dist/talkpilot/calls/calls.statistics.types.d.ts.map +1 -0
  63. package/dist/talkpilot/calls/calls.statistics.types.js +3 -0
  64. package/dist/talkpilot/calls/calls.statistics.types.js.map +1 -0
  65. package/dist/talkpilot/calls/calls.types.d.ts +6 -10
  66. package/dist/talkpilot/calls/calls.types.d.ts.map +1 -1
  67. package/dist/talkpilot/calls/calls.types.js +0 -3
  68. package/dist/talkpilot/calls/calls.types.js.map +1 -1
  69. package/dist/talkpilot/calls/dashboard/calls.dashboard.d.ts +36 -0
  70. package/dist/talkpilot/calls/dashboard/calls.dashboard.d.ts.map +1 -0
  71. package/dist/talkpilot/calls/dashboard/calls.dashboard.js +208 -0
  72. package/dist/talkpilot/calls/dashboard/calls.dashboard.js.map +1 -0
  73. package/dist/talkpilot/calls/dashboard/calls.dashboard.types.d.ts +66 -0
  74. package/dist/talkpilot/calls/dashboard/calls.dashboard.types.d.ts.map +1 -0
  75. package/dist/talkpilot/calls/dashboard/calls.dashboard.types.js +3 -0
  76. package/dist/talkpilot/calls/dashboard/calls.dashboard.types.js.map +1 -0
  77. package/dist/talkpilot/calls/index.d.ts +4 -0
  78. package/dist/talkpilot/calls/index.d.ts.map +1 -1
  79. package/dist/talkpilot/calls/index.js +4 -0
  80. package/dist/talkpilot/calls/index.js.map +1 -1
  81. package/dist/talkpilot/clientsConfig/clientsConfig.getters.d.ts +2 -1
  82. package/dist/talkpilot/clientsConfig/clientsConfig.getters.d.ts.map +1 -1
  83. package/dist/talkpilot/clientsConfig/clientsConfig.getters.js +14 -0
  84. package/dist/talkpilot/clientsConfig/clientsConfig.getters.js.map +1 -1
  85. package/dist/talkpilot/clientsConfig/clientsConfig.types.d.ts +4 -1
  86. package/dist/talkpilot/clientsConfig/clientsConfig.types.d.ts.map +1 -1
  87. package/dist/talkpilot/clientsConfig/clientsConfig.types.js +6 -0
  88. package/dist/talkpilot/clientsConfig/clientsConfig.types.js.map +1 -1
  89. package/dist/talkpilot/flows/flows.schema.js +1 -1
  90. package/dist/talkpilot/phone_numbers/index.d.ts +2 -2
  91. package/dist/talkpilot/phone_numbers/phone_numbers.getter.d.ts +1 -1
  92. package/dist/talkpilot/phone_numbers/phone_numbers.getter.d.ts.map +1 -1
  93. package/dist/talkpilot/phone_numbers/phone_numbers.getter.js +5 -3
  94. package/dist/talkpilot/phone_numbers/phone_numbers.getter.js.map +1 -1
  95. package/dist/talkpilot/phone_numbers/phone_numbers.schema.js +12 -12
  96. package/dist/talkpilot/phone_numbers/phone_numbers.types.d.ts +4 -4
  97. package/dist/talkpilot/results/results.getter.d.ts.map +1 -1
  98. package/dist/talkpilot/results/results.getter.js.map +1 -1
  99. package/dist/talkpilot/retry_analyze/retryAnalyze.getters.d.ts.map +1 -1
  100. package/dist/talkpilot/retry_analyze/retryAnalyze.getters.js.map +1 -1
  101. package/dist/utils/date.utils.d.ts +49 -0
  102. package/dist/utils/date.utils.d.ts.map +1 -0
  103. package/dist/utils/date.utils.js +103 -0
  104. package/dist/utils/date.utils.js.map +1 -0
  105. package/dist/utils/shared.types.d.ts +5 -0
  106. package/dist/utils/shared.types.d.ts.map +1 -0
  107. package/dist/utils/shared.types.js +3 -0
  108. package/dist/utils/shared.types.js.map +1 -0
  109. package/dist/utils/statistics.aggregation.d.ts +20 -0
  110. package/dist/utils/statistics.aggregation.d.ts.map +1 -0
  111. package/dist/utils/statistics.aggregation.js +43 -0
  112. package/dist/utils/statistics.aggregation.js.map +1 -0
  113. package/package.json +2 -1
  114. package/src/municipal/tickets/__tests__/tickets.getters.spec.ts +1 -37
  115. package/src/municipal/tickets/__tests__/tickets.statistics.spec.ts +104 -0
  116. package/src/municipal/tickets/index.ts +2 -1
  117. package/src/municipal/tickets/tickets.constants.ts +8 -0
  118. package/src/municipal/tickets/tickets.getters.ts +0 -140
  119. package/src/municipal/tickets/tickets.statistics.aggregation.ts +113 -0
  120. package/src/municipal/tickets/tickets.statistics.getters.ts +93 -0
  121. package/src/municipal/tickets/tickets.types.ts +14 -9
  122. package/src/talkpilot/calls/__tests__/calls.dashboard.spec.ts +46 -0
  123. package/src/talkpilot/calls/__tests__/calls.spec.ts +48 -30
  124. package/src/talkpilot/calls/__tests__/calls.statistics.spec.ts +281 -0
  125. package/src/talkpilot/calls/calls.constants.ts +20 -0
  126. package/src/talkpilot/calls/calls.getters.ts +6 -6
  127. package/src/talkpilot/calls/calls.statistics.getters.ts +525 -0
  128. package/src/talkpilot/calls/calls.statistics.types.ts +44 -0
  129. package/src/talkpilot/calls/calls.types.ts +16 -15
  130. package/src/talkpilot/calls/dashboard/calls.dashboard.ts +243 -0
  131. package/src/talkpilot/calls/dashboard/calls.dashboard.types.ts +70 -0
  132. package/src/talkpilot/calls/index.ts +4 -0
  133. package/src/talkpilot/clientsConfig/__tests__/clientsConfig.getters.spec.ts +53 -0
  134. package/src/talkpilot/clientsConfig/__tests__/clientsConfig.spec.ts +19 -9
  135. package/src/talkpilot/clientsConfig/clientsConfig.getters.ts +34 -1
  136. package/src/talkpilot/clientsConfig/clientsConfig.types.ts +9 -1
  137. package/src/talkpilot/flows/__tests__/flows.schema.spec.ts +6 -2
  138. package/src/talkpilot/flows/flows.schema.ts +1 -1
  139. package/src/talkpilot/phone_numbers/__tests__/phone_numbers.spec.ts +40 -35
  140. package/src/talkpilot/phone_numbers/index.ts +2 -2
  141. package/src/talkpilot/phone_numbers/phone_numbers.getter.ts +10 -6
  142. package/src/talkpilot/phone_numbers/phone_numbers.schema.ts +12 -12
  143. package/src/talkpilot/phone_numbers/phone_numbers.types.ts +4 -4
  144. package/src/talkpilot/results/results.getter.ts +6 -2
  145. package/src/talkpilot/retry_analyze/retryAnalyze.getters.ts +13 -4
  146. package/src/utils/date.utils.ts +116 -0
  147. package/src/utils/shared.types.ts +4 -0
@@ -6,12 +6,12 @@ import {
6
6
  getFlowsCollection,
7
7
  ObjectId,
8
8
  findSubscriptions,
9
- } from '../index';
9
+ } from "../index";
10
10
  import {
11
11
  ClientPhoneNumberForFlow,
12
12
  PhoneNumber,
13
13
  PhoneNumberWithFlow,
14
- PurchasedPhoneProviderPayload
14
+ PurchasedPhoneProviderPayload,
15
15
  } from "./phone_numbers.types";
16
16
 
17
17
  export const getPhoneNumbersCollection = (): Collection<PhoneNumber> =>
@@ -140,13 +140,17 @@ export const createPurchasedPhoneNumber = async (
140
140
  await getPhoneNumbersCollection().insertOne(doc);
141
141
 
142
142
  const created = await getClientPhoneData(clientId, isPrimary);
143
- if (!created) throw new Error('Failed to create phoneNumber');
143
+ if (!created) throw new Error("Failed to create phoneNumber");
144
144
  return created;
145
145
  };
146
146
 
147
- export const findClientByPhoneNumber = async (phoneNumber: string): Promise<Client> => {
148
- const phoneData = await getPhoneNumbersCollection().findOne({ phone_number: phoneNumber });
149
- if (!phoneData) throw new Error('Failed to get phone data');
147
+ export const findClientByPhoneNumber = async (
148
+ phoneNumber: string,
149
+ ): Promise<Client> => {
150
+ const phoneData = await getPhoneNumbersCollection().findOne({
151
+ phone_number: phoneNumber,
152
+ });
153
+ if (!phoneData) throw new Error("Failed to get phone data");
150
154
  const clientId = phoneData.client_id;
151
155
  const client = await getClientsCollection().findOne({ clientId });
152
156
  if (!client) throw new Error("Failed to get client");
@@ -1,17 +1,17 @@
1
1
  export const phoneNumbersMongoSchema = {
2
- bsonType: 'object',
3
- required: ['client_id', 'phone_number'],
2
+ bsonType: "object",
3
+ required: ["client_id", "phone_number"],
4
4
  properties: {
5
- _id: { bsonType: 'objectId' },
6
- client_id: { bsonType: 'string' },
7
- flow_id: { bsonType: ['objectId', 'string'] },
8
- phone_number: { bsonType: 'string' },
9
- is_primary: { bsonType: 'bool' },
10
- provider: { bsonType: 'string' },
11
- provider_sid: { bsonType: 'string' },
12
- friendly_name: { bsonType: 'string' },
13
- createdAt: { bsonType: 'date' },
14
- updatedAt: { bsonType: 'date' },
5
+ _id: { bsonType: "objectId" },
6
+ client_id: { bsonType: "string" },
7
+ flow_id: { bsonType: ["objectId", "string"] },
8
+ phone_number: { bsonType: "string" },
9
+ is_primary: { bsonType: "bool" },
10
+ provider: { bsonType: "string" },
11
+ provider_sid: { bsonType: "string" },
12
+ friendly_name: { bsonType: "string" },
13
+ createdAt: { bsonType: "date" },
14
+ updatedAt: { bsonType: "date" },
15
15
  },
16
16
  additionalProperties: false,
17
17
  } as const;
@@ -1,8 +1,8 @@
1
- import { ObjectId, WithId } from 'mongodb';
2
- import { Flow } from '../flows/flows.types';
1
+ import { ObjectId, WithId } from "mongodb";
2
+ import { Flow } from "../flows/flows.types";
3
3
 
4
4
  export type PurchasedPhoneProviderPayload = {
5
- provider: 'twilio' | 'telnyx';
5
+ provider: "twilio" | "telnyx";
6
6
  provider_sid: string;
7
7
  friendly_name?: string;
8
8
  };
@@ -14,7 +14,7 @@ export type PhoneNumber = {
14
14
  phone_number: string;
15
15
  subscriptionId?: string;
16
16
  is_primary: boolean;
17
- provider?: 'twilio' | 'telnyx';
17
+ provider?: "twilio" | "telnyx";
18
18
  provider_sid?: string;
19
19
  friendly_name?: string;
20
20
  createdAt: Date;
@@ -26,10 +26,14 @@ export const initializeResultDocument = async (
26
26
  return result;
27
27
  };
28
28
 
29
- export const findResultById = async (resultId: string | ObjectId): Promise<Result | null> => {
29
+ export const findResultById = async (
30
+ resultId: string | ObjectId,
31
+ ): Promise<Result | null> => {
30
32
  return getResultsCollection().findOne({ _id: new ObjectId(resultId) });
31
33
  };
32
34
 
33
- export const findResultByCallSid = async (callSid: string): Promise<Result | null> => {
35
+ export const findResultByCallSid = async (
36
+ callSid: string,
37
+ ): Promise<Result | null> => {
34
38
  return getResultsCollection().findOne({ "calls.callSid": callSid });
35
39
  };
@@ -8,7 +8,9 @@ export const getRetryAnalyzeCollection = (): Collection<RetryAnalyzeDoc> => {
8
8
  return getDb().collection<RetryAnalyzeDoc>(COLLECTION_NAME);
9
9
  };
10
10
 
11
- export const getAllRetryAnalyzeDocs = async (): Promise<RetryAnalyzeWithId[]> => {
11
+ export const getAllRetryAnalyzeDocs = async (): Promise<
12
+ RetryAnalyzeWithId[]
13
+ > => {
12
14
  return getRetryAnalyzeCollection()
13
15
  .find({
14
16
  $or: [{ retry: { $lt: 5 } }, { retry: { $exists: false } }],
@@ -44,18 +46,25 @@ export const upsertRetryAnalyzeDoc = async (
44
46
  );
45
47
 
46
48
  if (result.matchedCount > 0) {
47
- await getRetryAnalyzeCollection().updateOne({ callSid: doc.callSid }, { $inc: { retry: 1 } });
49
+ await getRetryAnalyzeCollection().updateOne(
50
+ { callSid: doc.callSid },
51
+ { $inc: { retry: 1 } },
52
+ );
48
53
  }
49
54
 
50
55
  return result.upsertedId || null;
51
56
  };
52
57
 
53
- export const deleteRetryAnalyzeDocById = async (id: ObjectId): Promise<boolean> => {
58
+ export const deleteRetryAnalyzeDocById = async (
59
+ id: ObjectId,
60
+ ): Promise<boolean> => {
54
61
  const result = await getRetryAnalyzeCollection().deleteOne({ _id: id });
55
62
  return result.deletedCount === 1;
56
63
  };
57
64
 
58
- export const deleteRetryAnalyzeDocByCallSid = async (callSid: string): Promise<boolean> => {
65
+ export const deleteRetryAnalyzeDocByCallSid = async (
66
+ callSid: string,
67
+ ): Promise<boolean> => {
59
68
  const result = await getRetryAnalyzeCollection().deleteOne({ callSid });
60
69
  return result.deletedCount === 1;
61
70
  };
@@ -0,0 +1,116 @@
1
+ /**
2
+ * Shared timezone-aware date helpers for statistics aggregations.
3
+ */
4
+
5
+ /** Milliseconds in a single day. */
6
+ export const DAY_MS = 24 * 60 * 60 * 1000;
7
+
8
+ /** Maps a short weekday name (as produced by Intl) to its index (Sun = 0). */
9
+ export const WEEKDAY: Record<string, number> = {
10
+ Sun: 0,
11
+ Mon: 1,
12
+ Tue: 2,
13
+ Wed: 3,
14
+ Thu: 4,
15
+ Fri: 5,
16
+ Sat: 6,
17
+ };
18
+
19
+ /** Parses a `YYYY-MM-DD` string into `[year, month, day]` numbers. */
20
+ export const parseYmd = (dateStr: string): [number, number, number] => {
21
+ const [y, m, d] = dateStr.split("-").map(Number);
22
+ return [y, m, d];
23
+ };
24
+
25
+ /** Builds a zero-padded `YYYY-MM-DD` string from numeric parts. */
26
+ export const ymdToStr = (y: number, m: number, d: number): string =>
27
+ `${y}-${String(m).padStart(2, "0")}-${String(d).padStart(2, "0")}`;
28
+
29
+ /** Parses a `YYYY-MM-DD` string as midnight UTC. */
30
+ export const toUtcDate = (dateStr: string): Date =>
31
+ new Date(`${dateStr}T00:00:00.000Z`);
32
+
33
+ /** Formats a date as a `YYYY-MM-DD` string in UTC. */
34
+ export const formatDate = (date: Date): string => date.toISOString().slice(0, 10);
35
+
36
+ /** Adds `days` to a `YYYY-MM-DD` string, returning the resulting `YYYY-MM-DD`. */
37
+ export const addDaysToDateStr = (dateStr: string, days: number): string =>
38
+ formatDate(new Date(toUtcDate(dateStr).getTime() + days * DAY_MS));
39
+
40
+ /** Next civil calendar day (proleptic Gregorian). Avoids DST 24h steps that can stall iteration. */
41
+ export const incrementYmd = (
42
+ y: number,
43
+ m: number,
44
+ d: number,
45
+ ): [number, number, number] => {
46
+ const next = new Date(Date.UTC(y, m - 1, d + 1));
47
+ return [next.getUTCFullYear(), next.getUTCMonth() + 1, next.getUTCDate()];
48
+ };
49
+
50
+ /**
51
+ * Formats a date as the calendar day in the given timezone.
52
+ * `en-CA` yields ISO-8601 `YYYY-MM-DD`, which is lexicographically sortable
53
+ * (string compare == chronological compare) and matches MongoDB's `%Y-%m-%d`.
54
+ */
55
+ export const formatYmdInTz = (date: Date, timezone: string): string =>
56
+ new Intl.DateTimeFormat("en-CA", { timeZone: timezone }).format(date);
57
+
58
+ /**
59
+ * Returns the calendar day in the given timezone as numeric parts.
60
+ * Reads parts by `type` (not string order), so `en-US` is fine here.
61
+ */
62
+ export const getYmdInTz = (date: Date, timezone: string) => {
63
+ const parts = Object.fromEntries(
64
+ new Intl.DateTimeFormat("en-US", {
65
+ timeZone: timezone,
66
+ year: "numeric",
67
+ month: "numeric",
68
+ day: "numeric",
69
+ })
70
+ .formatToParts(date)
71
+ .map((p) => [p.type, Number(p.value)]),
72
+ );
73
+ return { y: parts.year, m: parts.month, d: parts.day };
74
+ };
75
+
76
+ /** Weekday index (Sun = 0) of a date in the given timezone. */
77
+ export const getWeekdayInTz = (date: Date, timezone: string): number =>
78
+ WEEKDAY[
79
+ new Intl.DateTimeFormat("en-US", { timeZone: timezone, weekday: "short" }).format(
80
+ date,
81
+ )
82
+ ] ?? 0;
83
+
84
+ /**
85
+ * Returns the given `YYYY-MM-DD` day at noon UTC — a stable anchor inside the
86
+ * calendar day, far from midnight so timezone/DST shifts can't cross a date boundary.
87
+ */
88
+ export const dateAtNoonUtc = (dateStr: string): Date => {
89
+ const [y, m, d] = parseYmd(dateStr);
90
+ return new Date(Date.UTC(y, m - 1, d, 12, 0, 0));
91
+ };
92
+
93
+ /**
94
+ * UTC instant at the start of the given `YYYY-MM-DD` calendar day in `timezone`.
95
+ * Binary-searches the boundary so it stays correct across DST transitions.
96
+ */
97
+ export const startOfCalendarDayInTz = (dateStr: string, timezone: string): Date => {
98
+ const anchor = dateAtNoonUtc(dateStr).getTime();
99
+ let low = anchor - 2 * DAY_MS;
100
+ let high = anchor + DAY_MS;
101
+
102
+ while (high - low > 1 /* ms */) {
103
+ const mid = Math.floor((low + high) / 2);
104
+ if (formatYmdInTz(new Date(mid), timezone) >= dateStr) high = mid;
105
+ else low = mid;
106
+ }
107
+
108
+ return new Date(high);
109
+ };
110
+
111
+ /** UTC instant at the last millisecond of the given calendar day in `timezone`. */
112
+ export const endOfCalendarDayInTz = (dateStr: string, timezone: string): Date => {
113
+ const [y, m, d] = parseYmd(dateStr);
114
+ const nextDay = new Date(Date.UTC(y, m - 1, d + 1)).toISOString().slice(0, 10);
115
+ return new Date(startOfCalendarDayInTz(nextDay, timezone).getTime() - 1);
116
+ };
@@ -0,0 +1,4 @@
1
+ export interface CallLengthThresholds {
2
+ shortThreshold: number;
3
+ mediumThreshold: number;
4
+ }