I am not getting events for the email interactions in the backend java code if there is any existing email interaction to be answered by agent in his queue.
Scenario goes as explained below-
Suppose, all the genesys cloud agents are logged out and I send an e-mail(manually) and then say after 5 minutes, I run the java code that logs in an agent, subscribes to email conversations and sets it to on-queue. Then in that case, we don't receive any events for email interaction in the backend.
When I login to genesys cloud dashboard, i get that email interaction alert to answer it.
However, if i run the java code that logs in agents and subscribes to email conversations and then, send an e-mail manually, i get proper events.
I don't understand what's wrongs. Could you please help me out.
Notifications are real time events. When you subscribe to a topic, you'll get events that happen after that point in time, in real time. You will not get events that occurred before you subscribed to them. If you need to fetch existing information, please use the API to fetch the data you need to initialize your app.
However, can you please share the api that can be used to get the conversations that are pending for the user to be answered, the api that you are mentioning, as I tried to find it but didn't get any success.
I am sure, you aren't pointing towards -
/api/v2/conversations
The above api returns active conversations for a user, but since our conversations haven't been accepted yet, I hope they won't be considered active.