@sendbird/ai-agent-messenger-react 1.6.2 → 1.6.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.cjs CHANGED
@@ -1 +1 @@
1
- "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./cjs/BUvLOAVj.cjs");require("react");exports.AgentProviderContainer=e.AgentProviderContainer;exports.AgentUIProviderContainer=e.AgentUIProviderContainer;exports.AnonymousSessionInfo=e.AnonymousSessionInfo;exports.CSATType=e.CSATType;exports.Commands=e.DispatcherCommands;exports.Conversation=e.Conversation;exports.ConversationContext=e.ConversationContext;exports.ConversationContextProvider=e.ConversationContextProvider;exports.ConversationLayout=e.ConversationLayout;exports.ConversationList=e.ConversationList;exports.ConversationListContext=e.ConversationListContext;exports.ConversationListContextProvider=e.ConversationListContextProvider;exports.ConversationListItemLayout=e.ConversationListItemLayout;exports.ConversationListLayout=e.ConversationListLayout;exports.DefaultMessenger=e.DefaultMessenger;exports.FixedMessenger=e.FixedMessenger;exports.IncomingMessageLayout=e.IncomingMessageLayout;exports.LauncherBase=e.LauncherBase;exports.LogLevel=e.LogLevel;exports.ManualSessionInfo=e.ManualSessionInfo;exports.MessageLogs=e.MessageLogs;exports.OutgoingMessageLayout=e.OutgoingMessageLayout;exports.PlaceholderLayout=e.PlaceholderLayout;exports.SystemMessageLayout=e.SystemMessageLayout;exports.messengerDispatcher=e.messengerDispatcher;exports.useConversationContext=e.useConversationContext;exports.useConversationListContext=e.useConversationListContext;exports.useLocalizationContext=e.useLocalizationContext;exports.useMessengerContext=e.useMessengerContext;exports.useMessengerSessionContext=e.useMessengerSessionContext;
1
+ "use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const e=require("./cjs/Cgpjda0S.cjs");require("react");exports.AgentProviderContainer=e.AgentProviderContainer;exports.AgentUIProviderContainer=e.AgentUIProviderContainer;exports.AnonymousSessionInfo=e.AnonymousSessionInfo;exports.CSATType=e.CSATType;exports.Commands=e.DispatcherCommands;exports.Conversation=e.Conversation;exports.ConversationContext=e.ConversationContext;exports.ConversationContextProvider=e.ConversationContextProvider;exports.ConversationLayout=e.ConversationLayout;exports.ConversationList=e.ConversationList;exports.ConversationListContext=e.ConversationListContext;exports.ConversationListContextProvider=e.ConversationListContextProvider;exports.ConversationListItemLayout=e.ConversationListItemLayout;exports.ConversationListLayout=e.ConversationListLayout;exports.DefaultMessenger=e.DefaultMessenger;exports.FixedMessenger=e.FixedMessenger;exports.IncomingMessageLayout=e.IncomingMessageLayout;exports.LauncherBase=e.LauncherBase;exports.LogLevel=e.LogLevel;exports.ManualSessionInfo=e.ManualSessionInfo;exports.MessageLogs=e.MessageLogs;exports.OutgoingMessageLayout=e.OutgoingMessageLayout;exports.PlaceholderLayout=e.PlaceholderLayout;exports.SystemMessageLayout=e.SystemMessageLayout;exports.messengerDispatcher=e.messengerDispatcher;exports.useConversationContext=e.useConversationContext;exports.useConversationListContext=e.useConversationListContext;exports.useLocalizationContext=e.useLocalizationContext;exports.useMessengerContext=e.useMessengerContext;exports.useMessengerSessionContext=e.useMessengerSessionContext;
package/dist/index.d.ts CHANGED
@@ -290,6 +290,10 @@ declare interface AIAgentConversationContextValue {
290
290
  sendUserMessage: (params: UserMessageCreateParams) => Promise<UserMessage>;
291
291
  sendFileMessage: (params: FileMessageCreateParams) => Promise<FileMessage>;
292
292
  };
293
+
294
+ state: {
295
+ input: InputState;
296
+ };
293
297
  }
294
298
 
