Open myke-roly opened 3 months ago
When calling chatSDK.getMessages() in my React Native project, the method returns an empty array ([]) instead of the expected list of messages.
await chatSDK .getMessages() .then(messages => { console.log(messages) }) .catch(e => { console.error('Error getting messages', e) })
The method chatSDK.getMessages() should return a list of messages instead of an empty array.
@microsoft/omnichannel-chat-sdk: 1.9.0 react-native: 0.71.11 react: 18.2.0
Devices: Tested on both Android and iOS
LOG [ScenarioMarker][startScenario] LOG [AriaTelemetry][fillMobilePlatformData][Android] LOG [AriaTelemetry][info] occhatsdk_events LOG {"name": "occhatsdk_events", "priority": 3, "properties": {"CDNPackagesInfo": undefined, "CallId": "", "ChatId": "{ChatId}", "ChatSDKRuntimeId": "{ChatSDKRuntimeId}", "ChatSDKVersion": "1.9.0", "DeviceInfo_OsName": "Android", "DeviceInfo_OsVersion": 34, "Domain": "", "ElapsedTimeInMilliseconds": "", "Event": "GetMessagesStarted", "ExceptionDetails": "", "LogLevel": "INFO", "NPMPackagesInfo": "{\"OCSDK\":\"0.5.2\",\"IC3Core\":\"0.1.3\",\"ACSChat\":\"1.1.1\",\"ACSCommon\":\"1.1.0\",\"AMSClient\":\"0.1.6\"}", "OrgId": "{OrgId}", "OrgUrl": "{OrgUrl}", "PlatformDetails": "{\"Renderer\":\"ReactNative\",\"DeviceInfo_OsVersion\":34,\"DeviceInfo_OsName\":\"Android\"}", "RequestId": "{RequestId}", "WidgetId": "{WidgetId}"}} LOG GetMessagesStarted LOG [ScenarioMarker][startScenario] LOG [AriaTelemetry][fillMobilePlatformData][Android] LOG [AriaTelemetry][info] occhatsdk_acsclientevents LOG {"name": "occhatsdk_acsclientevents", "priority": 3, "properties": {"ACSChatVersion": "1.1.1", "ChatId": "{ChatId}", "ChatSDKRuntimeId": "{ChatSDKRuntimeId}", "ElapsedTimeInMilliseconds": "", "Event": "GetMessagesStarted", "ExceptionDetails": "", "LogLevel": "INFO", "OrgId": "{OrgId}", "OrgUrl": "{OrgUrl}", "RequestId": "{RequestId}", "WidgetId": "{WidgetId}"}} LOG GetMessagesStarted LOG [ScenarioMarker][completeScenario] LOG [AriaTelemetry][fillMobilePlatformData][Android] LOG [AriaTelemetry][info] occhatsdk_acsclientevents LOG {"name": "occhatsdk_acsclientevents", "priority": 3, "properties": {"ACSChatVersion": "1.1.1", "ChatId": "{ChatId}", "ChatSDKRuntimeId": "{ChatSDKRuntimeId}", "ElapsedTimeInMilliseconds": 998, "Event": "GetMessagesCompleted", "ExceptionDetails": "", "LogLevel": "INFO", "OrgId": "{OrgId}", "OrgUrl": "{OrgUrl}", "RequestId": "{RequestId}", "WidgetId": "{WidgetId}"}} LOG GetMessagesCompleted LOG [ScenarioMarker][completeScenario] LOG [AriaTelemetry][fillMobilePlatformData][Android] LOG [AriaTelemetry][info] occhatsdk_events LOG {"name": "occhatsdk_events", "priority": 3, "properties": {"CDNPackagesInfo": undefined, "CallId": "", "ChatId": "{ChatId}", "ChatSDKRuntimeId": "{ChatSDKRuntimeId}", "ChatSDKVersion": "1.9.0", "DeviceInfo_OsName": "Android", "DeviceInfo_OsVersion": 34, "Domain": "", "ElapsedTimeInMilliseconds": 1001, "Event": "GetMessagesCompleted", "ExceptionDetails": "", "LogLevel": "INFO", "NPMPackagesInfo": "{\"OCSDK\":\"0.5.2\",\"IC3Core\":\"0.1.3\",\"ACSChat\":\"1.1.1\",\"ACSCommon\":\"1.1.0\",\"AMSClient\":\"0.1.6\"}", "OrgId": "{OrgId}", "OrgUrl": "{OrgUrl}", "PlatformDetails": "{\"Renderer\":\"ReactNative\",\"DeviceInfo_OsVersion\":34,\"DeviceInfo_OsName\":\"Android\"}", "RequestId": "{RequestId}", "WidgetId": "{WidgetId}"}} LOG GetMessagesCompleted LOG []
When calling chatSDK.getMessages() in my React Native project, the method returns an empty array ([]) instead of the expected list of messages.
Implemetation
Result []
The method chatSDK.getMessages() should return a list of messages instead of an empty array.
Environment Information
@microsoft/omnichannel-chat-sdk: 1.9.0 react-native: 0.71.11 react: 18.2.0
Devices: Tested on both Android and iOS
LOGS setDebug(true)