@eka-care/ekascribe-ts-sdk 3.0.19 → 3.0.22
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/index.d.ts +77 -0
- package/dist/index.mjs +1999 -1319
- package/package.json +2 -2
package/dist/index.d.ts
CHANGED
|
@@ -103,6 +103,7 @@ declare class EkaScribe {
|
|
|
103
103
|
private allianceClient;
|
|
104
104
|
private recording;
|
|
105
105
|
private output;
|
|
106
|
+
private widgetManager;
|
|
106
107
|
readonly documents: DocumentManager;
|
|
107
108
|
readonly sessions: SessionUtils;
|
|
108
109
|
private constructor();
|
|
@@ -135,6 +136,7 @@ declare class EkaScribe {
|
|
|
135
136
|
commitTransactionCall(): Promise<TEndRecordingResponse>;
|
|
136
137
|
/** @deprecated Backward compatible */
|
|
137
138
|
stopTransactionCall(): Promise<TEndRecordingResponse>;
|
|
139
|
+
startForPatient(config: StartForPatientConfig): Promise<void>;
|
|
138
140
|
/** @deprecated Backward compatible */
|
|
139
141
|
getTemplateOutput(request: {
|
|
140
142
|
txn_id: string;
|
|
@@ -178,6 +180,7 @@ export declare interface EkaScribeConfig {
|
|
|
178
180
|
useWorker?: boolean | 'auto';
|
|
179
181
|
debug?: boolean;
|
|
180
182
|
};
|
|
183
|
+
widget?: WidgetConfig;
|
|
181
184
|
}
|
|
182
185
|
|
|
183
186
|
export { EndSessionRequest }
|
|
@@ -275,6 +278,12 @@ declare class SessionUtils {
|
|
|
275
278
|
private extractHeaderFooterInfo;
|
|
276
279
|
}
|
|
277
280
|
|
|
281
|
+
export declare interface StartForPatientConfig {
|
|
282
|
+
txn_id: string;
|
|
283
|
+
patient_details?: Omit<TPatientDetails, 'oid'>;
|
|
284
|
+
additional_data?: Record<string, unknown>;
|
|
285
|
+
}
|
|
286
|
+
|
|
278
287
|
export declare type TChunkTranscriptResponse = {
|
|
279
288
|
text: string;
|
|
280
289
|
confidence: number;
|
|
@@ -1113,4 +1122,72 @@ export declare enum VAD_STATUS {
|
|
|
1113
1122
|
STOP = "stop"
|
|
1114
1123
|
}
|
|
1115
1124
|
|
|
1125
|
+
export declare interface WidgetCallbacks {
|
|
1126
|
+
onRecordingStart?: (data: {
|
|
1127
|
+
txn_id: string;
|
|
1128
|
+
}) => void;
|
|
1129
|
+
onRecordingPause?: (data: {
|
|
1130
|
+
txn_id: string;
|
|
1131
|
+
duration: number;
|
|
1132
|
+
}) => void;
|
|
1133
|
+
onRecordingResume?: (data: {
|
|
1134
|
+
txn_id: string;
|
|
1135
|
+
}) => void;
|
|
1136
|
+
onRecordingStop?: (data: {
|
|
1137
|
+
txn_id: string;
|
|
1138
|
+
duration: number;
|
|
1139
|
+
}) => void;
|
|
1140
|
+
onProcessingStart?: (data: {
|
|
1141
|
+
txn_id: string;
|
|
1142
|
+
}) => void;
|
|
1143
|
+
onProcessingComplete?: (data: {
|
|
1144
|
+
txn_id: string;
|
|
1145
|
+
sessionData: unknown;
|
|
1146
|
+
}) => void;
|
|
1147
|
+
onError?: (data: {
|
|
1148
|
+
error_code: string;
|
|
1149
|
+
message: string;
|
|
1150
|
+
}) => void;
|
|
1151
|
+
onWidgetClose?: (data: {
|
|
1152
|
+
txn_id: string;
|
|
1153
|
+
}) => void;
|
|
1154
|
+
}
|
|
1155
|
+
|
|
1156
|
+
export declare interface WidgetConfig {
|
|
1157
|
+
enabled: boolean;
|
|
1158
|
+
theme?: WidgetTheme;
|
|
1159
|
+
zIndex?: number;
|
|
1160
|
+
primaryColor?: string;
|
|
1161
|
+
position?: WidgetPosition;
|
|
1162
|
+
callbacks?: WidgetCallbacks;
|
|
1163
|
+
sessionDefaults: {
|
|
1164
|
+
input_language: string[];
|
|
1165
|
+
output_format_template: {
|
|
1166
|
+
template_id: string;
|
|
1167
|
+
template_name?: string;
|
|
1168
|
+
template_type?: string;
|
|
1169
|
+
}[];
|
|
1170
|
+
model_type: string;
|
|
1171
|
+
mode: string;
|
|
1172
|
+
};
|
|
1173
|
+
}
|
|
1174
|
+
|
|
1175
|
+
export declare interface WidgetPosition {
|
|
1176
|
+
bottom?: number;
|
|
1177
|
+
right?: number;
|
|
1178
|
+
top?: number;
|
|
1179
|
+
left?: number;
|
|
1180
|
+
}
|
|
1181
|
+
|
|
1182
|
+
export declare enum WidgetState {
|
|
1183
|
+
COLLAPSED = "collapsed",
|
|
1184
|
+
RECORDING = "recording",
|
|
1185
|
+
PAUSED = "paused",
|
|
1186
|
+
PROCESSING = "processing",
|
|
1187
|
+
DONE = "done",
|
|
1188
|
+
ERROR = "error"
|
|
1189
|
+
}
|
|
1190
|
+
|
|
1191
|
+
export declare type WidgetTheme = 'dark' | 'light';
|
|
1192
|
+
|
|
1116
1193
|
export { }
|