@tellescope/types-models 1.250.2 → 1.251.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.
- package/lib/cjs/index.d.ts +39 -3
- package/lib/cjs/index.d.ts.map +1 -1
- package/lib/cjs/index.js.map +1 -1
- package/lib/esm/index.d.ts +39 -3
- package/lib/esm/index.d.ts.map +1 -1
- package/lib/esm/index.js.map +1 -1
- package/lib/tsconfig.tsbuildinfo +1 -1
- package/package.json +3 -3
- package/src/index.ts +50 -4
package/src/index.ts
CHANGED
|
@@ -541,6 +541,7 @@ export interface Organization extends Organization_readonly, Organization_requir
|
|
|
541
541
|
answersSyncToPortal?: { id: string, questions: string[] }[]
|
|
542
542
|
externalFormIdsToSync?: string[],
|
|
543
543
|
enforceMFA?: boolean,
|
|
544
|
+
accountSwitchingEnabled?: boolean, // opt-in: must be true for users in this org to participate in linked-account access (as either requester or target)
|
|
544
545
|
analyticsIframes?: {
|
|
545
546
|
title: string,
|
|
546
547
|
iframeURL: string,
|
|
@@ -571,6 +572,7 @@ export interface Organization extends Organization_readonly, Organization_requir
|
|
|
571
572
|
skipActivePatientBilling?: boolean,
|
|
572
573
|
portalV2SchemaURL?: string,
|
|
573
574
|
timeTrackingPrograms?: TimeTrackingProgram[],
|
|
575
|
+
belugaAutomationMappings?: BelugaAutomationMappingEntry[],
|
|
574
576
|
}
|
|
575
577
|
export type OrganizationTheme = {
|
|
576
578
|
name: string,
|
|
@@ -673,6 +675,11 @@ export interface UserSession extends Session, OrganizationLimits { // User joine
|
|
|
673
675
|
availablePhoneNumbers: string[],
|
|
674
676
|
availableFromEmails: string[],
|
|
675
677
|
isa?: boolean,
|
|
678
|
+
// When set, this session was created via account-switching. actorUserId is the user
|
|
679
|
+
// who initiated the switch (e.g. A switching into B → session.id = B, session.actorUserId = A).
|
|
680
|
+
actorUserId?: string,
|
|
681
|
+
actorEmail?: string,
|
|
682
|
+
actorBusinessId?: string,
|
|
676
683
|
}
|
|
677
684
|
|
|
678
685
|
export type StateCredentialInfo = {
|
|
@@ -722,6 +729,31 @@ export type UserCallRoutingBehavior = (
|
|
|
722
729
|
|
|
723
730
|
export type MFASettings = { email?: boolean }
|
|
724
731
|
|
|
732
|
+
export interface LinkedAccount {
|
|
733
|
+
id: string,
|
|
734
|
+
email: string,
|
|
735
|
+
orgName: string,
|
|
736
|
+
fname?: string,
|
|
737
|
+
lname?: string,
|
|
738
|
+
requiresMFA: boolean,
|
|
739
|
+
}
|
|
740
|
+
|
|
741
|
+
export type LinkedAccountAccessStatus = 'pending' | 'accepted'
|
|
742
|
+
|
|
743
|
+
export interface LinkedAccountAccessEntry {
|
|
744
|
+
userId: string,
|
|
745
|
+
email: string,
|
|
746
|
+
fname?: string,
|
|
747
|
+
lname?: string,
|
|
748
|
+
orgName?: string,
|
|
749
|
+
status: LinkedAccountAccessStatus,
|
|
750
|
+
createdAt: Date,
|
|
751
|
+
// Governs only the pending-request TTL. Once status flips to 'accepted',
|
|
752
|
+
// this field is preserved for audit but no longer gates anything; switching
|
|
753
|
+
// is permitted indefinitely until the owner revokes.
|
|
754
|
+
requestExpiresAt: Date,
|
|
755
|
+
}
|
|
756
|
+
|
|
725
757
|
export type LabeledField = { field: string, value: string }
|
|
726
758
|
|
|
727
759
|
export interface User_readonly extends ClientRecord {
|
|
@@ -810,6 +842,7 @@ export interface User extends User_required, User_readonly, User_updatesDisabled
|
|
|
810
842
|
dashboardView?: CustomDashboardView,
|
|
811
843
|
hideFromCalendarView?: boolean,
|
|
812
844
|
requireSSO?: string[],
|
|
845
|
+
linkedAccountAccess?: LinkedAccountAccessEntry[],
|
|
813
846
|
}
|
|
814
847
|
|
|
815
848
|
export type Preference = 'email' | 'sms' | 'call' | 'chat'
|
|
@@ -2604,7 +2637,7 @@ export interface FormResponse extends FormResponse_readonly, FormResponse_requir
|
|
|
2604
2637
|
calendarEventId?: string,
|
|
2605
2638
|
copiedFrom?: string,
|
|
2606
2639
|
copiedFromEnduserId?: string,
|
|
2607
|
-
groupId?: string, // may be an automationStepId when created from Journey in push forms action
|
|
2640
|
+
groupId?: string, // may be an automationStepId when created from Journey in push forms action — intentional, so Canvas sibling lookup (canvas.ts) and the per-push completion detector can find the batch. The API resolves the real formGroupId from the automation step at trigger-detection time for "Form Group Completed" triggers.
|
|
2608
2641
|
groupInstance?: string,
|
|
2609
2642
|
groupPosition?: number,
|
|
2610
2643
|
utm?: LabeledField[],
|
|
@@ -3372,8 +3405,9 @@ export type BelugaAutoRxPatientPreferenceItem = {
|
|
|
3372
3405
|
medId: string,
|
|
3373
3406
|
}
|
|
3374
3407
|
export type BelugaAutoRxAutomationAction = AutomationActionBuilder<'belugaAutoRx', {
|
|
3375
|
-
patientPreference
|
|
3376
|
-
pharmacyId
|
|
3408
|
+
patientPreference?: BelugaAutoRxPatientPreferenceItem,
|
|
3409
|
+
pharmacyId?: string,
|
|
3410
|
+
useOrganizationMapping?: boolean,
|
|
3377
3411
|
}>
|
|
3378
3412
|
export type BelugaUpdateVisitPatientPreferenceItem = {
|
|
3379
3413
|
name: string,
|
|
@@ -3384,9 +3418,15 @@ export type BelugaUpdateVisitPatientPreferenceItem = {
|
|
|
3384
3418
|
medId: string,
|
|
3385
3419
|
}
|
|
3386
3420
|
export type BelugaUpdateVisitAutomationAction = AutomationActionBuilder<'belugaUpdateVisit', {
|
|
3421
|
+
patientPreferences?: BelugaUpdateVisitPatientPreferenceItem[],
|
|
3422
|
+
pharmacyId?: string,
|
|
3423
|
+
useOrganizationMapping?: boolean,
|
|
3424
|
+
}>
|
|
3425
|
+
export type BelugaAutomationMappingEntry = {
|
|
3426
|
+
enduserCondition: Record<string, any>,
|
|
3387
3427
|
patientPreferences: BelugaUpdateVisitPatientPreferenceItem[],
|
|
3388
3428
|
pharmacyId: string,
|
|
3389
|
-
}
|
|
3429
|
+
}
|
|
3390
3430
|
export type SendChatAutomationAction = AutomationActionBuilder<'sendChat', {
|
|
3391
3431
|
templateId: string,
|
|
3392
3432
|
identifier: string,
|
|
@@ -3951,6 +3991,9 @@ export interface UserLog extends UserLog_readonly, UserLog_required, UserLog_upd
|
|
|
3951
3991
|
info?: Indexable,
|
|
3952
3992
|
enduserId?: string,
|
|
3953
3993
|
note?: string,
|
|
3994
|
+
// Set on logs emitted during a switched-in session; reflects the user who initiated the switch.
|
|
3995
|
+
// userId on the same row is the acted-as user (target). See UserSession.actorUserId.
|
|
3996
|
+
actorUserId?: string,
|
|
3954
3997
|
}
|
|
3955
3998
|
|
|
3956
3999
|
export interface EnduserTask_readonly extends ClientRecord {}
|
|
@@ -4807,6 +4850,9 @@ export type AutomationTriggerEvents = {
|
|
|
4807
4850
|
'Incoming Fax': AutomationTriggerEventBuilder<"Incoming Fax", {
|
|
4808
4851
|
senderFaxNumbers?: string[],
|
|
4809
4852
|
}, {}>,
|
|
4853
|
+
'Beluga Visit Sync Failed': AutomationTriggerEventBuilder<"Beluga Visit Sync Failed", {
|
|
4854
|
+
formIds?: string[],
|
|
4855
|
+
}, {}>,
|
|
4810
4856
|
}
|
|
4811
4857
|
export type AutomationTriggerEventType = keyof AutomationTriggerEvents
|
|
4812
4858
|
export type AutomationTriggerEvent = AutomationTriggerEvents[AutomationTriggerEventType]
|