@iblai/web-utils 1.1.2 → 1.1.3

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 (113) hide show
  1. package/dist/data-layer/src/core/index.d.ts +7 -1
  2. package/dist/data-layer/src/features/analytics/constants.d.ts +6 -6
  3. package/dist/data-layer/src/features/analytics/types.d.ts +9 -0
  4. package/dist/data-layer/src/features/api-keys/api-slice.d.ts +72 -24
  5. package/dist/data-layer/src/features/apps/api-slice.d.ts +72 -24
  6. package/dist/data-layer/src/features/artifacts/api-slice.d.ts +1798 -0
  7. package/dist/data-layer/src/features/artifacts/constants.d.ts +42 -0
  8. package/dist/data-layer/src/features/artifacts/types.d.ts +37 -0
  9. package/dist/data-layer/src/features/auth/types.d.ts +1 -1
  10. package/dist/data-layer/src/features/billing/api-slice.d.ts +15 -5
  11. package/dist/data-layer/src/features/billing/constants.d.ts +16 -0
  12. package/dist/data-layer/src/features/billing/custom-api-slice.d.ts +634 -0
  13. package/dist/data-layer/src/features/billing/types.d.ts +35 -0
  14. package/dist/data-layer/src/features/career/api-slice.d.ts +342 -114
  15. package/dist/data-layer/src/features/catalog/api-slice.d.ts +1050 -317
  16. package/dist/data-layer/src/features/chat/api-slice.d.ts +204 -68
  17. package/dist/data-layer/src/features/chat-history/api-slice.d.ts +202 -60
  18. package/dist/data-layer/src/features/core/api-slice.d.ts +1143 -134
  19. package/dist/data-layer/src/features/core/custom-public-image-asset-api-slice.d.ts +60 -20
  20. package/dist/data-layer/src/features/credentials/api-slice.d.ts +3706 -146
  21. package/dist/data-layer/src/features/credentials/constants.d.ts +9 -1
  22. package/dist/data-layer/src/features/credentials/custom-api-slice.d.ts +535 -2
  23. package/dist/data-layer/src/features/credentials/types.d.ts +14 -0
  24. package/dist/data-layer/src/features/datasets/api-slice.d.ts +60 -197
  25. package/dist/data-layer/src/features/llms/api-slice.d.ts +60 -20
  26. package/dist/data-layer/src/features/mcp/api-slice.d.ts +2613 -0
  27. package/dist/data-layer/src/features/mcp/constants.d.ts +57 -0
  28. package/dist/data-layer/src/features/mcp/types.d.ts +176 -0
  29. package/dist/data-layer/src/features/memory/types.d.ts +1 -0
  30. package/dist/data-layer/src/features/mentor/api-slice.d.ts +1789 -473
  31. package/dist/data-layer/src/features/mentor/constants.d.ts +7 -1
  32. package/dist/data-layer/src/features/mentor/custom-api-slice.d.ts +162 -1
  33. package/dist/data-layer/src/features/mentor/types.d.ts +7 -1
  34. package/dist/data-layer/src/features/mentor-categories/api-slice.d.ts +117 -39
  35. package/dist/data-layer/src/features/moderation-logs/api-slice.d.ts +705 -0
  36. package/dist/data-layer/src/features/notifications/api-slice.d.ts +214 -86
  37. package/dist/data-layer/src/features/per-learner/api-slice.d.ts +174 -58
  38. package/dist/data-layer/src/features/platform/api-slice.d.ts +1568 -293
  39. package/dist/data-layer/src/features/platform/types.d.ts +13 -0
  40. package/dist/data-layer/src/features/prompts/api-slice.d.ts +249 -83
  41. package/dist/data-layer/src/features/reports/api-slice.d.ts +145 -41
  42. package/dist/data-layer/src/features/search/ai-search-api-slice.d.ts +399 -1
  43. package/dist/data-layer/src/features/search/api-slice.d.ts +117 -39
  44. package/dist/data-layer/src/features/search/constants.d.ts +10 -0
  45. package/dist/data-layer/src/features/search/types.d.ts +72 -0
  46. package/dist/data-layer/src/features/sessions/api-slice.d.ts +440 -46
  47. package/dist/data-layer/src/features/skills/api-slice.d.ts +231 -77
  48. package/dist/data-layer/src/features/tenant/api-slice.d.ts +123 -41
  49. package/dist/data-layer/src/features/tools/api-slice.d.ts +60 -20
  50. package/dist/data-layer/src/features/training-documents/api-slice.d.ts +141 -47
  51. package/dist/data-layer/src/features/user-invitations/api-slice.d.ts +66 -22
  52. package/dist/data-layer/src/index.d.ts +6 -0
  53. package/dist/index.d.ts +367 -33
  54. package/dist/index.esm.js +7619 -3934
  55. package/dist/index.esm.js.map +1 -1
  56. package/dist/index.js +7644 -3931
  57. package/dist/index.js.map +1 -1
  58. package/dist/package.json +22 -12
  59. package/dist/web-utils/src/__tests__/index.mobile.test.d.ts +7 -0
  60. package/dist/web-utils/src/__tests__/index.web.test.d.ts +8 -0
  61. package/dist/web-utils/src/constants/__tests__/chat.test.d.ts +1 -0
  62. package/dist/web-utils/src/constants/chat.d.ts +1 -1
  63. package/dist/web-utils/src/features/chat/__tests__/slice.test.d.ts +1 -0
  64. package/dist/web-utils/src/features/chat/slice.d.ts +37 -2
  65. package/dist/web-utils/src/features/csv/combine-csv.d.ts +35 -0
  66. package/dist/web-utils/src/features/csv/index.d.ts +1 -0
  67. package/dist/web-utils/src/features/files/__tests__/filesSlice.test.d.ts +1 -0
  68. package/dist/web-utils/src/features/index.d.ts +1 -0
  69. package/dist/web-utils/src/hoc/index.d.ts +2 -0
  70. package/dist/web-utils/src/hoc/with-permissions.d.ts +44 -0
  71. package/dist/web-utils/src/hooks/__tests__/use-mentor-settings.test.d.ts +1 -0
  72. package/dist/web-utils/src/hooks/chat/ollama-client.d.ts +57 -0
  73. package/dist/web-utils/src/hooks/chat/use-advanced-chat.d.ts +10 -4
  74. package/dist/web-utils/src/hooks/chat/use-advanced-chat.test.d.ts +1 -0
  75. package/dist/web-utils/src/hooks/chat/use-chat-v2.d.ts +59 -2
  76. package/dist/web-utils/src/hooks/chat/use-chat-v2.test.d.ts +1 -0
  77. package/dist/web-utils/src/hooks/chat/use-chat.d.ts +1 -0
  78. package/dist/web-utils/src/hooks/chat/use-get-chat-details.test.d.ts +1 -0
  79. package/dist/web-utils/src/hooks/chat/use-mentor-tools.d.ts +2 -0
  80. package/dist/web-utils/src/hooks/chat/use-mentor-tools.test.d.ts +1 -0
  81. package/dist/web-utils/src/hooks/index.d.ts +1 -0
  82. package/dist/web-utils/src/hooks/subscription-v2/constants.d.ts +5 -0
  83. package/dist/web-utils/src/hooks/subscription-v2/use-subscription-handler.d.ts +56 -1
  84. package/dist/web-utils/src/hooks/tenant-metadata/__tests__/config-loader.test.d.ts +10 -0
  85. package/dist/web-utils/src/hooks/tenant-metadata/__tests__/use-tenant-metadata.test.d.ts +1 -0
  86. package/dist/web-utils/src/hooks/tenant-metadata/use-tenant-metadata.d.ts +2 -1
  87. package/dist/web-utils/src/index.d.ts +1 -0
  88. package/dist/web-utils/src/index.mobile.d.ts +130 -10
  89. package/dist/web-utils/src/index.web.d.ts +174 -12
  90. package/dist/web-utils/src/providers/__tests__/mentor-provider.test.d.ts +1 -0
  91. package/dist/web-utils/src/providers/__tests__/tenant-provider.test.d.ts +1 -0
  92. package/dist/web-utils/src/providers/auth-provider.d.ts +5 -2
  93. package/dist/web-utils/src/providers/mentor-provider.d.ts +2 -1
  94. package/dist/web-utils/src/providers/tenant-provider.d.ts +7 -2
  95. package/dist/web-utils/src/types/index.d.ts +1 -0
  96. package/dist/web-utils/src/types/subscription.d.ts +21 -0
  97. package/dist/web-utils/src/utils/__tests__/auth.test.d.ts +1 -0
  98. package/dist/web-utils/src/utils/__tests__/constants.test.d.ts +1 -0
  99. package/dist/web-utils/src/utils/__tests__/helpers.test.d.ts +1 -0
  100. package/dist/web-utils/src/utils/__tests__/platform.test.d.ts +1 -0
  101. package/dist/web-utils/src/utils/constants.d.ts +1 -0
  102. package/dist/web-utils/src/utils/data/__tests__/advanced-tab.test.d.ts +1 -0
  103. package/dist/web-utils/src/utils/helpers.d.ts +6 -0
  104. package/dist/web-utils/src/utils/index.d.ts +1 -0
  105. package/dist/web-utils/src/utils/platform.d.ts +1 -0
  106. package/dist/web-utils/tests/hooks/chat/use-mentor-tools.test.d.ts +1 -0
  107. package/dist/web-utils/tests/hooks/subscription-v2/use-subscription-handler.test.d.ts +1 -0
  108. package/dist/web-utils/tests/hooks/use-mentor-settings.test.d.ts +1 -0
  109. package/dist/web-utils/tests/providers/mentor-provider.test.d.ts +1 -0
  110. package/dist/web-utils/tests/providers/tenant-provider.test.d.ts +1 -0
  111. package/dist/web-utils/tests/utils/helpers.test.d.ts +1 -0
  112. package/dist/web-utils/tsconfig.tsbuildinfo +1 -1
  113. package/package.json +22 -12
