@awell-health/awell-extensions 2.1.66 → 2.1.68
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.
- package/dist/extensions/dateHelpers/actions/getNextWorkday/config/fields.d.ts +10 -0
- package/dist/extensions/dateHelpers/actions/getNextWorkday/config/fields.js +9 -1
- package/dist/extensions/dateHelpers/actions/getNextWorkday/config/fields.js.map +1 -1
- package/dist/extensions/dateHelpers/actions/getNextWorkday/getNextWorkday.js +95 -12
- package/dist/extensions/dateHelpers/actions/getNextWorkday/getNextWorkday.js.map +1 -1
- package/dist/extensions/dateHelpers/actions/index.d.ts +7 -0
- package/dist/extensions/freshdesk/lib/api/schema/GetTicket.schema.d.ts +2 -2
- package/dist/extensions/freshdesk/lib/api/schema/UpdateTicket.schema.d.ts +4 -4
- package/dist/extensions/freshdesk/lib/api/schema/atoms/Ticket.Schema.d.ts +2 -2
- package/dist/extensions/healthie/lib/validation/sendFormCompletionRequest.zod.d.ts +8 -8
- package/package.json +1 -1
|
@@ -15,14 +15,24 @@ export declare const fields: {
|
|
|
15
15
|
type: FieldType.BOOLEAN;
|
|
16
16
|
required: false;
|
|
17
17
|
};
|
|
18
|
+
timezone: {
|
|
19
|
+
id: string;
|
|
20
|
+
label: string;
|
|
21
|
+
description: string;
|
|
22
|
+
type: FieldType.STRING;
|
|
23
|
+
required: false;
|
|
24
|
+
};
|
|
18
25
|
};
|
|
19
26
|
export declare const FieldsValidationSchema: z.ZodObject<{
|
|
20
27
|
referenceDate: z.ZodOptional<z.ZodDate>;
|
|
21
28
|
includeReferenceDate: z.ZodDefault<z.ZodOptional<z.ZodBoolean>>;
|
|
29
|
+
timezone: z.ZodDefault<z.ZodOptional<z.ZodString>>;
|
|
22
30
|
}, "strip", z.ZodTypeAny, {
|
|
31
|
+
timezone: string;
|
|
23
32
|
includeReferenceDate: boolean;
|
|
24
33
|
referenceDate?: Date | undefined;
|
|
25
34
|
}, {
|
|
35
|
+
timezone?: string | undefined;
|
|
26
36
|
referenceDate?: Date | undefined;
|
|
27
37
|
includeReferenceDate?: boolean | undefined;
|
|
28
38
|
}>;
|
|
@@ -14,13 +14,21 @@ exports.fields = {
|
|
|
14
14
|
includeReferenceDate: {
|
|
15
15
|
id: 'includeReferenceDate',
|
|
16
16
|
label: 'Include reference date',
|
|
17
|
-
description: 'If this option is enabled and the reference date is a
|
|
17
|
+
description: 'If this option is enabled and the reference date is a work day, that date will be returned. If it is disabled, the next work day after the reference date will be returned.',
|
|
18
18
|
type: extensions_core_1.FieldType.BOOLEAN,
|
|
19
19
|
required: false,
|
|
20
20
|
},
|
|
21
|
+
timezone: {
|
|
22
|
+
id: 'timezone',
|
|
23
|
+
label: 'Timezone',
|
|
24
|
+
description: 'The IANA timezone identifier to use for the next workday calculation (e.g., "America/New_York", "Europe/London", "America/Chicago", "UTC"). If not specified, America/Chicago will be used.',
|
|
25
|
+
type: extensions_core_1.FieldType.STRING,
|
|
26
|
+
required: false,
|
|
27
|
+
},
|
|
21
28
|
};
|
|
22
29
|
exports.FieldsValidationSchema = zod_1.z.object({
|
|
23
30
|
referenceDate: zod_1.z.optional(zod_1.z.coerce.date()),
|
|
24
31
|
includeReferenceDate: zod_1.z.boolean().optional().default(true),
|
|
32
|
+
timezone: zod_1.z.string().optional().default('America/Chicago'),
|
|
25
33
|
});
|
|
26
34
|
//# sourceMappingURL=fields.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"fields.js","sourceRoot":"","sources":["../../../../../../extensions/dateHelpers/actions/getNextWorkday/config/fields.ts"],"names":[],"mappings":";;;AAAA,6BAAwC;AACxC,mEAAqE;AAExD,QAAA,MAAM,GAAG;IACpB,aAAa,EAAE;QACb,EAAE,EAAE,eAAe;QACnB,KAAK,EAAE,gBAAgB;QACvB,WAAW,EACT,qHAAqH;QACvH,IAAI,EAAE,2BAAS,CAAC,IAAI;QACpB,QAAQ,EAAE,KAAK;KAChB;IACD,oBAAoB,EAAE;QACpB,EAAE,EAAE,sBAAsB;QAC1B,KAAK,EAAE,wBAAwB;QAC/B,WAAW,EACT,
|
|
1
|
+
{"version":3,"file":"fields.js","sourceRoot":"","sources":["../../../../../../extensions/dateHelpers/actions/getNextWorkday/config/fields.ts"],"names":[],"mappings":";;;AAAA,6BAAwC;AACxC,mEAAqE;AAExD,QAAA,MAAM,GAAG;IACpB,aAAa,EAAE;QACb,EAAE,EAAE,eAAe;QACnB,KAAK,EAAE,gBAAgB;QACvB,WAAW,EACT,qHAAqH;QACvH,IAAI,EAAE,2BAAS,CAAC,IAAI;QACpB,QAAQ,EAAE,KAAK;KAChB;IACD,oBAAoB,EAAE;QACpB,EAAE,EAAE,sBAAsB;QAC1B,KAAK,EAAE,wBAAwB;QAC/B,WAAW,EACT,6KAA6K;QAC/K,IAAI,EAAE,2BAAS,CAAC,OAAO;QACvB,QAAQ,EAAE,KAAK;KAChB;IACD,QAAQ,EAAE;QACR,EAAE,EAAE,UAAU;QACd,KAAK,EAAE,UAAU;QACjB,WAAW,EACT,6LAA6L;QAC/L,IAAI,EAAE,2BAAS,CAAC,MAAM;QACtB,QAAQ,EAAE,KAAK;KAChB;CAC8B,CAAA;AAEpB,QAAA,sBAAsB,GAAG,OAAC,CAAC,MAAM,CAAC;IAC7C,aAAa,EAAE,OAAC,CAAC,QAAQ,CAAC,OAAC,CAAC,MAAM,CAAC,IAAI,EAAE,CAAC;IAC1C,oBAAoB,EAAE,OAAC,CAAC,OAAO,EAAE,CAAC,QAAQ,EAAE,CAAC,OAAO,CAAC,IAAI,CAAC;IAC1D,QAAQ,EAAE,OAAC,CAAC,MAAM,EAAE,CAAC,QAAQ,EAAE,CAAC,OAAO,CAAC,iBAAiB,CAAC;CACT,CAAC,CAAA"}
|
|
@@ -6,33 +6,116 @@ const config_1 = require("./config");
|
|
|
6
6
|
exports.getNextWorkday = {
|
|
7
7
|
key: 'getNextWorkday',
|
|
8
8
|
title: 'Get Next Workday',
|
|
9
|
-
description: 'Get the next workday',
|
|
9
|
+
description: 'Get the next US Federal workday (Defaults to America/Chicago time zone)',
|
|
10
10
|
category: extensions_core_1.Category.WORKFLOW,
|
|
11
11
|
fields: config_1.fields,
|
|
12
12
|
dataPoints: config_1.dataPoints,
|
|
13
13
|
previewable: true,
|
|
14
14
|
onActivityCreated: async (payload, onComplete, onError) => {
|
|
15
15
|
const { referenceDate: referenceDateInput, includeReferenceDate } = config_1.FieldsValidationSchema.parse(payload.fields);
|
|
16
|
-
const
|
|
17
|
-
|
|
18
|
-
|
|
16
|
+
const toZonedStartOfDay = (date, tz) => {
|
|
17
|
+
const parts = new Intl.DateTimeFormat('en-US', {
|
|
18
|
+
timeZone: tz,
|
|
19
|
+
year: 'numeric',
|
|
20
|
+
month: 'numeric',
|
|
21
|
+
day: 'numeric',
|
|
22
|
+
})
|
|
23
|
+
.formatToParts(date)
|
|
24
|
+
.reduce((acc, part) => {
|
|
25
|
+
if (part.type === 'year')
|
|
26
|
+
acc.year = parseInt(part.value, 10);
|
|
27
|
+
if (part.type === 'month')
|
|
28
|
+
acc.month = parseInt(part.value, 10);
|
|
29
|
+
if (part.type === 'day')
|
|
30
|
+
acc.day = parseInt(part.value, 10);
|
|
31
|
+
return acc;
|
|
32
|
+
}, { year: 0, month: 0, day: 0 });
|
|
33
|
+
return new Date(Date.UTC(parts.year, parts.month - 1, parts.day, 0, 0, 0));
|
|
34
|
+
};
|
|
35
|
+
// Use provided timezone if present, default from validation schema is America/Chicago
|
|
36
|
+
const { timezone } = config_1.FieldsValidationSchema.parse(payload.fields);
|
|
37
|
+
let referenceDate = toZonedStartOfDay(referenceDateInput !== null && referenceDateInput !== void 0 ? referenceDateInput : new Date(), timezone);
|
|
19
38
|
const SUNDAY = 0;
|
|
20
39
|
const SATURDAY = 6;
|
|
21
|
-
const isWeekend = (date) =>
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
40
|
+
const isWeekend = (date) => {
|
|
41
|
+
return date.getUTCDay() === SUNDAY || date.getUTCDay() === SATURDAY;
|
|
42
|
+
};
|
|
43
|
+
const isHoliday = (date) => {
|
|
44
|
+
const year = date.getUTCFullYear();
|
|
45
|
+
const makeDateUTC = (y, mZero, d) => new Date(Date.UTC(y, mZero, d, 0, 0, 0, 0));
|
|
46
|
+
const isSameUTCDate = (a, b) => a.getUTCFullYear() === b.getUTCFullYear() &&
|
|
47
|
+
a.getUTCMonth() === b.getUTCMonth() &&
|
|
48
|
+
a.getUTCDate() === b.getUTCDate();
|
|
49
|
+
const observedFixed = (y, mZero, d) => {
|
|
50
|
+
const actual = makeDateUTC(y, mZero, d);
|
|
51
|
+
const dow = actual.getUTCDay();
|
|
52
|
+
if (dow === 0) {
|
|
53
|
+
// Sunday -> observed Monday
|
|
54
|
+
return makeDateUTC(y, mZero, d + 1);
|
|
55
|
+
}
|
|
56
|
+
if (dow === 6) {
|
|
57
|
+
// Saturday -> observed Friday
|
|
58
|
+
return makeDateUTC(y, mZero, d - 1);
|
|
59
|
+
}
|
|
60
|
+
return actual;
|
|
61
|
+
};
|
|
62
|
+
const nthWeekdayOfMonth = (y, mZero, weekday, n) => {
|
|
63
|
+
const firstOfMonth = makeDateUTC(y, mZero, 1);
|
|
64
|
+
const firstDow = firstOfMonth.getUTCDay();
|
|
65
|
+
const day = 1 + ((7 + weekday - firstDow) % 7) + (n - 1) * 7;
|
|
66
|
+
return makeDateUTC(y, mZero, day);
|
|
67
|
+
};
|
|
68
|
+
const lastWeekdayOfMonth = (y, mZero, weekday) => {
|
|
69
|
+
const lastOfMonth = new Date(Date.UTC(y, mZero + 1, 0));
|
|
70
|
+
const lastDow = lastOfMonth.getUTCDay();
|
|
71
|
+
const day = lastOfMonth.getUTCDate() - ((7 + (lastDow - weekday)) % 7);
|
|
72
|
+
return makeDateUTC(y, mZero, day);
|
|
73
|
+
};
|
|
74
|
+
// US Federal holidays (observed):
|
|
75
|
+
const holidays = [];
|
|
76
|
+
// New Year's Day (may be observed on Dec 31 of previous year)
|
|
77
|
+
holidays.push(observedFixed(year, 0, 1));
|
|
78
|
+
// Also include observed date for next year's New Year in case it falls on Dec 31 of this year
|
|
79
|
+
holidays.push(observedFixed(year + 1, 0, 1));
|
|
80
|
+
// Martin Luther King Jr. Day (3rd Monday of January)
|
|
81
|
+
holidays.push(nthWeekdayOfMonth(year, 0, 1, 3));
|
|
82
|
+
// Presidents' Day (3rd Monday of February)
|
|
83
|
+
holidays.push(nthWeekdayOfMonth(year, 1, 1, 3));
|
|
84
|
+
// Memorial Day (last Monday of May)
|
|
85
|
+
holidays.push(lastWeekdayOfMonth(year, 4, 1));
|
|
86
|
+
// Juneteenth (June 19, observed)
|
|
87
|
+
holidays.push(observedFixed(year, 5, 19));
|
|
88
|
+
// Independence Day (July 4, observed)
|
|
89
|
+
holidays.push(observedFixed(year, 6, 4));
|
|
90
|
+
// Labor Day (1st Monday of September)
|
|
91
|
+
holidays.push(nthWeekdayOfMonth(year, 8, 1, 1));
|
|
92
|
+
// Columbus Day / Indigenous Peoples' Day (2nd Monday of October)
|
|
93
|
+
holidays.push(nthWeekdayOfMonth(year, 9, 1, 2));
|
|
94
|
+
// Veterans Day (Nov 11, observed)
|
|
95
|
+
holidays.push(observedFixed(year, 10, 11));
|
|
96
|
+
// Thanksgiving (4th Thursday of November)
|
|
97
|
+
holidays.push(nthWeekdayOfMonth(year, 10, 4, 4));
|
|
98
|
+
// Christmas Eve (Dec 24, fixed - no observed rollover, only a holiday when it falls on a weekday)
|
|
99
|
+
holidays.push(makeDateUTC(year, 11, 24));
|
|
100
|
+
// Christmas Day (Dec 25, observed)
|
|
101
|
+
holidays.push(observedFixed(year, 11, 25));
|
|
102
|
+
return holidays.some((h) => isSameUTCDate(date, h));
|
|
103
|
+
};
|
|
104
|
+
const referenceDateIsWeekday = (referenceDate) => !isWeekend(referenceDate) && !isHoliday(referenceDate);
|
|
105
|
+
// If reference date is a weekday and we should *not* include it, move forward by one day (in timezone)
|
|
106
|
+
const refIsWeekday = referenceDateIsWeekday(referenceDate);
|
|
107
|
+
if (!includeReferenceDate && refIsWeekday) {
|
|
108
|
+
referenceDate.setUTCDate(referenceDate.getUTCDate() + 1);
|
|
26
109
|
}
|
|
27
110
|
// If resultDate is a weekend, keep moving forward to the next weekday
|
|
28
|
-
while (
|
|
29
|
-
referenceDate.
|
|
111
|
+
while (!referenceDateIsWeekday(referenceDate)) {
|
|
112
|
+
referenceDate.setUTCDate(referenceDate.getUTCDate() + 1);
|
|
30
113
|
}
|
|
31
114
|
const nextWorkday = referenceDate.toISOString();
|
|
32
115
|
await onComplete({
|
|
33
116
|
data_points: {
|
|
34
117
|
nextWorkday,
|
|
35
|
-
referenceDateIsWeekday: String(
|
|
118
|
+
referenceDateIsWeekday: String(refIsWeekday),
|
|
36
119
|
},
|
|
37
120
|
});
|
|
38
121
|
},
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"getNextWorkday.js","sourceRoot":"","sources":["../../../../../extensions/dateHelpers/actions/getNextWorkday/getNextWorkday.ts"],"names":[],"mappings":";;;AACA,mEAAwD;AAExD,qCAAqE;AAExD,QAAA,cAAc,GAIvB;IACF,GAAG,EAAE,gBAAgB;IACrB,KAAK,EAAE,kBAAkB;IACzB,WAAW,
|
|
1
|
+
{"version":3,"file":"getNextWorkday.js","sourceRoot":"","sources":["../../../../../extensions/dateHelpers/actions/getNextWorkday/getNextWorkday.ts"],"names":[],"mappings":";;;AACA,mEAAwD;AAExD,qCAAqE;AAExD,QAAA,cAAc,GAIvB;IACF,GAAG,EAAE,gBAAgB;IACrB,KAAK,EAAE,kBAAkB;IACzB,WAAW,EACT,yEAAyE;IAC3E,QAAQ,EAAE,0BAAQ,CAAC,QAAQ;IAC3B,MAAM,EAAN,eAAM;IACN,UAAU,EAAV,mBAAU;IACV,WAAW,EAAE,IAAI;IACjB,iBAAiB,EAAE,KAAK,EAAE,OAAO,EAAE,UAAU,EAAE,OAAO,EAAE,EAAE;QACxD,MAAM,EAAE,aAAa,EAAE,kBAAkB,EAAE,oBAAoB,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timezone: {
|
|
18
|
+
id: string;
|
|
19
|
+
label: string;
|
|
20
|
+
description: string;
|
|
21
|
+
type: import("@awell-health/extensions-core").FieldType.STRING;
|
|
22
|
+
required: false;
|
|
23
|
+
};
|
|
17
24
|
}, {}, "nextWorkday" | "referenceDateIsWeekday">;
|
|
18
25
|
checkWorkingHours: import("@awell-health/extensions-core").Action<{
|
|
19
26
|
workingHoursStart: {
|
|
@@ -47,7 +47,7 @@ export declare const GetTicketResponseSchema: z.ZodObject<{
|
|
|
47
47
|
fr_escalated: boolean;
|
|
48
48
|
requester_id: number;
|
|
49
49
|
responder_id: number | null;
|
|
50
|
-
source: 1 | 2 | 3 | 7 |
|
|
50
|
+
source: 1 | 2 | 3 | 7 | 9 | 10;
|
|
51
51
|
spam: boolean;
|
|
52
52
|
to_emails: string[] | null;
|
|
53
53
|
product_id: number | null;
|
|
@@ -77,7 +77,7 @@ export declare const GetTicketResponseSchema: z.ZodObject<{
|
|
|
77
77
|
fr_escalated: boolean;
|
|
78
78
|
requester_id: number;
|
|
79
79
|
responder_id: number | null;
|
|
80
|
-
source: 1 | 2 | 3 | 7 |
|
|
80
|
+
source: 1 | 2 | 3 | 7 | 9 | 10;
|
|
81
81
|
spam: boolean;
|
|
82
82
|
to_emails: string[] | null;
|
|
83
83
|
product_id: number | null;
|
|
@@ -42,7 +42,7 @@ export declare const UpdateTicketInputSchema: z.ZodObject<{
|
|
|
42
42
|
email_config_id?: number | undefined;
|
|
43
43
|
requester_id?: number | undefined;
|
|
44
44
|
responder_id?: number | undefined;
|
|
45
|
-
source?: 1 | 2 | 3 | 7 |
|
|
45
|
+
source?: 1 | 2 | 3 | 7 | 9 | 10 | undefined;
|
|
46
46
|
company_id?: number | undefined;
|
|
47
47
|
product_id?: number | undefined;
|
|
48
48
|
due_by?: string | undefined;
|
|
@@ -70,7 +70,7 @@ export declare const UpdateTicketInputSchema: z.ZodObject<{
|
|
|
70
70
|
email_config_id?: number | undefined;
|
|
71
71
|
requester_id?: number | undefined;
|
|
72
72
|
responder_id?: number | undefined;
|
|
73
|
-
source?: 1 | 2 | 3 | 7 |
|
|
73
|
+
source?: 1 | 2 | 3 | 7 | 9 | 10 | undefined;
|
|
74
74
|
company_id?: number | undefined;
|
|
75
75
|
product_id?: number | undefined;
|
|
76
76
|
due_by?: string | undefined;
|
|
@@ -133,7 +133,7 @@ export declare const UpdateTicketResponseSchema: z.ZodObject<{
|
|
|
133
133
|
fr_escalated: boolean;
|
|
134
134
|
requester_id: number;
|
|
135
135
|
responder_id: number | null;
|
|
136
|
-
source: 1 | 2 | 3 | 7 |
|
|
136
|
+
source: 1 | 2 | 3 | 7 | 9 | 10;
|
|
137
137
|
spam: boolean;
|
|
138
138
|
to_emails: string[] | null;
|
|
139
139
|
product_id: number | null;
|
|
@@ -163,7 +163,7 @@ export declare const UpdateTicketResponseSchema: z.ZodObject<{
|
|
|
163
163
|
fr_escalated: boolean;
|
|
164
164
|
requester_id: number;
|
|
165
165
|
responder_id: number | null;
|
|
166
|
-
source: 1 | 2 | 3 | 7 |
|
|
166
|
+
source: 1 | 2 | 3 | 7 | 9 | 10;
|
|
167
167
|
spam: boolean;
|
|
168
168
|
to_emails: string[] | null;
|
|
169
169
|
product_id: number | null;
|
|
@@ -47,7 +47,7 @@ export declare const TicketSchema: z.ZodObject<{
|
|
|
47
47
|
fr_escalated: boolean;
|
|
48
48
|
requester_id: number;
|
|
49
49
|
responder_id: number | null;
|
|
50
|
-
source: 1 | 2 | 3 | 7 |
|
|
50
|
+
source: 1 | 2 | 3 | 7 | 9 | 10;
|
|
51
51
|
spam: boolean;
|
|
52
52
|
to_emails: string[] | null;
|
|
53
53
|
product_id: number | null;
|
|
@@ -77,7 +77,7 @@ export declare const TicketSchema: z.ZodObject<{
|
|
|
77
77
|
fr_escalated: boolean;
|
|
78
78
|
requester_id: number;
|
|
79
79
|
responder_id: number | null;
|
|
80
|
-
source: 1 | 2 | 3 | 7 |
|
|
80
|
+
source: 1 | 2 | 3 | 7 | 9 | 10;
|
|
81
81
|
spam: boolean;
|
|
82
82
|
to_emails: string[] | null;
|
|
83
83
|
product_id: number | null;
|
|
@@ -14,10 +14,10 @@ export declare const FieldsSchema: z.ZodEffects<z.ZodObject<{
|
|
|
14
14
|
healthie_patient_id: string;
|
|
15
15
|
form_id: string;
|
|
16
16
|
period?: string | undefined;
|
|
17
|
-
minute?: string | undefined;
|
|
18
17
|
hour?: string | undefined;
|
|
19
|
-
|
|
18
|
+
minute?: string | undefined;
|
|
20
19
|
weekday?: string | undefined;
|
|
20
|
+
frequency?: string | undefined;
|
|
21
21
|
monthday?: string | undefined;
|
|
22
22
|
is_recurring?: boolean | undefined;
|
|
23
23
|
ends_on?: string | undefined;
|
|
@@ -25,10 +25,10 @@ export declare const FieldsSchema: z.ZodEffects<z.ZodObject<{
|
|
|
25
25
|
healthie_patient_id: string;
|
|
26
26
|
form_id: string;
|
|
27
27
|
period?: string | undefined;
|
|
28
|
-
minute?: string | undefined;
|
|
29
28
|
hour?: string | undefined;
|
|
30
|
-
|
|
29
|
+
minute?: string | undefined;
|
|
31
30
|
weekday?: string | undefined;
|
|
31
|
+
frequency?: string | undefined;
|
|
32
32
|
monthday?: string | undefined;
|
|
33
33
|
is_recurring?: boolean | undefined;
|
|
34
34
|
ends_on?: "" | Date | undefined;
|
|
@@ -36,10 +36,10 @@ export declare const FieldsSchema: z.ZodEffects<z.ZodObject<{
|
|
|
36
36
|
healthie_patient_id: string;
|
|
37
37
|
form_id: string;
|
|
38
38
|
period?: string | undefined;
|
|
39
|
-
minute?: string | undefined;
|
|
40
39
|
hour?: string | undefined;
|
|
41
|
-
|
|
40
|
+
minute?: string | undefined;
|
|
42
41
|
weekday?: string | undefined;
|
|
42
|
+
frequency?: string | undefined;
|
|
43
43
|
monthday?: string | undefined;
|
|
44
44
|
is_recurring?: boolean | undefined;
|
|
45
45
|
ends_on?: string | undefined;
|
|
@@ -47,10 +47,10 @@ export declare const FieldsSchema: z.ZodEffects<z.ZodObject<{
|
|
|
47
47
|
healthie_patient_id: string;
|
|
48
48
|
form_id: string;
|
|
49
49
|
period?: string | undefined;
|
|
50
|
-
minute?: string | undefined;
|
|
51
50
|
hour?: string | undefined;
|
|
52
|
-
|
|
51
|
+
minute?: string | undefined;
|
|
53
52
|
weekday?: string | undefined;
|
|
53
|
+
frequency?: string | undefined;
|
|
54
54
|
monthday?: string | undefined;
|
|
55
55
|
is_recurring?: boolean | undefined;
|
|
56
56
|
ends_on?: "" | Date | undefined;
|