camox 0.0.0 → 0.1.2-alpha.2

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 (255) hide show
  1. package/LICENSE.md +110 -0
  2. package/dist/components/AuthGate.d.ts +7 -0
  3. package/dist/components/AuthGate.d.ts.map +1 -0
  4. package/dist/core/components/AddBlockControlBar.d.ts +9 -0
  5. package/dist/core/components/AddBlockControlBar.d.ts.map +1 -0
  6. package/dist/core/components/AddBlockControlBar.js +65 -0
  7. package/dist/core/components/lexical/InlineContentEditable.d.ts +7 -0
  8. package/dist/core/components/lexical/InlineContentEditable.d.ts.map +1 -0
  9. package/dist/core/components/lexical/InlineContentEditable.js +40 -0
  10. package/dist/core/components/lexical/InlineLexicalEditor.d.ts +12 -0
  11. package/dist/core/components/lexical/InlineLexicalEditor.d.ts.map +1 -0
  12. package/dist/core/components/lexical/InlineLexicalEditor.js +133 -0
  13. package/dist/core/components/lexical/InlineParagraphNode.d.ts +10 -0
  14. package/dist/core/components/lexical/InlineParagraphNode.d.ts.map +1 -0
  15. package/dist/core/components/lexical/InlineParagraphNode.js +34 -0
  16. package/dist/core/components/lexical/SelectionBroadcaster.d.ts +6 -0
  17. package/dist/core/components/lexical/SelectionBroadcaster.d.ts.map +1 -0
  18. package/dist/core/components/lexical/SelectionBroadcaster.js +62 -0
  19. package/dist/core/components/lexical/SidebarLexicalEditor.d.ts +9 -0
  20. package/dist/core/components/lexical/SidebarLexicalEditor.d.ts.map +1 -0
  21. package/dist/core/components/lexical/editorConfig.d.ts +4 -0
  22. package/dist/core/components/lexical/editorConfig.d.ts.map +1 -0
  23. package/dist/core/components/lexical/editorConfig.js +24 -0
  24. package/dist/core/createApp.d.ts +373 -0
  25. package/dist/core/createApp.d.ts.map +1 -0
  26. package/dist/core/createApp.js +40 -0
  27. package/dist/core/createBlock.d.ts +947 -0
  28. package/dist/core/createBlock.d.ts.map +1 -0
  29. package/dist/core/createBlock.js +873 -0
  30. package/dist/core/createLayout.d.ts +78 -0
  31. package/dist/core/createLayout.d.ts.map +1 -0
  32. package/dist/core/createLayout.js +73 -0
  33. package/dist/core/hooks/useFieldSelection.d.ts +11 -0
  34. package/dist/core/hooks/useFieldSelection.d.ts.map +1 -0
  35. package/dist/core/hooks/useFieldSelection.js +25 -0
  36. package/dist/core/hooks/useIsEditable.d.ts +2 -0
  37. package/dist/core/hooks/useIsEditable.d.ts.map +1 -0
  38. package/dist/core/hooks/useIsEditable.js +12 -0
  39. package/dist/core/hooks/useOverlayMessage.d.ts +10 -0
  40. package/dist/core/hooks/useOverlayMessage.d.ts.map +1 -0
  41. package/dist/core/hooks/useOverlayMessage.js +37 -0
  42. package/dist/core/lib/contentType.d.ts +165 -0
  43. package/dist/core/lib/contentType.d.ts.map +1 -0
  44. package/dist/core/lib/contentType.js +148 -0
  45. package/dist/core/lib/fieldTypes.d.ts +85 -0
  46. package/dist/core/lib/fieldTypes.d.ts.map +1 -0
  47. package/dist/core/lib/lexicalReact.d.ts +3 -0
  48. package/dist/core/lib/lexicalReact.d.ts.map +1 -0
  49. package/dist/core/lib/lexicalReact.js +24 -0
  50. package/dist/core/lib/lexicalState.d.ts +10 -0
  51. package/dist/core/lib/lexicalState.d.ts.map +1 -0
  52. package/dist/core/lib/lexicalState.js +38 -0
  53. package/dist/core/lib/modifierFormats.d.ts +9 -0
  54. package/dist/core/lib/modifierFormats.d.ts.map +1 -0
  55. package/dist/core/lib/modifierFormats.js +8 -0
  56. package/dist/core/lib/modifiers.d.ts +12 -0
  57. package/dist/core/lib/modifiers.d.ts.map +1 -0
  58. package/dist/core/lib/modifiers.js +27 -0
  59. package/dist/features/content/CamoxContent.d.ts +2 -0
  60. package/dist/features/content/CamoxContent.d.ts.map +1 -0
  61. package/dist/features/content/CamoxContent.js +100 -0
  62. package/dist/features/content/components/AssetCard.d.ts +10 -0
  63. package/dist/features/content/components/AssetCard.d.ts.map +1 -0
  64. package/dist/features/content/components/AssetCard.js +41 -0
  65. package/dist/features/content/components/AssetCardSkeleton.d.ts +2 -0
  66. package/dist/features/content/components/AssetCardSkeleton.d.ts.map +1 -0
  67. package/dist/features/content/components/AssetCardSkeleton.js +11 -0
  68. package/dist/features/content/components/ContentSidebar.d.ts +2 -0
  69. package/dist/features/content/components/ContentSidebar.d.ts.map +1 -0
  70. package/dist/features/content/components/ContentSidebar.js +15 -0
  71. package/dist/features/content/components/UploadDropZone.d.ts +9 -0
  72. package/dist/features/content/components/UploadDropZone.d.ts.map +1 -0
  73. package/dist/features/content/components/UploadDropZone.js +51 -0
  74. package/dist/features/content/components/UploadProgressDrawer.d.ts +11 -0
  75. package/dist/features/content/components/UploadProgressDrawer.d.ts.map +1 -0
  76. package/dist/features/content/components/UploadProgressDrawer.js +72 -0
  77. package/dist/features/preview/CamoxPreview.d.ts +124 -0
  78. package/dist/features/preview/CamoxPreview.d.ts.map +1 -0
  79. package/dist/features/preview/CamoxPreview.js +253 -0
  80. package/dist/features/preview/components/AddBlockSheet.d.ts +3 -0
  81. package/dist/features/preview/components/AddBlockSheet.d.ts.map +1 -0
  82. package/dist/features/preview/components/AddBlockSheet.js +121 -0
  83. package/dist/features/preview/components/AgentChatSheet.d.ts +3 -0
  84. package/dist/features/preview/components/AgentChatSheet.d.ts.map +1 -0
  85. package/dist/features/preview/components/AgentChatSheet.js +24 -0
  86. package/dist/features/preview/components/AssetFieldEditor.d.ts +18 -0
  87. package/dist/features/preview/components/AssetFieldEditor.d.ts.map +1 -0
  88. package/dist/features/preview/components/AssetFieldEditor.js +139 -0
  89. package/dist/features/preview/components/AssetLightbox.d.ts +9 -0
  90. package/dist/features/preview/components/AssetLightbox.d.ts.map +1 -0
  91. package/dist/features/preview/components/AssetLightbox.js +421 -0
  92. package/dist/features/preview/components/AssetPickerGrid.d.ts +11 -0
  93. package/dist/features/preview/components/AssetPickerGrid.d.ts.map +1 -0
  94. package/dist/features/preview/components/AssetPickerGrid.js +92 -0
  95. package/dist/features/preview/components/BlockActionsPopover.d.ts +15 -0
  96. package/dist/features/preview/components/BlockActionsPopover.d.ts.map +1 -0
  97. package/dist/features/preview/components/BlockActionsPopover.js +506 -0
  98. package/dist/features/preview/components/CreatePageSheet.d.ts +3 -0
  99. package/dist/features/preview/components/CreatePageSheet.d.ts.map +1 -0
  100. package/dist/features/preview/components/CreatePageSheet.js +159 -0
  101. package/dist/features/preview/components/DebouncedFieldEditor.d.ts +10 -0
  102. package/dist/features/preview/components/DebouncedFieldEditor.d.ts.map +1 -0
  103. package/dist/features/preview/components/DebouncedFieldEditor.js +51 -0
  104. package/dist/features/preview/components/EditPageSheet.d.ts +3 -0
  105. package/dist/features/preview/components/EditPageSheet.d.ts.map +1 -0
  106. package/dist/features/preview/components/EditPageSheet.js +352 -0
  107. package/dist/features/preview/components/ItemFieldsEditor.d.ts +29 -0
  108. package/dist/features/preview/components/ItemFieldsEditor.d.ts.map +1 -0
  109. package/dist/features/preview/components/ItemFieldsEditor.js +308 -0
  110. package/dist/features/preview/components/LinkFieldEditor.d.ts +8 -0
  111. package/dist/features/preview/components/LinkFieldEditor.d.ts.map +1 -0
  112. package/dist/features/preview/components/LinkFieldEditor.js +190 -0
  113. package/dist/features/preview/components/MultipleAssetFieldEditor.d.ts +10 -0
  114. package/dist/features/preview/components/MultipleAssetFieldEditor.d.ts.map +1 -0
  115. package/dist/features/preview/components/MultipleAssetFieldEditor.js +232 -0
  116. package/dist/features/preview/components/OverlayTracker.d.ts +6 -0
  117. package/dist/features/preview/components/OverlayTracker.d.ts.map +1 -0
  118. package/dist/features/preview/components/OverlayTracker.js +41 -0
  119. package/dist/features/preview/components/Overlays.d.ts +6 -0
  120. package/dist/features/preview/components/Overlays.d.ts.map +1 -0
  121. package/dist/features/preview/components/Overlays.js +58 -0
  122. package/dist/features/preview/components/PageContentSheet.d.ts +3 -0
  123. package/dist/features/preview/components/PageContentSheet.d.ts.map +1 -0
  124. package/dist/features/preview/components/PageContentSheet.js +492 -0
  125. package/dist/features/preview/components/PageLocationFieldset.d.ts +14 -0
  126. package/dist/features/preview/components/PageLocationFieldset.d.ts.map +1 -0
  127. package/dist/features/preview/components/PageLocationFieldset.js +77 -0
  128. package/dist/features/preview/components/PagePicker.d.ts +3 -0
  129. package/dist/features/preview/components/PagePicker.d.ts.map +1 -0
  130. package/dist/features/preview/components/PagePicker.js +185 -0
  131. package/dist/features/preview/components/PageTree.d.ts +3 -0
  132. package/dist/features/preview/components/PageTree.d.ts.map +1 -0
  133. package/dist/features/preview/components/PageTree.js +410 -0
  134. package/dist/features/preview/components/PeekedBlock.d.ts +6 -0
  135. package/dist/features/preview/components/PeekedBlock.d.ts.map +1 -0
  136. package/dist/features/preview/components/PeekedBlock.js +95 -0
  137. package/dist/features/preview/components/PreviewPanel.d.ts +12 -0
  138. package/dist/features/preview/components/PreviewPanel.d.ts.map +1 -0
  139. package/dist/features/preview/components/PreviewPanel.js +192 -0
  140. package/dist/features/preview/components/PreviewSideSheet.d.ts +13 -0
  141. package/dist/features/preview/components/PreviewSideSheet.d.ts.map +1 -0
  142. package/dist/features/preview/components/PreviewSideSheet.js +28 -0
  143. package/dist/features/preview/components/PreviewToolbar.d.ts +2 -0
  144. package/dist/features/preview/components/PreviewToolbar.d.ts.map +1 -0
  145. package/dist/features/preview/components/PreviewToolbar.js +79 -0
  146. package/dist/features/preview/components/RepeatableItemsList.d.ts +14 -0
  147. package/dist/features/preview/components/RepeatableItemsList.d.ts.map +1 -0
  148. package/dist/features/preview/components/RepeatableItemsList.js +366 -0
  149. package/dist/features/preview/components/ShikiMarkdown.d.ts +4 -0
  150. package/dist/features/preview/components/ShikiMarkdown.d.ts.map +1 -0
  151. package/dist/features/preview/components/ShikiMarkdown.js +37 -0
  152. package/dist/features/preview/components/TextFormatToolbar.d.ts +2 -0
  153. package/dist/features/preview/components/TextFormatToolbar.d.ts.map +1 -0
  154. package/dist/features/preview/components/TextFormatToolbar.js +73 -0
  155. package/dist/features/preview/components/UnlinkAssetButton.d.ts +9 -0
  156. package/dist/features/preview/components/UnlinkAssetButton.d.ts.map +1 -0
  157. package/dist/features/preview/components/UnlinkAssetButton.js +55 -0
  158. package/dist/features/preview/overlayConstants.d.ts +19 -0
  159. package/dist/features/preview/overlayConstants.d.ts.map +1 -0
  160. package/dist/features/preview/overlayConstants.js +21 -0
  161. package/dist/features/preview/overlayMessages.d.ts +62 -0
  162. package/dist/features/preview/overlayMessages.d.ts.map +1 -0
  163. package/dist/features/preview/overlayMessages.js +9 -0
  164. package/dist/features/preview/previewConstants.d.ts +2 -0
  165. package/dist/features/preview/previewConstants.d.ts.map +1 -0
  166. package/dist/features/preview/previewStore.d.ts +116 -0
  167. package/dist/features/preview/previewStore.d.ts.map +1 -0
  168. package/dist/features/preview/previewStore.js +321 -0
  169. package/dist/features/provider/CamoxProvider.d.ts +11 -0
  170. package/dist/features/provider/CamoxProvider.d.ts.map +1 -0
  171. package/dist/features/provider/CamoxProvider.js +73 -0
  172. package/dist/features/provider/actionsStore.d.ts +39 -0
  173. package/dist/features/provider/actionsStore.d.ts.map +1 -0
  174. package/dist/features/provider/actionsStore.js +35 -0
  175. package/dist/features/provider/components/CamoxAppContext.d.ts +371 -0
  176. package/dist/features/provider/components/CamoxAppContext.d.ts.map +1 -0
  177. package/dist/features/provider/components/CamoxAppContext.js +17 -0
  178. package/dist/features/provider/components/CommandPalette.d.ts +3 -0
  179. package/dist/features/provider/components/CommandPalette.d.ts.map +1 -0
  180. package/dist/features/provider/components/CommandPalette.js +127 -0
  181. package/dist/features/provider/useAdminShortcuts.d.ts +5 -0
  182. package/dist/features/provider/useAdminShortcuts.d.ts.map +1 -0
  183. package/dist/features/provider/useAdminShortcuts.js +83 -0
  184. package/dist/features/routes/ogRoute.d.ts +7 -0
  185. package/dist/features/routes/ogRoute.d.ts.map +1 -0
  186. package/dist/features/routes/ogRoute.js +19 -0
  187. package/dist/features/routes/pageRoute.d.ts +135 -0
  188. package/dist/features/routes/pageRoute.d.ts.map +1 -0
  189. package/dist/features/routes/pageRoute.js +112 -0
  190. package/dist/features/studio/CamoxStudio.d.ts +7 -0
  191. package/dist/features/studio/CamoxStudio.d.ts.map +1 -0
  192. package/dist/features/studio/CamoxStudio.js +24 -0
  193. package/dist/features/studio/components/Navbar.d.ts +4 -0
  194. package/dist/features/studio/components/Navbar.d.ts.map +1 -0
  195. package/dist/features/studio/components/Navbar.js +95 -0
  196. package/dist/features/studio/components/ProjectMenu.d.ts +2 -0
  197. package/dist/features/studio/components/ProjectMenu.d.ts.map +1 -0
  198. package/dist/features/studio/components/ProjectMenu.js +132 -0
  199. package/dist/features/studio/components/UserButton.d.ts +2 -0
  200. package/dist/features/studio/components/UserButton.d.ts.map +1 -0
  201. package/dist/features/studio/components/UserButton.js +96 -0
  202. package/dist/features/studio/studioStore.d.ts +17 -0
  203. package/dist/features/studio/studioStore.d.ts.map +1 -0
  204. package/dist/features/studio/studioStore.js +44 -0
  205. package/dist/features/studio/useTheme.d.ts +9 -0
  206. package/dist/features/studio/useTheme.d.ts.map +1 -0
  207. package/dist/features/studio/useTheme.js +98 -0
  208. package/dist/features/vite/appGeneration.d.ts +4 -0
  209. package/dist/features/vite/appGeneration.d.ts.map +1 -0
  210. package/dist/features/vite/appGeneration.js +67 -0
  211. package/dist/features/vite/blockBoilerplate.d.ts +3 -0
  212. package/dist/features/vite/blockBoilerplate.d.ts.map +1 -0
  213. package/dist/features/vite/blockBoilerplate.js +59 -0
  214. package/dist/features/vite/convexSync.d.ts +6 -0
  215. package/dist/features/vite/convexSync.d.ts.map +1 -0
  216. package/dist/features/vite/convexSync.js +98 -0
  217. package/dist/features/vite/definitionsSync.d.ts +11 -0
  218. package/dist/features/vite/definitionsSync.d.ts.map +1 -0
  219. package/dist/features/vite/definitionsSync.js +157 -0
  220. package/dist/features/vite/routeGeneration.d.ts +4 -0
  221. package/dist/features/vite/routeGeneration.d.ts.map +1 -0
  222. package/dist/features/vite/routeGeneration.js +194 -0
  223. package/dist/features/vite/skillGeneration.d.ts +4 -0
  224. package/dist/features/vite/skillGeneration.d.ts.map +1 -0
  225. package/dist/features/vite/skillGeneration.js +69 -0
  226. package/dist/features/vite/utils.d.ts +2 -0
  227. package/dist/features/vite/utils.d.ts.map +1 -0
  228. package/dist/features/vite/utils.js +10 -0
  229. package/dist/features/vite/vite.d.ts +18 -0
  230. package/dist/features/vite/vite.d.ts.map +1 -0
  231. package/dist/features/vite/vite.js +77 -0
  232. package/dist/hooks/use-file-upload.d.ts +22 -0
  233. package/dist/hooks/use-file-upload.d.ts.map +1 -0
  234. package/dist/hooks/use-marquee-selection.d.ts +17 -0
  235. package/dist/hooks/use-marquee-selection.d.ts.map +1 -0
  236. package/dist/lib/analytics-client.d.ts +3 -0
  237. package/dist/lib/analytics-client.d.ts.map +1 -0
  238. package/dist/lib/analytics.d.ts +3 -0
  239. package/dist/lib/analytics.d.ts.map +1 -0
  240. package/dist/lib/analytics.js +24 -0
  241. package/dist/lib/auth.d.ts +3683 -0
  242. package/dist/lib/auth.d.ts.map +1 -0
  243. package/dist/lib/convex-site.d.ts +3 -0
  244. package/dist/lib/convex-site.d.ts.map +1 -0
  245. package/dist/lib/utils.d.ts +40 -0
  246. package/dist/lib/utils.d.ts.map +1 -0
  247. package/dist/studio.css +2 -0
  248. package/package.json +123 -10
  249. package/server/api.d.ts +1 -0
  250. package/server/api.js +1 -0
  251. package/server/dataModel.d.ts +1 -0
  252. package/server/dataModel.js +1 -0
  253. package/skills/camox-block/SKILL.md +357 -0
  254. package/skills/camox-layout/SKILL.md +181 -0
  255. package/index.js +0 -3