@@ -1,10 +1,130 @@
1
- export { useGetChatDetails } from './hooks/chat/use-get-chat-details';
2
- export { useAdvancedChat } from './hooks/chat/use-advanced-chat';
3
- export { useTimeTracker } from './features/tracking/use-time-tracker';
4
- export { useMentorSettings } from './hooks/use-mentor-settings';
5
- export type { ChatMode } from './types';
6
- export { advancedTabsProperties, ANONYMOUS_USERNAME } from './utils';
7
- export { isAlphaNumeric32 } from './utils';
8
- export { getTimeAgo } from './utils';
9
- export { getInitials } from './utils';
10
- export { chatActions, selectSessionId } from './features/chat/slice';
1
+ import { useGetChatDetails as _useGetChatDetails } from "./hooks/chat/use-get-chat-details";
2
+ import { useAdvancedChat as _useAdvancedChat } from "./hooks/chat/use-advanced-chat";
3
+ import { useTimeTracker as _useTimeTracker } from "./features/tracking/use-time-tracker";
4
+ import { useMentorSettings as _useMentorSettings } from "./hooks/use-mentor-settings";
5
+ import { getTimeAgo as _getTimeAgo } from "./utils";
6
+ export declare const useGetChatDetails: typeof _useGetChatDetails;
7
+ export declare const useAdvancedChat: typeof _useAdvancedChat;
8
+ export declare const useTimeTracker: typeof _useTimeTracker;
9
+ export declare const useMentorSettings: typeof _useMentorSettings;
10
+ export declare const advancedTabsProperties: {
11
+ chat: {
12
+ display: string;
13
+ name: string;
14
+ tag: string;
15
+ showHeader: boolean;
16
+ prompts: {
17
+ type: string;
18
+ icon: string;
19
+ summary: string;
20
+ content: string;
21
+ }[];
22
+ };
23
+ summarize: {
24
+ display: string;
25
+ showHeader: boolean;
26
+ name: string;
27
+ tag: string;
28
+ prompts: {
29
+ type: string;
30
+ proactive: boolean;
31
+ hide: boolean;
32
+ content: string;
33
+ }[];
34
+ };
35
+ translate: {
36
+ display: string;
37
+ showHeader: boolean;
38
+ name: string;
39
+ tag: string;
40
+ description: string;
41
+ metaDescription: string;
42
+ prompts: ({
43
+ type: string;
44
+ hide: boolean;
45
+ tag: string;
46
+ summary: string;
47
+ content: string;
48
+ } | {
49
+ type: string;
50
+ summary: string;
51
+ content: string;
52
+ hide?: undefined;
53
+ tag?: undefined;
54
+ })[];
55
+ };
56
+ expand: {
57
+ display: string;
58
+ showHeader: boolean;
59
+ name: string;
60
+ tag: string;
61
+ prompts: {
62
+ type: string;
63
+ proactive: boolean;
64
+ hide: boolean;
65
+ content: string;
66
+ }[];
67
+ };
68
+ };
69
+ export declare const ANONYMOUS_USERNAME = "anonymous";
70
+ export declare const isAlphaNumeric32: (text: string) => boolean;
71
+ export declare const getTimeAgo: typeof _getTimeAgo;
72
+ export declare const getInitials: (fullName: string) => string;
73
+ export declare const chatActions: import("@reduxjs/toolkit").CaseReducerActions<import("@reduxjs/toolkit").SliceCaseReducers<{
74
+ chats: import("./features/chat/slice").ChatState;
75
+ isTyping: boolean;
76
+ streaming: boolean;
77
+ currentStreamingMessage: import("./features/chat/slice").StreamingMessage;
78
+ currentStreamingArtifact: import("./features/chat/slice").StreamingArtifact | null;
79
+ activeTab: import("./utils").AdvancedTab;
80
+ sessionId: string;
81
+ sessionIds: import("./features/chat/slice").SessionIds;
82
+ status: import("./features/chat/slice").ChatStatus;
83
+ tools: string[];
84
+ token: string | null;
85
+ tokenEnabled: boolean;
86
+ iframeContext: {
87
+ hostInfo: {
88
+ title: string;
89
+ href: string;
90
+ };
91
+ pageContent: string;
92
+ };
93
+ documentFilter: Record<string, unknown> | null;
94
+ shouldStartNewChat: boolean;
95
+ showingSharedChat: boolean;
96
+ artifactsEnabled: boolean;
97
+ streamingArtifactContentBuffer: string;
98
+ lastArtifactContentFlushTime: number;
99
+ }>, string>;
100
+ export declare const selectSessionId: (state: {
101
+ chatSliceShared: {
102
+ chats: import("./features/chat/slice").ChatState;
103
+ isTyping: boolean;
104
+ streaming: boolean;
105
+ currentStreamingMessage: import("./features/chat/slice").StreamingMessage;
106
+ currentStreamingArtifact: import("./features/chat/slice").StreamingArtifact | null;
107
+ activeTab: import("./utils").AdvancedTab;
108
+ sessionId: string;
109
+ sessionIds: import("./features/chat/slice").SessionIds;
110
+ status: import("./features/chat/slice").ChatStatus;
111
+ tools: string[];
112
+ token: string | null;
113
+ tokenEnabled: boolean;
114
+ iframeContext: {
115
+ hostInfo: {
116
+ title: string;
117
+ href: string;
118
+ };
119
+ pageContent: string;
120
+ };
121
+ documentFilter: Record<string, unknown> | null;
122
+ shouldStartNewChat: boolean;
123
+ showingSharedChat: boolean;
124
+ artifactsEnabled: boolean;
125
+ streamingArtifactContentBuffer: string;
126
+ lastArtifactContentFlushTime: number;
127
+ };
128
+ }) => string;
129
+ export type { ChatMode } from "./types";
130
+ export type { OAuthRequiredData, OAuthResolvedData, } from "./hooks/chat/use-chat-v2";
@@ -1,14 +1,176 @@
1
- export { useGetChatDetails } from "./hooks/chat/use-get-chat-details";
2
- export { useAdvancedChat } from "./hooks/chat/use-advanced-chat";
3
- export { useTimeTracker } from "./features/tracking/use-time-tracker";
4
- export { useMentorSettings } from "./hooks/use-mentor-settings";
1
+ import { useGetChatDetails as _useGetChatDetails } from "./hooks/chat/use-get-chat-details";
2
+ import { useAdvancedChat as _useAdvancedChat } from "./hooks/chat/use-advanced-chat";
3
+ import { useTimeTracker as _useTimeTracker } from "./features/tracking/use-time-tracker";
4
+ import { useMentorSettings as _useMentorSettings } from "./hooks/use-mentor-settings";
5
+ import { getTimeAgo as _getTimeAgo } from "./utils";
6
+ import { isInIframe as _isInIframe, sendMessageToParentWebsite as _sendMessageToParentWebsite, deleteCookie as _deleteCookie, getDomainParts as _getDomainParts, deleteCookieOnAllDomains as _deleteCookieOnAllDomains, getParentDomain as _getParentDomain, setCookieForAuth as _setCookieForAuth, clearCookies as _clearCookies, isLoggedIn as _isLoggedIn, getPlatformKey as _getPlatformKey, redirectToAuthSpa as _redirectToAuthSpa, getAuthSpaJoinUrl as _getAuthSpaJoinUrl, redirectToAuthSpaJoinTenant as _redirectToAuthSpaJoinTenant, handleLogout as _handleLogout } from "./utils/auth";
7
+ import { AuthProvider as _AuthProvider, TenantProvider as _TenantProvider, MentorProvider as _MentorProvider } from "./providers";
8
+ import { useSearchParams as _useSearchParams, useParams as _useParams, useRouter as _useRouter, usePathname as _usePathname } from "next/navigation";
9
+ export declare const useGetChatDetails: typeof _useGetChatDetails;
10
+ export declare const useAdvancedChat: typeof _useAdvancedChat;
11
+ export declare const useTimeTracker: typeof _useTimeTracker;
12
+ export declare const useMentorSettings: typeof _useMentorSettings;
13
+ export declare const advancedTabsProperties: {
14
+ chat: {
15
+ display: string;
16
+ name: string;
17
+ tag: string;
18
+ showHeader: boolean;
19
+ prompts: {
20
+ type: string;
21
+ icon: string;
22
+ summary: string;
23
+ content: string;
24
+ }[];
25
+ };
26
+ summarize: {
27
+ display: string;
28
+ showHeader: boolean;
29
+ name: string;
30
+ tag: string;
31
+ prompts: {
32
+ type: string;
33
+ proactive: boolean;
34
+ hide: boolean;
35
+ content: string;
36
+ }[];
37
+ };
38
+ translate: {
39
+ display: string;
40
+ showHeader: boolean;
41
+ name: string;
42
+ tag: string;
43
+ description: string;
44
+ metaDescription: string;
45
+ prompts: ({
46
+ type: string;
47
+ hide: boolean;
48
+ tag: string;
49
+ summary: string;
50
+ content: string;
51
+ } | {
52
+ type: string;
53
+ summary: string;
54
+ content: string;
55
+ hide?: undefined;
56
+ tag?: undefined;
57
+ })[];
58
+ };
59
+ expand: {
60
+ display: string;
61
+ showHeader: boolean;
62
+ name: string;
63
+ tag: string;
64
+ prompts: {
65
+ type: string;
66
+ proactive: boolean;
67
+ hide: boolean;
68
+ content: string;
69
+ }[];
70
+ };
71
+ };
72
+ export declare const ANONYMOUS_USERNAME = "anonymous";
73
+ export declare const isAlphaNumeric32: (text: string) => boolean;
74
+ export declare const getTimeAgo: typeof _getTimeAgo;
75
+ export declare const getInitials: (fullName: string) => string;
76
+ export declare const isInIframe: typeof _isInIframe;
77
+ export declare const sendMessageToParentWebsite: typeof _sendMessageToParentWebsite;
78
+ export declare const deleteCookie: typeof _deleteCookie;
79
+ export declare const getDomainParts: typeof _getDomainParts;
80
+ export declare const deleteCookieOnAllDomains: typeof _deleteCookieOnAllDomains;
81
+ export declare const getParentDomain: typeof _getParentDomain;
82
+ export declare const setCookieForAuth: typeof _setCookieForAuth;
83
+ export declare const clearCookies: typeof _clearCookies;
84
+ export declare const isLoggedIn: typeof _isLoggedIn;
85
+ export declare const getPlatformKey: typeof _getPlatformKey;
86
+ export declare const redirectToAuthSpa: typeof _redirectToAuthSpa;
87
+ export declare const getAuthSpaJoinUrl: typeof _getAuthSpaJoinUrl;
88
+ export declare const redirectToAuthSpaJoinTenant: typeof _redirectToAuthSpaJoinTenant;
89
+ export declare const handleLogout: typeof _handleLogout;
90
+ export declare const chatActions: import("@reduxjs/toolkit").CaseReducerActions<import("@reduxjs/toolkit").SliceCaseReducers<{
91
+ chats: import("./features/chat/slice").ChatState;
92
+ isTyping: boolean;
93
+ streaming: boolean;
94
+ currentStreamingMessage: import("./features/chat/slice").StreamingMessage;
95
+ currentStreamingArtifact: import("./features/chat/slice").StreamingArtifact | null;
96
+ activeTab: import("./utils").AdvancedTab;
97
+ sessionId: string;
98
+ sessionIds: import("./features/chat/slice").SessionIds;
99
+ status: import("./features/chat/slice").ChatStatus;
100
+ tools: string[];
101
+ token: string | null;
102
+ tokenEnabled: boolean;
103
+ iframeContext: {
104
+ hostInfo: {
105
+ title: string;
106
+ href: string;
107
+ };
108
+ pageContent: string;
109
+ };
110
+ documentFilter: Record<string, unknown> | null;
111
+ shouldStartNewChat: boolean;
112
+ showingSharedChat: boolean;
113
+ artifactsEnabled: boolean;
114
+ streamingArtifactContentBuffer: string;
115
+ lastArtifactContentFlushTime: number;
116
+ }>, string>;
117
+ export declare const selectSessionId: (state: {
118
+ chatSliceShared: {
119
+ chats: import("./features/chat/slice").ChatState;
120
+ isTyping: boolean;
121
+ streaming: boolean;
122
+ currentStreamingMessage: import("./features/chat/slice").StreamingMessage;
123
+ currentStreamingArtifact: import("./features/chat/slice").StreamingArtifact | null;
124
+ activeTab: import("./utils").AdvancedTab;
125
+ sessionId: string;
126
+ sessionIds: import("./features/chat/slice").SessionIds;
127
+ status: import("./features/chat/slice").ChatStatus;
128
+ tools: string[];
129
+ token: string | null;
130
+ tokenEnabled: boolean;
131
+ iframeContext: {
132
+ hostInfo: {
133
+ title: string;
134
+ href: string;
135
+ };
136
+ pageContent: string;
137
+ };
138
+ documentFilter: Record<string, unknown> | null;
139
+ shouldStartNewChat: boolean;
140
+ showingSharedChat: boolean;
141
+ artifactsEnabled: boolean;
142
+ streamingArtifactContentBuffer: string;
143
+ lastArtifactContentFlushTime: number;
144
+ };
145
+ }) => string;
146
+ export declare const AuthProvider: typeof _AuthProvider;
147
+ export declare const TenantProvider: typeof _TenantProvider;
148
+ export declare const MentorProvider: typeof _MentorProvider;
149
+ export declare const WithFormPermissions: import("react").FC<{
150
+ name: string | string[];
151
+ permissions: Record<string, {
152
+ read?: boolean;
153
+ write: boolean;
154
+ delete?: boolean;
155
+ }>;
156
+ children: (props: {
157
+ disabled: boolean;
158
+ canDelete?: boolean;
159
+ }) => React.ReactNode;
160
+ enableRBAC?: boolean;
161
+ }>;
162
+ export declare const WithPermissions: ({ rbacResource, rbacPermissions, children, }: {
163
+ rbacResource: string;
164
+ rbacPermissions: object;
165
+ children: (props: {
166
+ hasPermission: boolean;
167
+ }) => React.ReactNode;
168
+ }) => import("react/jsx-runtime").JSX.Element;
169
+ export declare const checkRbacPermission: (rbacPermissions: object, rbacResource: string, enableRBAC?: boolean) => boolean;
170
+ export declare const useSearchParams: typeof _useSearchParams;
171
+ export declare const useParams: typeof _useParams;
172
+ export declare const useRouter: typeof _useRouter;
173
+ export declare const usePathname: typeof _usePathname;
5
174
  export type { ChatMode } from "./types";
