@8wave/ai-elements 0.126.0-beta.5 → 0.126.0-beta.6

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.
@@ -1,11 +1,13 @@
1
1
  import { BetterAuthPlugin } from 'better-auth';
2
2
  /**
3
- * Provides an endpoint to re-authenticate an existing anonymous user
4
- * by creating a new session for them without requiring a new user to be created.
3
+ * Lets an anonymous user come back after its session expired, so the widget
4
+ * does not start a new anonymous user and lose the chats of the previous one.
5
5
  *
6
- * This solves the problem where an anonymous user's session expires and the
7
- * client would otherwise create a brand-new anonymous user, losing chat history.
8
- *
9
- * Security: only works for users with `isAnonymous = true`.
6
+ * The widget proves it held a session of that user with a proof the backend
7
+ * signed and handed to that session (`/anonymous-reauth/proof`). The id alone
8
+ * is not enough: it leaves the visitor's browser (the host page receives it
9
+ * on sign-in), and until 2026-11-05 whoever knew it took the session, the
10
+ * chats, and could carry them into an account of their own. Only anonymous
11
+ * users come back this way.
10
12
  */
11
13
  export declare function anonymousReauth(): BetterAuthPlugin;
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@8wave/ai-elements",
3
3
  "private": false,
4
- "version": "0.126.0-beta.5",
4
+ "version": "0.126.0-beta.6",
5
5
  "type": "module",
6
6
  "scripts": {
7
7
  "dev": "vite --port 8082 --open --host",