@docgenlab.com/chat-widget 0.4.2 → 0.5.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/api.d.ts +12 -0
- package/dist/index.js +561 -463
- package/dist/index.js.map +1 -1
- package/dist/index.umd.cjs +6 -6
- package/dist/index.umd.cjs.map +1 -1
- package/dist/widget.css +1 -1
- package/package.json +1 -1
package/dist/api.d.ts
CHANGED
|
@@ -27,6 +27,18 @@ export declare class WidgetClient {
|
|
|
27
27
|
constructor(opts: ClientOptions);
|
|
28
28
|
private headers;
|
|
29
29
|
getAgent(): Promise<AgentInfo>;
|
|
30
|
+
/** List all conversations this visitor has had with this agent.
|
|
31
|
+
* Used by the "All chats" modal to let users browse + jump back
|
|
32
|
+
* to previous threads. Lightweight payload — message bodies are
|
|
33
|
+
* fetched on demand via getConversation when the user opens one. */
|
|
34
|
+
listConversations(): Promise<Array<{
|
|
35
|
+
id: string;
|
|
36
|
+
title: string | null;
|
|
37
|
+
preview: string | null;
|
|
38
|
+
message_count: number;
|
|
39
|
+
created_at: string | null;
|
|
40
|
+
updated_at: string | null;
|
|
41
|
+
}>>;
|
|
30
42
|
/** Load a previous conversation's messages so the widget can show
|
|
31
43
|
* history after a refresh / re-open. The visitor-id header is the
|
|
32
44
|
* authorization — the backend only returns conversations owned by
|