Examples: query, "exact match", wildcard*, wild?ard, wild*rd
Fuzzy search: cake~ (finds cakes, bake)
Term boost: "red velvet"^4, chocolate^2
Field grouping: tags:(+work -"fun-stuff")
Escape special characters +-&|!(){}[]^"~*?:\ - e.g. \+ \* \!
Range search: properties.timestamp:[1587729413488 TO *] (inclusive), properties.title:{A TO Z}(excluding A and Z)
Combinations: chocolate AND vanilla, chocolate OR vanilla, (chocolate OR vanilla) NOT "vanilla pudding"
Field search: properties.title:"The Title" AND text
Answered
Pulling up the messages in the room posted before bot was added in the room

The issue comprimises of incapability of pulling up the messages in the room posted before bot was added in the room. Messages posted post bot is added are searched successfully

Step to reproduce:
Step1 : Create room
Step 2: Add few message
Step 3: Add bot in Room
Step 4: Pull all messages from room using message serach API https://developers.symphony.com/restapi/reference/message-search-post

Expected Result
All messages matching the search criteria should be pulled

Actual Result :
Messages pulled are the ones posted after the bot is added.

  
  
Posted one year ago
  
  

Even we have enable "Let new members browse history"

Vaibhav Mankar   one year ago Report
Votes Newest

Answers 3


Hi Vaibhav,

Thank you for posting your question.

I have been able to follow the steps to reproduce the exact scenario as you have described:

Step 1 : Create a new chatroom with the 'Let new memebers browse room history' chatroom permission enabled
Step 2: Add messages to the chatroom
Step 3: Add the chatbot into the chatroom
Step 4: Execute the POST Message Search REST API endpoint to obtain the messages (https://developers.symphony.com/restapi/reference/message-search-post)

From testing the scernario whilst using the POST Message Search REST API - I can confirm that the chatbot will not be able to obtain messages sent in the chatroom before the chatbot has been added. If there are any messages sent into the chatroom after the chatbot has been added then the POST Message Search REST API will be able to obtain & return the messages sent into the chatroom.

I believe for the exact scenario / use case you have described, there is a more suited Symphony REST API endpoint that you can use that will obtain messages before or after the chatbot has been added into the chatroom.

If you use the GET Get Messages REST API endpoint (https://developers.symphony.com/restapi/reference/messages-v4) - whilst specifing the 'ConversationID/StreamID' of the chosen chatroom & using the 'since' query parameter including the EPOCH timestamp. The EPOCH timestamp can be before the message is sent into the chatroom or a time period on when you would like to focus on. After using these criteria for the GET Get Message REST API, you will be able to obtain all of the messages sent into the room before or after the chatbot has been added to the chatroom.

I have been able to double check this scenario and I can confirm that the GET Get Message REST API will work for your use case.

Please feel free to let me know if you have any questions or feedback.

  
  
Posted one year ago
Kaosar Ahmed
310 × 3 Administrator

Hi Vaibhav,

Apolgises for the delay - can you confirm if you are still having the same SocketTimeoutException issue?

If the issue is still ongoing - I would recommend reaching out to either myself or the Symphony Support team (support@symphony.com) - so we can investigate in more detail to find out precisely.

It is likely that trying to pull messages from a really old chat room would result in the error you quoted - the criteria used to query the chat room may take too long for the result to return.

Please let me know should you need any further help or assistance.

  
  
Posted one year ago
Kaosar Ahmed
310 × 3 Administrator

Thanks Kaosar,

Get Messages REST API is worked.

  
  
Posted one year ago
  
  

Hi Team,

GET Get Messages REST API endpoint (https://developers.symphony.com/restapi/reference/messages-v4) API is working fine for resendly created room.
But when we try to pull messages from older room, we are getting SocketTimeoutException

ERROR:
javax.ws.rs.ProcessingException: java.net.SocketTimeoutException: Read timed out
at org.glassfish.jersey.apache.connector.ApacheConnector.apply(ApacheConnector.java:531) ~[jersey-apache-connector-2.33.jar!/:na]
at org.glassfish.jersey.client.ClientRuntime.invoke(ClientRuntime.java:297) ~[jersey-client-2...

Vaibhav Mankar   one year ago Report
1K Views
3 Answers
one year ago
one year ago
Tags