allem-sdk 0.1.3 → 0.1.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +18 -12
- package/dist/agents.d.mts +3 -0
- package/dist/agents.d.ts +3 -0
- package/dist/index.d.mts +7 -4
- package/dist/index.d.ts +7 -4
- package/dist/index.js +73 -0
- package/dist/index.mjs +80 -4
- package/dist/notifications.d.mts +1 -0
- package/dist/notifications.d.ts +1 -0
- package/dist/notifications.js +25 -0
- package/dist/notifications.mjs +4 -0
- package/dist/realtime.d.mts +1 -0
- package/dist/realtime.d.ts +1 -0
- package/dist/realtime.js +25 -0
- package/dist/realtime.mjs +4 -0
- package/dist/storage.d.mts +1 -0
- package/dist/storage.d.ts +1 -0
- package/dist/storage.js +25 -0
- package/dist/storage.mjs +4 -0
- package/package.json +39 -11
package/README.md
CHANGED
|
@@ -8,12 +8,12 @@
|
|
|
8
8
|
<img src="https://img.shields.io/badge/react-19-61dafb" alt="React 19" />
|
|
9
9
|
<img src="https://img.shields.io/badge/typescript-strict-blue" alt="TypeScript" />
|
|
10
10
|
<img src="https://img.shields.io/badge/AI_SDK-v6-black" alt="AI SDK v6" />
|
|
11
|
-
<img src="https://img.shields.io/badge/tests-
|
|
11
|
+
<img src="https://img.shields.io/badge/tests-96_passing-brightgreen" alt="Tests" />
|
|
12
12
|
</p>
|
|
13
13
|
|
|
14
14
|
# allem-sdk
|
|
15
15
|
|
|
16
|
-
The complete Allem SDK for React.
|
|
16
|
+
The complete Allem SDK for React. AI agents, chat, hooks, forms, auth, analytics, storage, notifications, and realtime in a single install.
|
|
17
17
|
|
|
18
18
|
## Installation
|
|
19
19
|
|
|
@@ -24,12 +24,15 @@ npm install allem-sdk
|
|
|
24
24
|
Or install individual packages:
|
|
25
25
|
|
|
26
26
|
```bash
|
|
27
|
-
npm install @allem-sdk/hooks
|
|
28
|
-
npm install @allem-sdk/ai
|
|
29
|
-
npm install @allem-sdk/agents
|
|
30
|
-
npm install @allem-sdk/forms
|
|
31
|
-
npm install @allem-sdk/analytics
|
|
32
|
-
npm install @allem-sdk/auth
|
|
27
|
+
npm install @allem-sdk/hooks # 13 React hooks
|
|
28
|
+
npm install @allem-sdk/ai # AI chat & completions
|
|
29
|
+
npm install @allem-sdk/agents # Agentic AI with tool calling
|
|
30
|
+
npm install @allem-sdk/forms # Form management
|
|
31
|
+
npm install @allem-sdk/analytics # Analytics tracking
|
|
32
|
+
npm install @allem-sdk/auth # Authentication
|
|
33
|
+
npm install @allem-sdk/storage # Key-value storage
|
|
34
|
+
npm install @allem-sdk/notifications # Toast notifications
|
|
35
|
+
npm install @allem-sdk/realtime # WebSocket/SSE
|
|
33
36
|
```
|
|
34
37
|
|
|
35
38
|
## Quick Start
|
|
@@ -49,12 +52,15 @@ import { useDebounce, useAllemChat, useForm, useAuth } from "allem-sdk";
|
|
|
49
52
|
|
|
50
53
|
| Package | Description |
|
|
51
54
|
|---------|-------------|
|
|
52
|
-
| [`@allem-sdk/hooks`](https://www.npmjs.com/package/@allem-sdk/hooks) |
|
|
55
|
+
| [`@allem-sdk/hooks`](https://www.npmjs.com/package/@allem-sdk/hooks) | 13 React hooks: useDebounce, useFetch, useThrottle, useLocalStorage, and more |
|
|
53
56
|
| [`@allem-sdk/ai`](https://www.npmjs.com/package/@allem-sdk/ai) | AI hooks built on Vercel AI SDK v6 with multi-provider chat & completions |
|
|
54
|
-
| [`@allem-sdk/agents`](https://www.npmjs.com/package/@allem-sdk/agents) | Agentic AI with tool
|
|
57
|
+
| [`@allem-sdk/agents`](https://www.npmjs.com/package/@allem-sdk/agents) | Agentic AI with tool loops, guardrails, memory, and planning |
|
|
55
58
|
| [`@allem-sdk/forms`](https://www.npmjs.com/package/@allem-sdk/forms) | Lightweight form management with 9 built-in validators |
|
|
56
|
-
| [`@allem-sdk/analytics`](https://www.npmjs.com/package/@allem-sdk/analytics) | Provider-agnostic analytics
|
|
57
|
-
| [`@allem-sdk/auth`](https://www.npmjs.com/package/@allem-sdk/auth) | Authentication
|
|
59
|
+
| [`@allem-sdk/analytics`](https://www.npmjs.com/package/@allem-sdk/analytics) | Provider-agnostic analytics with Mixpanel, PostHog, Segment adapters |
|
|
60
|
+
| [`@allem-sdk/auth`](https://www.npmjs.com/package/@allem-sdk/auth) | Authentication with Supabase, NextAuth, Clerk adapters |
|
|
61
|
+
| [`@allem-sdk/storage`](https://www.npmjs.com/package/@allem-sdk/storage) | Key-value storage with localStorage, cookie, memory adapters |
|
|
62
|
+
| [`@allem-sdk/notifications`](https://www.npmjs.com/package/@allem-sdk/notifications) | Headless toast/notification system |
|
|
63
|
+
| [`@allem-sdk/realtime`](https://www.npmjs.com/package/@allem-sdk/realtime) | WebSocket/SSE abstraction with channels and presence |
|
|
58
64
|
|
|
59
65
|
## Features
|
|
60
66
|
|
package/dist/agents.d.mts
CHANGED
package/dist/agents.d.ts
CHANGED
package/dist/index.d.mts
CHANGED
|
@@ -1,6 +1,9 @@
|
|
|
1
|
-
export { useClickOutside, useCopyToClipboard, useDebounce, useIntersectionObserver, useLocalStorage, useMediaQuery, useToggle, useWindowSize } from '@allem-sdk/hooks';
|
|
1
|
+
export { useClickOutside, useCopyToClipboard, useDebounce, useFetch, useIntersectionObserver, useKeyPress, useLocalStorage, useMediaQuery, useOnlineStatus, usePrevious, useThrottle, useToggle, useWindowSize } from '@allem-sdk/hooks';
|
|
2
2
|
export * from '@allem-sdk/ai';
|
|
3
|
-
export { AgentProvider, AgentProviderProps, AgentStatus, AgentStep, AgentToolCall, AgentToolRegistration, AllemAgentHandlerConfig, AllemToolConfig, UseAllemAgentOptions, UseAllemAgentReturn, createAllemAgentHandler, createAllemTool, useAgentTools, useAllemAgent } from '@allem-sdk/agents';
|
|
3
|
+
export { AgentMemoryAdapter, AgentProvider, AgentProviderProps, AgentStatus, AgentStep, AgentToolCall, AgentToolRegistration, AllemAgentHandlerConfig, AllemGuardrailConfig, AllemToolConfig, UseAllemAgentOptions, UseAllemAgentReturn, createAllemAgentHandler, createAllemGuardrail, createAllemTool, createMemoryAdapter, hasToolCall, isLoopFinished, planExecuteVerify, restrictAfter, stepCountIs, thinkThenAct, useAgentTools, useAllemAgent } from '@allem-sdk/agents';
|
|
4
4
|
export { FieldConfig, FormConfig, FormErrors, FormTouched, UseFieldOptions, UseFieldReturn, UseFormReturn, ValidationRule, custom, email, max, maxLength, min, minLength, pattern, required, url, useField, useForm } from '@allem-sdk/forms';
|
|
5
|
-
export { AnalyticsAdapter, AnalyticsProvider, AnalyticsProviderProps, useIdentify, usePageView, useTrack } from '@allem-sdk/analytics';
|
|
6
|
-
export { AuthAdapter, AuthProvider, AuthProviderProps, AuthSession, AuthStatus, AuthUser, ProtectedRoute, ProtectedRouteProps, UseAuthReturn, UseSessionReturn, useAuth, useSession } from '@allem-sdk/auth';
|
|
5
|
+
export { AnalyticsAdapter, AnalyticsProvider, AnalyticsProviderProps, consoleAdapter, mixpanelAdapter, posthogAdapter, segmentAdapter, useIdentify, usePageView, useTrack } from '@allem-sdk/analytics';
|
|
6
|
+
export { AuthAdapter, AuthProvider, AuthProviderProps, AuthSession, AuthStatus, AuthUser, ProtectedRoute, ProtectedRouteProps, UseAuthReturn, UseSessionReturn, clerkAdapter, nextAuthAdapter, supabaseAdapter, useAuth, useSession } from '@allem-sdk/auth';
|
|
7
|
+
export { StorageAdapter, StorageProvider, StorageProviderProps, cookieAdapter, localStorageAdapter, memoryAdapter, sessionStorageAdapter, useStorageAdapter, useStorageItem } from '@allem-sdk/storage';
|
|
8
|
+
export { Notification, NotificationProvider, NotificationProviderProps, NotificationType, NotifyOptions, useNotifications, useNotify } from '@allem-sdk/notifications';
|
|
9
|
+
export { ConnectionStatus, PresenceMember, RealtimeAdapter, RealtimeProvider, RealtimeProviderProps, useChannel, useConnectionStatus, usePresence, useRealtimeAdapter } from '@allem-sdk/realtime';
|
package/dist/index.d.ts
CHANGED
|
@@ -1,6 +1,9 @@
|
|
|
1
|
-
export { useClickOutside, useCopyToClipboard, useDebounce, useIntersectionObserver, useLocalStorage, useMediaQuery, useToggle, useWindowSize } from '@allem-sdk/hooks';
|
|
1
|
+
export { useClickOutside, useCopyToClipboard, useDebounce, useFetch, useIntersectionObserver, useKeyPress, useLocalStorage, useMediaQuery, useOnlineStatus, usePrevious, useThrottle, useToggle, useWindowSize } from '@allem-sdk/hooks';
|
|
2
2
|
export * from '@allem-sdk/ai';
|
|
3
|
-
export { AgentProvider, AgentProviderProps, AgentStatus, AgentStep, AgentToolCall, AgentToolRegistration, AllemAgentHandlerConfig, AllemToolConfig, UseAllemAgentOptions, UseAllemAgentReturn, createAllemAgentHandler, createAllemTool, useAgentTools, useAllemAgent } from '@allem-sdk/agents';
|
|
3
|
+
export { AgentMemoryAdapter, AgentProvider, AgentProviderProps, AgentStatus, AgentStep, AgentToolCall, AgentToolRegistration, AllemAgentHandlerConfig, AllemGuardrailConfig, AllemToolConfig, UseAllemAgentOptions, UseAllemAgentReturn, createAllemAgentHandler, createAllemGuardrail, createAllemTool, createMemoryAdapter, hasToolCall, isLoopFinished, planExecuteVerify, restrictAfter, stepCountIs, thinkThenAct, useAgentTools, useAllemAgent } from '@allem-sdk/agents';
|
|
4
4
|
export { FieldConfig, FormConfig, FormErrors, FormTouched, UseFieldOptions, UseFieldReturn, UseFormReturn, ValidationRule, custom, email, max, maxLength, min, minLength, pattern, required, url, useField, useForm } from '@allem-sdk/forms';
|
|
5
|
-
export { AnalyticsAdapter, AnalyticsProvider, AnalyticsProviderProps, useIdentify, usePageView, useTrack } from '@allem-sdk/analytics';
|
|
6
|
-
export { AuthAdapter, AuthProvider, AuthProviderProps, AuthSession, AuthStatus, AuthUser, ProtectedRoute, ProtectedRouteProps, UseAuthReturn, UseSessionReturn, useAuth, useSession } from '@allem-sdk/auth';
|
|
5
|
+
export { AnalyticsAdapter, AnalyticsProvider, AnalyticsProviderProps, consoleAdapter, mixpanelAdapter, posthogAdapter, segmentAdapter, useIdentify, usePageView, useTrack } from '@allem-sdk/analytics';
|
|
6
|
+
export { AuthAdapter, AuthProvider, AuthProviderProps, AuthSession, AuthStatus, AuthUser, ProtectedRoute, ProtectedRouteProps, UseAuthReturn, UseSessionReturn, clerkAdapter, nextAuthAdapter, supabaseAdapter, useAuth, useSession } from '@allem-sdk/auth';
|
|
7
|
+
export { StorageAdapter, StorageProvider, StorageProviderProps, cookieAdapter, localStorageAdapter, memoryAdapter, sessionStorageAdapter, useStorageAdapter, useStorageItem } from '@allem-sdk/storage';
|
|
8
|
+
export { Notification, NotificationProvider, NotificationProviderProps, NotificationType, NotifyOptions, useNotifications, useNotify } from '@allem-sdk/notifications';
|
|
9
|
+
export { ConnectionStatus, PresenceMember, RealtimeAdapter, RealtimeProvider, RealtimeProviderProps, useChannel, useConnectionStatus, usePresence, useRealtimeAdapter } from '@allem-sdk/realtime';
|
package/dist/index.js
CHANGED
|
@@ -25,32 +25,67 @@ __export(index_exports, {
|
|
|
25
25
|
AgentProvider: () => import_agents.AgentProvider,
|
|
26
26
|
AnalyticsProvider: () => import_analytics.AnalyticsProvider,
|
|
27
27
|
AuthProvider: () => import_auth.AuthProvider,
|
|
28
|
+
NotificationProvider: () => import_notifications.NotificationProvider,
|
|
28
29
|
ProtectedRoute: () => import_auth.ProtectedRoute,
|
|
30
|
+
RealtimeProvider: () => import_realtime.RealtimeProvider,
|
|
31
|
+
StorageProvider: () => import_storage.StorageProvider,
|
|
32
|
+
clerkAdapter: () => import_auth.clerkAdapter,
|
|
33
|
+
consoleAdapter: () => import_analytics.consoleAdapter,
|
|
34
|
+
cookieAdapter: () => import_storage.cookieAdapter,
|
|
29
35
|
createAllemAgentHandler: () => import_agents.createAllemAgentHandler,
|
|
36
|
+
createAllemGuardrail: () => import_agents.createAllemGuardrail,
|
|
30
37
|
createAllemTool: () => import_agents.createAllemTool,
|
|
38
|
+
createMemoryAdapter: () => import_agents.createMemoryAdapter,
|
|
31
39
|
custom: () => import_forms.custom,
|
|
32
40
|
email: () => import_forms.email,
|
|
41
|
+
hasToolCall: () => import_agents.hasToolCall,
|
|
42
|
+
isLoopFinished: () => import_agents.isLoopFinished,
|
|
43
|
+
localStorageAdapter: () => import_storage.localStorageAdapter,
|
|
33
44
|
max: () => import_forms.max,
|
|
34
45
|
maxLength: () => import_forms.maxLength,
|
|
46
|
+
memoryAdapter: () => import_storage.memoryAdapter,
|
|
35
47
|
min: () => import_forms.min,
|
|
36
48
|
minLength: () => import_forms.minLength,
|
|
49
|
+
mixpanelAdapter: () => import_analytics.mixpanelAdapter,
|
|
50
|
+
nextAuthAdapter: () => import_auth.nextAuthAdapter,
|
|
37
51
|
pattern: () => import_forms.pattern,
|
|
52
|
+
planExecuteVerify: () => import_agents.planExecuteVerify,
|
|
53
|
+
posthogAdapter: () => import_analytics.posthogAdapter,
|
|
38
54
|
required: () => import_forms.required,
|
|
55
|
+
restrictAfter: () => import_agents.restrictAfter,
|
|
56
|
+
segmentAdapter: () => import_analytics.segmentAdapter,
|
|
57
|
+
sessionStorageAdapter: () => import_storage.sessionStorageAdapter,
|
|
58
|
+
stepCountIs: () => import_agents.stepCountIs,
|
|
59
|
+
supabaseAdapter: () => import_auth.supabaseAdapter,
|
|
60
|
+
thinkThenAct: () => import_agents.thinkThenAct,
|
|
39
61
|
url: () => import_forms.url,
|
|
40
62
|
useAgentTools: () => import_agents.useAgentTools,
|
|
41
63
|
useAllemAgent: () => import_agents.useAllemAgent,
|
|
42
64
|
useAuth: () => import_auth.useAuth,
|
|
65
|
+
useChannel: () => import_realtime.useChannel,
|
|
43
66
|
useClickOutside: () => import_hooks.useClickOutside,
|
|
67
|
+
useConnectionStatus: () => import_realtime.useConnectionStatus,
|
|
44
68
|
useCopyToClipboard: () => import_hooks.useCopyToClipboard,
|
|
45
69
|
useDebounce: () => import_hooks.useDebounce,
|
|
70
|
+
useFetch: () => import_hooks.useFetch,
|
|
46
71
|
useField: () => import_forms.useField,
|
|
47
72
|
useForm: () => import_forms.useForm,
|
|
48
73
|
useIdentify: () => import_analytics.useIdentify,
|
|
49
74
|
useIntersectionObserver: () => import_hooks.useIntersectionObserver,
|
|
75
|
+
useKeyPress: () => import_hooks.useKeyPress,
|
|
50
76
|
useLocalStorage: () => import_hooks.useLocalStorage,
|
|
51
77
|
useMediaQuery: () => import_hooks.useMediaQuery,
|
|
78
|
+
useNotifications: () => import_notifications.useNotifications,
|
|
79
|
+
useNotify: () => import_notifications.useNotify,
|
|
80
|
+
useOnlineStatus: () => import_hooks.useOnlineStatus,
|
|
52
81
|
usePageView: () => import_analytics.usePageView,
|
|
82
|
+
usePresence: () => import_realtime.usePresence,
|
|
83
|
+
usePrevious: () => import_hooks.usePrevious,
|
|
84
|
+
useRealtimeAdapter: () => import_realtime.useRealtimeAdapter,
|
|
53
85
|
useSession: () => import_auth.useSession,
|
|
86
|
+
useStorageAdapter: () => import_storage.useStorageAdapter,
|
|
87
|
+
useStorageItem: () => import_storage.useStorageItem,
|
|
88
|
+
useThrottle: () => import_hooks.useThrottle,
|
|
54
89
|
useToggle: () => import_hooks.useToggle,
|
|
55
90
|
useTrack: () => import_analytics.useTrack,
|
|
56
91
|
useWindowSize: () => import_hooks.useWindowSize
|
|
@@ -62,37 +97,75 @@ var import_agents = require("@allem-sdk/agents");
|
|
|
62
97
|
var import_forms = require("@allem-sdk/forms");
|
|
63
98
|
var import_analytics = require("@allem-sdk/analytics");
|
|
64
99
|
var import_auth = require("@allem-sdk/auth");
|
|
100
|
+
var import_storage = require("@allem-sdk/storage");
|
|
101
|
+
var import_notifications = require("@allem-sdk/notifications");
|
|
102
|
+
var import_realtime = require("@allem-sdk/realtime");
|
|
65
103
|
// Annotate the CommonJS export names for ESM import in node:
|
|
66
104
|
0 && (module.exports = {
|
|
67
105
|
AgentProvider,
|
|
68
106
|
AnalyticsProvider,
|
|
69
107
|
AuthProvider,
|
|
108
|
+
NotificationProvider,
|
|
70
109
|
ProtectedRoute,
|
|
110
|
+
RealtimeProvider,
|
|
111
|
+
StorageProvider,
|
|
112
|
+
clerkAdapter,
|
|
113
|
+
consoleAdapter,
|
|
114
|
+
cookieAdapter,
|
|
71
115
|
createAllemAgentHandler,
|
|
116
|
+
createAllemGuardrail,
|
|
72
117
|
createAllemTool,
|
|
118
|
+
createMemoryAdapter,
|
|
73
119
|
custom,
|
|
74
120
|
email,
|
|
121
|
+
hasToolCall,
|
|
122
|
+
isLoopFinished,
|
|
123
|
+
localStorageAdapter,
|
|
75
124
|
max,
|
|
76
125
|
maxLength,
|
|
126
|
+
memoryAdapter,
|
|
77
127
|
min,
|
|
78
128
|
minLength,
|
|
129
|
+
mixpanelAdapter,
|
|
130
|
+
nextAuthAdapter,
|
|
79
131
|
pattern,
|
|
132
|
+
planExecuteVerify,
|
|
133
|
+
posthogAdapter,
|
|
80
134
|
required,
|
|
135
|
+
restrictAfter,
|
|
136
|
+
segmentAdapter,
|
|
137
|
+
sessionStorageAdapter,
|
|
138
|
+
stepCountIs,
|
|
139
|
+
supabaseAdapter,
|
|
140
|
+
thinkThenAct,
|
|
81
141
|
url,
|
|
82
142
|
useAgentTools,
|
|
83
143
|
useAllemAgent,
|
|
84
144
|
useAuth,
|
|
145
|
+
useChannel,
|
|
85
146
|
useClickOutside,
|
|
147
|
+
useConnectionStatus,
|
|
86
148
|
useCopyToClipboard,
|
|
87
149
|
useDebounce,
|
|
150
|
+
useFetch,
|
|
88
151
|
useField,
|
|
89
152
|
useForm,
|
|
90
153
|
useIdentify,
|
|
91
154
|
useIntersectionObserver,
|
|
155
|
+
useKeyPress,
|
|
92
156
|
useLocalStorage,
|
|
93
157
|
useMediaQuery,
|
|
158
|
+
useNotifications,
|
|
159
|
+
useNotify,
|
|
160
|
+
useOnlineStatus,
|
|
94
161
|
usePageView,
|
|
162
|
+
usePresence,
|
|
163
|
+
usePrevious,
|
|
164
|
+
useRealtimeAdapter,
|
|
95
165
|
useSession,
|
|
166
|
+
useStorageAdapter,
|
|
167
|
+
useStorageItem,
|
|
168
|
+
useThrottle,
|
|
96
169
|
useToggle,
|
|
97
170
|
useTrack,
|
|
98
171
|
useWindowSize,
|
package/dist/index.mjs
CHANGED
|
@@ -9,7 +9,12 @@ import {
|
|
|
9
9
|
useToggle,
|
|
10
10
|
useCopyToClipboard,
|
|
11
11
|
useIntersectionObserver,
|
|
12
|
-
useWindowSize
|
|
12
|
+
useWindowSize,
|
|
13
|
+
useFetch,
|
|
14
|
+
useThrottle,
|
|
15
|
+
usePrevious,
|
|
16
|
+
useKeyPress,
|
|
17
|
+
useOnlineStatus
|
|
13
18
|
} from "@allem-sdk/hooks";
|
|
14
19
|
export * from "@allem-sdk/ai";
|
|
15
20
|
import {
|
|
@@ -17,7 +22,15 @@ import {
|
|
|
17
22
|
AgentProvider,
|
|
18
23
|
useAgentTools,
|
|
19
24
|
createAllemAgentHandler,
|
|
20
|
-
createAllemTool
|
|
25
|
+
createAllemTool,
|
|
26
|
+
createAllemGuardrail,
|
|
27
|
+
createMemoryAdapter,
|
|
28
|
+
thinkThenAct,
|
|
29
|
+
planExecuteVerify,
|
|
30
|
+
restrictAfter,
|
|
31
|
+
stepCountIs,
|
|
32
|
+
isLoopFinished,
|
|
33
|
+
hasToolCall
|
|
21
34
|
} from "@allem-sdk/agents";
|
|
22
35
|
import {
|
|
23
36
|
useForm,
|
|
@@ -36,44 +49,107 @@ import {
|
|
|
36
49
|
AnalyticsProvider,
|
|
37
50
|
useTrack,
|
|
38
51
|
usePageView,
|
|
39
|
-
useIdentify
|
|
52
|
+
useIdentify,
|
|
53
|
+
mixpanelAdapter,
|
|
54
|
+
posthogAdapter,
|
|
55
|
+
segmentAdapter,
|
|
56
|
+
consoleAdapter
|
|
40
57
|
} from "@allem-sdk/analytics";
|
|
41
58
|
import {
|
|
42
59
|
AuthProvider,
|
|
43
60
|
useAuth,
|
|
44
61
|
useSession,
|
|
45
|
-
ProtectedRoute
|
|
62
|
+
ProtectedRoute,
|
|
63
|
+
supabaseAdapter,
|
|
64
|
+
nextAuthAdapter,
|
|
65
|
+
clerkAdapter
|
|
46
66
|
} from "@allem-sdk/auth";
|
|
67
|
+
import {
|
|
68
|
+
StorageProvider,
|
|
69
|
+
useStorageAdapter,
|
|
70
|
+
useStorageItem,
|
|
71
|
+
localStorageAdapter,
|
|
72
|
+
sessionStorageAdapter,
|
|
73
|
+
cookieAdapter,
|
|
74
|
+
memoryAdapter
|
|
75
|
+
} from "@allem-sdk/storage";
|
|
76
|
+
import {
|
|
77
|
+
NotificationProvider,
|
|
78
|
+
useNotifications,
|
|
79
|
+
useNotify
|
|
80
|
+
} from "@allem-sdk/notifications";
|
|
81
|
+
import {
|
|
82
|
+
RealtimeProvider,
|
|
83
|
+
useRealtimeAdapter,
|
|
84
|
+
useChannel,
|
|
85
|
+
usePresence,
|
|
86
|
+
useConnectionStatus
|
|
87
|
+
} from "@allem-sdk/realtime";
|
|
47
88
|
export {
|
|
48
89
|
AgentProvider,
|
|
49
90
|
AnalyticsProvider,
|
|
50
91
|
AuthProvider,
|
|
92
|
+
NotificationProvider,
|
|
51
93
|
ProtectedRoute,
|
|
94
|
+
RealtimeProvider,
|
|
95
|
+
StorageProvider,
|
|
96
|
+
clerkAdapter,
|
|
97
|
+
consoleAdapter,
|
|
98
|
+
cookieAdapter,
|
|
52
99
|
createAllemAgentHandler,
|
|
100
|
+
createAllemGuardrail,
|
|
53
101
|
createAllemTool,
|
|
102
|
+
createMemoryAdapter,
|
|
54
103
|
custom,
|
|
55
104
|
email,
|
|
105
|
+
hasToolCall,
|
|
106
|
+
isLoopFinished,
|
|
107
|
+
localStorageAdapter,
|
|
56
108
|
max,
|
|
57
109
|
maxLength,
|
|
110
|
+
memoryAdapter,
|
|
58
111
|
min,
|
|
59
112
|
minLength,
|
|
113
|
+
mixpanelAdapter,
|
|
114
|
+
nextAuthAdapter,
|
|
60
115
|
pattern,
|
|
116
|
+
planExecuteVerify,
|
|
117
|
+
posthogAdapter,
|
|
61
118
|
required,
|
|
119
|
+
restrictAfter,
|
|
120
|
+
segmentAdapter,
|
|
121
|
+
sessionStorageAdapter,
|
|
122
|
+
stepCountIs,
|
|
123
|
+
supabaseAdapter,
|
|
124
|
+
thinkThenAct,
|
|
62
125
|
url,
|
|
63
126
|
useAgentTools,
|
|
64
127
|
useAllemAgent,
|
|
65
128
|
useAuth,
|
|
129
|
+
useChannel,
|
|
66
130
|
useClickOutside,
|
|
131
|
+
useConnectionStatus,
|
|
67
132
|
useCopyToClipboard,
|
|
68
133
|
useDebounce,
|
|
134
|
+
useFetch,
|
|
69
135
|
useField,
|
|
70
136
|
useForm,
|
|
71
137
|
useIdentify,
|
|
72
138
|
useIntersectionObserver,
|
|
139
|
+
useKeyPress,
|
|
73
140
|
useLocalStorage,
|
|
74
141
|
useMediaQuery,
|
|
142
|
+
useNotifications,
|
|
143
|
+
useNotify,
|
|
144
|
+
useOnlineStatus,
|
|
75
145
|
usePageView,
|
|
146
|
+
usePresence,
|
|
147
|
+
usePrevious,
|
|
148
|
+
useRealtimeAdapter,
|
|
76
149
|
useSession,
|
|
150
|
+
useStorageAdapter,
|
|
151
|
+
useStorageItem,
|
|
152
|
+
useThrottle,
|
|
77
153
|
useToggle,
|
|
78
154
|
useTrack,
|
|
79
155
|
useWindowSize
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from '@allem-sdk/notifications';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from '@allem-sdk/notifications';
|
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
"use strict";
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
|
+
var __copyProps = (to, from, except, desc) => {
|
|
8
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
9
|
+
for (let key of __getOwnPropNames(from))
|
|
10
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
11
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
12
|
+
}
|
|
13
|
+
return to;
|
|
14
|
+
};
|
|
15
|
+
var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
|
|
16
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
17
|
+
|
|
18
|
+
// src/notifications.ts
|
|
19
|
+
var notifications_exports = {};
|
|
20
|
+
module.exports = __toCommonJS(notifications_exports);
|
|
21
|
+
__reExport(notifications_exports, require("@allem-sdk/notifications"), module.exports);
|
|
22
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
23
|
+
0 && (module.exports = {
|
|
24
|
+
...require("@allem-sdk/notifications")
|
|
25
|
+
});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from '@allem-sdk/realtime';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from '@allem-sdk/realtime';
|
package/dist/realtime.js
ADDED
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
"use strict";
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
|
+
var __copyProps = (to, from, except, desc) => {
|
|
8
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
9
|
+
for (let key of __getOwnPropNames(from))
|
|
10
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
11
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
12
|
+
}
|
|
13
|
+
return to;
|
|
14
|
+
};
|
|
15
|
+
var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
|
|
16
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
17
|
+
|
|
18
|
+
// src/realtime.ts
|
|
19
|
+
var realtime_exports = {};
|
|
20
|
+
module.exports = __toCommonJS(realtime_exports);
|
|
21
|
+
__reExport(realtime_exports, require("@allem-sdk/realtime"), module.exports);
|
|
22
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
23
|
+
0 && (module.exports = {
|
|
24
|
+
...require("@allem-sdk/realtime")
|
|
25
|
+
});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from '@allem-sdk/storage';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from '@allem-sdk/storage';
|
package/dist/storage.js
ADDED
|
@@ -0,0 +1,25 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
"use strict";
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
|
+
var __copyProps = (to, from, except, desc) => {
|
|
8
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
9
|
+
for (let key of __getOwnPropNames(from))
|
|
10
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
11
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
12
|
+
}
|
|
13
|
+
return to;
|
|
14
|
+
};
|
|
15
|
+
var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
|
|
16
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
17
|
+
|
|
18
|
+
// src/storage.ts
|
|
19
|
+
var storage_exports = {};
|
|
20
|
+
module.exports = __toCommonJS(storage_exports);
|
|
21
|
+
__reExport(storage_exports, require("@allem-sdk/storage"), module.exports);
|
|
22
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
23
|
+
0 && (module.exports = {
|
|
24
|
+
...require("@allem-sdk/storage")
|
|
25
|
+
});
|
package/dist/storage.mjs
ADDED
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "allem-sdk",
|
|
3
|
-
"version": "0.1.
|
|
4
|
-
"description": "The
|
|
3
|
+
"version": "0.1.5",
|
|
4
|
+
"description": "The React SDK for AI agents, chat, forms, auth, analytics, and 8 essential hooks. One install, zero lock-in. Built on Vercel AI SDK v6.",
|
|
5
5
|
"license": "MIT",
|
|
6
6
|
"author": "Ahmed Allem (https://kingallem.com)",
|
|
7
7
|
"main": "./dist/index.js",
|
|
@@ -42,6 +42,21 @@
|
|
|
42
42
|
"types": "./dist/agents.d.ts",
|
|
43
43
|
"import": "./dist/agents.mjs",
|
|
44
44
|
"require": "./dist/agents.js"
|
|
45
|
+
},
|
|
46
|
+
"./storage": {
|
|
47
|
+
"types": "./dist/storage.d.ts",
|
|
48
|
+
"import": "./dist/storage.mjs",
|
|
49
|
+
"require": "./dist/storage.js"
|
|
50
|
+
},
|
|
51
|
+
"./notifications": {
|
|
52
|
+
"types": "./dist/notifications.d.ts",
|
|
53
|
+
"import": "./dist/notifications.mjs",
|
|
54
|
+
"require": "./dist/notifications.js"
|
|
55
|
+
},
|
|
56
|
+
"./realtime": {
|
|
57
|
+
"types": "./dist/realtime.d.ts",
|
|
58
|
+
"import": "./dist/realtime.mjs",
|
|
59
|
+
"require": "./dist/realtime.js"
|
|
45
60
|
}
|
|
46
61
|
},
|
|
47
62
|
"files": [
|
|
@@ -49,12 +64,15 @@
|
|
|
49
64
|
],
|
|
50
65
|
"sideEffects": false,
|
|
51
66
|
"dependencies": {
|
|
52
|
-
"@allem-sdk/hooks": "0.1.
|
|
53
|
-
"@allem-sdk/
|
|
54
|
-
"@allem-sdk/
|
|
55
|
-
"@allem-sdk/
|
|
56
|
-
"@allem-sdk/
|
|
57
|
-
"@allem-sdk/
|
|
67
|
+
"@allem-sdk/hooks": "0.1.3",
|
|
68
|
+
"@allem-sdk/ai": "0.1.3",
|
|
69
|
+
"@allem-sdk/forms": "0.1.2",
|
|
70
|
+
"@allem-sdk/analytics": "0.1.3",
|
|
71
|
+
"@allem-sdk/auth": "0.1.3",
|
|
72
|
+
"@allem-sdk/agents": "0.1.4",
|
|
73
|
+
"@allem-sdk/notifications": "0.1.1",
|
|
74
|
+
"@allem-sdk/storage": "0.1.1",
|
|
75
|
+
"@allem-sdk/realtime": "0.1.1"
|
|
58
76
|
},
|
|
59
77
|
"devDependencies": {
|
|
60
78
|
"@types/react": "^19.0.0",
|
|
@@ -89,13 +107,23 @@
|
|
|
89
107
|
"keywords": [
|
|
90
108
|
"allem-sdk",
|
|
91
109
|
"react",
|
|
92
|
-
"hooks",
|
|
110
|
+
"react-hooks",
|
|
93
111
|
"ai",
|
|
94
|
-
"agents",
|
|
112
|
+
"ai-agents",
|
|
113
|
+
"ai-sdk",
|
|
114
|
+
"vercel-ai-sdk",
|
|
115
|
+
"chatbot",
|
|
116
|
+
"tool-calling",
|
|
95
117
|
"forms",
|
|
118
|
+
"validation",
|
|
96
119
|
"analytics",
|
|
97
120
|
"auth",
|
|
98
|
-
"
|
|
121
|
+
"authentication",
|
|
122
|
+
"sdk",
|
|
123
|
+
"typescript",
|
|
124
|
+
"nextjs",
|
|
125
|
+
"ssr",
|
|
126
|
+
"hooks"
|
|
99
127
|
],
|
|
100
128
|
"publishConfig": {
|
|
101
129
|
"access": "public"
|