6
- export { advancedTabsProperties, ANONYMOUS_USERNAME } from "./utils";
7
- export { isAlphaNumeric32 } from "./utils";
8
- export { getTimeAgo } from "./utils";
9
- export { getInitials } from "./utils";
10
- export { isInIframe, sendMessageToParentWebsite, deleteCookie, getDomainParts, deleteCookieOnAllDomains, getParentDomain, setCookieForAuth, clearCookies, isLoggedIn, getPlatformKey, redirectToAuthSpa, getAuthSpaJoinUrl, redirectToAuthSpaJoinTenant, handleLogout, } from "./utils/auth";
175
+ export type { OAuthRequiredData, OAuthResolvedData, } from "./hooks/chat/use-chat-v2";
11
176
  export type { RedirectToAuthSpaOptions, HandleLogoutOptions, } from "./utils/auth";
12
- export { chatActions, selectSessionId } from "./features/chat/slice";
13
- export { AuthProvider, TenantProvider, MentorProvider } from "./providers";
14
- export { useSearchParams, useParams, useRouter, usePathname, } from "next/navigation";
@@ -69,7 +69,7 @@ export declare function clearCurrentTenantCookie(): void;
69
69
  */
70
70
  export declare function clearAuthCookies(): void;
71
71
  export declare function getUserName(storageService: StorageService): Promise<any>;