@@ -0,0 +1,3683 @@
1
+ import * as React from "react";
2
+ export type CamoxAuthClient = ReturnType<typeof createCamoxAuthClient>;
3
+ export declare function createCamoxAuthClient(managementUrl: string): {
4
+ useActiveOrganization: () => {
5
+ data: import('better-auth').Prettify<{
6
+ id: string;
7
+ name: string;
8
+ slug: string;
9
+ createdAt: Date;
10
+ logo?: string | null | undefined | undefined;
11
+ metadata?: any;
12
+ } & {
13
+ members: {
14
+ id: string;
15
+ organizationId: string;
16
+ role: "member" | "admin" | "owner";
17
+ createdAt: Date;
18
+ userId: string;
19
+ user: {
20
+ id: string;
21
+ email: string;
22
+ name: string;
23
+ image?: string | undefined;
24
+ };
25
+ }[];
26
+ invitations: {
27
+ id: string;
28
+ organizationId: string;
29
+ email: string;
30
+ role: "member" | "admin" | "owner";
31
+ status: import('better-auth/plugins').InvitationStatus;
32
+ inviterId: string;
33
+ expiresAt: Date;
34
+ createdAt: Date;
35
+ }[];
36
+ }> | null;
37
+ error: null | import('better-auth/client').BetterFetchError;
38
+ isPending: boolean;
39
+ isRefetching: boolean;
40
+ refetch: (queryParams?: {
41
+ query?: import('better-auth').SessionQueryParams;
42
+ } | undefined) => Promise<void>;
43
+ };
44
+ useListOrganizations: () => {
45
+ data: {
46
+ id: string;
47
+ name: string;
48
+ slug: string;
49
+ createdAt: Date;
50
+ logo?: string | null | undefined | undefined;
51
+ metadata?: any;
52
+ }[] | null;
53
+ error: null | import('better-auth/client').BetterFetchError;
54
+ isPending: boolean;
55
+ isRefetching: boolean;
56
+ refetch: (queryParams?: {
57
+ query?: import('better-auth').SessionQueryParams;
58
+ } | undefined) => Promise<void>;
59
+ };
60
+ useActiveMember: () => {
61
+ data: {
62
+ id: string;
63
+ organizationId: string;
64
+ userId: string;
65
+ role: string;
66
+ createdAt: Date;
67
+ } | null;
68
+ error: null | import('better-auth/client').BetterFetchError;
69
+ isPending: boolean;
70
+ isRefetching: boolean;
71
+ refetch: (queryParams?: {
72
+ query?: import('better-auth').SessionQueryParams;
73
+ } | undefined) => Promise<void>;
74
+ };
75
+ useActiveMemberRole: () => {
76
+ data: {
77
+ role: string;
78
+ } | null;
79
+ error: null | import('better-auth/client').BetterFetchError;
80
+ isPending: boolean;
81
+ isRefetching: boolean;
82
+ refetch: (queryParams?: {
83
+ query?: import('better-auth').SessionQueryParams;
84
+ } | undefined) => Promise<void>;
85
+ };
86
+ } & {
87
+ convex: {
88
+ jwks: <FetchOptions extends import('better-auth').ClientFetchOption<never, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0?: import('better-auth').Prettify<{
89
+ query?: Record<string, any> | undefined;
90
+ fetchOptions?: FetchOptions | undefined;
91
+ }> | undefined, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<import('better-auth').JSONWebKeySet, {
92
+ code?: string | undefined;
93
+ message?: string | undefined;
94
+ }, FetchOptions["throw"] extends true ? true : false>>;
95
+ };
96
+ } & {
97
+ convex: {
98
+ token: <FetchOptions extends import('better-auth').ClientFetchOption<never, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0?: import('better-auth').Prettify<{
99
+ query?: Record<string, any> | undefined;
100
+ fetchOptions?: FetchOptions | undefined;
101
+ }> | undefined, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
102
+ token: string;
103
+ }, {
104
+ code?: string | undefined;
105
+ message?: string | undefined;
106
+ }, FetchOptions["throw"] extends true ? true : false>>;
107
+ };
108
+ } & {
109
+ organization: {
110
+ create: <FetchOptions extends import('better-auth').ClientFetchOption<Partial<{
111
+ name: string;
112
+ slug: string;
113
+ userId?: string | undefined;
114
+ logo?: string | undefined;
115
+ metadata?: Record<string, any> | undefined;
116
+ keepCurrentActiveOrganization?: boolean | undefined;
117
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0: import('better-auth').Prettify<{
118
+ name: string;
119
+ slug: string;
120
+ userId?: string | undefined;
121
+ logo?: string | undefined;
122
+ metadata?: Record<string, any> | undefined;
123
+ keepCurrentActiveOrganization?: boolean | undefined;
124
+ } & {
125
+ fetchOptions?: FetchOptions | undefined;
126
+ }>, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<NonNullable<{
127
+ id: string;
128
+ name: string;
129
+ slug: string;
130
+ createdAt: Date;
131
+ logo?: string | null | undefined | undefined;
132
+ metadata?: any;
133
+ } & {
134
+ metadata: any;
135
+ members: ({
136
+ id: string;
137
+ organizationId: string;
138
+ userId: string;
139
+ role: string;
140
+ createdAt: Date;
141
+ } | undefined)[];
142
+ }>, {
143
+ code?: string | undefined;
144
+ message?: string | undefined;
145
+ }, FetchOptions["throw"] extends true ? true : false>>;
146
+ };
147
+ } & {
148
+ organization: {
149
+ update: <FetchOptions extends import('better-auth').ClientFetchOption<Partial<{
150
+ data: {
151
+ name?: string | undefined;
152
+ slug?: string | undefined;
153
+ logo?: string | undefined;
154
+ metadata?: Record<string, any> | undefined;
155
+ } & Partial<{}>;
156
+ organizationId?: string | undefined;
157
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0: import('better-auth').Prettify<{
158
+ data: {
159
+ name?: string | undefined;
160
+ slug?: string | undefined;
161
+ logo?: string | undefined;
162
+ metadata?: Record<string, any> | undefined;
163
+ } & Partial<{}>;
164
+ organizationId?: string | undefined;
165
+ } & {
166
+ fetchOptions?: FetchOptions | undefined;
167
+ }>, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
168
+ id: string;
169
+ name: string;
170
+ slug: string;
171
+ createdAt: Date;
172
+ logo?: string | null | undefined | undefined;
173
+ metadata?: any;
174
+ }, {
175
+ code?: string | undefined;
176
+ message?: string | undefined;
177
+ }, FetchOptions["throw"] extends true ? true : false>>;
178
+ };
179
+ } & {
180
+ organization: {
181
+ delete: <FetchOptions extends import('better-auth').ClientFetchOption<Partial<{
182
+ organizationId: string;
183
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0: import('better-auth').Prettify<{
184
+ organizationId: string;
185
+ } & {
186
+ fetchOptions?: FetchOptions | undefined;
187
+ }>, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
188
+ id: string;
189
+ name: string;
190
+ slug: string;
191
+ createdAt: Date;
192
+ logo?: string | null | undefined | undefined;
193
+ metadata?: any;
194
+ }, {
195
+ code?: string | undefined;
196
+ message?: string | undefined;
197
+ }, FetchOptions["throw"] extends true ? true : false>>;
198
+ };
199
+ } & {
200
+ organization: {
201
+ setActive: <FetchOptions extends import('better-auth').ClientFetchOption<Partial<{
202
+ organizationId?: string | null | undefined;
203
+ organizationSlug?: string | undefined;
204
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0?: import('better-auth').Prettify<{
205
+ organizationId?: string | null | undefined;
206
+ organizationSlug?: string | undefined;
207
+ } & {
208
+ fetchOptions?: FetchOptions | undefined;
209
+ }> | undefined, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
210
+ members: {
211
+ id: string;
212
+ organizationId: string;
213
+ role: "member" | "admin" | "owner";
214
+ createdAt: Date;
215
+ userId: string;
216
+ user: {
217
+ id: string;
218
+ email: string;
219
+ name: string;
220
+ image?: string | undefined;
221
+ };
222
+ }[];
223
+ invitations: {
224
+ id: string;
225
+ organizationId: string;
226
+ email: string;
227
+ role: "member" | "admin" | "owner";
228
+ status: import('better-auth/plugins').InvitationStatus;
229
+ inviterId: string;
230
+ expiresAt: Date;
231
+ createdAt: Date;
232
+ }[];
233
+ } & {
234
+ id: string;
235
+ name: string;
236
+ slug: string;
237
+ createdAt: Date;
238
+ logo?: string | null | undefined | undefined;
239
+ metadata?: any;
240
+ }, {
241
+ code?: string | undefined;
242
+ message?: string | undefined;
243
+ }, FetchOptions["throw"] extends true ? true : false>>;
244
+ };
245
+ } & {
246
+ organization: {
247
+ getFullOrganization: <FetchOptions extends import('better-auth').ClientFetchOption<never, Partial<{
248
+ organizationId?: string | undefined;
249
+ organizationSlug?: string | undefined;
250
+ membersLimit?: string | number | undefined;
251
+ }> & Record<string, any>, Record<string, any> | undefined>>(data_0?: import('better-auth').Prettify<{
252
+ query?: {
253
+ organizationId?: string | undefined;
254
+ organizationSlug?: string | undefined;
255
+ membersLimit?: string | number | undefined;
256
+ } | undefined;
257
+ fetchOptions?: FetchOptions | undefined;
258
+ }> | undefined, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
259
+ members: {
260
+ id: string;
261
+ organizationId: string;
262
+ role: "member" | "admin" | "owner";
263
+ createdAt: Date;
264
+ userId: string;
265
+ user: {
266
+ id: string;
267
+ email: string;
268
+ name: string;
269
+ image?: string | undefined;
270
+ };
271
+ }[];
272
+ invitations: {
273
+ id: string;
274
+ organizationId: string;
275
+ email: string;
276
+ role: "member" | "admin" | "owner";
277
+ status: import('better-auth/plugins').InvitationStatus;
278
+ inviterId: string;
279
+ expiresAt: Date;
280
+ createdAt: Date;
281
+ }[];
282
+ } & {
283
+ id: string;
284
+ name: string;
285
+ slug: string;
286
+ createdAt: Date;
287
+ logo?: string | null | undefined | undefined;
288
+ metadata?: any;
289
+ }, {
290
+ code?: string | undefined;
291
+ message?: string | undefined;
292
+ }, FetchOptions["throw"] extends true ? true : false>>;
293
+ };
294
+ } & {
295
+ organization: {
296
+ list: <FetchOptions extends import('better-auth').ClientFetchOption<never, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0?: import('better-auth').Prettify<{
297
+ query?: Record<string, any> | undefined;
298
+ fetchOptions?: FetchOptions | undefined;
299
+ }> | undefined, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
300
+ id: string;
301
+ name: string;
302
+ slug: string;
303
+ createdAt: Date;
304
+ logo?: string | null | undefined | undefined;
305
+ metadata?: any;
306
+ }[], {
307
+ code?: string | undefined;
308
+ message?: string | undefined;
309
+ }, FetchOptions["throw"] extends true ? true : false>>;
310
+ };
311
+ } & {
312
+ organization: {
313
+ inviteMember: <FetchOptions extends import('better-auth').ClientFetchOption<Partial<{
314
+ email: string;
315
+ role: "member" | "admin" | "owner" | ("member" | "admin" | "owner")[];
316
+ organizationId?: string | undefined;
317
+ resend?: boolean | undefined;
318
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0: import('better-auth').Prettify<{
319
+ email: string;
320
+ role: "member" | "admin" | "owner" | ("member" | "admin" | "owner")[];
321
+ organizationId?: string | undefined;
322
+ resend?: boolean | undefined;
323
+ } & {
324
+ fetchOptions?: FetchOptions | undefined;
325
+ }>, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<NonNullable<{
326
+ id: string;
327
+ organizationId: string;
328
+ email: string;
329
+ role: "member" | "admin" | "owner";
330
+ status: import('better-auth/plugins').InvitationStatus;
331
+ inviterId: string;
332
+ expiresAt: Date;
333
+ createdAt: Date;
334
+ } | {
335
+ id: string;
336
+ organizationId: string;
337
+ email: string;
338
+ role: "member" | "admin" | "owner";
339
+ status: import('better-auth/plugins').InvitationStatus;
340
+ inviterId: string;
341
+ expiresAt: Date;
342
+ createdAt: Date;
343
+ }>, {
344
+ code?: string | undefined;
345
+ message?: string | undefined;
346
+ }, FetchOptions["throw"] extends true ? true : false>>;
347
+ };
348
+ } & {
349
+ organization: {
350
+ cancelInvitation: <FetchOptions extends import('better-auth').ClientFetchOption<Partial<{
351
+ invitationId: string;
352
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0: import('better-auth').Prettify<{
353
+ invitationId: string;
354
+ } & {
355
+ fetchOptions?: FetchOptions | undefined;
356
+ }>, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
357
+ id: string;
358
+ organizationId: string;
359
+ email: string;
360
+ role: "member" | "admin" | "owner";
361
+ status: import('better-auth/plugins').InvitationStatus;
362
+ inviterId: string;
363
+ expiresAt: Date;
364
+ createdAt: Date;
365
+ }, {
366
+ code?: string | undefined;
367
+ message?: string | undefined;
368
+ }, FetchOptions["throw"] extends true ? true : false>>;
369
+ };
370
+ } & {
371
+ organization: {
372
+ acceptInvitation: <FetchOptions extends import('better-auth').ClientFetchOption<Partial<{
373
+ invitationId: string;
374
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0: import('better-auth').Prettify<{
375
+ invitationId: string;
376
+ } & {
377
+ fetchOptions?: FetchOptions | undefined;
378
+ }>, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
379
+ invitation: {
380
+ id: string;
381
+ organizationId: string;
382
+ email: string;
383
+ role: "member" | "admin" | "owner";
384
+ status: import('better-auth/plugins').InvitationStatus;
385
+ inviterId: string;
386
+ expiresAt: Date;
387
+ createdAt: Date;
388
+ };
389
+ member: {
390
+ id: string;
391
+ organizationId: string;
392
+ userId: string;
393
+ role: string;
394
+ createdAt: Date;
395
+ };
396
+ }, {
397
+ code?: string | undefined;
398
+ message?: string | undefined;
399
+ }, FetchOptions["throw"] extends true ? true : false>>;
400
+ };
401
+ } & {
402
+ organization: {
403
+ getInvitation: <FetchOptions extends import('better-auth').ClientFetchOption<never, Partial<{
404
+ id: string;
405
+ }> & Record<string, any>, Record<string, any> | undefined>>(data_0: import('better-auth').Prettify<{
406
+ query: {
407
+ id: string;
408
+ };
409
+ fetchOptions?: FetchOptions | undefined;
410
+ }>, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<NonNullable<{
411
+ id: string;
412
+ organizationId: string;
413
+ email: string;
414
+ role: "member" | "admin" | "owner";
415
+ status: import('better-auth/plugins').InvitationStatus;
416
+ inviterId: string;
417
+ expiresAt: Date;
418
+ createdAt: Date;
419
+ } & {
420
+ organizationName: string;
421
+ organizationSlug: string;
422
+ inviterEmail: string;
423
+ }>, {
424
+ code?: string | undefined;
425
+ message?: string | undefined;
426
+ }, FetchOptions["throw"] extends true ? true : false>>;
427
+ };
428
+ } & {
429
+ organization: {
430
+ rejectInvitation: <FetchOptions extends import('better-auth').ClientFetchOption<Partial<{
431
+ invitationId: string;
432
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0: import('better-auth').Prettify<{
433
+ invitationId: string;
434
+ } & {
435
+ fetchOptions?: FetchOptions | undefined;
436
+ }>, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
437
+ invitation: {
438
+ id: string;
439
+ organizationId: string;
440
+ email: string;
441
+ role: "admin" | "member" | "owner";
442
+ status: import('better-auth/plugins').InvitationStatus;
443
+ inviterId: string;
444
+ expiresAt: Date;
445
+ createdAt: Date;
446
+ } | null;
447
+ member: null;
448
+ }, {
449
+ code?: string | undefined;
450
+ message?: string | undefined;
451
+ }, FetchOptions["throw"] extends true ? true : false>>;
452
+ };
453
+ } & {
454
+ organization: {
455
+ listInvitations: <FetchOptions extends import('better-auth').ClientFetchOption<never, Partial<{
456
+ organizationId?: string | undefined;
457
+ }> & Record<string, any>, Record<string, any> | undefined>>(data_0?: import('better-auth').Prettify<{
458
+ query?: {
459
+ organizationId?: string | undefined;
460
+ } | undefined;
461
+ fetchOptions?: FetchOptions | undefined;
462
+ }> | undefined, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
463
+ id: string;
464
+ organizationId: string;
465
+ email: string;
466
+ role: "member" | "admin" | "owner";
467
+ status: import('better-auth/plugins').InvitationStatus;
468
+ inviterId: string;
469
+ expiresAt: Date;
470
+ createdAt: Date;
471
+ }[], {
472
+ code?: string | undefined;
473
+ message?: string | undefined;
474
+ }, FetchOptions["throw"] extends true ? true : false>>;
475
+ };
476
+ } & {
477
+ organization: {
478
+ getActiveMember: <FetchOptions extends import('better-auth').ClientFetchOption<never, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0?: import('better-auth').Prettify<{
479
+ query?: Record<string, any> | undefined;
480
+ fetchOptions?: FetchOptions | undefined;
481
+ }> | undefined, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<NonNullable<Omit<{
482
+ id: string;
483
+ organizationId: string;
484
+ role: "member" | "admin" | "owner";
485
+ createdAt: Date;
486
+ userId: string;
487
+ user: {
488
+ id: string;
489
+ email: string;
490
+ name: string;
491
+ image?: string | undefined;
492
+ };
493
+ } & {
494
+ user: {
495
+ id: string;
496
+ createdAt: Date;
497
+ updatedAt: Date;
498
+ email: string;
499
+ emailVerified: boolean;
500
+ name: string;
501
+ image?: string | null | undefined;
502
+ };
503
+ }, "user"> & {
504
+ user: {
505
+ id: string;
506
+ name: string;
507
+ email: string;
508
+ image: string | undefined;
509
+ };
510
+ }>, {
511
+ code?: string | undefined;
512
+ message?: string | undefined;
513
+ }, FetchOptions["throw"] extends true ? true : false>>;
514
+ };
515
+ } & {
516
+ organization: {
517
+ checkSlug: <FetchOptions extends import('better-auth').ClientFetchOption<Partial<{
518
+ slug: string;
519
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0: import('better-auth').Prettify<{
520
+ slug: string;
521
+ } & {
522
+ fetchOptions?: FetchOptions | undefined;
523
+ }>, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
524
+ status: boolean;
525
+ }, {
526
+ code?: string | undefined;
527
+ message?: string | undefined;
528
+ }, FetchOptions["throw"] extends true ? true : false>>;
529
+ };
530
+ } & {
531
+ organization: {
532
+ removeMember: <FetchOptions extends import('better-auth').ClientFetchOption<Partial<{
533
+ memberIdOrEmail: string;
534
+ organizationId?: string | undefined;
535
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0: import('better-auth').Prettify<{
536
+ memberIdOrEmail: string;
537
+ organizationId?: string | undefined;
538
+ } & {
539
+ fetchOptions?: FetchOptions | undefined;
540
+ }>, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
541
+ member: {
542
+ id: string;
543
+ organizationId: string;
544
+ role: "member" | "admin" | "owner";
545
+ createdAt: Date;
546
+ userId: string;
547
+ user: {
548
+ id: string;
549
+ email: string;
550
+ name: string;
551
+ image?: string | undefined;
552
+ };
553
+ };
554
+ }, {
555
+ code?: string | undefined;
556
+ message?: string | undefined;
557
+ }, FetchOptions["throw"] extends true ? true : false>>;
558
+ };
559
+ } & {
560
+ organization: {
561
+ updateMemberRole: <FetchOptions extends import('better-auth').ClientFetchOption<Partial<{
562
+ role: import('better-auth').LiteralString | "member" | import('better-auth').LiteralString[] | "admin" | "owner" | ("member" | "admin" | "owner")[];
563
+ memberId: string;
564
+ organizationId?: string | undefined;
565
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0: import('better-auth').Prettify<{
566
+ role: import('better-auth').LiteralString | "member" | import('better-auth').LiteralString[] | "admin" | "owner" | ("member" | "admin" | "owner")[];
567
+ memberId: string;
568
+ organizationId?: string | undefined;
569
+ } & {
570
+ fetchOptions?: FetchOptions | undefined;
571
+ }>, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
572
+ id: string;
573
+ organizationId: string;
574
+ role: "admin" | "member" | "owner";
575
+ createdAt: Date;
576
+ userId: string;
577
+ user: {
578
+ id: string;
579
+ email: string;
580
+ name: string;
581
+ image?: string | undefined;
582
+ };
583
+ }, {
584
+ code?: string | undefined;
585
+ message?: string | undefined;
586
+ }, FetchOptions["throw"] extends true ? true : false>>;
587
+ };
588
+ } & {
589
+ organization: {
590
+ leave: <FetchOptions extends import('better-auth').ClientFetchOption<Partial<{
591
+ organizationId: string;
592
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0: import('better-auth').Prettify<{
593
+ organizationId: string;
594
+ } & {
595
+ fetchOptions?: FetchOptions | undefined;
596
+ }>, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<NonNullable<Omit<{
597
+ id: string;
598
+ organizationId: string;
599
+ role: "member" | "admin" | "owner";
600
+ createdAt: Date;
601
+ userId: string;
602
+ user: {
603
+ id: string;
604
+ email: string;
605
+ name: string;
606
+ image?: string | undefined;
607
+ };
608
+ } & {
609
+ user: {
610
+ id: string;
611
+ createdAt: Date;
612
+ updatedAt: Date;
613
+ email: string;
614
+ emailVerified: boolean;
615
+ name: string;
616
+ image?: string | null | undefined;
617
+ };
618
+ }, "user"> & {
619
+ user: {
620
+ id: string;
621
+ name: string;
622
+ email: string;
623
+ image: string | undefined;
624
+ };
625
+ }>, {
626
+ code?: string | undefined;
627
+ message?: string | undefined;
628
+ }, FetchOptions["throw"] extends true ? true : false>>;
629
+ };
630
+ } & {
631
+ organization: {
632
+ listUserInvitations: <FetchOptions extends import('better-auth').ClientFetchOption<never, Partial<{
633
+ email?: string | undefined;
634
+ }> & Record<string, any>, Record<string, any> | undefined>>(data_0?: import('better-auth').Prettify<{
635
+ query?: {
636
+ email?: string | undefined;
637
+ } | undefined;
638
+ fetchOptions?: FetchOptions | undefined;
639
+ }> | undefined, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<(Omit<{
640
+ id: string;
641
+ organizationId: string;
642
+ email: string;
643
+ role: "member" | "admin" | "owner";
644
+ status: import('better-auth/plugins').InvitationStatus;
645
+ inviterId: string;
646
+ expiresAt: Date;
647
+ createdAt: Date;
648
+ } & {
649
+ organization: {
650
+ id: string;
651
+ name: string;
652
+ slug: string;
653
+ createdAt: Date;
654
+ logo?: string | null | undefined | undefined;
655
+ metadata?: any;
656
+ };
657
+ }, "organization"> & {
658
+ organizationName: string;
659
+ })[], {
660
+ code?: string | undefined;
661
+ message?: string | undefined;
662
+ }, FetchOptions["throw"] extends true ? true : false>>;
663
+ };
664
+ } & {
665
+ organization: {
666
+ listMembers: <FetchOptions extends import('better-auth').ClientFetchOption<never, Partial<{
667
+ limit?: string | number | undefined;
668
+ offset?: string | number | undefined;
669
+ sortBy?: string | undefined;
670
+ sortDirection?: "desc" | "asc" | undefined;
671
+ filterField?: string | undefined;
672
+ filterValue?: string | number | boolean | string[] | number[] | undefined;
673
+ filterOperator?: "in" | "eq" | "ne" | "gt" | "gte" | "lt" | "lte" | "not_in" | "contains" | "starts_with" | "ends_with" | undefined;
674
+ organizationId?: string | undefined;
675
+ organizationSlug?: string | undefined;
676
+ }> & Record<string, any>, Record<string, any> | undefined>>(data_0?: import('better-auth').Prettify<{
677
+ query?: {
678
+ limit?: string | number | undefined;
679
+ offset?: string | number | undefined;
680
+ sortBy?: string | undefined;
681
+ sortDirection?: "desc" | "asc" | undefined;
682
+ filterField?: string | undefined;
683
+ filterValue?: string | number | boolean | string[] | number[] | undefined;
684
+ filterOperator?: "in" | "eq" | "ne" | "gt" | "gte" | "lt" | "lte" | "not_in" | "contains" | "starts_with" | "ends_with" | undefined;
685
+ organizationId?: string | undefined;
686
+ organizationSlug?: string | undefined;
687
+ } | undefined;
688
+ fetchOptions?: FetchOptions | undefined;
689
+ }> | undefined, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
690
+ members: ({
691
+ id: string;
692
+ organizationId: string;
693
+ role: "member" | "admin" | "owner";
694
+ createdAt: Date;
695
+ userId: string;
696
+ user: {
697
+ id: string;
698
+ email: string;
699
+ name: string;
700
+ image?: string | undefined;
701
+ };
702
+ } & {
703
+ user: {
704
+ id: string;
705
+ name: string;
706
+ email: string;
707
+ image: string | null | undefined;
708
+ };
709
+ })[];
710
+ total: number;
711
+ }, {
712
+ code?: string | undefined;
713
+ message?: string | undefined;
714
+ }, FetchOptions["throw"] extends true ? true : false>>;
715
+ };
716
+ } & {
717
+ organization: {
718
+ getActiveMemberRole: <FetchOptions extends import('better-auth').ClientFetchOption<never, Partial<{
719
+ userId?: string | undefined;
720
+ organizationId?: string | undefined;
721
+ organizationSlug?: string | undefined;
722
+ }> & Record<string, any>, Record<string, any> | undefined>>(data_0?: import('better-auth').Prettify<{
723
+ query?: {
724
+ userId?: string | undefined;
725
+ organizationId?: string | undefined;
726
+ organizationSlug?: string | undefined;
727
+ } | undefined;
728
+ fetchOptions?: FetchOptions | undefined;
729
+ }> | undefined, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
730
+ role: "member" | "admin" | "owner";
731
+ }, {
732
+ code?: string | undefined;
733
+ message?: string | undefined;
734
+ }, FetchOptions["throw"] extends true ? true : false>>;
735
+ };
736
+ } & {
737
+ organization: {
738
+ hasPermission: <FetchOptions extends import('better-auth').ClientFetchOption<Partial<{
739
+ permissions: {
740
+ readonly organization?: ("delete" | "update")[] | undefined;
741
+ readonly member?: ("delete" | "create" | "update")[] | undefined;
742
+ readonly invitation?: ("cancel" | "create")[] | undefined;
743
+ readonly team?: ("delete" | "create" | "update")[] | undefined;
744
+ readonly ac?: ("delete" | "create" | "update" | "read")[] | undefined;
745
+ };
746
+ } & {
747
+ organizationId?: string | undefined;
748
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0: import('better-auth').Prettify<{
749
+ permissions: {
750
+ readonly organization?: ("delete" | "update")[] | undefined;
751
+ readonly member?: ("delete" | "create" | "update")[] | undefined;
752
+ readonly invitation?: ("cancel" | "create")[] | undefined;
753
+ readonly team?: ("delete" | "create" | "update")[] | undefined;
754
+ readonly ac?: ("delete" | "create" | "update" | "read")[] | undefined;
755
+ };
756
+ } & {
757
+ organizationId?: string | undefined;
758
+ } & {
759
+ fetchOptions?: FetchOptions | undefined;
760
+ }>, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
761
+ error: null;
762
+ success: boolean;
763
+ }, {
764
+ code?: string | undefined;
765
+ message?: string | undefined;
766
+ }, FetchOptions["throw"] extends true ? true : false>>;
767
+ };
768
+ } & {
769
+ oneTimeToken: {
770
+ generate: <FetchOptions extends import('better-auth').ClientFetchOption<never, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0?: import('better-auth').Prettify<{
771
+ query?: Record<string, any> | undefined;
772
+ fetchOptions?: FetchOptions | undefined;
773
+ }> | undefined, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
774
+ token: string;
775
+ }, {
776
+ code?: string | undefined;
777
+ message?: string | undefined;
778
+ }, FetchOptions["throw"] extends true ? true : false>>;
779
+ };
780
+ } & {
781
+ signIn: {
782
+ social: <FetchOptions extends import('better-auth').ClientFetchOption<Partial<{
783
+ provider: "line" | (string & {}) | "linear" | "huggingface" | "github" | "apple" | "atlassian" | "cognito" | "discord" | "facebook" | "figma" | "microsoft" | "google" | "slack" | "spotify" | "twitch" | "twitter" | "dropbox" | "kick" | "linkedin" | "gitlab" | "tiktok" | "reddit" | "roblox" | "salesforce" | "vk" | "zoom" | "notion" | "kakao" | "naver" | "paybin" | "paypal" | "polar" | "railway" | "vercel";
784
+ callbackURL?: string | undefined;
785
+ newUserCallbackURL?: string | undefined;
786
+ errorCallbackURL?: string | undefined;
787
+ disableRedirect?: boolean | undefined;
788
+ idToken?: {
789
+ token: string;
790
+ nonce?: string | undefined;
791
+ accessToken?: string | undefined;
792
+ refreshToken?: string | undefined;
793
+ expiresAt?: number | undefined;
794
+ user?: {
795
+ name?: {
796
+ firstName?: string | undefined;
797
+ lastName?: string | undefined;
798
+ } | undefined;
799
+ email?: string | undefined;
800
+ } | undefined;
801
+ } | undefined;
802
+ scopes?: string[] | undefined;
803
+ requestSignUp?: boolean | undefined;
804
+ loginHint?: string | undefined;
805
+ additionalData?: Record<string, any> | undefined;
806
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0: import('better-auth').Prettify<{
807
+ provider: "line" | (string & {}) | "linear" | "huggingface" | "github" | "apple" | "atlassian" | "cognito" | "discord" | "facebook" | "figma" | "microsoft" | "google" | "slack" | "spotify" | "twitch" | "twitter" | "dropbox" | "kick" | "linkedin" | "gitlab" | "tiktok" | "reddit" | "roblox" | "salesforce" | "vk" | "zoom" | "notion" | "kakao" | "naver" | "paybin" | "paypal" | "polar" | "railway" | "vercel";
808
+ callbackURL?: string | undefined;
809
+ newUserCallbackURL?: string | undefined;
810
+ errorCallbackURL?: string | undefined;
811
+ disableRedirect?: boolean | undefined;
812
+ idToken?: {
813
+ token: string;
814
+ nonce?: string | undefined;
815
+ accessToken?: string | undefined;
816
+ refreshToken?: string | undefined;
817
+ expiresAt?: number | undefined;
818
+ user?: {
819
+ name?: {
820
+ firstName?: string | undefined;
821
+ lastName?: string | undefined;
822
+ } | undefined;
823
+ email?: string | undefined;
824
+ } | undefined;
825
+ } | undefined;
826
+ scopes?: string[] | undefined;
827
+ requestSignUp?: boolean | undefined;
828
+ loginHint?: string | undefined;
829
+ additionalData?: Record<string, any> | undefined;
830
+ } & {
831
+ fetchOptions?: FetchOptions | undefined;
832
+ }>, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
833
+ redirect: boolean;
834
+ url: string;
835
+ } | (Omit<{
836
+ redirect: boolean;
837
+ token: string;
838
+ url: undefined;
839
+ user: {
840
+ id: string;
841
+ createdAt: Date;
842
+ updatedAt: Date;
843
+ email: string;
844
+ emailVerified: boolean;
845
+ name: string;
846
+ image?: string | null | undefined | undefined;
847
+ };
848
+ }, "user"> & {
849
+ user: import('better-auth').StripEmptyObjects<{
850
+ id: string;
851
+ createdAt: Date;
852
+ updatedAt: Date;
853
+ email: string;
854
+ emailVerified: boolean;
855
+ name: string;
856
+ image?: string | null | undefined;
857
+ } & {} & {
858
+ userId?: string | null | undefined;
859
+ }>;
860
+ }), {
861
+ code?: string | undefined;
862
+ message?: string | undefined;
863
+ }, FetchOptions["throw"] extends true ? true : false>>;
864
+ };
865
+ } & {
866
+ signOut: <FetchOptions extends import('better-auth').ClientFetchOption<never, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0?: import('better-auth').Prettify<{
867
+ query?: Record<string, any> | undefined;
868
+ fetchOptions?: FetchOptions | undefined;
869
+ }> | undefined, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
870
+ success: boolean;
871
+ }, {
872
+ code?: string | undefined;
873
+ message?: string | undefined;
874
+ }, FetchOptions["throw"] extends true ? true : false>>;
875
+ } & {
876
+ signUp: {
877
+ email: <FetchOptions extends import('better-auth').ClientFetchOption<Partial<{
878
+ name: string;
879
+ email: string;
880
+ password: string;
881
+ image?: string | undefined;
882
+ callbackURL?: string | undefined;
883
+ rememberMe?: boolean | undefined;
884
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0: import('better-auth').Prettify<import('better-auth/client').InferSignUpEmailCtx<{
885
+ baseURL: string;
886
+ plugins: ({
887
+ id: "convex";
888
+ $InferServerPlugin: ReturnType<(opts: {
889
+ authConfig: import('convex/server').AuthConfig;
890
+ jwt?: {
891
+ expirationSeconds?: number;
892
+ definePayload?: (session: {
893
+ user: {
894
+ id: string;
895
+ createdAt: Date;
896
+ updatedAt: Date;
897
+ email: string;
898
+ emailVerified: boolean;
899
+ name: string;
900
+ image?: string | null | undefined;
901
+ } & Record<string, any>;
902
+ session: {
903
+ id: string;
904
+ createdAt: Date;
905
+ updatedAt: Date;
906
+ userId: string;
907
+ expiresAt: Date;
908
+ token: string;
909
+ ipAddress?: string | null | undefined;
910
+ userAgent?: string | null | undefined;
911
+ } & Record<string, any>;
912
+ }) => Promise<Record<string, any>> | Record<string, any> | undefined;
913
+ };
914
+ jwtExpirationSeconds?: number;
915
+ jwks?: string;
916
+ jwksRotateOnTokenGenerationError?: boolean;
917
+ options?: import('better-auth').BetterAuthOptions;
918
+ }) => {
919
+ id: "convex";
920
+ init: (ctx: import('better-auth').AuthContext) => void;
921
+ hooks: {
922
+ before: ({
923
+ matcher(context: import('better-auth').HookEndpointContext): boolean;
924
+ handler: (inputContext: import('better-auth').MiddlewareInputContext<import('better-auth').MiddlewareOptions>) => Promise<{
925
+ context: {
926
+ headers: Headers;
927
+ };
928
+ } | undefined>;
929
+ } | {
930
+ matcher: (ctx: import('better-auth').HookEndpointContext) => boolean;
931
+ handler: (inputContext: import('better-auth').MiddlewareInputContext<import('better-auth').MiddlewareOptions>) => Promise<{
932
+ context: import('better-auth').MiddlewareContext<import('better-auth').MiddlewareOptions, {
933
+ returned?: unknown | undefined;
934
+ responseHeaders?: Headers | undefined;
935
+ } & import('better-auth').PluginContext<import('better-auth').BetterAuthOptions> & import('better-auth').InfoContext & {
936
+ options: import('better-auth').BetterAuthOptions;
937
+ trustedOrigins: string[];
938
+ trustedProviders: string[];
939
+ isTrustedOrigin: (url: string, settings?: {
940
+ allowRelativePaths: boolean;
941
+ }) => boolean;
942
+ oauthConfig: {
943
+ skipStateCookieCheck?: boolean | undefined;
944
+ storeStateStrategy: "database" | "cookie";
945
+ };
946
+ newSession: {
947
+ session: {
948
+ id: string;
949
+ createdAt: Date;
950
+ updatedAt: Date;
951
+ userId: string;
952
+ expiresAt: Date;
953
+ token: string;
954
+ ipAddress?: string | null | undefined;
955
+ userAgent?: string | null | undefined;
956
+ } & Record<string, any>;
957
+ user: {
958
+ id: string;
959
+ createdAt: Date;
960
+ updatedAt: Date;
961
+ email: string;
962
+ emailVerified: boolean;
963
+ name: string;
964
+ image?: string | null | undefined;
965
+ } & Record<string, any>;
966
+ } | null;
967
+ session: {
968
+ session: {
969
+ id: string;
970
+ createdAt: Date;
971
+ updatedAt: Date;
972
+ userId: string;
973
+ expiresAt: Date;
974
+ token: string;
975
+ ipAddress?: string | null | undefined;
976
+ userAgent?: string | null | undefined;
977
+ } & Record<string, any>;
978
+ user: {
979
+ id: string;
980
+ createdAt: Date;
981
+ updatedAt: Date;
982
+ email: string;
983
+ emailVerified: boolean;
984
+ name: string;
985
+ image?: string | null | undefined;
986
+ } & Record<string, any>;
987
+ } | null;
988
+ setNewSession: (session: {
989
+ session: {
990
+ id: string;
991
+ createdAt: Date;
992
+ updatedAt: Date;
993
+ userId: string;
994
+ expiresAt: Date;
995
+ token: string;
996
+ ipAddress?: string | null | undefined;
997
+ userAgent?: string | null | undefined;
998
+ } & Record<string, any>;
999
+ user: {
1000
+ id: string;
1001
+ createdAt: Date;
1002
+ updatedAt: Date;
1003
+ email: string;
1004
+ emailVerified: boolean;
1005
+ name: string;
1006
+ image?: string | null | undefined;
1007
+ } & Record<string, any>;
1008
+ } | null) => void;
1009
+ socialProviders: import('better-auth').OAuthProvider[];
1010
+ authCookies: import('better-auth').BetterAuthCookies;
1011
+ logger: ReturnType<(options?: import('better-auth').Logger | undefined) => import('better-auth').InternalLogger>;
1012
+ rateLimit: {
1013
+ enabled: boolean;
1014
+ window: number;
1015
+ max: number;
1016
+ storage: "memory" | "database" | "secondary-storage";
1017
+ } & Omit<import('better-auth').BetterAuthRateLimitOptions, "enabled" | "window" | "max" | "storage">;
1018
+ adapter: import('better-auth').DBAdapter<import('better-auth').BetterAuthOptions>;
1019
+ internalAdapter: import('better-auth').InternalAdapter<import('better-auth').BetterAuthOptions>;
1020
+ createAuthCookie: (cookieName: string, overrideAttributes?: Partial<import('better-auth').CookieOptions> | undefined) => import('better-auth').BetterAuthCookie;
1021
+ secret: string;
1022
+ secretConfig: string | import('better-auth').SecretConfig;
1023
+ sessionConfig: {
1024
+ updateAge: number;
1025
+ expiresIn: number;
1026
+ freshAge: number;
1027
+ cookieRefreshCache: false | {
1028
+ enabled: true;
1029
+ updateAge: number;
1030
+ };
1031
+ };
1032
+ generateId: (options: {
1033
+ model: import('better-auth').ModelNames;
1034
+ size?: number | undefined;
1035
+ }) => string | false;
1036
+ secondaryStorage: import('better-auth').SecondaryStorage | undefined;
1037
+ password: {
1038
+ hash: (password: string) => Promise<string>;
1039
+ verify: (data: {
1040
+ password: string;
1041
+ hash: string;
1042
+ }) => Promise<boolean>;
1043
+ config: {
1044
+ minPasswordLength: number;
1045
+ maxPasswordLength: number;
1046
+ };
1047
+ checkPassword: (userId: string, ctx: import('better-auth').GenericEndpointContext<import('better-auth').BetterAuthOptions>) => Promise<boolean>;
1048
+ };
1049
+ tables: import('better-auth').BetterAuthDBSchema;
1050
+ runMigrations: () => Promise<void>;
1051
+ publishTelemetry: (event: {
1052
+ type: string;
1053
+ anonymousId?: string | undefined;
1054
+ payload: Record<string, any>;
1055
+ }) => Promise<void>;
1056
+ skipOriginCheck: boolean | string[];
1057
+ skipCSRFCheck: boolean;
1058
+ runInBackground: (promise: Promise<unknown>) => void;
1059
+ runInBackgroundOrAwait: (promise: Promise<unknown> | void) => import('better-auth').Awaitable<unknown>;
1060
+ }>;
1061
+ }>;
1062
+ })[];
1063
+ after: {
1064
+ matcher: (context: import('better-auth').HookEndpointContext) => boolean;
1065
+ handler: import('better-auth/api').AuthMiddleware;
1066
+ }[];
1067
+ };
1068
+ endpoints: {
1069
+ getOpenIdConfig: import('better-auth').StrictEndpoint<"/convex/.well-known/openid-configuration", {
1070
+ method: "GET";
1071
+ metadata: {
1072
+ isAction: false;
1073
+ };
1074
+ }, import('better-auth/plugins').OIDCMetadata>;
1075
+ getJwks: import('better-auth').StrictEndpoint<"/convex/jwks", {
1076
+ method: "GET";
1077
+ metadata: {
1078
+ openapi: {
1079
+ description: string;
1080
+ responses: {
1081
+ "200": {
1082
+ description: string;
1083
+ content: {
1084
+ "application/json": {
1085
+ schema: {
1086
+ type: "object";
1087
+ properties: {
1088
+ keys: {
1089
+ type: string;
1090
+ description: string;
1091
+ items: {
1092
+ type: string;
1093
+ properties: {
1094
+ kid: {
1095
+ type: string;
1096
+ description: string;
1097
+ };
1098
+ kty: {
1099
+ type: string;
1100
+ description: string;
1101
+ };
1102
+ alg: {
1103
+ type: string;
1104
+ description: string;
1105
+ };
1106
+ use: {
1107
+ type: string;
1108
+ description: string;
1109
+ enum: string[];
1110
+ nullable: boolean;
1111
+ };
1112
+ n: {
1113
+ type: string;
1114
+ description: string;
1115
+ nullable: boolean;
1116
+ };
1117
+ e: {
1118
+ type: string;
1119
+ description: string;
1120
+ nullable: boolean;
1121
+ };
1122
+ crv: {
1123
+ type: string;
1124
+ description: string;
1125
+ nullable: boolean;
1126
+ };
1127
+ x: {
1128
+ type: string;
1129
+ description: string;
1130
+ nullable: boolean;
1131
+ };
1132
+ y: {
1133
+ type: string;
1134
+ description: string;
1135
+ nullable: boolean;
1136
+ };
1137
+ };
1138
+ required: string[];
1139
+ };
1140
+ };
1141
+ };
1142
+ required: string[];
1143
+ };
1144
+ };
1145
+ };
1146
+ };
1147
+ };
1148
+ };
1149
+ };
1150
+ }, import('better-auth').JSONWebKeySet>;
1151
+ getLatestJwks: import('better-auth').StrictEndpoint<"/convex/latest-jwks", {
1152
+ isAction: boolean;
1153
+ method: "POST";
1154
+ metadata: {
1155
+ SERVER_ONLY: true;
1156
+ openapi: {
1157
+ description: string;
1158
+ };
1159
+ };
1160
+ }, any[]>;
1161
+ rotateKeys: import('better-auth').StrictEndpoint<"/convex/rotate-keys", {
1162
+ isAction: boolean;
1163
+ method: "POST";
1164
+ metadata: {
1165
+ SERVER_ONLY: true;
1166
+ openapi: {
1167
+ description: string;
1168
+ };
1169
+ };
1170
+ }, any[]>;
1171
+ getToken: import('better-auth').StrictEndpoint<"/convex/token", {
1172
+ method: "GET";
1173
+ requireHeaders: true;
1174
+ use: ((inputContext: import('better-auth').MiddlewareInputContext<import('better-auth').MiddlewareOptions>) => Promise<{
1175
+ session: {
1176
+ session: Record<string, any> & {
1177
+ id: string;
1178
+ createdAt: Date;
1179
+ updatedAt: Date;
1180
+ userId: string;
1181
+ expiresAt: Date;
1182
+ token: string;
1183
+ ipAddress?: string | null | undefined;
1184
+ userAgent?: string | null | undefined;
1185
+ };
1186
+ user: Record<string, any> & {
1187
+ id: string;
1188
+ createdAt: Date;
1189
+ updatedAt: Date;
1190
+ email: string;
1191
+ emailVerified: boolean;
1192
+ name: string;
1193
+ image?: string | null | undefined;
1194
+ };
1195
+ };
1196
+ }>)[];
1197
+ metadata: {
1198
+ openapi: {
1199
+ description: string;
1200
+ responses: {
1201
+ 200: {
1202
+ description: string;
1203
+ content: {
1204
+ "application/json": {
1205
+ schema: {
1206
+ type: "object";
1207
+ properties: {
1208
+ token: {
1209
+ type: string;
1210
+ };
1211
+ };
1212
+ };
1213
+ };
1214
+ };
1215
+ };
1216
+ };
1217
+ };
1218
+ };
1219
+ }, {
1220
+ token: string;
1221
+ }>;
1222
+ };
1223
+ schema: {
1224
+ jwks: {
1225
+ fields: {
1226
+ publicKey: {
1227
+ type: "string";
1228
+ required: true;
1229
+ };
1230
+ privateKey: {
1231
+ type: "string";
1232
+ required: true;
1233
+ };
1234
+ createdAt: {
1235
+ type: "date";
1236
+ required: true;
1237
+ };
1238
+ expiresAt: {
1239
+ type: "date";
1240
+ required: false;
1241
+ };
1242
+ };
1243
+ };
1244
+ user: {
1245
+ readonly fields: {
1246
+ readonly userId: {
1247
+ readonly type: "string";
1248
+ readonly required: false;
1249
+ readonly input: false;
1250
+ };
1251
+ };
1252
+ };
1253
+ };
1254
+ }>;
1255
+ } | {
1256
+ id: "cross-domain";
1257
+ $InferServerPlugin: ReturnType<({ siteUrl }: {
1258
+ siteUrl: string;
1259
+ }) => {
1260
+ id: "cross-domain";
1261
+ init(): {
1262
+ options: {
1263
+ trustedOrigins: string[];
1264
+ };
1265
+ context: {
1266
+ oauthConfig: {
1267
+ storeStateStrategy: "database";
1268
+ skipStateCookieCheck: true;
1269
+ };
1270
+ };
1271
+ };
1272
+ hooks: {
1273
+ before: ({
1274
+ matcher(ctx: import('better-auth').HookEndpointContext): boolean;
1275
+ handler: (inputContext: import('better-auth').MiddlewareInputContext<import('better-auth').MiddlewareOptions>) => Promise<{
1276
+ context: {
1277
+ headers: Headers;
1278
+ };
1279
+ } | undefined>;
1280
+ } | {
1281
+ matcher: (ctx: import('better-auth').HookEndpointContext) => boolean;
1282
+ handler: (inputContext: import('better-auth').MiddlewareInputContext<import('better-auth').MiddlewareOptions>) => Promise<{
1283
+ context: import('better-auth').MiddlewareContext<import('better-auth').MiddlewareOptions, {
1284
+ returned?: unknown | undefined;
1285
+ responseHeaders?: Headers | undefined;
1286
+ } & import('better-auth').PluginContext<import('better-auth').BetterAuthOptions> & import('better-auth').InfoContext & {
1287
+ options: import('better-auth').BetterAuthOptions;
1288
+ trustedOrigins: string[];
1289
+ trustedProviders: string[];
1290
+ isTrustedOrigin: (url: string, settings?: {
1291
+ allowRelativePaths: boolean;
1292
+ }) => boolean;
1293
+ oauthConfig: {
1294
+ skipStateCookieCheck?: boolean | undefined;
1295
+ storeStateStrategy: "database" | "cookie";
1296
+ };
1297
+ newSession: {
1298
+ session: {
1299
+ id: string;
1300
+ createdAt: Date;
1301
+ updatedAt: Date;
1302
+ userId: string;
1303
+ expiresAt: Date;
1304
+ token: string;
1305
+ ipAddress?: string | null | undefined;
1306
+ userAgent?: string | null | undefined;
1307
+ } & Record<string, any>;
1308
+ user: {
1309
+ id: string;
1310
+ createdAt: Date;
1311
+ updatedAt: Date;
1312
+ email: string;
1313
+ emailVerified: boolean;
1314
+ name: string;
1315
+ image?: string | null | undefined;
1316
+ } & Record<string, any>;
1317
+ } | null;
1318
+ session: {
1319
+ session: {
1320
+ id: string;
1321
+ createdAt: Date;
1322
+ updatedAt: Date;
1323
+ userId: string;
1324
+ expiresAt: Date;
1325
+ token: string;
1326
+ ipAddress?: string | null | undefined;
1327
+ userAgent?: string | null | undefined;
1328
+ } & Record<string, any>;
1329
+ user: {
1330
+ id: string;
1331
+ createdAt: Date;
1332
+ updatedAt: Date;
1333
+ email: string;
1334
+ emailVerified: boolean;
1335
+ name: string;
1336
+ image?: string | null | undefined;
1337
+ } & Record<string, any>;
1338
+ } | null;
1339
+ setNewSession: (session: {
1340
+ session: {
1341
+ id: string;
1342
+ createdAt: Date;
1343
+ updatedAt: Date;
1344
+ userId: string;
1345
+ expiresAt: Date;
1346
+ token: string;
1347
+ ipAddress?: string | null | undefined;
1348
+ userAgent?: string | null | undefined;
1349
+ } & Record<string, any>;
1350
+ user: {
1351
+ id: string;
1352
+ createdAt: Date;
1353
+ updatedAt: Date;
1354
+ email: string;
1355
+ emailVerified: boolean;
1356
+ name: string;
1357
+ image?: string | null | undefined;
1358
+ } & Record<string, any>;
1359
+ } | null) => void;
1360
+ socialProviders: import('better-auth').OAuthProvider[];
1361
+ authCookies: import('better-auth').BetterAuthCookies;
1362
+ logger: ReturnType<(options?: import('better-auth').Logger | undefined) => import('better-auth').InternalLogger>;
1363
+ rateLimit: {
1364
+ enabled: boolean;
1365
+ window: number;
1366
+ max: number;
1367
+ storage: "memory" | "database" | "secondary-storage";
1368
+ } & Omit<import('better-auth').BetterAuthRateLimitOptions, "enabled" | "window" | "max" | "storage">;
1369
+ adapter: import('better-auth').DBAdapter<import('better-auth').BetterAuthOptions>;
1370
+ internalAdapter: import('better-auth').InternalAdapter<import('better-auth').BetterAuthOptions>;
1371
+ createAuthCookie: (cookieName: string, overrideAttributes?: Partial<import('better-auth').CookieOptions> | undefined) => import('better-auth').BetterAuthCookie;
1372
+ secret: string;
1373
+ secretConfig: string | import('better-auth').SecretConfig;
1374
+ sessionConfig: {
1375
+ updateAge: number;
1376
+ expiresIn: number;
1377
+ freshAge: number;
1378
+ cookieRefreshCache: false | {
1379
+ enabled: true;
1380
+ updateAge: number;
1381
+ };
1382
+ };
1383
+ generateId: (options: {
1384
+ model: import('better-auth').ModelNames;
1385
+ size?: number | undefined;
1386
+ }) => string | false;
1387
+ secondaryStorage: import('better-auth').SecondaryStorage | undefined;
1388
+ password: {
1389
+ hash: (password: string) => Promise<string>;
1390
+ verify: (data: {
1391
+ password: string;
1392
+ hash: string;
1393
+ }) => Promise<boolean>;
1394
+ config: {
1395
+ minPasswordLength: number;
1396
+ maxPasswordLength: number;
1397
+ };
1398
+ checkPassword: (userId: string, ctx: import('better-auth').GenericEndpointContext<import('better-auth').BetterAuthOptions>) => Promise<boolean>;
1399
+ };
1400
+ tables: import('better-auth').BetterAuthDBSchema;
1401
+ runMigrations: () => Promise<void>;
1402
+ publishTelemetry: (event: {
1403
+ type: string;
1404
+ anonymousId?: string | undefined;
1405
+ payload: Record<string, any>;
1406
+ }) => Promise<void>;
1407
+ skipOriginCheck: boolean | string[];
1408
+ skipCSRFCheck: boolean;
1409
+ runInBackground: (promise: Promise<unknown>) => void;
1410
+ runInBackgroundOrAwait: (promise: Promise<unknown> | void) => import('better-auth').Awaitable<unknown>;
1411
+ }>;
1412
+ }>;
1413
+ })[];
1414
+ after: {
1415
+ matcher(ctx: import('better-auth').HookEndpointContext): boolean;
1416
+ handler: (inputContext: import('better-auth').MiddlewareInputContext<import('better-auth').MiddlewareOptions>) => Promise<void>;
1417
+ }[];
1418
+ };
1419
+ endpoints: {
1420
+ verifyOneTimeToken: import('better-auth').StrictEndpoint<"/cross-domain/one-time-token/verify", {
1421
+ method: "POST";
1422
+ body: import('zod').ZodObject<{
1423
+ token: import('zod').ZodString;
1424
+ }, import('better-auth').$strip>;
1425
+ }, {
1426
+ session: import('better-auth').Session & Record<string, any>;
1427
+ user: import('better-auth').User & Record<string, any>;
1428
+ }>;
1429
+ };
1430
+ }>;
1431
+ getActions(_: import('better-auth/client').BetterFetch, $store: import('better-auth').ClientStore): {
1432
+ getCookie: () => string;
1433
+ updateSession: () => void;
1434
+ getSessionData: () => Record<string, unknown> | null;
1435
+ };
1436
+ fetchPlugins: {
1437
+ id: string;
1438
+ name: string;
1439
+ hooks: {
1440
+ onSuccess(context: import('better-auth/client').SuccessContext<any>): Promise<void>;
1441
+ };
1442
+ init(url: string, options: ({
1443
+ method?: string | undefined;
1444
+ headers?: (HeadersInit & (HeadersInit | {
1445
+ accept: "application/json" | "text/plain" | "application/octet-stream";
1446
+ "content-type": "application/json" | "text/plain" | "application/x-www-form-urlencoded" | "multipart/form-data" | "application/octet-stream";
1447
+ authorization: "Bearer" | "Basic";
1448
+ })) | undefined;
1449
+ redirect?: RequestRedirect | undefined;
1450
+ window?: null | undefined;
1451
+ cache?: RequestCache | undefined;
1452
+ credentials?: RequestCredentials | undefined;
1453
+ integrity?: string | undefined;
1454
+ keepalive?: boolean | undefined;
1455
+ mode?: RequestMode | undefined;
1456
+ priority?: RequestPriority | undefined;
1457
+ referrer?: string | undefined;
1458
+ referrerPolicy?: ReferrerPolicy | undefined;
1459
+ signal?: (AbortSignal | null) | undefined;
1460
+ onRequest?: (<T extends Record<string, any>>(context: import('better-auth/client').RequestContext<T>) => Promise<import('better-auth/client').RequestContext | void> | import('better-auth/client').RequestContext | void) | undefined;
1461
+ onResponse?: ((context: import('better-auth/client').ResponseContext) => Promise<Response | void | import('better-auth/client').ResponseContext> | Response | import('better-auth/client').ResponseContext | void) | undefined;
1462
+ onSuccess?: ((context: import('better-auth/client').SuccessContext<any>) => Promise<void> | void) | undefined;
1463
+ onError?: ((context: import('better-auth/client').ErrorContext) => Promise<void> | void) | undefined;
1464
+ onRetry?: ((response: import('better-auth/client').ResponseContext) => Promise<void> | void) | undefined;
1465
+ hookOptions?: {
1466
+ cloneResponse?: boolean;
1467
+ } | undefined;
1468
+ timeout
1469
+ /**
1470
+ * Registers sign-out and manage-account actions in the command palette.
1471
+ */
1472
+ ? /**
1473
+ * Registers sign-out and manage-account actions in the command palette.
1474
+ */: number | undefined;
1475
+ customFetchImpl?: import('better-auth/client').FetchEsque | undefined;
1476
+ plugins?: import('better-auth/client').BetterFetchPlugin[] | undefined;
1477
+ baseURL?: string | undefined;
1478
+ throw?: boolean | undefined;
1479
+ auth?: ({
1480
+ type: "Bearer";
1481
+ token: string | Promise<string | undefined> | (() => string | Promise<string | undefined> | undefined) | undefined;
1482
+ } | {
1483
+ type: "Basic";
1484
+ username: string | (() => string | undefined) | undefined;
1485
+ password: string | (() => string | undefined) | undefined;
1486
+ } | {
1487
+ type: "Custom";
1488
+ prefix: string | (() => string | undefined) | undefined;
1489
+ value: string | (() => string | undefined) | undefined;
1490
+ }) | undefined;
1491
+ body?: any;
1492
+ query?: any;
1493
+ params?: any;
1494
+ duplex?: "full" | "half" | undefined;
1495
+ jsonParser?: ((text: string) => Promise<any> | any) | undefined;
1496
+ retry?: import('better-auth/client').RetryOptions | undefined;
1497
+ retryAttempt?: number | undefined;
1498
+ output?: (import('better-auth/client').StandardSchemaV1 | typeof Blob | typeof File) | undefined;
1499
+ errorSchema?: import('better-auth/client').StandardSchemaV1 | undefined;
1500
+ disableValidation?: boolean | undefined;
1501
+ } & Record<string, any>) | undefined): Promise<{
1502
+ url: string;
1503
+ options: import('better-auth/client').BetterFetchOption;
1504
+ }>;
1505
+ }[];
1506
+ } | {
1507
+ id: "organization";
1508
+ $InferServerPlugin: import('better-auth/plugins').OrganizationPlugin<{
1509
+ ac: import('better-auth/plugins').AccessControl<{
1510
+ readonly organization: readonly ["update", "delete"];
1511
+ readonly member: readonly ["create", "update", "delete"];
1512
+ readonly invitation: readonly ["create", "cancel"];
1513
+ readonly team: readonly ["create", "update", "delete"];
1514
+ readonly ac: readonly ["create", "read", "update", "delete"];
1515
+ }>;
1516
+ roles: {
1517
+ admin: import('better-auth/plugins').Role;
1518
+ member: import('better-auth/plugins').Role;
1519
+ owner: import('better-auth/plugins').Role;
1520
+ };
1521
+ teams: {
1522
+ enabled: false;
1523
+ };
1524
+ schema: {
1525
+ organization?: {
1526
+ additionalFields?: {
1527
+ [key: string]: import('better-auth').DBFieldAttribute;
1528
+ };
1529
+ };
1530
+ member?: {
1531
+ additionalFields?: {
1532
+ [key: string]: import('better-auth').DBFieldAttribute;
1533
+ };
1534
+ };
1535
+ invitation?: {
1536
+ additionalFields?: {
1537
+ [key: string]: import('better-auth').DBFieldAttribute;
1538
+ };
1539
+ };
1540
+ team?: {
1541
+ additionalFields?: {
1542
+ [key: string]: import('better-auth').DBFieldAttribute;
1543
+ };
1544
+ };
1545
+ organizationRole?: {
1546
+ additionalFields?: {
1547
+ [key: string]: import('better-auth').DBFieldAttribute;
1548
+ };
1549
+ };
1550
+ } | undefined;
1551
+ dynamicAccessControl: {
1552
+ enabled: false;
1553
+ };
1554
+ }>;
1555
+ getActions: ($fetch: import('better-auth/client').BetterFetch, _$store: import('better-auth').ClientStore, co: import('better-auth').BetterAuthClientOptions | undefined) => {
1556
+ $Infer: {
1557
+ ActiveOrganization: {
1558
+ members: {
1559
+ id: string;
1560
+ organizationId: string;
1561
+ role: "member" | "admin" | "owner";
1562
+ createdAt: Date;
1563
+ userId: string;
1564
+ user: {
1565
+ id: string;
1566
+ email: string;
1567
+ name: string;
1568
+ image?: string | undefined;
1569
+ };
1570
+ }[];
1571
+ invitations: {
1572
+ id: string;
1573
+ organizationId: string;
1574
+ email: string;
1575
+ role: "member" | "admin" | "owner";
1576
+ status: import('better-auth/plugins').InvitationStatus;
1577
+ inviterId: string;
1578
+ expiresAt: Date;
1579
+ createdAt: Date;
1580
+ }[];
1581
+ } & {
1582
+ id: string;
1583
+ name: string;
1584
+ slug: string;
1585
+ createdAt: Date;
1586
+ logo?: string | null | undefined | undefined;
1587
+ metadata?: any;
1588
+ };
1589
+ Organization: {
1590
+ id: string;
1591
+ name: string;
1592
+ slug: string;
1593
+ createdAt: Date;
1594
+ logo?: string | null | undefined;
1595
+ metadata?: any;
1596
+ };
1597
+ Invitation: {
1598
+ id: string;
1599
+ organizationId: string;
1600
+ email: string;
1601
+ role: "member" | "admin" | "owner";
1602
+ status: import('better-auth/plugins').InvitationStatus;
1603
+ inviterId: string;
1604
+ expiresAt: Date;
1605
+ createdAt: Date;
1606
+ };
1607
+ Member: {
1608
+ id: string;
1609
+ organizationId: string;
1610
+ role: "member" | "admin" | "owner";
1611
+ createdAt: Date;
1612
+ userId: string;
1613
+ user: {
1614
+ id: string;
1615
+ email: string;
1616
+ name: string;
1617
+ image?: string | undefined;
1618
+ };
1619
+ };
1620
+ Team: {
1621
+ id: string;
1622
+ name: string;
1623
+ organizationId: string;
1624
+ createdAt: Date;
1625
+ updatedAt?: Date | undefined;
1626
+ };
1627
+ };
1628
+ organization: {
1629
+ checkRolePermission: <R extends "member" | "admin" | "owner">(data: {
1630
+ permissions: {
1631
+ readonly organization?: ("delete" | "update")[] | undefined;
1632
+ readonly member?: ("delete" | "create" | "update")[] | undefined;
1633
+ readonly invitation?: ("cancel" | "create")[] | undefined;
1634
+ readonly team?: ("delete" | "create" | "update")[] | undefined;
1635
+ readonly ac?: ("delete" | "create" | "update" | "read")[] | undefined;
1636
+ };
1637
+ } & {
1638
+ role: R;
1639
+ }) => boolean;
1640
+ };
1641
+ };
1642
+ getAtoms: ($fetch: import('better-auth/client').BetterFetch) => {
1643
+ $listOrg: import('better-auth/client').PreinitializedWritableAtom<boolean> & object;
1644
+ $activeOrgSignal: import('better-auth/client').PreinitializedWritableAtom<boolean> & object;
1645
+ $activeMemberSignal: import('better-auth/client').PreinitializedWritableAtom<boolean> & object;
1646
+ $activeMemberRoleSignal: import('better-auth/client').PreinitializedWritableAtom<boolean> & object;
1647
+ activeOrganization: import('better-auth/client').AuthQueryAtom<import('better-auth').Prettify<{
1648
+ id: string;
1649
+ name: string;
1650
+ slug: string;
1651
+ createdAt: Date;
1652
+ logo?: string | null | undefined | undefined;
1653
+ metadata?: any;
1654
+ } & {
1655
+ members: {
1656
+ id: string;
1657
+ organizationId: string;
1658
+ role: "member" | "admin" | "owner";
1659
+ createdAt: Date;
1660
+ userId: string;
1661
+ user: {
1662
+ id: string;
1663
+ email: string;
1664
+ name: string;
1665
+ image?: string | undefined;
1666
+ };
1667
+ }[];
1668
+ invitations: {
1669
+ id: string;
1670
+ organizationId: string;
1671
+ email: string;
1672
+ role: "member" | "admin" | "owner";
1673
+ status: import('better-auth/plugins').InvitationStatus;
1674
+ inviterId: string;
1675
+ expiresAt: Date;
1676
+ createdAt: Date;
1677
+ }[];
1678
+ }>>;
1679
+ listOrganizations: import('better-auth/client').AuthQueryAtom<{
1680
+ id: string;
1681
+ name: string;
1682
+ slug: string;
1683
+ createdAt: Date;
1684
+ logo?: string | null | undefined | undefined;
1685
+ metadata?: any;
1686
+ }[]>;
1687
+ activeMember: import('better-auth/client').AuthQueryAtom<{
1688
+ id: string;
1689
+ organizationId: string;
1690
+ userId: string;
1691
+ role: string;
1692
+ createdAt: Date;
1693
+ }>;
1694
+ activeMemberRole: import('better-auth/client').AuthQueryAtom<{
1695
+ role: string;
1696
+ }>;
1697
+ };
1698
+ pathMethods: {
1699
+ "/organization/get-full-organization": "GET";
1700
+ "/organization/list-user-teams": "GET";
1701
+ };
1702
+ atomListeners: ({
1703
+ matcher(path: string): path is "/organization/create" | "/organization/update" | "/organization/delete";
1704
+ signal: "$listOrg";
1705
+ } | {
1706
+ matcher(path: string): boolean;
1707
+ signal: "$activeOrgSignal";
1708
+ } | {
1709
+ matcher(path: string): boolean;
1710
+ signal: "$sessionSignal";
1711
+ } | {
1712
+ matcher(path: string): boolean;
1713
+ signal: "$activeMemberSignal";
1714
+ } | {
1715
+ matcher(path: string): boolean;
1716
+ signal: "$activeMemberRoleSignal";
1717
+ })[];
1718
+ $ERROR_CODES: {
1719
+ YOU_ARE_NOT_ALLOWED_TO_CREATE_A_NEW_ORGANIZATION: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_CREATE_A_NEW_ORGANIZATION">;
1720
+ YOU_HAVE_REACHED_THE_MAXIMUM_NUMBER_OF_ORGANIZATIONS: import('better-auth').RawError<"YOU_HAVE_REACHED_THE_MAXIMUM_NUMBER_OF_ORGANIZATIONS">;
1721
+ ORGANIZATION_ALREADY_EXISTS: import('better-auth').RawError<"ORGANIZATION_ALREADY_EXISTS">;
1722
+ ORGANIZATION_SLUG_ALREADY_TAKEN: import('better-auth').RawError<"ORGANIZATION_SLUG_ALREADY_TAKEN">;
1723
+ ORGANIZATION_NOT_FOUND: import('better-auth').RawError<"ORGANIZATION_NOT_FOUND">;
1724
+ USER_IS_NOT_A_MEMBER_OF_THE_ORGANIZATION: import('better-auth').RawError<"USER_IS_NOT_A_MEMBER_OF_THE_ORGANIZATION">;
1725
+ YOU_ARE_NOT_ALLOWED_TO_UPDATE_THIS_ORGANIZATION: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_UPDATE_THIS_ORGANIZATION">;
1726
+ YOU_ARE_NOT_ALLOWED_TO_DELETE_THIS_ORGANIZATION: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_DELETE_THIS_ORGANIZATION">;
1727
+ NO_ACTIVE_ORGANIZATION: import('better-auth').RawError<"NO_ACTIVE_ORGANIZATION">;
1728
+ USER_IS_ALREADY_A_MEMBER_OF_THIS_ORGANIZATION: import('better-auth').RawError<"USER_IS_ALREADY_A_MEMBER_OF_THIS_ORGANIZATION">;
1729
+ MEMBER_NOT_FOUND: import('better-auth').RawError<"MEMBER_NOT_FOUND">;
1730
+ ROLE_NOT_FOUND: import('better-auth').RawError<"ROLE_NOT_FOUND">;
1731
+ YOU_ARE_NOT_ALLOWED_TO_CREATE_A_NEW_TEAM: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_CREATE_A_NEW_TEAM">;
1732
+ TEAM_ALREADY_EXISTS: import('better-auth').RawError<"TEAM_ALREADY_EXISTS">;
1733
+ TEAM_NOT_FOUND: import('better-auth').RawError<"TEAM_NOT_FOUND">;
1734
+ YOU_CANNOT_LEAVE_THE_ORGANIZATION_AS_THE_ONLY_OWNER: import('better-auth').RawError<"YOU_CANNOT_LEAVE_THE_ORGANIZATION_AS_THE_ONLY_OWNER">;
1735
+ YOU_CANNOT_LEAVE_THE_ORGANIZATION_WITHOUT_AN_OWNER: import('better-auth').RawError<"YOU_CANNOT_LEAVE_THE_ORGANIZATION_WITHOUT_AN_OWNER">;
1736
+ YOU_ARE_NOT_ALLOWED_TO_DELETE_THIS_MEMBER: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_DELETE_THIS_MEMBER">;
1737
+ YOU_ARE_NOT_ALLOWED_TO_INVITE_USERS_TO_THIS_ORGANIZATION: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_INVITE_USERS_TO_THIS_ORGANIZATION">;
1738
+ USER_IS_ALREADY_INVITED_TO_THIS_ORGANIZATION: import('better-auth').RawError<"USER_IS_ALREADY_INVITED_TO_THIS_ORGANIZATION">;
1739
+ INVITATION_NOT_FOUND: import('better-auth').RawError<"INVITATION_NOT_FOUND">;
1740
+ YOU_ARE_NOT_THE_RECIPIENT_OF_THE_INVITATION: import('better-auth').RawError<"YOU_ARE_NOT_THE_RECIPIENT_OF_THE_INVITATION">;
1741
+ EMAIL_VERIFICATION_REQUIRED_BEFORE_ACCEPTING_OR_REJECTING_INVITATION: import('better-auth').RawError<"EMAIL_VERIFICATION_REQUIRED_BEFORE_ACCEPTING_OR_REJECTING_INVITATION">;
1742
+ YOU_ARE_NOT_ALLOWED_TO_CANCEL_THIS_INVITATION: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_CANCEL_THIS_INVITATION">;
1743
+ INVITER_IS_NO_LONGER_A_MEMBER_OF_THE_ORGANIZATION: import('better-auth').RawError<"INVITER_IS_NO_LONGER_A_MEMBER_OF_THE_ORGANIZATION">;
1744
+ YOU_ARE_NOT_ALLOWED_TO_INVITE_USER_WITH_THIS_ROLE: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_INVITE_USER_WITH_THIS_ROLE">;
1745
+ FAILED_TO_RETRIEVE_INVITATION: import('better-auth').RawError<"FAILED_TO_RETRIEVE_INVITATION">;
1746
+ YOU_HAVE_REACHED_THE_MAXIMUM_NUMBER_OF_TEAMS: import('better-auth').RawError<"YOU_HAVE_REACHED_THE_MAXIMUM_NUMBER_OF_TEAMS">;
1747
+ UNABLE_TO_REMOVE_LAST_TEAM: import('better-auth').RawError<"UNABLE_TO_REMOVE_LAST_TEAM">;
1748
+ YOU_ARE_NOT_ALLOWED_TO_UPDATE_THIS_MEMBER: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_UPDATE_THIS_MEMBER">;
1749
+ ORGANIZATION_MEMBERSHIP_LIMIT_REACHED: import('better-auth').RawError<"ORGANIZATION_MEMBERSHIP_LIMIT_REACHED">;
1750
+ YOU_ARE_NOT_ALLOWED_TO_CREATE_TEAMS_IN_THIS_ORGANIZATION: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_CREATE_TEAMS_IN_THIS_ORGANIZATION">;
1751
+ YOU_ARE_NOT_ALLOWED_TO_DELETE_TEAMS_IN_THIS_ORGANIZATION: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_DELETE_TEAMS_IN_THIS_ORGANIZATION">;
1752
+ YOU_ARE_NOT_ALLOWED_TO_UPDATE_THIS_TEAM: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_UPDATE_THIS_TEAM">;
1753
+ YOU_ARE_NOT_ALLOWED_TO_DELETE_THIS_TEAM: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_DELETE_THIS_TEAM">;
1754
+ INVITATION_LIMIT_REACHED: import('better-auth').RawError<"INVITATION_LIMIT_REACHED">;
1755
+ TEAM_MEMBER_LIMIT_REACHED: import('better-auth').RawError<"TEAM_MEMBER_LIMIT_REACHED">;
1756
+ USER_IS_NOT_A_MEMBER_OF_THE_TEAM: import('better-auth').RawError<"USER_IS_NOT_A_MEMBER_OF_THE_TEAM">;
1757
+ YOU_CAN_NOT_ACCESS_THE_MEMBERS_OF_THIS_TEAM: import('better-auth').RawError<"YOU_CAN_NOT_ACCESS_THE_MEMBERS_OF_THIS_TEAM">;
1758
+ YOU_DO_NOT_HAVE_AN_ACTIVE_TEAM: import('better-auth').RawError<"YOU_DO_NOT_HAVE_AN_ACTIVE_TEAM">;
1759
+ YOU_ARE_NOT_ALLOWED_TO_CREATE_A_NEW_TEAM_MEMBER: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_CREATE_A_NEW_TEAM_MEMBER">;
1760
+ YOU_ARE_NOT_ALLOWED_TO_REMOVE_A_TEAM_MEMBER: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_REMOVE_A_TEAM_MEMBER">;
1761
+ YOU_ARE_NOT_ALLOWED_TO_ACCESS_THIS_ORGANIZATION: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_ACCESS_THIS_ORGANIZATION">;
1762
+ YOU_ARE_NOT_A_MEMBER_OF_THIS_ORGANIZATION: import('better-auth').RawError<"YOU_ARE_NOT_A_MEMBER_OF_THIS_ORGANIZATION">;
1763
+ MISSING_AC_INSTANCE: import('better-auth').RawError<"MISSING_AC_INSTANCE">;
1764
+ YOU_MUST_BE_IN_AN_ORGANIZATION_TO_CREATE_A_ROLE: import('better-auth').RawError<"YOU_MUST_BE_IN_AN_ORGANIZATION_TO_CREATE_A_ROLE">;
1765
+ YOU_ARE_NOT_ALLOWED_TO_CREATE_A_ROLE: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_CREATE_A_ROLE">;
1766
+ YOU_ARE_NOT_ALLOWED_TO_UPDATE_A_ROLE: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_UPDATE_A_ROLE">;
1767
+ YOU_ARE_NOT_ALLOWED_TO_DELETE_A_ROLE: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_DELETE_A_ROLE">;
1768
+ YOU_ARE_NOT_ALLOWED_TO_READ_A_ROLE: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_READ_A_ROLE">;
1769
+ YOU_ARE_NOT_ALLOWED_TO_LIST_A_ROLE: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_LIST_A_ROLE">;
1770
+ YOU_ARE_NOT_ALLOWED_TO_GET_A_ROLE: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_GET_A_ROLE">;
1771
+ TOO_MANY_ROLES: import('better-auth').RawError<"TOO_MANY_ROLES">;
1772
+ INVALID_RESOURCE: import('better-auth').RawError<"INVALID_RESOURCE">;
1773
+ ROLE_NAME_IS_ALREADY_TAKEN: import('better-auth').RawError<"ROLE_NAME_IS_ALREADY_TAKEN">;
1774
+ CANNOT_DELETE_A_PRE_DEFINED_ROLE: import('better-auth').RawError<"CANNOT_DELETE_A_PRE_DEFINED_ROLE">;
1775
+ ROLE_IS_ASSIGNED_TO_MEMBERS: import('better-auth').RawError<"ROLE_IS_ASSIGNED_TO_MEMBERS">;
1776
+ };
1777
+ } | {
1778
+ id: "one-time-token";
1779
+ $InferServerPlugin: ReturnType<(options?: import('better-auth/plugins').OneTimeTokenOptions | undefined) => {
1780
+ id: "one-time-token";
1781
+ endpoints: {
1782
+ generateOneTimeToken: import('better-auth').StrictEndpoint<"/one-time-token/generate", {
1783
+ method: "GET";
1784
+ use: ((inputContext: import('better-auth').MiddlewareInputContext<import('better-auth').MiddlewareOptions>) => Promise<{
1785
+ session: {
1786
+ session: Record<string, any> & {
1787
+ id: string;
1788
+ createdAt: Date;
1789
+ updatedAt: Date;
1790
+ userId: string;
1791
+ expiresAt: Date;
1792
+ token: string;
1793
+ ipAddress?: string | null | undefined;
1794
+ userAgent?: string | null | undefined;
1795
+ };
1796
+ user: Record<string, any> & {
1797
+ id: string;
1798
+ createdAt: Date;
1799
+ updatedAt: Date;
1800
+ email: string;
1801
+ emailVerified: boolean;
1802
+ name: string;
1803
+ image?: string | null | undefined;
1804
+ };
1805
+ };
1806
+ }>)[];
1807
+ }, {
1808
+ token: string;
1809
+ }>;
1810
+ verifyOneTimeToken: import('better-auth').StrictEndpoint<"/one-time-token/verify", {
1811
+ method: "POST";
1812
+ body: import('zod').ZodObject<{
1813
+ token: import('zod').ZodString;
1814
+ }, import('better-auth').$strip>;
1815
+ }, {
1816
+ session: {
1817
+ id: string;
1818
+ createdAt: Date;
1819
+ updatedAt: Date;
1820
+ userId: string;
1821
+ expiresAt: Date;
1822
+ token: string;
1823
+ ipAddress?: string | null | undefined;
1824
+ userAgent?: string | null | undefined;
1825
+ } & Record<string, any>;
1826
+ user: {
1827
+ id: string;
1828
+ createdAt: Date;
1829
+ updatedAt: Date;
1830
+ email: string;
1831
+ emailVerified: boolean;
1832
+ name: string;
1833
+ image?: string | null | undefined;
1834
+ } & Record<string, any>;
1835
+ }>;
1836
+ };
1837
+ hooks: {
1838
+ after: {
1839
+ matcher: () => true;
1840
+ handler: (inputContext: import('better-auth').MiddlewareInputContext<import('better-auth').MiddlewareOptions>) => Promise<void>;
1841
+ }[];
1842
+ };
1843
+ options: import('better-auth/plugins').OneTimeTokenOptions | undefined;
1844
+ }>;
1845
+ })[];
1846
+ }, FetchOptions>>, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<(Omit<{
1847
+ token: null;
1848
+ user: {
1849
+ id: string;
1850
+ createdAt: Date;
1851
+ updatedAt: Date;
1852
+ email: string;
1853
+ emailVerified: boolean;
1854
+ name: string;
1855
+ image?: string | null | undefined | undefined;
1856
+ };
1857
+ }, "user"> & {
1858
+ user: import('better-auth').StripEmptyObjects<{
1859
+ id: string;
1860
+ createdAt: Date;
1861
+ updatedAt: Date;
1862
+ email: string;
1863
+ emailVerified: boolean;
1864
+ name: string;
1865
+ image?: string | null | undefined;
1866
+ } & {} & {
1867
+ userId?: string | null | undefined;
1868
+ }>;
1869
+ }) | (Omit<{
1870
+ token: string;
1871
+ user: {
1872
+ id: string;
1873
+ createdAt: Date;
1874
+ updatedAt: Date;
1875
+ email: string;
1876
+ emailVerified: boolean;
1877
+ name: string;
1878
+ image?: string | null | undefined | undefined;
1879
+ };
1880
+ }, "user"> & {
1881
+ user: import('better-auth').StripEmptyObjects<{
1882
+ id: string;
1883
+ createdAt: Date;
1884
+ updatedAt: Date;
1885
+ email: string;
1886
+ emailVerified: boolean;
1887
+ name: string;
1888
+ image?: string | null | undefined;
1889
+ } & {} & {
1890
+ userId?: string | null | undefined;
1891
+ }>;
1892
+ }), {
1893
+ code?: string | undefined;
1894
+ message?: string | undefined;
1895
+ }, FetchOptions["throw"] extends true ? true : false>>;
1896
+ };
1897
+ } & {
1898
+ signIn: {
1899
+ email: <FetchOptions extends import('better-auth').ClientFetchOption<Partial<{
1900
+ email: string;
1901
+ password: string;
1902
+ callbackURL?: string | undefined;
1903
+ rememberMe?: boolean | undefined;
1904
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0: import('better-auth').Prettify<{
1905
+ email: string;
1906
+ password: string;
1907
+ callbackURL?: string | undefined;
1908
+ rememberMe?: boolean | undefined;
1909
+ } & {
1910
+ fetchOptions?: FetchOptions | undefined;
1911
+ }>, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<Omit<{
1912
+ redirect: boolean;
1913
+ token: string;
1914
+ url?: string | undefined;
1915
+ user: {
1916
+ id: string;
1917
+ createdAt: Date;
1918
+ updatedAt: Date;
1919
+ email: string;
1920
+ emailVerified: boolean;
1921
+ name: string;
1922
+ image?: string | null | undefined | undefined;
1923
+ };
1924
+ }, "user"> & {
1925
+ user: import('better-auth').StripEmptyObjects<{
1926
+ id: string;
1927
+ createdAt: Date;
1928
+ updatedAt: Date;
1929
+ email: string;
1930
+ emailVerified: boolean;
1931
+ name: string;
1932
+ image?: string | null | undefined;
1933
+ } & {} & {
1934
+ userId?: string | null | undefined;
1935
+ }>;
1936
+ }, {
1937
+ code?: string | undefined;
1938
+ message?: string | undefined;
1939
+ }, FetchOptions["throw"] extends true ? true : false>>;
1940
+ };
1941
+ } & {
1942
+ resetPassword: <FetchOptions extends import('better-auth').ClientFetchOption<Partial<{
1943
+ newPassword: string;
1944
+ token?: string | undefined;
1945
+ }> & Record<string, any>, Partial<{
1946
+ token?: string | undefined;
1947
+ }> & Record<string, any>, Record<string, any> | undefined>>(data_0: import('better-auth').Prettify<{
1948
+ newPassword: string;
1949
+ token?: string | undefined;
1950
+ } & {
1951
+ fetchOptions?: FetchOptions | undefined;
1952
+ }>, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
1953
+ status: boolean;
1954
+ }, {
1955
+ code?: string | undefined;
1956
+ message?: string | undefined;
1957
+ }, FetchOptions["throw"] extends true ? true : false>>;
1958
+ } & {
1959
+ verifyEmail: <FetchOptions extends import('better-auth').ClientFetchOption<never, Partial<{
1960
+ token: string;
1961
+ callbackURL?: string | undefined;
1962
+ }> & Record<string, any>, Record<string, any> | undefined>>(data_0: import('better-auth').Prettify<{
1963
+ query: {
1964
+ token: string;
1965
+ callbackURL?: string | undefined;
1966
+ };
1967
+ fetchOptions?: FetchOptions | undefined;
1968
+ }>, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<NonNullable<void | {
1969
+ status: boolean;
1970
+ }>, {
1971
+ code?: string | undefined;
1972
+ message?: string | undefined;
1973
+ }, FetchOptions["throw"] extends true ? true : false>>;
1974
+ } & {
1975
+ sendVerificationEmail: <FetchOptions extends import('better-auth').ClientFetchOption<Partial<{
1976
+ email: string;
1977
+ callbackURL?: string | undefined;
1978
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0: import('better-auth').Prettify<{
1979
+ email: string;
1980
+ callbackURL?: string | undefined;
1981
+ } & {
1982
+ fetchOptions?: FetchOptions | undefined;
1983
+ }>, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
1984
+ status: boolean;
1985
+ }, {
1986
+ code?: string | undefined;
1987
+ message?: string | undefined;
1988
+ }, FetchOptions["throw"] extends true ? true : false>>;
1989
+ } & {
1990
+ changeEmail: <FetchOptions extends import('better-auth').ClientFetchOption<Partial<{
1991
+ newEmail: string;
1992
+ callbackURL?: string | undefined;
1993
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0: import('better-auth').Prettify<{
1994
+ newEmail: string;
1995
+ callbackURL?: string | undefined;
1996
+ } & {
1997
+ fetchOptions?: FetchOptions | undefined;
1998
+ }>, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
1999
+ status: boolean;
2000
+ }, {
2001
+ code?: string | undefined;
2002
+ message?: string | undefined;
2003
+ }, FetchOptions["throw"] extends true ? true : false>>;
2004
+ } & {
2005
+ changePassword: <FetchOptions extends import('better-auth').ClientFetchOption<Partial<{
2006
+ newPassword: string;
2007
+ currentPassword: string;
2008
+ revokeOtherSessions?: boolean | undefined;
2009
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0: import('better-auth').Prettify<{
2010
+ newPassword: string;
2011
+ currentPassword: string;
2012
+ revokeOtherSessions?: boolean | undefined;
2013
+ } & {
2014
+ fetchOptions?: FetchOptions | undefined;
2015
+ }>, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<Omit<{
2016
+ token: string | null;
2017
+ user: {
2018
+ id: string;
2019
+ createdAt: Date;
2020
+ updatedAt: Date;
2021
+ email: string;
2022
+ emailVerified: boolean;
2023
+ name: string;
2024
+ image?: string | null | undefined;
2025
+ } & Record<string, any> & {
2026
+ id: string;
2027
+ createdAt: Date;
2028
+ updatedAt: Date;
2029
+ email: string;
2030
+ emailVerified: boolean;
2031
+ name: string;
2032
+ image?: string | null | undefined;
2033
+ };
2034
+ }, "user"> & {
2035
+ user: import('better-auth').StripEmptyObjects<{
2036
+ id: string;
2037
+ createdAt: Date;
2038
+ updatedAt: Date;
2039
+ email: string;
2040
+ emailVerified: boolean;
2041
+ name: string;
2042
+ image?: string | null | undefined;
2043
+ } & {} & {
2044
+ userId?: string | null | undefined;
2045
+ }>;
2046
+ }, {
2047
+ code?: string | undefined;
2048
+ message?: string | undefined;
2049
+ }, FetchOptions["throw"] extends true ? true : false>>;
2050
+ } & {
2051
+ updateSession: <FetchOptions extends import('better-auth').ClientFetchOption<Partial<Partial<{}>> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0?: import('better-auth').Prettify<Partial<{}> & {
2052
+ fetchOptions?: FetchOptions | undefined;
2053
+ }> | undefined, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
2054
+ session: {
2055
+ id: string;
2056
+ createdAt: Date;
2057
+ updatedAt: Date;
2058
+ userId: string;
2059
+ expiresAt: Date;
2060
+ token: string;
2061
+ ipAddress?: string | null | undefined;
2062
+ userAgent?: string | null | undefined;
2063
+ };
2064
+ }, {
2065
+ code?: string | undefined;
2066
+ message?: string | undefined;
2067
+ }, FetchOptions["throw"] extends true ? true : false>>;
2068
+ } & {
2069
+ updateUser: <FetchOptions extends import('better-auth').ClientFetchOption<Partial<Partial<{}> & {
2070
+ name?: string | undefined;
2071
+ image?: string | undefined | null;
2072
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0?: import('better-auth').Prettify<import('better-auth/client').InferUserUpdateCtx<{
2073
+ baseURL: string;
2074
+ plugins: ({
2075
+ id: "convex";
2076
+ $InferServerPlugin: ReturnType<(opts: {
2077
+ authConfig: import('convex/server').AuthConfig;
2078
+ jwt?: {
2079
+ expirationSeconds?: number;
2080
+ definePayload?: (session: {
2081
+ user: {
2082
+ id: string;
2083
+ createdAt: Date;
2084
+ updatedAt: Date;
2085
+ email: string;
2086
+ emailVerified: boolean;
2087
+ name: string;
2088
+ image?: string | null | undefined;
2089
+ } & Record<string, any>;
2090
+ session: {
2091
+ id: string;
2092
+ createdAt: Date;
2093
+ updatedAt: Date;
2094
+ userId: string;
2095
+ expiresAt: Date;
2096
+ token: string;
2097
+ ipAddress?: string | null | undefined;
2098
+ userAgent?: string | null | undefined;
2099
+ } & Record<string, any>;
2100
+ }) => Promise<Record<string, any>> | Record<string, any> | undefined;
2101
+ };
2102
+ jwtExpirationSeconds?: number;
2103
+ jwks?: string;
2104
+ jwksRotateOnTokenGenerationError?: boolean;
2105
+ options?: import('better-auth').BetterAuthOptions;
2106
+ }) => {
2107
+ id: "convex";
2108
+ init: (ctx: import('better-auth').AuthContext) => void;
2109
+ hooks: {
2110
+ before: ({
2111
+ matcher(context: import('better-auth').HookEndpointContext): boolean;
2112
+ handler: (inputContext: import('better-auth').MiddlewareInputContext<import('better-auth').MiddlewareOptions>) => Promise<{
2113
+ context: {
2114
+ headers: Headers;
2115
+ };
2116
+ } | undefined>;
2117
+ } | {
2118
+ matcher: (ctx: import('better-auth').HookEndpointContext) => boolean;
2119
+ handler: (inputContext: import('better-auth').MiddlewareInputContext<import('better-auth').MiddlewareOptions>) => Promise<{
2120
+ context: import('better-auth').MiddlewareContext<import('better-auth').MiddlewareOptions, {
2121
+ returned?: unknown | undefined;
2122
+ responseHeaders?: Headers | undefined;
2123
+ } & import('better-auth').PluginContext<import('better-auth').BetterAuthOptions> & import('better-auth').InfoContext & {
2124
+ options: import('better-auth').BetterAuthOptions;
2125
+ trustedOrigins: string[];
2126
+ trustedProviders: string[];
2127
+ isTrustedOrigin: (url: string, settings?: {
2128
+ allowRelativePaths: boolean;
2129
+ }) => boolean;
2130
+ oauthConfig: {
2131
+ skipStateCookieCheck?: boolean | undefined;
2132
+ storeStateStrategy: "database" | "cookie";
2133
+ };
2134
+ newSession: {
2135
+ session: {
2136
+ id: string;
2137
+ createdAt: Date;
2138
+ updatedAt: Date;
2139
+ userId: string;
2140
+ expiresAt: Date;
2141
+ token: string;
2142
+ ipAddress?: string | null | undefined;
2143
+ userAgent?: string | null | undefined;
2144
+ } & Record<string, any>;
2145
+ user: {
2146
+ id: string;
2147
+ createdAt: Date;
2148
+ updatedAt: Date;
2149
+ email: string;
2150
+ emailVerified: boolean;
2151
+ name: string;
2152
+ image?: string | null | undefined;
2153
+ } & Record<string, any>;
2154
+ } | null;
2155
+ session: {
2156
+ session: {
2157
+ id: string;
2158
+ createdAt: Date;
2159
+ updatedAt: Date;
2160
+ userId: string;
2161
+ expiresAt: Date;
2162
+ token: string;
2163
+ ipAddress?: string | null | undefined;
2164
+ userAgent?: string | null | undefined;
2165
+ } & Record<string, any>;
2166
+ user: {
2167
+ id: string;
2168
+ createdAt: Date;
2169
+ updatedAt: Date;
2170
+ email: string;
2171
+ emailVerified: boolean;
2172
+ name: string;
2173
+ image?: string | null | undefined;
2174
+ } & Record<string, any>;
2175
+ } | null;
2176
+ setNewSession: (session: {
2177
+ session: {
2178
+ id: string;
2179
+ createdAt: Date;
2180
+ updatedAt: Date;
2181
+ userId: string;
2182
+ expiresAt: Date;
2183
+ token: string;
2184
+ ipAddress?: string | null | undefined;
2185
+ userAgent?: string | null | undefined;
2186
+ } & Record<string, any>;
2187
+ user: {
2188
+ id: string;
2189
+ createdAt: Date;
2190
+ updatedAt: Date;
2191
+ email: string;
2192
+ emailVerified: boolean;
2193
+ name: string;
2194
+ image?: string | null | undefined;
2195
+ } & Record<string, any>;
2196
+ } | null) => void;
2197
+ socialProviders: import('better-auth').OAuthProvider[];
2198
+ authCookies: import('better-auth').BetterAuthCookies;
2199
+ logger: ReturnType<(options?: import('better-auth').Logger | undefined) => import('better-auth').InternalLogger>;
2200
+ rateLimit: {
2201
+ enabled: boolean;
2202
+ window: number;
2203
+ max: number;
2204
+ storage: "memory" | "database" | "secondary-storage";
2205
+ } & Omit<import('better-auth').BetterAuthRateLimitOptions, "enabled" | "window" | "max" | "storage">;
2206
+ adapter: import('better-auth').DBAdapter<import('better-auth').BetterAuthOptions>;
2207
+ internalAdapter: import('better-auth').InternalAdapter<import('better-auth').BetterAuthOptions>;
2208
+ createAuthCookie: (cookieName: string, overrideAttributes?: Partial<import('better-auth').CookieOptions> | undefined) => import('better-auth').BetterAuthCookie;
2209
+ secret: string;
2210
+ secretConfig: string | import('better-auth').SecretConfig;
2211
+ sessionConfig: {
2212
+ updateAge: number;
2213
+ expiresIn: number;
2214
+ freshAge: number;
2215
+ cookieRefreshCache: false | {
2216
+ enabled: true;
2217
+ updateAge: number;
2218
+ };
2219
+ };
2220
+ generateId: (options: {
2221
+ model: import('better-auth').ModelNames;
2222
+ size?: number | undefined;
2223
+ }) => string | false;
2224
+ secondaryStorage: import('better-auth').SecondaryStorage | undefined;
2225
+ password: {
2226
+ hash: (password: string) => Promise<string>;
2227
+ verify: (data: {
2228
+ password: string;
2229
+ hash: string;
2230
+ }) => Promise<boolean>;
2231
+ config: {
2232
+ minPasswordLength: number;
2233
+ maxPasswordLength: number;
2234
+ };
2235
+ checkPassword: (userId: string, ctx: import('better-auth').GenericEndpointContext<import('better-auth').BetterAuthOptions>) => Promise<boolean>;
2236
+ };
2237
+ tables: import('better-auth').BetterAuthDBSchema;
2238
+ runMigrations: () => Promise<void>;
2239
+ publishTelemetry: (event: {
2240
+ type: string;
2241
+ anonymousId?: string | undefined;
2242
+ payload: Record<string, any>;
2243
+ }) => Promise<void>;
2244
+ skipOriginCheck: boolean | string[];
2245
+ skipCSRFCheck: boolean;
2246
+ runInBackground: (promise: Promise<unknown>) => void;
2247
+ runInBackgroundOrAwait: (promise: Promise<unknown> | void) => import('better-auth').Awaitable<unknown>;
2248
+ }>;
2249
+ }>;
2250
+ })[];
2251
+ after: {
2252
+ matcher: (context: import('better-auth').HookEndpointContext) => boolean;
2253
+ handler: import('better-auth/api').AuthMiddleware;
2254
+ }[];
2255
+ };
2256
+ endpoints: {
2257
+ getOpenIdConfig: import('better-auth').StrictEndpoint<"/convex/.well-known/openid-configuration", {
2258
+ method: "GET";
2259
+ metadata: {
2260
+ isAction: false;
2261
+ };
2262
+ }, import('better-auth/plugins').OIDCMetadata>;
2263
+ getJwks: import('better-auth').StrictEndpoint<"/convex/jwks", {
2264
+ method: "GET";
2265
+ metadata: {
2266
+ openapi: {
2267
+ description: string;
2268
+ responses: {
2269
+ "200": {
2270
+ description: string;
2271
+ content: {
2272
+ "application/json": {
2273
+ schema: {
2274
+ type: "object";
2275
+ properties: {
2276
+ keys: {
2277
+ type: string;
2278
+ description: string;
2279
+ items: {
2280
+ type: string;
2281
+ properties: {
2282
+ kid: {
2283
+ type: string;
2284
+ description: string;
2285
+ };
2286
+ kty: {
2287
+ type: string;
2288
+ description: string;
2289
+ };
2290
+ alg: {
2291
+ type: string;
2292
+ description: string;
2293
+ };
2294
+ use: {
2295
+ type: string;
2296
+ description: string;
2297
+ enum: string[];
2298
+ nullable: boolean;
2299
+ };
2300
+ n: {
2301
+ type: string;
2302
+ description: string;
2303
+ nullable: boolean;
2304
+ };
2305
+ e: {
2306
+ type: string;
2307
+ description: string;
2308
+ nullable: boolean;
2309
+ };
2310
+ crv: {
2311
+ type: string;
2312
+ description: string;
2313
+ nullable: boolean;
2314
+ };
2315
+ x: {
2316
+ type: string;
2317
+ description: string;
2318
+ nullable: boolean;
2319
+ };
2320
+ y: {
2321
+ type: string;
2322
+ description: string;
2323
+ nullable: boolean;
2324
+ };
2325
+ };
2326
+ required: string[];
2327
+ };
2328
+ };
2329
+ };
2330
+ required: string[];
2331
+ };
2332
+ };
2333
+ };
2334
+ };
2335
+ };
2336
+ };
2337
+ };
2338
+ }, import('better-auth').JSONWebKeySet>;
2339
+ getLatestJwks: import('better-auth').StrictEndpoint<"/convex/latest-jwks", {
2340
+ isAction: boolean;
2341
+ method: "POST";
2342
+ metadata: {
2343
+ SERVER_ONLY: true;
2344
+ openapi: {
2345
+ description: string;
2346
+ };
2347
+ };
2348
+ }, any[]>;
2349
+ rotateKeys: import('better-auth').StrictEndpoint<"/convex/rotate-keys", {
2350
+ isAction: boolean;
2351
+ method: "POST";
2352
+ metadata: {
2353
+ SERVER_ONLY: true;
2354
+ openapi: {
2355
+ description: string;
2356
+ };
2357
+ };
2358
+ }, any[]>;
2359
+ getToken: import('better-auth').StrictEndpoint<"/convex/token", {
2360
+ method: "GET";
2361
+ requireHeaders: true;
2362
+ use: ((inputContext: import('better-auth').MiddlewareInputContext<import('better-auth').MiddlewareOptions>) => Promise<{
2363
+ session: {
2364
+ session: Record<string, any> & {
2365
+ id: string;
2366
+ createdAt: Date;
2367
+ updatedAt: Date;
2368
+ userId: string;
2369
+ expiresAt: Date;
2370
+ token: string;
2371
+ ipAddress?: string | null | undefined;
2372
+ userAgent?: string | null | undefined;
2373
+ };
2374
+ user: Record<string, any> & {
2375
+ id: string;
2376
+ createdAt: Date;
2377
+ updatedAt: Date;
2378
+ email: string;
2379
+ emailVerified: boolean;
2380
+ name: string;
2381
+ image?: string | null | undefined;
2382
+ };
2383
+ };
2384
+ }>)[];
2385
+ metadata: {
2386
+ openapi: {
2387
+ description: string;
2388
+ responses: {
2389
+ 200: {
2390
+ description: string;
2391
+ content: {
2392
+ "application/json": {
2393
+ schema: {
2394
+ type: "object";
2395
+ properties: {
2396
+ token: {
2397
+ type: string;
2398
+ };
2399
+ };
2400
+ };
2401
+ };
2402
+ };
2403
+ };
2404
+ };
2405
+ };
2406
+ };
2407
+ }, {
2408
+ token: string;
2409
+ }>;
2410
+ };
2411
+ schema: {
2412
+ jwks: {
2413
+ fields: {
2414
+ publicKey: {
2415
+ type: "string";
2416
+ required: true;
2417
+ };
2418
+ privateKey: {
2419
+ type: "string";
2420
+ required: true;
2421
+ };
2422
+ createdAt: {
2423
+ type: "date";
2424
+ required: true;
2425
+ };
2426
+ expiresAt: {
2427
+ type: "date";
2428
+ required: false;
2429
+ };
2430
+ };
2431
+ };
2432
+ user: {
2433
+ readonly fields: {
2434
+ readonly userId: {
2435
+ readonly type: "string";
2436
+ readonly required: false;
2437
+ readonly input: false;
2438
+ };
2439
+ };
2440
+ };
2441
+ };
2442
+ }>;
2443
+ } | {
2444
+ id: "cross-domain";
2445
+ $InferServerPlugin: ReturnType<({ siteUrl }: {
2446
+ siteUrl: string;
2447
+ }) => {
2448
+ id: "cross-domain";
2449
+ init(): {
2450
+ options: {
2451
+ trustedOrigins: string[];
2452
+ };
2453
+ context: {
2454
+ oauthConfig: {
2455
+ storeStateStrategy: "database";
2456
+ skipStateCookieCheck: true;
2457
+ };
2458
+ };
2459
+ };
2460
+ hooks: {
2461
+ before: ({
2462
+ matcher(ctx: import('better-auth').HookEndpointContext): boolean;
2463
+ handler: (inputContext: import('better-auth').MiddlewareInputContext<import('better-auth').MiddlewareOptions>) => Promise<{
2464
+ context: {
2465
+ headers: Headers;
2466
+ };
2467
+ } | undefined>;
2468
+ } | {
2469
+ matcher: (ctx: import('better-auth').HookEndpointContext) => boolean;
2470
+ handler: (inputContext: import('better-auth').MiddlewareInputContext<import('better-auth').MiddlewareOptions>) => Promise<{
2471
+ context: import('better-auth').MiddlewareContext<import('better-auth').MiddlewareOptions, {
2472
+ returned?: unknown | undefined;
2473
+ responseHeaders?: Headers | undefined;
2474
+ } & import('better-auth').PluginContext<import('better-auth').BetterAuthOptions> & import('better-auth').InfoContext & {
2475
+ options: import('better-auth').BetterAuthOptions;
2476
+ trustedOrigins: string[];
2477
+ trustedProviders: string[];
2478
+ isTrustedOrigin: (url: string, settings?: {
2479
+ allowRelativePaths: boolean;
2480
+ }) => boolean;
2481
+ oauthConfig: {
2482
+ skipStateCookieCheck?: boolean | undefined;
2483
+ storeStateStrategy: "database" | "cookie";
2484
+ };
2485
+ newSession: {
2486
+ session: {
2487
+ id: string;
2488
+ createdAt: Date;
2489
+ updatedAt: Date;
2490
+ userId: string;
2491
+ expiresAt: Date;
2492
+ token: string;
2493
+ ipAddress?: string | null | undefined;
2494
+ userAgent?: string | null | undefined;
2495
+ } & Record<string, any>;
2496
+ user: {
2497
+ id: string;
2498
+ createdAt: Date;
2499
+ updatedAt: Date;
2500
+ email: string;
2501
+ emailVerified: boolean;
2502
+ name: string;
2503
+ image?: string | null | undefined;
2504
+ } & Record<string, any>;
2505
+ } | null;
2506
+ session: {
2507
+ session: {
2508
+ id: string;
2509
+ createdAt: Date;
2510
+ updatedAt: Date;
2511
+ userId: string;
2512
+ expiresAt: Date;
2513
+ token: string;
2514
+ ipAddress?: string | null | undefined;
2515
+ userAgent?: string | null | undefined;
2516
+ } & Record<string, any>;
2517
+ user: {
2518
+ id: string;
2519
+ createdAt: Date;
2520
+ updatedAt: Date;
2521
+ email: string;
2522
+ emailVerified: boolean;
2523
+ name: string;
2524
+ image?: string | null | undefined;
2525
+ } & Record<string, any>;
2526
+ } | null;
2527
+ setNewSession: (session: {
2528
+ session: {
2529
+ id: string;
2530
+ createdAt: Date;
2531
+ updatedAt: Date;
2532
+ userId: string;
2533
+ expiresAt: Date;
2534
+ token: string;
2535
+ ipAddress?: string | null | undefined;
2536
+ userAgent?: string | null | undefined;
2537
+ } & Record<string, any>;
2538
+ user: {
2539
+ id: string;
2540
+ createdAt: Date;
2541
+ updatedAt: Date;
2542
+ email: string;
2543
+ emailVerified: boolean;
2544
+ name: string;
2545
+ image?: string | null | undefined;
2546
+ } & Record<string, any>;
2547
+ } | null) => void;
2548
+ socialProviders: import('better-auth').OAuthProvider[];
2549
+ authCookies: import('better-auth').BetterAuthCookies;
2550
+ logger: ReturnType<(options?: import('better-auth').Logger | undefined) => import('better-auth').InternalLogger>;
2551
+ rateLimit: {
2552
+ enabled: boolean;
2553
+ window: number;
2554
+ max: number;
2555
+ storage: "memory" | "database" | "secondary-storage";
2556
+ } & Omit<import('better-auth').BetterAuthRateLimitOptions, "enabled" | "window" | "max" | "storage">;
2557
+ adapter: import('better-auth').DBAdapter<import('better-auth').BetterAuthOptions>;
2558
+ internalAdapter: import('better-auth').InternalAdapter<import('better-auth').BetterAuthOptions>;
2559
+ createAuthCookie: (cookieName: string, overrideAttributes?: Partial<import('better-auth').CookieOptions> | undefined) => import('better-auth').BetterAuthCookie;
2560
+ secret: string;
2561
+ secretConfig: string | import('better-auth').SecretConfig;
2562
+ sessionConfig: {
2563
+ updateAge: number;
2564
+ expiresIn: number;
2565
+ freshAge: number;
2566
+ cookieRefreshCache: false | {
2567
+ enabled: true;
2568
+ updateAge: number;
2569
+ };
2570
+ };
2571
+ generateId: (options: {
2572
+ model: import('better-auth').ModelNames;
2573
+ size?: number | undefined;
2574
+ }) => string | false;
2575
+ secondaryStorage: import('better-auth').SecondaryStorage | undefined;
2576
+ password: {
2577
+ hash: (password: string) => Promise<string>;
2578
+ verify: (data: {
2579
+ password: string;
2580
+ hash: string;
2581
+ }) => Promise<boolean>;
2582
+ config: {
2583
+ minPasswordLength: number;
2584
+ maxPasswordLength: number;
2585
+ };
2586
+ checkPassword: (userId: string, ctx: import('better-auth').GenericEndpointContext<import('better-auth').BetterAuthOptions>) => Promise<boolean>;
2587
+ };
2588
+ tables: import('better-auth').BetterAuthDBSchema;
2589
+ runMigrations: () => Promise<void>;
2590
+ publishTelemetry: (event: {
2591
+ type: string;
2592
+ anonymousId?: string | undefined;
2593
+ payload: Record<string, any>;
2594
+ }) => Promise<void>;
2595
+ skipOriginCheck: boolean | string[];
2596
+ skipCSRFCheck: boolean;
2597
+ runInBackground: (promise: Promise<unknown>) => void;
2598
+ runInBackgroundOrAwait: (promise: Promise<unknown> | void) => import('better-auth').Awaitable<unknown>;
2599
+ }>;
2600
+ }>;
2601
+ })[];
2602
+ after: {
2603
+ matcher(ctx: import('better-auth').HookEndpointContext): boolean;
2604
+ handler: (inputContext: import('better-auth').MiddlewareInputContext<import('better-auth').MiddlewareOptions>) => Promise<void>;
2605
+ }[];
2606
+ };
2607
+ endpoints: {
2608
+ verifyOneTimeToken: import('better-auth').StrictEndpoint<"/cross-domain/one-time-token/verify", {
2609
+ method: "POST";
2610
+ body: import('zod').ZodObject<{
2611
+ token: import('zod').ZodString;
2612
+ }, import('better-auth').$strip>;
2613
+ }, {
2614
+ session: import('better-auth').Session & Record<string, any>;
2615
+ user: import('better-auth').User & Record<string, any>;
2616
+ }>;
2617
+ };
2618
+ }>;
2619
+ getActions(_: import('better-auth/client').BetterFetch, $store: import('better-auth').ClientStore): {
2620
+ getCookie: () => string;
2621
+ updateSession: () => void;
2622
+ getSessionData: () => Record<string, unknown> | null;
2623
+ };
2624
+ fetchPlugins: {
2625
+ id: string;
2626
+ name: string;
2627
+ hooks: {
2628
+ onSuccess(context: import('better-auth/client').SuccessContext<any>): Promise<void>;
2629
+ };
2630
+ init(url: string, options: ({
2631
+ method?: string | undefined;
2632
+ headers?: (HeadersInit & (HeadersInit | {
2633
+ accept: "application/json" | "text/plain" | "application/octet-stream";
2634
+ "content-type": "application/json" | "text/plain" | "application/x-www-form-urlencoded" | "multipart/form-data" | "application/octet-stream";
2635
+ authorization: "Bearer" | "Basic";
2636
+ })) | undefined;
2637
+ redirect?: RequestRedirect | undefined;
2638
+ window?: null | undefined;
2639
+ cache?: RequestCache | undefined;
2640
+ credentials?: RequestCredentials | undefined;
2641
+ integrity?: string | undefined;
2642
+ keepalive?: boolean | undefined;
2643
+ mode?: RequestMode | undefined;
2644
+ priority?: RequestPriority | undefined;
2645
+ referrer?: string | undefined;
2646
+ referrerPolicy?: ReferrerPolicy | undefined;
2647
+ signal?: (AbortSignal | null) | undefined;
2648
+ onRequest?: (<T extends Record<string, any>>(context: import('better-auth/client').RequestContext<T>) => Promise<import('better-auth/client').RequestContext | void> | import('better-auth/client').RequestContext | void) | undefined;
2649
+ onResponse?: ((context: import('better-auth/client').ResponseContext) => Promise<Response | void | import('better-auth/client').ResponseContext> | Response | import('better-auth/client').ResponseContext | void) | undefined;
2650
+ onSuccess?: ((context: import('better-auth/client').SuccessContext<any>) => Promise<void> | void) | undefined;
2651
+ onError?: ((context: import('better-auth/client').ErrorContext) => Promise<void> | void) | undefined;
2652
+ onRetry?: ((response: import('better-auth/client').ResponseContext) => Promise<void> | void) | undefined;
2653
+ hookOptions?: {
2654
+ cloneResponse?: boolean;
2655
+ } | undefined;
2656
+ timeout
2657
+ /**
2658
+ * Registers sign-out and manage-account actions in the command palette.
2659
+ */
2660
+ ? /**
2661
+ * Registers sign-out and manage-account actions in the command palette.
2662
+ */: number | undefined;
2663
+ customFetchImpl?: import('better-auth/client').FetchEsque | undefined;
2664
+ plugins?: import('better-auth/client').BetterFetchPlugin[] | undefined;
2665
+ baseURL?: string | undefined;
2666
+ throw?: boolean | undefined;
2667
+ auth?: ({
2668
+ type: "Bearer";
2669
+ token: string | Promise<string | undefined> | (() => string | Promise<string | undefined> | undefined) | undefined;
2670
+ } | {
2671
+ type: "Basic";
2672
+ username: string | (() => string | undefined) | undefined;
2673
+ password: string | (() => string | undefined) | undefined;
2674
+ } | {
2675
+ type: "Custom";
2676
+ prefix: string | (() => string | undefined) | undefined;
2677
+ value: string | (() => string | undefined) | undefined;
2678
+ }) | undefined;
2679
+ body?: any;
2680
+ query?: any;
2681
+ params?: any;
2682
+ duplex?: "full" | "half" | undefined;
2683
+ jsonParser?: ((text: string) => Promise<any> | any) | undefined;
2684
+ retry?: import('better-auth/client').RetryOptions | undefined;
2685
+ retryAttempt?: number | undefined;
2686
+ output?: (import('better-auth/client').StandardSchemaV1 | typeof Blob | typeof File) | undefined;
2687
+ errorSchema?: import('better-auth/client').StandardSchemaV1 | undefined;
2688
+ disableValidation?: boolean | undefined;
2689
+ } & Record<string, any>) | undefined): Promise<{
2690
+ url: string;
2691
+ options: import('better-auth/client').BetterFetchOption;
2692
+ }>;
2693
+ }[];
2694
+ } | {
2695
+ id: "organization";
2696
+ $InferServerPlugin: import('better-auth/plugins').OrganizationPlugin<{
2697
+ ac: import('better-auth/plugins').AccessControl<{
2698
+ readonly organization: readonly ["update", "delete"];
2699
+ readonly member: readonly ["create", "update", "delete"];
2700
+ readonly invitation: readonly ["create", "cancel"];
2701
+ readonly team: readonly ["create", "update", "delete"];
2702
+ readonly ac: readonly ["create", "read", "update", "delete"];
2703
+ }>;
2704
+ roles: {
2705
+ admin: import('better-auth/plugins').Role;
2706
+ member: import('better-auth/plugins').Role;
2707
+ owner: import('better-auth/plugins').Role;
2708
+ };
2709
+ teams: {
2710
+ enabled: false;
2711
+ };
2712
+ schema: {
2713
+ organization?: {
2714
+ additionalFields?: {
2715
+ [key: string]: import('better-auth').DBFieldAttribute;
2716
+ };
2717
+ };
2718
+ member?: {
2719
+ additionalFields?: {
2720
+ [key: string]: import('better-auth').DBFieldAttribute;
2721
+ };
2722
+ };
2723
+ invitation?: {
2724
+ additionalFields?: {
2725
+ [key: string]: import('better-auth').DBFieldAttribute;
2726
+ };
2727
+ };
2728
+ team?: {
2729
+ additionalFields?: {
2730
+ [key: string]: import('better-auth').DBFieldAttribute;
2731
+ };
2732
+ };
2733
+ organizationRole?: {
2734
+ additionalFields?: {
2735
+ [key: string]: import('better-auth').DBFieldAttribute;
2736
+ };
2737
+ };
2738
+ } | undefined;
2739
+ dynamicAccessControl: {
2740
+ enabled: false;
2741
+ };
2742
+ }>;
2743
+ getActions: ($fetch: import('better-auth/client').BetterFetch, _$store: import('better-auth').ClientStore, co: import('better-auth').BetterAuthClientOptions | undefined) => {
2744
+ $Infer: {
2745
+ ActiveOrganization: {
2746
+ members: {
2747
+ id: string;
2748
+ organizationId: string;
2749
+ role: "member" | "admin" | "owner";
2750
+ createdAt: Date;
2751
+ userId: string;
2752
+ user: {
2753
+ id: string;
2754
+ email: string;
2755
+ name: string;
2756
+ image?: string | undefined;
2757
+ };
2758
+ }[];
2759
+ invitations: {
2760
+ id: string;
2761
+ organizationId: string;
2762
+ email: string;
2763
+ role: "member" | "admin" | "owner";
2764
+ status: import('better-auth/plugins').InvitationStatus;
2765
+ inviterId: string;
2766
+ expiresAt: Date;
2767
+ createdAt: Date;
2768
+ }[];
2769
+ } & {
2770
+ id: string;
2771
+ name: string;
2772
+ slug: string;
2773
+ createdAt: Date;
2774
+ logo?: string | null | undefined | undefined;
2775
+ metadata?: any;
2776
+ };
2777
+ Organization: {
2778
+ id: string;
2779
+ name: string;
2780
+ slug: string;
2781
+ createdAt: Date;
2782
+ logo?: string | null | undefined;
2783
+ metadata?: any;
2784
+ };
2785
+ Invitation: {
2786
+ id: string;
2787
+ organizationId: string;
2788
+ email: string;
2789
+ role: "member" | "admin" | "owner";
2790
+ status: import('better-auth/plugins').InvitationStatus;
2791
+ inviterId: string;
2792
+ expiresAt: Date;
2793
+ createdAt: Date;
2794
+ };
2795
+ Member: {
2796
+ id: string;
2797
+ organizationId: string;
2798
+ role: "member" | "admin" | "owner";
2799
+ createdAt: Date;
2800
+ userId: string;
2801
+ user: {
2802
+ id: string;
2803
+ email: string;
2804
+ name: string;
2805
+ image?: string | undefined;
2806
+ };
2807
+ };
2808
+ Team: {
2809
+ id: string;
2810
+ name: string;
2811
+ organizationId: string;
2812
+ createdAt: Date;
2813
+ updatedAt?: Date | undefined;
2814
+ };
2815
+ };
2816
+ organization: {
2817
+ checkRolePermission: <R extends "member" | "admin" | "owner">(data: {
2818
+ permissions: {
2819
+ readonly organization?: ("delete" | "update")[] | undefined;
2820
+ readonly member?: ("delete" | "create" | "update")[] | undefined;
2821
+ readonly invitation?: ("cancel" | "create")[] | undefined;
2822
+ readonly team?: ("delete" | "create" | "update")[] | undefined;
2823
+ readonly ac?: ("delete" | "create" | "update" | "read")[] | undefined;
2824
+ };
2825
+ } & {
2826
+ role: R;
2827
+ }) => boolean;
2828
+ };
2829
+ };
2830
+ getAtoms: ($fetch: import('better-auth/client').BetterFetch) => {
2831
+ $listOrg: import('better-auth/client').PreinitializedWritableAtom<boolean> & object;
2832
+ $activeOrgSignal: import('better-auth/client').PreinitializedWritableAtom<boolean> & object;
2833
+ $activeMemberSignal: import('better-auth/client').PreinitializedWritableAtom<boolean> & object;
2834
+ $activeMemberRoleSignal: import('better-auth/client').PreinitializedWritableAtom<boolean> & object;
2835
+ activeOrganization: import('better-auth/client').AuthQueryAtom<import('better-auth').Prettify<{
2836
+ id: string;
2837
+ name: string;
2838
+ slug: string;
2839
+ createdAt: Date;
2840
+ logo?: string | null | undefined | undefined;
2841
+ metadata?: any;
2842
+ } & {
2843
+ members: {
2844
+ id: string;
2845
+ organizationId: string;
2846
+ role: "member" | "admin" | "owner";
2847
+ createdAt: Date;
2848
+ userId: string;
2849
+ user: {
2850
+ id: string;
2851
+ email: string;
2852
+ name: string;
2853
+ image?: string | undefined;
2854
+ };
2855
+ }[];
2856
+ invitations: {
2857
+ id: string;
2858
+ organizationId: string;
2859
+ email: string;
2860
+ role: "member" | "admin" | "owner";
2861
+ status: import('better-auth/plugins').InvitationStatus;
2862
+ inviterId: string;
2863
+ expiresAt: Date;
2864
+ createdAt: Date;
2865
+ }[];
2866
+ }>>;
2867
+ listOrganizations: import('better-auth/client').AuthQueryAtom<{
2868
+ id: string;
2869
+ name: string;
2870
+ slug: string;
2871
+ createdAt: Date;
2872
+ logo?: string | null | undefined | undefined;
2873
+ metadata?: any;
2874
+ }[]>;
2875
+ activeMember: import('better-auth/client').AuthQueryAtom<{
2876
+ id: string;
2877
+ organizationId: string;
2878
+ userId: string;
2879
+ role: string;
2880
+ createdAt: Date;
2881
+ }>;
2882
+ activeMemberRole: import('better-auth/client').AuthQueryAtom<{
2883
+ role: string;
2884
+ }>;
2885
+ };
2886
+ pathMethods: {
2887
+ "/organization/get-full-organization": "GET";
2888
+ "/organization/list-user-teams": "GET";
2889
+ };
2890
+ atomListeners: ({
2891
+ matcher(path: string): path is "/organization/create" | "/organization/update" | "/organization/delete";
2892
+ signal: "$listOrg";
2893
+ } | {
2894
+ matcher(path: string): boolean;
2895
+ signal: "$activeOrgSignal";
2896
+ } | {
2897
+ matcher(path: string): boolean;
2898
+ signal: "$sessionSignal";
2899
+ } | {
2900
+ matcher(path: string): boolean;
2901
+ signal: "$activeMemberSignal";
2902
+ } | {
2903
+ matcher(path: string): boolean;
2904
+ signal: "$activeMemberRoleSignal";
2905
+ })[];
2906
+ $ERROR_CODES: {
2907
+ YOU_ARE_NOT_ALLOWED_TO_CREATE_A_NEW_ORGANIZATION: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_CREATE_A_NEW_ORGANIZATION">;
2908
+ YOU_HAVE_REACHED_THE_MAXIMUM_NUMBER_OF_ORGANIZATIONS: import('better-auth').RawError<"YOU_HAVE_REACHED_THE_MAXIMUM_NUMBER_OF_ORGANIZATIONS">;
2909
+ ORGANIZATION_ALREADY_EXISTS: import('better-auth').RawError<"ORGANIZATION_ALREADY_EXISTS">;
2910
+ ORGANIZATION_SLUG_ALREADY_TAKEN: import('better-auth').RawError<"ORGANIZATION_SLUG_ALREADY_TAKEN">;
2911
+ ORGANIZATION_NOT_FOUND: import('better-auth').RawError<"ORGANIZATION_NOT_FOUND">;
2912
+ USER_IS_NOT_A_MEMBER_OF_THE_ORGANIZATION: import('better-auth').RawError<"USER_IS_NOT_A_MEMBER_OF_THE_ORGANIZATION">;
2913
+ YOU_ARE_NOT_ALLOWED_TO_UPDATE_THIS_ORGANIZATION: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_UPDATE_THIS_ORGANIZATION">;
2914
+ YOU_ARE_NOT_ALLOWED_TO_DELETE_THIS_ORGANIZATION: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_DELETE_THIS_ORGANIZATION">;
2915
+ NO_ACTIVE_ORGANIZATION: import('better-auth').RawError<"NO_ACTIVE_ORGANIZATION">;
2916
+ USER_IS_ALREADY_A_MEMBER_OF_THIS_ORGANIZATION: import('better-auth').RawError<"USER_IS_ALREADY_A_MEMBER_OF_THIS_ORGANIZATION">;
2917
+ MEMBER_NOT_FOUND: import('better-auth').RawError<"MEMBER_NOT_FOUND">;
2918
+ ROLE_NOT_FOUND: import('better-auth').RawError<"ROLE_NOT_FOUND">;
2919
+ YOU_ARE_NOT_ALLOWED_TO_CREATE_A_NEW_TEAM: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_CREATE_A_NEW_TEAM">;
2920
+ TEAM_ALREADY_EXISTS: import('better-auth').RawError<"TEAM_ALREADY_EXISTS">;
2921
+ TEAM_NOT_FOUND: import('better-auth').RawError<"TEAM_NOT_FOUND">;
2922
+ YOU_CANNOT_LEAVE_THE_ORGANIZATION_AS_THE_ONLY_OWNER: import('better-auth').RawError<"YOU_CANNOT_LEAVE_THE_ORGANIZATION_AS_THE_ONLY_OWNER">;
2923
+ YOU_CANNOT_LEAVE_THE_ORGANIZATION_WITHOUT_AN_OWNER: import('better-auth').RawError<"YOU_CANNOT_LEAVE_THE_ORGANIZATION_WITHOUT_AN_OWNER">;
2924
+ YOU_ARE_NOT_ALLOWED_TO_DELETE_THIS_MEMBER: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_DELETE_THIS_MEMBER">;
2925
+ YOU_ARE_NOT_ALLOWED_TO_INVITE_USERS_TO_THIS_ORGANIZATION: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_INVITE_USERS_TO_THIS_ORGANIZATION">;
2926
+ USER_IS_ALREADY_INVITED_TO_THIS_ORGANIZATION: import('better-auth').RawError<"USER_IS_ALREADY_INVITED_TO_THIS_ORGANIZATION">;
2927
+ INVITATION_NOT_FOUND: import('better-auth').RawError<"INVITATION_NOT_FOUND">;
2928
+ YOU_ARE_NOT_THE_RECIPIENT_OF_THE_INVITATION: import('better-auth').RawError<"YOU_ARE_NOT_THE_RECIPIENT_OF_THE_INVITATION">;
2929
+ EMAIL_VERIFICATION_REQUIRED_BEFORE_ACCEPTING_OR_REJECTING_INVITATION: import('better-auth').RawError<"EMAIL_VERIFICATION_REQUIRED_BEFORE_ACCEPTING_OR_REJECTING_INVITATION">;
2930
+ YOU_ARE_NOT_ALLOWED_TO_CANCEL_THIS_INVITATION: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_CANCEL_THIS_INVITATION">;
2931
+ INVITER_IS_NO_LONGER_A_MEMBER_OF_THE_ORGANIZATION: import('better-auth').RawError<"INVITER_IS_NO_LONGER_A_MEMBER_OF_THE_ORGANIZATION">;
2932
+ YOU_ARE_NOT_ALLOWED_TO_INVITE_USER_WITH_THIS_ROLE: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_INVITE_USER_WITH_THIS_ROLE">;
2933
+ FAILED_TO_RETRIEVE_INVITATION: import('better-auth').RawError<"FAILED_TO_RETRIEVE_INVITATION">;
2934
+ YOU_HAVE_REACHED_THE_MAXIMUM_NUMBER_OF_TEAMS: import('better-auth').RawError<"YOU_HAVE_REACHED_THE_MAXIMUM_NUMBER_OF_TEAMS">;
2935
+ UNABLE_TO_REMOVE_LAST_TEAM: import('better-auth').RawError<"UNABLE_TO_REMOVE_LAST_TEAM">;
2936
+ YOU_ARE_NOT_ALLOWED_TO_UPDATE_THIS_MEMBER: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_UPDATE_THIS_MEMBER">;
2937
+ ORGANIZATION_MEMBERSHIP_LIMIT_REACHED: import('better-auth').RawError<"ORGANIZATION_MEMBERSHIP_LIMIT_REACHED">;
2938
+ YOU_ARE_NOT_ALLOWED_TO_CREATE_TEAMS_IN_THIS_ORGANIZATION: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_CREATE_TEAMS_IN_THIS_ORGANIZATION">;
2939
+ YOU_ARE_NOT_ALLOWED_TO_DELETE_TEAMS_IN_THIS_ORGANIZATION: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_DELETE_TEAMS_IN_THIS_ORGANIZATION">;
2940
+ YOU_ARE_NOT_ALLOWED_TO_UPDATE_THIS_TEAM: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_UPDATE_THIS_TEAM">;
2941
+ YOU_ARE_NOT_ALLOWED_TO_DELETE_THIS_TEAM: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_DELETE_THIS_TEAM">;
2942
+ INVITATION_LIMIT_REACHED: import('better-auth').RawError<"INVITATION_LIMIT_REACHED">;
2943
+ TEAM_MEMBER_LIMIT_REACHED: import('better-auth').RawError<"TEAM_MEMBER_LIMIT_REACHED">;
2944
+ USER_IS_NOT_A_MEMBER_OF_THE_TEAM: import('better-auth').RawError<"USER_IS_NOT_A_MEMBER_OF_THE_TEAM">;
2945
+ YOU_CAN_NOT_ACCESS_THE_MEMBERS_OF_THIS_TEAM: import('better-auth').RawError<"YOU_CAN_NOT_ACCESS_THE_MEMBERS_OF_THIS_TEAM">;
2946
+ YOU_DO_NOT_HAVE_AN_ACTIVE_TEAM: import('better-auth').RawError<"YOU_DO_NOT_HAVE_AN_ACTIVE_TEAM">;
2947
+ YOU_ARE_NOT_ALLOWED_TO_CREATE_A_NEW_TEAM_MEMBER: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_CREATE_A_NEW_TEAM_MEMBER">;
2948
+ YOU_ARE_NOT_ALLOWED_TO_REMOVE_A_TEAM_MEMBER: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_REMOVE_A_TEAM_MEMBER">;
2949
+ YOU_ARE_NOT_ALLOWED_TO_ACCESS_THIS_ORGANIZATION: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_ACCESS_THIS_ORGANIZATION">;
2950
+ YOU_ARE_NOT_A_MEMBER_OF_THIS_ORGANIZATION: import('better-auth').RawError<"YOU_ARE_NOT_A_MEMBER_OF_THIS_ORGANIZATION">;
2951
+ MISSING_AC_INSTANCE: import('better-auth').RawError<"MISSING_AC_INSTANCE">;
2952
+ YOU_MUST_BE_IN_AN_ORGANIZATION_TO_CREATE_A_ROLE: import('better-auth').RawError<"YOU_MUST_BE_IN_AN_ORGANIZATION_TO_CREATE_A_ROLE">;
2953
+ YOU_ARE_NOT_ALLOWED_TO_CREATE_A_ROLE: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_CREATE_A_ROLE">;
2954
+ YOU_ARE_NOT_ALLOWED_TO_UPDATE_A_ROLE: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_UPDATE_A_ROLE">;
2955
+ YOU_ARE_NOT_ALLOWED_TO_DELETE_A_ROLE: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_DELETE_A_ROLE">;
2956
+ YOU_ARE_NOT_ALLOWED_TO_READ_A_ROLE: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_READ_A_ROLE">;
2957
+ YOU_ARE_NOT_ALLOWED_TO_LIST_A_ROLE: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_LIST_A_ROLE">;
2958
+ YOU_ARE_NOT_ALLOWED_TO_GET_A_ROLE: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_GET_A_ROLE">;
2959
+ TOO_MANY_ROLES: import('better-auth').RawError<"TOO_MANY_ROLES">;
2960
+ INVALID_RESOURCE: import('better-auth').RawError<"INVALID_RESOURCE">;
2961
+ ROLE_NAME_IS_ALREADY_TAKEN: import('better-auth').RawError<"ROLE_NAME_IS_ALREADY_TAKEN">;
2962
+ CANNOT_DELETE_A_PRE_DEFINED_ROLE: import('better-auth').RawError<"CANNOT_DELETE_A_PRE_DEFINED_ROLE">;
2963
+ ROLE_IS_ASSIGNED_TO_MEMBERS: import('better-auth').RawError<"ROLE_IS_ASSIGNED_TO_MEMBERS">;
2964
+ };
2965
+ } | {
2966
+ id: "one-time-token";
2967
+ $InferServerPlugin: ReturnType<(options?: import('better-auth/plugins').OneTimeTokenOptions | undefined) => {
2968
+ id: "one-time-token";
2969
+ endpoints: {
2970
+ generateOneTimeToken: import('better-auth').StrictEndpoint<"/one-time-token/generate", {
2971
+ method: "GET";
2972
+ use: ((inputContext: import('better-auth').MiddlewareInputContext<import('better-auth').MiddlewareOptions>) => Promise<{
2973
+ session: {
2974
+ session: Record<string, any> & {
2975
+ id: string;
2976
+ createdAt: Date;
2977
+ updatedAt: Date;
2978
+ userId: string;
2979
+ expiresAt: Date;
2980
+ token: string;
2981
+ ipAddress?: string | null | undefined;
2982
+ userAgent?: string | null | undefined;
2983
+ };
2984
+ user: Record<string, any> & {
2985
+ id: string;
2986
+ createdAt: Date;
2987
+ updatedAt: Date;
2988
+ email: string;
2989
+ emailVerified: boolean;
2990
+ name: string;
2991
+ image?: string | null | undefined;
2992
+ };
2993
+ };
2994
+ }>)[];
2995
+ }, {
2996
+ token: string;
2997
+ }>;
2998
+ verifyOneTimeToken: import('better-auth').StrictEndpoint<"/one-time-token/verify", {
2999
+ method: "POST";
3000
+ body: import('zod').ZodObject<{
3001
+ token: import('zod').ZodString;
3002
+ }, import('better-auth').$strip>;
3003
+ }, {
3004
+ session: {
3005
+ id: string;
3006
+ createdAt: Date;
3007
+ updatedAt: Date;
3008
+ userId: string;
3009
+ expiresAt: Date;
3010
+ token: string;
3011
+ ipAddress?: string | null | undefined;
3012
+ userAgent?: string | null | undefined;
3013
+ } & Record<string, any>;
3014
+ user: {
3015
+ id: string;
3016
+ createdAt: Date;
3017
+ updatedAt: Date;
3018
+ email: string;
3019
+ emailVerified: boolean;
3020
+ name: string;
3021
+ image?: string | null | undefined;
3022
+ } & Record<string, any>;
3023
+ }>;
3024
+ };
3025
+ hooks: {
3026
+ after: {
3027
+ matcher: () => true;
3028
+ handler: (inputContext: import('better-auth').MiddlewareInputContext<import('better-auth').MiddlewareOptions>) => Promise<void>;
3029
+ }[];
3030
+ };
3031
+ options: import('better-auth/plugins').OneTimeTokenOptions | undefined;
3032
+ }>;
3033
+ })[];
3034
+ }, FetchOptions>> | undefined, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
3035
+ status: boolean;
3036
+ }, {
3037
+ code?: string | undefined;
3038
+ message?: string | undefined;
3039
+ }, FetchOptions["throw"] extends true ? true : false>>;
3040
+ } & {
3041
+ deleteUser: <FetchOptions extends import('better-auth').ClientFetchOption<Partial<{
3042
+ callbackURL?: string | undefined;
3043
+ password?: string | undefined;
3044
+ token?: string | undefined;
3045
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0?: import('better-auth').Prettify<{
3046
+ callbackURL?: string | undefined;
3047
+ password?: string | undefined;
3048
+ token?: string | undefined;
3049
+ } & {
3050
+ fetchOptions?: FetchOptions | undefined;
3051
+ }> | undefined, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
3052
+ success: boolean;
3053
+ message: string;
3054
+ }, {
3055
+ code?: string | undefined;
3056
+ message?: string | undefined;
3057
+ }, FetchOptions["throw"] extends true ? true : false>>;
3058
+ } & {
3059
+ requestPasswordReset: <FetchOptions extends import('better-auth').ClientFetchOption<Partial<{
3060
+ email: string;
3061
+ redirectTo?: string | undefined;
3062
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0: import('better-auth').Prettify<{
3063
+ email: string;
3064
+ redirectTo?: string | undefined;
3065
+ } & {
3066
+ fetchOptions?: FetchOptions | undefined;
3067
+ }>, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
3068
+ status: boolean;
3069
+ message: string;
3070
+ }, {
3071
+ code?: string | undefined;
3072
+ message?: string | undefined;
3073
+ }, FetchOptions["throw"] extends true ? true : false>>;
3074
+ } & {
3075
+ resetPassword: {
3076
+ ":token": <FetchOptions extends import('better-auth').ClientFetchOption<never, Partial<{
3077
+ callbackURL: string;
3078
+ }> & Record<string, any>, {
3079
+ token: string;
3080
+ }>>(data_0: import('better-auth').Prettify<{
3081
+ query: {
3082
+ callbackURL: string;
3083
+ };
3084
+ fetchOptions?: FetchOptions | undefined;
3085
+ }>, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<never, {
3086
+ code?: string | undefined;
3087
+ message?: string | undefined;
3088
+ }, FetchOptions["throw"] extends true ? true : false>>;
3089
+ };
3090
+ } & {
3091
+ listSessions: <FetchOptions extends import('better-auth').ClientFetchOption<never, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0?: import('better-auth').Prettify<{
3092
+ query?: Record<string, any> | undefined;
3093
+ fetchOptions?: FetchOptions | undefined;
3094
+ }> | undefined, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<import('better-auth').Prettify<{
3095
+ id: string;
3096
+ createdAt: Date;
3097
+ updatedAt: Date;
3098
+ userId: string;
3099
+ expiresAt: Date;
3100
+ token: string;
3101
+ ipAddress?: string | null | undefined | undefined;
3102
+ userAgent?: string | null | undefined | undefined;
3103
+ }>[], {
3104
+ code?: string | undefined;
3105
+ message?: string | undefined;
3106
+ }, FetchOptions["throw"] extends true ? true : false>>;
3107
+ } & {
3108
+ revokeSession: <FetchOptions extends import('better-auth').ClientFetchOption<Partial<{
3109
+ token: string;
3110
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0: import('better-auth').Prettify<{
3111
+ token: string;
3112
+ } & {
3113
+ fetchOptions?: FetchOptions | undefined;
3114
+ }>, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
3115
+ status: boolean;
3116
+ }, {
3117
+ code?: string | undefined;
3118
+ message?: string | undefined;
3119
+ }, FetchOptions["throw"] extends true ? true : false>>;
3120
+ } & {
3121
+ revokeSessions: <FetchOptions extends import('better-auth').ClientFetchOption<never, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0?: import('better-auth').Prettify<{
3122
+ query?: Record<string, any> | undefined;
3123
+ fetchOptions?: FetchOptions | undefined;
3124
+ }> | undefined, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
3125
+ status: boolean;
3126
+ }, {
3127
+ code?: string | undefined;
3128
+ message?: string | undefined;
3129
+ }, FetchOptions["throw"] extends true ? true : false>>;
3130
+ } & {
3131
+ revokeOtherSessions: <FetchOptions extends import('better-auth').ClientFetchOption<never, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0?: import('better-auth').Prettify<{
3132
+ query?: Record<string, any> | undefined;
3133
+ fetchOptions?: FetchOptions | undefined;
3134
+ }> | undefined, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
3135
+ status: boolean;
3136
+ }, {
3137
+ code?: string | undefined;
3138
+ message?: string | undefined;
3139
+ }, FetchOptions["throw"] extends true ? true : false>>;
3140
+ } & {
3141
+ linkSocial: <FetchOptions extends import('better-auth').ClientFetchOption<Partial<{
3142
+ provider: unknown;
3143
+ callbackURL?: string | undefined;
3144
+ idToken?: {
3145
+ token: string;
3146
+ nonce?: string | undefined;
3147
+ accessToken?: string | undefined;
3148
+ refreshToken?: string | undefined;
3149
+ scopes?: string[] | undefined;
3150
+ } | undefined;
3151
+ requestSignUp?: boolean | undefined;
3152
+ scopes?: string[] | undefined;
3153
+ errorCallbackURL?: string | undefined;
3154
+ disableRedirect?: boolean | undefined;
3155
+ additionalData?: Record<string, any> | undefined;
3156
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0: import('better-auth').Prettify<{
3157
+ provider: unknown;
3158
+ callbackURL?: string | undefined;
3159
+ idToken?: {
3160
+ token: string;
3161
+ nonce?: string | undefined;
3162
+ accessToken?: string | undefined;
3163
+ refreshToken?: string | undefined;
3164
+ scopes?: string[] | undefined;
3165
+ } | undefined;
3166
+ requestSignUp?: boolean | undefined;
3167
+ scopes?: string[] | undefined;
3168
+ errorCallbackURL?: string | undefined;
3169
+ disableRedirect?: boolean | undefined;
3170
+ additionalData?: Record<string, any> | undefined;
3171
+ } & {
3172
+ fetchOptions?: FetchOptions | undefined;
3173
+ }>, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
3174
+ url: string;
3175
+ redirect: boolean;
3176
+ }, {
3177
+ code?: string | undefined;
3178
+ message?: string | undefined;
3179
+ }, FetchOptions["throw"] extends true ? true : false>>;
3180
+ } & {
3181
+ listAccounts: <FetchOptions extends import('better-auth').ClientFetchOption<never, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0?: import('better-auth').Prettify<{
3182
+ query?: Record<string, any> | undefined;
3183
+ fetchOptions?: FetchOptions | undefined;
3184
+ }> | undefined, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
3185
+ scopes: string[];
3186
+ id: string;
3187
+ createdAt: Date;
3188
+ updatedAt: Date;
3189
+ userId: string;
3190
+ providerId: string;
3191
+ accountId: string;
3192
+ }[], {
3193
+ code?: string | undefined;
3194
+ message?: string | undefined;
3195
+ }, FetchOptions["throw"] extends true ? true : false>>;
3196
+ } & {
3197
+ deleteUser: {
3198
+ callback: <FetchOptions extends import('better-auth').ClientFetchOption<never, Partial<{
3199
+ token: string;
3200
+ callbackURL?: string | undefined;
3201
+ }> & Record<string, any>, Record<string, any> | undefined>>(data_0: import('better-auth').Prettify<{
3202
+ query: {
3203
+ token: string;
3204
+ callbackURL?: string | undefined;
3205
+ };
3206
+ fetchOptions?: FetchOptions | undefined;
3207
+ }>, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
3208
+ success: boolean;
3209
+ message: string;
3210
+ }, {
3211
+ code?: string | undefined;
3212
+ message?: string | undefined;
3213
+ }, FetchOptions["throw"] extends true ? true : false>>;
3214
+ };
3215
+ } & {
3216
+ unlinkAccount: <FetchOptions extends import('better-auth').ClientFetchOption<Partial<{
3217
+ providerId: string;
3218
+ accountId?: string | undefined;
3219
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0: import('better-auth').Prettify<{
3220
+ providerId: string;
3221
+ accountId?: string | undefined;
3222
+ } & {
3223
+ fetchOptions?: FetchOptions | undefined;
3224
+ }>, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
3225
+ status: boolean;
3226
+ }, {
3227
+ code?: string | undefined;
3228
+ message?: string | undefined;
3229
+ }, FetchOptions["throw"] extends true ? true : false>>;
3230
+ } & {
3231
+ refreshToken: <FetchOptions extends import('better-auth').ClientFetchOption<Partial<{
3232
+ providerId: string;
3233
+ accountId?: string | undefined;
3234
+ userId?: string | undefined;
3235
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0: import('better-auth').Prettify<{
3236
+ providerId: string;
3237
+ accountId?: string | undefined;
3238
+ userId?: string | undefined;
3239
+ } & {
3240
+ fetchOptions?: FetchOptions | undefined;
3241
+ }>, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
3242
+ accessToken: string | undefined;
3243
+ refreshToken: string;
3244
+ accessTokenExpiresAt: Date | undefined;
3245
+ refreshTokenExpiresAt: Date | null | undefined;
3246
+ scope: string | null | undefined;
3247
+ idToken: string | null | undefined;
3248
+ providerId: string;
3249
+ accountId: string;
3250
+ }, {
3251
+ code?: string | undefined;
3252
+ message?: string | undefined;
3253
+ }, FetchOptions["throw"] extends true ? true : false>>;
3254
+ } & {
3255
+ getAccessToken: <FetchOptions extends import('better-auth').ClientFetchOption<Partial<{
3256
+ providerId: string;
3257
+ accountId?: string | undefined;
3258
+ userId?: string | undefined;
3259
+ }> & Record<string, any>, Partial<Record<string, any>> & Record<string, any>, Record<string, any> | undefined>>(data_0: import('better-auth').Prettify<{
3260
+ providerId: string;
3261
+ accountId?: string | undefined;
3262
+ userId?: string | undefined;
3263
+ } & {
3264
+ fetchOptions?: FetchOptions | undefined;
3265
+ }>, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
3266
+ accessToken: string;
3267
+ accessTokenExpiresAt: Date | undefined;
3268
+ scopes: string[];
3269
+ idToken: string | undefined;
3270
+ }, {
3271
+ code?: string | undefined;
3272
+ message?: string | undefined;
3273
+ }, FetchOptions["throw"] extends true ? true : false>>;
3274
+ } & {
3275
+ accountInfo: <FetchOptions extends import('better-auth').ClientFetchOption<never, Partial<{
3276
+ accountId?: string | undefined;
3277
+ }> & Record<string, any>, Record<string, any> | undefined>>(data_0?: import('better-auth').Prettify<{
3278
+ query?: {
3279
+ accountId?: string | undefined;
3280
+ } | undefined;
3281
+ fetchOptions?: FetchOptions | undefined;
3282
+ }> | undefined, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
3283
+ user: import('better-auth').OAuth2UserInfo;
3284
+ data: Record<string, any>;
3285
+ }, {
3286
+ code?: string | undefined;
3287
+ message?: string | undefined;
3288
+ }, FetchOptions["throw"] extends true ? true : false>>;
3289
+ } & {
3290
+ getSession: <FetchOptions extends import('better-auth').ClientFetchOption<never, Partial<{
3291
+ disableCookieCache?: unknown;
3292
+ disableRefresh?: unknown;
3293
+ }> & Record<string, any>, Record<string, any> | undefined>>(data_0?: import('better-auth').Prettify<{
3294
+ query?: {
3295
+ disableCookieCache?: unknown;
3296
+ disableRefresh?: unknown;
3297
+ } | undefined;
3298
+ fetchOptions?: FetchOptions | undefined;
3299
+ }> | undefined, data_1?: FetchOptions | undefined) => Promise<import('better-auth/client').BetterFetchResponse<{
3300
+ user: import('better-auth').StripEmptyObjects<{
3301
+ id: string;
3302
+ createdAt: Date;
3303
+ updatedAt: Date;
3304
+ email: string;
3305
+ emailVerified: boolean;
3306
+ name: string;
3307
+ image?: string | null | undefined;
3308
+ } & {} & {
3309
+ userId?: string | null | undefined;
3310
+ }>;
3311
+ session: import('better-auth').StripEmptyObjects<{
3312
+ id: string;
3313
+ createdAt: Date;
3314
+ updatedAt: Date;
3315
+ userId: string;
3316
+ expiresAt: Date;
3317
+ token: string;
3318
+ ipAddress?: string | null | undefined;
3319
+ userAgent?: string | null | undefined;
3320
+ } & {} & {
3321
+ activeOrganizationId?: string | null | undefined;
3322
+ }>;
3323
+ } | null, {
3324
+ code?: string | undefined;
3325
+ message?: string | undefined;
3326
+ }, FetchOptions["throw"] extends true ? true : false>>;
3327
+ } & {
3328
+ getCookie: () => string;
3329
+ updateSession: () => void;
3330
+ getSessionData: () => Record<string, unknown> | null;
3331
+ } & {
3332
+ $Infer: {
3333
+ ActiveOrganization: {
3334
+ members: {
3335
+ id: string;
3336
+ organizationId: string;
3337
+ role: "member" | "admin" | "owner";
3338
+ createdAt: Date;
3339
+ userId: string;
3340
+ user: {
3341
+ id: string;
3342
+ email: string;
3343
+ name: string;
3344
+ image?: string | undefined;
3345
+ };
3346
+ }[];
3347
+ invitations: {
3348
+ id: string;
3349
+ organizationId: string;
3350
+ email: string;
3351
+ role: "member" | "admin" | "owner";
3352
+ status: import('better-auth/plugins').InvitationStatus;
3353
+ inviterId: string;
3354
+ expiresAt: Date;
3355
+ createdAt: Date;
3356
+ }[];
3357
+ } & {
3358
+ id: string;
3359
+ name: string;
3360
+ slug: string;
3361
+ createdAt: Date;
3362
+ logo?: string | null | undefined | undefined;
3363
+ metadata?: any;
3364
+ };
3365
+ Organization: {
3366
+ id: string;
3367
+ name: string;
3368
+ slug: string;
3369
+ createdAt: Date;
3370
+ logo?: string | null | undefined;
3371
+ metadata?: any;
3372
+ };
3373
+ Invitation: {
3374
+ id: string;
3375
+ organizationId: string;
3376
+ email: string;
3377
+ role: "member" | "admin" | "owner";
3378
+ status: import('better-auth/plugins').InvitationStatus;
3379
+ inviterId: string;
3380
+ expiresAt: Date;
3381
+ createdAt: Date;
3382
+ };
3383
+ Member: {
3384
+ id: string;
3385
+ organizationId: string;
3386
+ role: "member" | "admin" | "owner";
3387
+ createdAt: Date;
3388
+ userId: string;
3389
+ user: {
3390
+ id: string;
3391
+ email: string;
3392
+ name: string;
3393
+ image?: string | undefined;
3394
+ };
3395
+ };
3396
+ Team: {
3397
+ id: string;
3398
+ name: string;
3399
+ organizationId: string;
3400
+ createdAt: Date;
3401
+ updatedAt?: Date | undefined;
3402
+ };
3403
+ };
3404
+ organization: {
3405
+ checkRolePermission: <R extends "member" | "admin" | "owner">(data: {
3406
+ permissions: {
3407
+ readonly organization?: ("delete" | "update")[] | undefined;
3408
+ readonly member?: ("delete" | "create" | "update")[] | undefined;
3409
+ readonly invitation?: ("cancel" | "create")[] | undefined;
3410
+ readonly team?: ("delete" | "create" | "update")[] | undefined;
3411
+ readonly ac?: ("delete" | "create" | "update" | "read")[] | undefined;
3412
+ };
3413
+ } & {
3414
+ role: R;
3415
+ }) => boolean;
3416
+ };
3417
+ } & {
3418
+ useSession: () => {
3419
+ data: {
3420
+ user: import('better-auth').StripEmptyObjects<{
3421
+ id: string;
3422
+ createdAt: Date;
3423
+ updatedAt: Date;
3424
+ email: string;
3425
+ emailVerified: boolean;
3426
+ name: string;
3427
+ image?: string | null | undefined;
3428
+ } & {} & {
3429
+ userId?: string | null | undefined;
3430
+ }>;
3431
+ session: import('better-auth').StripEmptyObjects<{
3432
+ id: string;
3433
+ createdAt: Date;
3434
+ updatedAt: Date;
3435
+ userId: string;
3436
+ expiresAt: Date;
3437
+ token: string;
3438
+ ipAddress?: string | null | undefined;
3439
+ userAgent?: string | null | undefined;
3440
+ } & {} & {
3441
+ activeOrganizationId?: string | null | undefined;
3442
+ }>;
3443
+ } | null;
3444
+ isPending: boolean;
3445
+ isRefetching: boolean;
3446
+ error: import('better-auth/client').BetterFetchError | null;
3447
+ refetch: (queryParams?: {
3448
+ query?: import('better-auth').SessionQueryParams;
3449
+ } | undefined) => Promise<void>;
3450
+ };
3451
+ $Infer: {
3452
+ Session: {
3453
+ user: import('better-auth').StripEmptyObjects<{
3454
+ id: string;
3455
+ createdAt: Date;
3456
+ updatedAt: Date;
3457
+ email: string;
3458
+ emailVerified: boolean;
3459
+ name: string;
3460
+ image?: string | null | undefined;
3461
+ } & {} & {
3462
+ userId?: string | null | undefined;
3463
+ }>;
3464
+ session: import('better-auth').StripEmptyObjects<{
3465
+ id: string;
3466
+ createdAt: Date;
3467
+ updatedAt: Date;
3468
+ userId: string;
3469
+ expiresAt: Date;
3470
+ token: string;
3471
+ ipAddress?: string | null | undefined;
3472
+ userAgent?: string | null | undefined;
3473
+ } & {} & {
3474
+ activeOrganizationId?: string | null | undefined;
3475
+ }>;
3476
+ };
3477
+ };
3478
+ $fetch: import('better-auth/client').BetterFetch<{
3479
+ plugins: (import('better-auth/client').BetterFetchPlugin<Record<string, any>> | {
3480
+ id: string;
3481
+ name: string;
3482
+ hooks: {
3483
+ onSuccess(context: import('better-auth/client').SuccessContext<any>): void;
3484
+ };
3485
+ } | {
3486
+ id: string;
3487
+ name: string;
3488
+ hooks: {
3489
+ onSuccess: ((context: import('better-auth/client').SuccessContext<any>) => Promise<void> | void) | undefined;
3490
+ onError: ((context: import('better-auth/client').ErrorContext) => Promise<void> | void) | undefined;
3491
+ onRequest: (<T extends Record<string, any>>(context: import('better-auth/client').RequestContext<T>) => Promise<import('better-auth/client').RequestContext | void> | import('better-auth/client').RequestContext | void) | undefined;
3492
+ onResponse: ((context: import('better-auth/client').ResponseContext) => Promise<Response | void | import('better-auth/client').ResponseContext> | Response | import('better-auth/client').ResponseContext | void) | undefined;
3493
+ };
3494
+ })[];
3495
+ cache?: RequestCache | undefined;
3496
+ priority?: RequestPriority | undefined;
3497
+ credentials?: RequestCredentials;
3498
+ headers?: (HeadersInit & (HeadersInit | {
3499
+ accept: "application/json" | "text/plain" | "application/octet-stream";
3500
+ "content-type": "application/json" | "text/plain" | "application/x-www-form-urlencoded" | "multipart/form-data" | "application/octet-stream";
3501
+ authorization: "Bearer" | "Basic";
3502
+ })) | undefined;
3503
+ integrity?: string | undefined;
3504
+ keepalive?: boolean | undefined;
3505
+ method: string;
3506
+ mode?: RequestMode | undefined;
3507
+ redirect?: RequestRedirect | undefined;
3508
+ referrer?: string | undefined;
3509
+ referrerPolicy?: ReferrerPolicy | undefined;
3510
+ signal?: (AbortSignal | null) | undefined;
3511
+ window?: null | undefined;
3512
+ onRetry?: ((response: import('better-auth/client').ResponseContext) => Promise<void> | void) | undefined;
3513
+ hookOptions?: {
3514
+ cloneResponse?: boolean;
3515
+ } | undefined;
3516
+ timeout?: number | undefined;
3517
+ customFetchImpl: import('better-auth/client').FetchEsque;
3518
+ baseURL: string;
3519
+ throw?: boolean | undefined;
3520
+ auth?: ({
3521
+ type: "Bearer";
3522
+ token: string | Promise<string | undefined> | (() => string | Promise<string | undefined> | undefined) | undefined;
3523
+ } | {
3524
+ type: "Basic";
3525
+ username: string | (() => string | undefined) | undefined;
3526
+ password: string | (() => string | undefined) | undefined;
3527
+ } | {
3528
+ type: "Custom";
3529
+ prefix: string | (() => string | undefined) | undefined;
3530
+ value: string | (() => string | undefined) | undefined;
3531
+ }) | undefined;
3532
+ body?: any;
3533
+ query?: any;
3534
+ params?: any;
3535
+ duplex?: "full" | "half" | undefined;
3536
+ jsonParser: (text: string) => Promise<any> | any;
3537
+ retry?: import('better-auth/client').RetryOptions | undefined;
3538
+ retryAttempt?: number | undefined;
3539
+ output?: (import('better-auth/client').StandardSchemaV1 | typeof Blob | typeof File) | undefined;
3540
+ errorSchema?: import('better-auth/client').StandardSchemaV1 | undefined;
3541
+ disableValidation?: boolean | undefined;
3542
+ disableSignal?: boolean | undefined;
3543
+ }, unknown, unknown, {}>;
3544
+ $store: {
3545
+ notify: (signal?: (Omit<string, "$sessionSignal"> | "$sessionSignal") | undefined) => void;
3546
+ listen: (signal: Omit<string, "$sessionSignal"> | "$sessionSignal", listener: (value: boolean, oldValue?: boolean | undefined) => void) => void;
3547
+ atoms: Record<string, import('better-auth/client').WritableAtom<any>>;
3548
+ };
3549
+ $ERROR_CODES: {
3550
+ YOU_ARE_NOT_ALLOWED_TO_CREATE_A_NEW_ORGANIZATION: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_CREATE_A_NEW_ORGANIZATION">;
3551
+ YOU_HAVE_REACHED_THE_MAXIMUM_NUMBER_OF_ORGANIZATIONS: import('better-auth').RawError<"YOU_HAVE_REACHED_THE_MAXIMUM_NUMBER_OF_ORGANIZATIONS">;
3552
+ ORGANIZATION_ALREADY_EXISTS: import('better-auth').RawError<"ORGANIZATION_ALREADY_EXISTS">;
3553
+ ORGANIZATION_SLUG_ALREADY_TAKEN: import('better-auth').RawError<"ORGANIZATION_SLUG_ALREADY_TAKEN">;
3554
+ ORGANIZATION_NOT_FOUND: import('better-auth').RawError<"ORGANIZATION_NOT_FOUND">;
3555
+ USER_IS_NOT_A_MEMBER_OF_THE_ORGANIZATION: import('better-auth').RawError<"USER_IS_NOT_A_MEMBER_OF_THE_ORGANIZATION">;
3556
+ YOU_ARE_NOT_ALLOWED_TO_UPDATE_THIS_ORGANIZATION: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_UPDATE_THIS_ORGANIZATION">;
3557
+ YOU_ARE_NOT_ALLOWED_TO_DELETE_THIS_ORGANIZATION: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_DELETE_THIS_ORGANIZATION">;
3558
+ NO_ACTIVE_ORGANIZATION: import('better-auth').RawError<"NO_ACTIVE_ORGANIZATION">;
3559
+ USER_IS_ALREADY_A_MEMBER_OF_THIS_ORGANIZATION: import('better-auth').RawError<"USER_IS_ALREADY_A_MEMBER_OF_THIS_ORGANIZATION">;
3560
+ MEMBER_NOT_FOUND: import('better-auth').RawError<"MEMBER_NOT_FOUND">;
3561
+ ROLE_NOT_FOUND: import('better-auth').RawError<"ROLE_NOT_FOUND">;
3562
+ YOU_ARE_NOT_ALLOWED_TO_CREATE_A_NEW_TEAM: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_CREATE_A_NEW_TEAM">;
3563
+ TEAM_ALREADY_EXISTS: import('better-auth').RawError<"TEAM_ALREADY_EXISTS">;
3564
+ TEAM_NOT_FOUND: import('better-auth').RawError<"TEAM_NOT_FOUND">;
3565
+ YOU_CANNOT_LEAVE_THE_ORGANIZATION_AS_THE_ONLY_OWNER: import('better-auth').RawError<"YOU_CANNOT_LEAVE_THE_ORGANIZATION_AS_THE_ONLY_OWNER">;
3566
+ YOU_CANNOT_LEAVE_THE_ORGANIZATION_WITHOUT_AN_OWNER: import('better-auth').RawError<"YOU_CANNOT_LEAVE_THE_ORGANIZATION_WITHOUT_AN_OWNER">;
3567
+ YOU_ARE_NOT_ALLOWED_TO_DELETE_THIS_MEMBER: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_DELETE_THIS_MEMBER">;
3568
+ YOU_ARE_NOT_ALLOWED_TO_INVITE_USERS_TO_THIS_ORGANIZATION: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_INVITE_USERS_TO_THIS_ORGANIZATION">;
3569
+ USER_IS_ALREADY_INVITED_TO_THIS_ORGANIZATION: import('better-auth').RawError<"USER_IS_ALREADY_INVITED_TO_THIS_ORGANIZATION">;
3570
+ INVITATION_NOT_FOUND: import('better-auth').RawError<"INVITATION_NOT_FOUND">;
3571
+ YOU_ARE_NOT_THE_RECIPIENT_OF_THE_INVITATION: import('better-auth').RawError<"YOU_ARE_NOT_THE_RECIPIENT_OF_THE_INVITATION">;
3572
+ EMAIL_VERIFICATION_REQUIRED_BEFORE_ACCEPTING_OR_REJECTING_INVITATION: import('better-auth').RawError<"EMAIL_VERIFICATION_REQUIRED_BEFORE_ACCEPTING_OR_REJECTING_INVITATION">;
3573
+ YOU_ARE_NOT_ALLOWED_TO_CANCEL_THIS_INVITATION: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_CANCEL_THIS_INVITATION">;
3574
+ INVITER_IS_NO_LONGER_A_MEMBER_OF_THE_ORGANIZATION: import('better-auth').RawError<"INVITER_IS_NO_LONGER_A_MEMBER_OF_THE_ORGANIZATION">;
3575
+ YOU_ARE_NOT_ALLOWED_TO_INVITE_USER_WITH_THIS_ROLE: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_INVITE_USER_WITH_THIS_ROLE">;
3576
+ FAILED_TO_RETRIEVE_INVITATION: import('better-auth').RawError<"FAILED_TO_RETRIEVE_INVITATION">;
3577
+ YOU_HAVE_REACHED_THE_MAXIMUM_NUMBER_OF_TEAMS: import('better-auth').RawError<"YOU_HAVE_REACHED_THE_MAXIMUM_NUMBER_OF_TEAMS">;
3578
+ UNABLE_TO_REMOVE_LAST_TEAM: import('better-auth').RawError<"UNABLE_TO_REMOVE_LAST_TEAM">;
3579
+ YOU_ARE_NOT_ALLOWED_TO_UPDATE_THIS_MEMBER: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_UPDATE_THIS_MEMBER">;
3580
+ ORGANIZATION_MEMBERSHIP_LIMIT_REACHED: import('better-auth').RawError<"ORGANIZATION_MEMBERSHIP_LIMIT_REACHED">;
3581
+ YOU_ARE_NOT_ALLOWED_TO_CREATE_TEAMS_IN_THIS_ORGANIZATION: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_CREATE_TEAMS_IN_THIS_ORGANIZATION">;
3582
+ YOU_ARE_NOT_ALLOWED_TO_DELETE_TEAMS_IN_THIS_ORGANIZATION: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_DELETE_TEAMS_IN_THIS_ORGANIZATION">;
3583
+ YOU_ARE_NOT_ALLOWED_TO_UPDATE_THIS_TEAM: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_UPDATE_THIS_TEAM">;
3584
+ YOU_ARE_NOT_ALLOWED_TO_DELETE_THIS_TEAM: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_DELETE_THIS_TEAM">;
3585
+ INVITATION_LIMIT_REACHED: import('better-auth').RawError<"INVITATION_LIMIT_REACHED">;
3586
+ TEAM_MEMBER_LIMIT_REACHED: import('better-auth').RawError<"TEAM_MEMBER_LIMIT_REACHED">;
3587
+ USER_IS_NOT_A_MEMBER_OF_THE_TEAM: import('better-auth').RawError<"USER_IS_NOT_A_MEMBER_OF_THE_TEAM">;
3588
+ YOU_CAN_NOT_ACCESS_THE_MEMBERS_OF_THIS_TEAM: import('better-auth').RawError<"YOU_CAN_NOT_ACCESS_THE_MEMBERS_OF_THIS_TEAM">;
3589
+ YOU_DO_NOT_HAVE_AN_ACTIVE_TEAM: import('better-auth').RawError<"YOU_DO_NOT_HAVE_AN_ACTIVE_TEAM">;
3590
+ YOU_ARE_NOT_ALLOWED_TO_CREATE_A_NEW_TEAM_MEMBER: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_CREATE_A_NEW_TEAM_MEMBER">;
3591
+ YOU_ARE_NOT_ALLOWED_TO_REMOVE_A_TEAM_MEMBER: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_REMOVE_A_TEAM_MEMBER">;
3592
+ YOU_ARE_NOT_ALLOWED_TO_ACCESS_THIS_ORGANIZATION: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_ACCESS_THIS_ORGANIZATION">;
3593
+ YOU_ARE_NOT_A_MEMBER_OF_THIS_ORGANIZATION: import('better-auth').RawError<"YOU_ARE_NOT_A_MEMBER_OF_THIS_ORGANIZATION">;
3594
+ MISSING_AC_INSTANCE: import('better-auth').RawError<"MISSING_AC_INSTANCE">;
3595
+ YOU_MUST_BE_IN_AN_ORGANIZATION_TO_CREATE_A_ROLE: import('better-auth').RawError<"YOU_MUST_BE_IN_AN_ORGANIZATION_TO_CREATE_A_ROLE">;
3596
+ YOU_ARE_NOT_ALLOWED_TO_CREATE_A_ROLE: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_CREATE_A_ROLE">;
3597
+ YOU_ARE_NOT_ALLOWED_TO_UPDATE_A_ROLE: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_UPDATE_A_ROLE">;
3598
+ YOU_ARE_NOT_ALLOWED_TO_DELETE_A_ROLE: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_DELETE_A_ROLE">;
3599
+ YOU_ARE_NOT_ALLOWED_TO_READ_A_ROLE: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_READ_A_ROLE">;
3600
+ YOU_ARE_NOT_ALLOWED_TO_LIST_A_ROLE: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_LIST_A_ROLE">;
3601
+ YOU_ARE_NOT_ALLOWED_TO_GET_A_ROLE: import('better-auth').RawError<"YOU_ARE_NOT_ALLOWED_TO_GET_A_ROLE">;
3602
+ TOO_MANY_ROLES: import('better-auth').RawError<"TOO_MANY_ROLES">;
3603
+ INVALID_RESOURCE: import('better-auth').RawError<"INVALID_RESOURCE">;
3604
+ ROLE_NAME_IS_ALREADY_TAKEN: import('better-auth').RawError<"ROLE_NAME_IS_ALREADY_TAKEN">;
3605
+ CANNOT_DELETE_A_PRE_DEFINED_ROLE: import('better-auth').RawError<"CANNOT_DELETE_A_PRE_DEFINED_ROLE">;
3606
+ ROLE_IS_ASSIGNED_TO_MEMBERS: import('better-auth').RawError<"ROLE_IS_ASSIGNED_TO_MEMBERS">;
3607
+ } & {
3608
+ USER_NOT_FOUND: import('better-auth').RawError<"USER_NOT_FOUND">;
3609
+ FAILED_TO_CREATE_USER: import('better-auth').RawError<"FAILED_TO_CREATE_USER">;
3610
+ FAILED_TO_CREATE_SESSION: import('better-auth').RawError<"FAILED_TO_CREATE_SESSION">;
3611
+ FAILED_TO_UPDATE_USER: import('better-auth').RawError<"FAILED_TO_UPDATE_USER">;
3612
+ FAILED_TO_GET_SESSION: import('better-auth').RawError<"FAILED_TO_GET_SESSION">;
3613
+ INVALID_PASSWORD: import('better-auth').RawError<"INVALID_PASSWORD">;
3614
+ INVALID_EMAIL: import('better-auth').RawError<"INVALID_EMAIL">;
3615
+ INVALID_EMAIL_OR_PASSWORD: import('better-auth').RawError<"INVALID_EMAIL_OR_PASSWORD">;
3616
+ INVALID_USER: import('better-auth').RawError<"INVALID_USER">;
3617
+ SOCIAL_ACCOUNT_ALREADY_LINKED: import('better-auth').RawError<"SOCIAL_ACCOUNT_ALREADY_LINKED">;
3618
+ PROVIDER_NOT_FOUND: import('better-auth').RawError<"PROVIDER_NOT_FOUND">;
3619
+ INVALID_TOKEN: import('better-auth').RawError<"INVALID_TOKEN">;
3620
+ TOKEN_EXPIRED: import('better-auth').RawError<"TOKEN_EXPIRED">;
3621
+ ID_TOKEN_NOT_SUPPORTED: import('better-auth').RawError<"ID_TOKEN_NOT_SUPPORTED">;
3622
+ FAILED_TO_GET_USER_INFO: import('better-auth').RawError<"FAILED_TO_GET_USER_INFO">;
3623
+ USER_EMAIL_NOT_FOUND: import('better-auth').RawError<"USER_EMAIL_NOT_FOUND">;
3624
+ EMAIL_NOT_VERIFIED: import('better-auth').RawError<"EMAIL_NOT_VERIFIED">;
3625
+ PASSWORD_TOO_SHORT: import('better-auth').RawError<"PASSWORD_TOO_SHORT">;
3626
+ PASSWORD_TOO_LONG: import('better-auth').RawError<"PASSWORD_TOO_LONG">;
3627
+ USER_ALREADY_EXISTS: import('better-auth').RawError<"USER_ALREADY_EXISTS">;
3628
+ USER_ALREADY_EXISTS_USE_ANOTHER_EMAIL: import('better-auth').RawError<"USER_ALREADY_EXISTS_USE_ANOTHER_EMAIL">;
3629
+ EMAIL_CAN_NOT_BE_UPDATED: import('better-auth').RawError<"EMAIL_CAN_NOT_BE_UPDATED">;
3630
+ CREDENTIAL_ACCOUNT_NOT_FOUND: import('better-auth').RawError<"CREDENTIAL_ACCOUNT_NOT_FOUND">;
3631
+ ACCOUNT_NOT_FOUND: import('better-auth').RawError<"ACCOUNT_NOT_FOUND">;
3632
+ SESSION_EXPIRED: import('better-auth').RawError<"SESSION_EXPIRED">;
3633
+ FAILED_TO_UNLINK_LAST_ACCOUNT: import('better-auth').RawError<"FAILED_TO_UNLINK_LAST_ACCOUNT">;
3634
+ USER_ALREADY_HAS_PASSWORD: import('better-auth').RawError<"USER_ALREADY_HAS_PASSWORD">;
3635
+ CROSS_SITE_NAVIGATION_LOGIN_BLOCKED: import('better-auth').RawError<"CROSS_SITE_NAVIGATION_LOGIN_BLOCKED">;
3636
+ VERIFICATION_EMAIL_NOT_ENABLED: import('better-auth').RawError<"VERIFICATION_EMAIL_NOT_ENABLED">;
3637
+ EMAIL_ALREADY_VERIFIED: import('better-auth').RawError<"EMAIL_ALREADY_VERIFIED">;
3638
+ EMAIL_MISMATCH: import('better-auth').RawError<"EMAIL_MISMATCH">;
3639
+ SESSION_NOT_FRESH: import('better-auth').RawError<"SESSION_NOT_FRESH">;
3640
+ LINKED_ACCOUNT_ALREADY_EXISTS: import('better-auth').RawError<"LINKED_ACCOUNT_ALREADY_EXISTS">;
3641
+ INVALID_ORIGIN: import('better-auth').RawError<"INVALID_ORIGIN">;
3642
+ INVALID_CALLBACK_URL: import('better-auth').RawError<"INVALID_CALLBACK_URL">;
3643
+ INVALID_REDIRECT_URL: import('better-auth').RawError<"INVALID_REDIRECT_URL">;
3644
+ INVALID_ERROR_CALLBACK_URL: import('better-auth').RawError<"INVALID_ERROR_CALLBACK_URL">;
3645
+ INVALID_NEW_USER_CALLBACK_URL: import('better-auth').RawError<"INVALID_NEW_USER_CALLBACK_URL">;
3646
+ MISSING_OR_NULL_ORIGIN: import('better-auth').RawError<"MISSING_OR_NULL_ORIGIN">;
3647
+ CALLBACK_URL_REQUIRED: import('better-auth').RawError<"CALLBACK_URL_REQUIRED">;
3648
+ FAILED_TO_CREATE_VERIFICATION: import('better-auth').RawError<"FAILED_TO_CREATE_VERIFICATION">;
3649
+ FIELD_NOT_ALLOWED: import('better-auth').RawError<"FIELD_NOT_ALLOWED">;
3650
+ ASYNC_VALIDATION_NOT_SUPPORTED: import('better-auth').RawError<"ASYNC_VALIDATION_NOT_SUPPORTED">;
3651
+ VALIDATION_ERROR: import('better-auth').RawError<"VALIDATION_ERROR">;
3652
+ MISSING_FIELD: import('better-auth').RawError<"MISSING_FIELD">;
3653
+ METHOD_NOT_ALLOWED_DEFER_SESSION_REQUIRED: import('better-auth').RawError<"METHOD_NOT_ALLOWED_DEFER_SESSION_REQUIRED">;
3654
+ BODY_MUST_BE_AN_OBJECT: import('better-auth').RawError<"BODY_MUST_BE_AN_OBJECT">;
3655
+ PASSWORD_ALREADY_SET: import('better-auth').RawError<"PASSWORD_ALREADY_SET">;
3656
+ };
3657
+ };
3658
+ /**
3659
+ * Process a `?ott=` one-time token from the URL before the ConvexBetterAuthProvider
3660
+ * mounts. Uses the standard `/one-time-token/verify` endpoint, then strips the
3661
+ * param so the provider doesn't attempt its own (cross-domain) verify.
3662
+ *
3663
+ * Returns `true` once processing is complete (or if there was no OTT).
3664
+ */
3665
+ export declare function useProcessOtt(authClient: CamoxAuthClient): boolean;
3666
+ interface AuthContextValue {
3667
+ authClient: CamoxAuthClient;
3668
+ managementUrl: string;
3669
+ }
3670
+ export declare const AuthContext: React.Context<AuthContextValue | null>;
3671
+ export declare function useIsAuthenticated(): boolean;
3672
+ /**
3673
+ * Returns a function that fetches a fresh Convex JWT from the management backend.
3674
+ * Use this for Authorization headers on file upload requests.
3675
+ */
3676
+ export declare function useConvexToken(): () => Promise<string | null>;
3677
+ export declare function useSignInRedirect(): () => void;
3678
+ /**
3679
+ * Registers sign-out and manage-account actions in the command palette.
3680
+ */
3681
+ export declare function useAuthActions(): void;
3682
+ export {};
3683
+ //# sourceMappingURL=auth.d.ts.map