295
299
  declare interface AIAgentConversationListContextValue {
@@ -887,38 +891,56 @@ export declare interface ExtendedMessagePayload {
887
891
  suggested_replies: string[];
888
892
  message_template: MessageTemplateShape;
889
893
  csat: {
890
- type: CSATType;
894
+ type: 'AI_AGENT_CSAT_5' | 'AI_AGENT_CSAT_5_WITH_CRE' | 'HELPDESK_CSAT_5';
891
895
  visibility: boolean;
896
+
892
897
  title: string;
893
898
  csat_question: string;
899
+
894
900
  csat_scores: {
895
901
  label: string;
896
902
  image_url: string;
897
903
  }[];
904
+
898
905
  csat_submit_label: string;
899
906
  csat_submitted_label: string;
907
+
900
908
  cre?: {
901
909
  question: string;
902
910
  positive_label: string;
903
911
  negative_label: string;
904
912
  };
905
- follow_up?: Array<{
913
+
914
+ follow_up?: Array<
915
+ | {
906
916
  response_type: 'free_text';
907
917
  question: string;
908
- scores: number[];
918
+ scores: number[]; // One or more CSAT scores that trigger this follow-up question.
909
919
  required?: boolean;
910
- } | {
920
+ }
921
+ | {
911
922
  response_type: 'single_choice';
912
923
  question: string;
913
- scores: number[];
914
- options: string[];
924
+ scores: number[]; // One or more CSAT scores that trigger this follow-up question.
925
+ options: string[]; // Up to 5 predefined answer choices
915
926
  required?: boolean;
916
- }>;
927
+ }
928
+ >;
917
929
  };
918
- bot_message_type: 'generated' | 'canned' | 'thinking' | 'welcome' | 'resolution_feedback' | 'maintenance' | 'safeguard' | 'error';
930
+ bot_message_type:
931
+ | 'generated'
932
+ | 'canned'
933
+ | 'thinking'
934
+ | 'welcome'
935
+ | 'resolution_feedback'
936
+ | 'maintenance'
937
+ | 'safeguard'
938
+ | 'error';
919
939
  citations?: CitationInfo[];
920
940
  feedback?: FeedbackInfo;
921
941
  form?: Form;
942
+
943
+ // logs
922
944
  groundedness: GroundednessInfo[];
923
945
  manual: ActionbookInfo;
924
946
  function_calls: FunctionCallsInfo[];
@@ -998,7 +1020,16 @@ export declare interface FunctionCallsInfo {
998
1020
 
999
1021
  export declare interface GroundednessInfo {
1000
1022
  id: number;
1001
- source_type: 'site' | 'file' | 'snippet' | 'sb_desk' | 'sb_salesforce' | 'sb_confluence' | 'sb_zendesk' | 'sb_sprinklr' | (string & {});
1023
+ source_type:
1024
+ | 'site'
1025
+ | 'file'
1026
+ | 'snippet'
1027
+ | 'sb_desk'
1028
+ | 'sb_salesforce'
1029
+ | 'sb_confluence'
1030
+ | 'sb_zendesk'
1031
+ | 'sb_sprinklr'
1032
+ | (string & {});
1002
1033
  preview_title: string;
1003
1034
  }
1004
1035
 
@@ -1202,6 +1233,11 @@ declare function IncomingSentTime({ createdAt }: Pick<IncomingMessageProps, 'cre
1202
1233
 
1203
1234
  declare function IncomingTypingIndicator({ customStyle }: TypingIndicatorProps): JSX.Element;
1204
1235
 
1236
+ declare type InputState = {
1237
+ disabled: boolean;
1238
+ disabledBy: 'unavailable' | 'form_active' | 'ai_responding' | 'conversation_closed' | (string & {});
1239
+ };
1240
+
1205
1241
  declare interface InternalMessageTemplateVariables {
1206
1242
  carousel_padding_left?: number;
1207
1243
  carousel_padding_right?: number;
package/dist/index.js CHANGED
@@ -1,4 +1,4 @@
1
- import { a as o, b as n, v as t, C as i, D as r, h as C, j as L, k as u, i as g, n as v, p as x, q as m, g as y, o as M, f as d, F as l, I, L as P, s as S, t as c, M as f, O as p, P as h, S as A, m as D, l as F, r as O, e as T, u as b, d as j } from "./es/DOUIpoTT.js";
1
+ import { a as o, b as n, v as t, C as i, D as r, h as C, j as L, k as u, i as g, n as v, p as x, q as m, g as y, o as M, f as d, F as l, I, L as P, s as S, t as c, M as f, O as p, P as h, S as A, m as D, l as F, r as O, e as T, u as b, d as j } from "./es/DgtM1NIG.js";
2
2
  import "react";
3
3
  export {
4
4
  o as AgentProviderContainer,
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@sendbird/ai-agent-messenger-react",
3
- "version": "1.6.2",
3
+ "version": "1.6.3",
4
4
  "description": "Sendbird AI Agent Messenger for React",
5
5
  "type": "module",
6
6
  "main": "dist/index.js",
@@ -20,9 +20,9 @@
20
20
  "sideEffects": false,
21
21
  "dependencies": {
22
22
  "@emotion/is-prop-valid": "^1.3.1",
23
- "@sendbird/react-uikit-message-template-view": "0.0.16",
24
- "@sendbird/uikit-message-template": "0.0.16",
25
- "@sendbird/uikit-tools": "0.0.16",
23
+ "@sendbird/react-uikit-message-template-view": "0.0.19",
24
+ "@sendbird/uikit-message-template": "0.0.19",
25
+ "@sendbird/uikit-tools": "0.0.19",
26
26
  "date-fns": "^4.1.0",
27
27
  "dompurify": "^3.2.4",
28
28
  "markdown-to-jsx": "^7.7.12",
@@ -44,7 +44,7 @@
44
44
  "react-dom": "^19.0.0",
45
45
  "strip-json-comments": "^5.0.1",
46
46
  "styled-components": "^6.1.15",
47
- "@sendbird/ai-agent-core": "1.6.2",
47
+ "@sendbird/ai-agent-core": "1.6.3",
48
48
  "@sendbird/vite-tools": "0.0.1",
49
49
  "@sendbird/config-editor": "0.1.0"
50
50
  },