72
- export declare function useAuthProvider({ middleware, onAuthSuccess, onAuthFailure, redirectToAuthSpa, hasNonExpiredAuthToken, username, pathname, storageService, skipAuthCheck, token, }: Props): {
72
+ export declare function useAuthProvider({ middleware, onAuthSuccess, onAuthFailure, redirectToAuthSpa, hasNonExpiredAuthToken, username, pathname, storageService, skipAuthCheck, token, enableStorageSync, }: Props): {
73
73
  isAuthenticating: boolean;
74
74
  userIsAccessingPublicRoute: boolean;
75
75
  setUserIsAccessingPublicRoute: React.Dispatch<React.SetStateAction<boolean>>;
@@ -80,6 +80,7 @@ export declare function useAuthProvider({ middleware, onAuthSuccess, onAuthFailu
80
80
  */
81
81
  export type AuthContextType = {
82
82
  userIsAccessingPublicRoute: boolean;
83
+ isLoggedIn: boolean;
83
84
  setUserIsAccessingPublicRoute: (iuserIsAccessingPublicRoute: boolean) => void;
84
85
  };
85
86
  export declare const AuthContext: React.Context<AuthContextType | undefined>;
@@ -111,6 +112,8 @@ type Props = {
111
112
  skipAuthCheck?: boolean;
112
113
  storageService?: StorageService;
113
114
  token?: string;
115
+ enableStorageSync?: boolean;
116
+ skip?: boolean;
114
117
  };
115
118
  /**
116
119
  * AuthProvider Component
@@ -122,5 +125,5 @@ type Props = {
122
125
  * 4. Handles redirects to auth SPA when needed
123
126
  * 5. Manages public route access state
124
127
  */
125
- export declare function AuthProvider({ children, fallback, middleware, onAuthSuccess, onAuthFailure, redirectToAuthSpa, hasNonExpiredAuthToken, username, pathname, skipAuthCheck, storageService, token, }: Props): string | number | bigint | boolean | Iterable<React.ReactNode> | Promise<string | number | bigint | boolean | React.ReactPortal | React.ReactElement<unknown, string | React.JSXElementConstructor<any>> | Iterable<React.ReactNode> | null | undefined> | import("react/jsx-runtime").JSX.Element | null | undefined;
128
+ export declare function AuthProvider({ children, fallback, middleware, onAuthSuccess, onAuthFailure, redirectToAuthSpa, hasNonExpiredAuthToken, username, pathname, skipAuthCheck, storageService, token, enableStorageSync, skip, }: Props): string | number | bigint | boolean | Iterable<React.ReactNode> | Promise<string | number | bigint | boolean | React.ReactPortal | React.ReactElement<unknown, string | React.JSXElementConstructor<any>> | Iterable<React.ReactNode> | null | undefined> | import("react/jsx-runtime").JSX.Element | null | undefined;
126
129
  export {};
@@ -29,6 +29,7 @@ type Props = {
29
29
  handleMentorNotFound?: () => Promise<void>;
30
30
  forceDetermineMentor?: boolean;
31
31
  onComplete?: () => void;
32
+ skip?: boolean;
32
33
  };
33
34
  /**
34
35
  * MentorProvider Component
@@ -39,5 +40,5 @@ type Props = {
39
40
  * 3. Manages redirection based on mentor availability
40
41
  * 4. Integrates with tenant context for access control
41
42
  */
42
- export declare function MentorProvider({ children, fallback, onAuthSuccess, onAuthFailure, redirectToAuthSpa, redirectToMentor, onLoadMentorsPermissions, redirectToNoMentorsPage, redirectToCreateMentor, username, isAdmin, mainTenantKey, requestedMentorId, handleMentorNotFound, forceDetermineMentor, onComplete, }: Props): React.ReactNode;
43
+ export declare function MentorProvider({ children, fallback, onAuthSuccess, onAuthFailure, redirectToAuthSpa, redirectToMentor, onLoadMentorsPermissions, redirectToNoMentorsPage, redirectToCreateMentor, username, isAdmin, mainTenantKey, requestedMentorId, handleMentorNotFound, forceDetermineMentor, onComplete, skip, }: Props): string | number | bigint | boolean | Iterable<React.ReactNode> | Promise<string | number | bigint | boolean | React.ReactPortal | React.ReactElement<unknown, string | React.JSXElementConstructor<any>> | Iterable<React.ReactNode> | null | undefined> | import("react/jsx-runtime").JSX.Element | null | undefined;
43
44
  export {};
@@ -19,6 +19,7 @@ export type TenantContextType = {
19
19
  determineUserPath: boolean;
20
20
  setDetermineUserPath: (value: boolean) => void;
21
21
  tenantKey: string;
22
+ setTenantKey: (tenantKey: string) => void;
22
23
  metadata: Record<string, any>;
23
24
  setMetadata: (metadata: Record<string, any>) => void;
24
25
  };
@@ -45,7 +46,7 @@ type Props = {
45
46
  onAuthFailure?: (reason: string) => void;
46
47
  currentTenant: string;
47
48
  requestedTenant: string;
48
- handleTenantSwitch: (tenant: string, saveRedirect: boolean) => Promise<void>;
49
+ handleTenantSwitch: (tenant: string, saveRedirect: boolean, useCustomDomain?: boolean) => Promise<void>;
49
50
  saveCurrentTenant: (tenant: Tenant) => void;
50
51
  saveUserTenants: (tenants: Tenant[]) => void;
51
52
  saveVisitingTenant?: (tenant: Tenant) => void;
@@ -55,6 +56,10 @@ type Props = {
55
56
  onAutoJoinUserToTenant?: (platformName: string) => void;
56
57
  redirectToAuthSpa?: (redirectTo?: string, platformKey?: string, logout?: boolean, saveRedirect?: boolean) => void;
57
58
  username?: string;
59
+ isIframed?: boolean;
60
+ setUseMentorProvider?: (useMentorProvider: boolean) => void;
61
+ skip?: boolean;
62
+ onLoadPlatformPermissions?: (rbacPermissions: Record<string, unknown> | undefined) => void;
58
63
  };
59
64
  /**
60
65
  * TenantProvider Component
@@ -66,5 +71,5 @@ type Props = {
66
71
  * 4. Handles tenant-specific domain redirects
67
72
  * 5. Maintains tenant access state
68
73
  */
69
- export declare function TenantProvider({ children, fallback, onAuthSuccess, onAuthFailure, currentTenant, requestedTenant, saveCurrentTenant, saveUserTenants, handleTenantSwitch, saveVisitingTenant, removeVisitingTenant, saveUserTokens, saveTenant, onAutoJoinUserToTenant, redirectToAuthSpa, username, }: Props): string | number | bigint | boolean | Iterable<React.ReactNode> | Promise<string | number | bigint | boolean | React.ReactPortal | React.ReactElement<unknown, string | React.JSXElementConstructor<any>> | Iterable<React.ReactNode> | null | undefined> | import("react/jsx-runtime").JSX.Element | null | undefined;
74
+ export declare function TenantProvider({ children, fallback, onAuthSuccess, onAuthFailure, currentTenant, requestedTenant, saveCurrentTenant, saveUserTenants, handleTenantSwitch, saveVisitingTenant, removeVisitingTenant, saveUserTokens, saveTenant, onAutoJoinUserToTenant, redirectToAuthSpa, username, isIframed, setUseMentorProvider, skip, onLoadPlatformPermissions, }: Props): string | number | bigint | boolean | Iterable<React.ReactNode> | Promise<string | number | bigint | boolean | React.ReactPortal | React.ReactElement<unknown, string | React.JSXElementConstructor<any>> | Iterable<React.ReactNode> | null | undefined> | import("react/jsx-runtime").JSX.Element | null | undefined;
70
75
  export {};
@@ -59,6 +59,7 @@ export interface Tenant {
59
59
  name?: string;
60
60
  platform_name: string;
61
61
  is_advertising?: boolean;
62
+ is_enterprise?: boolean;
62
63
  }
63
64
  export * from "./chat";
64
65
  export * from "./subscription";
@@ -16,3 +16,24 @@ export interface CreateStripeCustomerPortalRequest {
16
16
  userId: string;
17
17
  requestBody: StripeCustomerPortalRequest;
18
18
  }
19
+ /**
20
+ * Shape of the 402 Payment Required error response body.
21
+ * Note: Only `error` is required. Other fields may not be present
22
+ * in all error scenarios (e.g., generic API 402 vs WebSocket 402).
23
+ */
24
+ export interface Error402MessageData {
25
+ error: string;
26
+ message?: string;
27
+ details?: {
28
+ platform_key: string;
29
+ current_balance_usd: string;
30
+ required_usd: string;
31
+ deficit_usd: string;
32
+ };
33
+ pricing_table?: {
34
+ pricing_table_id: string;
35
+ pricing_table_js: string;
36
+ publishable_key?: string;
37
+ client_reference_id?: string;
38
+ };
39
+ }
@@ -0,0 +1 @@
1
+ export {};
@@ -26,6 +26,7 @@ export declare const TOOLS: {
26
26
  readonly HUMAN_SUPPORT: "human-support";
27
27
  readonly CODE_INTERPRETER: "code-interpreter";
28
28
  readonly DEEP_RESEARCH: "deep-research";
29
+ readonly STUDY_MODE: "study-mode";
29
30
  readonly MEMORY: "memory";
30
31
  readonly SCREEN_SHARE: "screen-share";
31
32
  readonly POWERPOINT: "powerpoint";
@@ -5,3 +5,9 @@ export declare const isAlphaNumeric32: (text: string) => boolean;
5
5
  export declare const addProtocolToUrl: (url: string) => string;
6
6
  export declare function getTimeAgo(createdAt: string): string;
7
7
  export declare const formatRelativeTime: (timestamp: string) => string;
8
+ /**
9
+ * Convert markdown text to plain text by removing markdown formatting
10
+ * @param text - The markdown text to convert
11
+ * @returns Plain text without markdown formatting
12
+ */
13
+ export declare const markdownToPlainText: (text: string) => string;
@@ -2,3 +2,4 @@ export * from "./data/advanced-tab";
2
2
  export * from "./constants";
3
3
  export * from "./helpers";
4
4
  export * from "./auth";
5
+ export * from "./platform";
@@ -2,6 +2,7 @@ export declare const isReactNative: () => boolean;
2
2
  export declare const isWeb: () => boolean;
3
3
  export declare const isNode: () => string | false;
4
4
  export declare const isExpo: () => any;
5
+ export declare const isTauri: () => boolean;
5
6
  export declare const getPlatform: () => "react-native" | "web" | "node" | "unknown";
6
7
  export declare const safeRequire: (moduleName: string) => any;
7
8
  export declare const getNextNavigation: () => any;
@@ -0,0 +1 @@
1
+ export {};