@1interface/chat-core 0.4.5 → 0.6.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/dist/index.d.ts CHANGED
@@ -222,6 +222,20 @@ export declare class AudioRecorder {
222
222
  cleanup(): void;
223
223
  }
224
224
 
225
+ export declare const AUTH_CLIENT_TYPES: {
226
+ readonly ALL: "all";
227
+ };
228
+
229
+ export declare const AUTH_MODES: {
230
+ readonly GUEST_ONLY: "guest_only";
231
+ readonly SIGN_IN_ONLY: "sign_in_only";
232
+ readonly GUEST_AND_SIGN_IN: "guest_and_sign_in";
233
+ };
234
+
235
+ export declare type AuthClientType = (typeof AUTH_CLIENT_TYPES)[keyof typeof AUTH_CLIENT_TYPES];
236
+
237
+ export declare type AuthMode = (typeof AUTH_MODES)[keyof typeof AUTH_MODES];
238
+
225
239
  export declare function bindChatLogger(getState: () => RootState): void;
226
240
 
227
241
  export declare const brandingApi: Api<BaseQueryFn<string | FetchArgs, unknown, FetchBaseQueryError>, {
@@ -589,9 +603,11 @@ export declare const clearMessageQueue: ActionCreatorWithoutPayload<"chat/clearM
589
603
  export declare interface ClientConfig {
590
604
  conversations: ConversationsConfig;
591
605
  voice_agent: VoiceAgentConfig;
606
+ stt: SttConfig;
592
607
  features?: string[];
593
608
  backend_version?: string;
594
609
  panel_switcher_enabled?: boolean;
610
+ auth_mode_config?: Partial<Record<AuthClientType, AuthMode>>;
595
611
  }
596
612
 
597
613
  export declare interface ClientConfigResponse {
@@ -712,6 +728,8 @@ export declare function getCachedLocation(storage: Storage_2): Promise<UserLocat
712
728
 
713
729
  export declare const getLatestRequestId: () => string;
714
730
 
731
+ export declare function guestLoginApi(): Promise<AuthApiResult>;
732
+
715
733
  export declare const hasAnyExtraData: (msg: any) => boolean;
716
734
 
717
735
  export declare function isApiServerError(err: unknown): boolean;
@@ -1156,6 +1174,10 @@ export declare interface StreamMessageParams {
1156
1174
  body?: Record<string, unknown>;
1157
1175
  }
1158
1176
 
1177
+ export declare interface SttConfig {
1178
+ enabled: boolean;
1179
+ }
1180
+
1159
1181
  export declare const THINKING_MESSAGES: {
1160
1182
  readonly INITIAL: readonly ["Working on it", "Just a moment", "Reviewing your request", "Looking into that", "One moment, please", "Checking"];
1161
1183
  readonly LATER: readonly ["Almost ready", "Gathering the details", "Finishing up", "Getting things in order", "Preparing your answer", "Wrapping this up"];
@@ -3277,6 +3299,19 @@ isError: false;
3277
3299
  }, "chatApi", unknown>>;
3278
3300
  };
3279
3301
 
3302
+ export declare function useGuestLogin(): {
3303
+ guest: () => Promise<{
3304
+ success: true;
3305
+ data: AppResponse<SessionResponse>;
3306
+ error?: undefined;
3307
+ } | {
3308
+ success: false;
3309
+ error: any;
3310
+ data?: undefined;
3311
+ }>;
3312
+ isLoading: boolean;
3313
+ };
3314
+
3280
3315
  export declare function useInfiniteScroll({ hasMore, isLoadingRef, scrollAreaRef, onLoadMore, itemCount, }: {
3281
3316
  hasMore: boolean;
3282
3317
  isLoadingRef: MutableRefObject<boolean>;