Genesys Cloud - Developer Community!

 View Only

Sign Up

  • 1.  How to Restore Mobile Messenger Chat Bubble After App Restart?

    Posted 7 days ago

    We are developing a Mobile Messenger integration. When the user clicks minimize, the chat bubble remains visible as expected. However, if the user force-closes (kills) the app and then reopens it, the chat bubble disappears even though the chat session is still active.

    How can we ensure that the chat bubble is restored and visible again when the user relaunches the app?


    #MobileMessenger

    ------------------------------
    Tzi Young
    ------------------------------


  • 2.  RE: How to Restore Mobile Messenger Chat Bubble After App Restart?

    Posted 6 days ago

    Hello,

    Please provide a bit more context of your use-case, perhaps some screenshots or video of the issue.

    After the app is reopened do you start a new session in the background? If yes that could be the problem. The chat needs to be presented as soon as 

    shouldPresentChatViewController() is called, as the chat session is not fully initialized until the chat is displayed, and displaying the chat with a delay will cause issues.



    ------------------------------
    Andras Solyom
    Senior Mobile Software Engineer - iOS
    ------------------------------



  • 3.  RE: How to Restore Mobile Messenger Chat Bubble After App Restart?

    Posted 6 days ago

    Hello,

    Below is the scenario:

    When a user minimizes the chat, the chat bubble appears as expected. However, if the user force-closes the app and then relaunches it, the chat bubble does not automatically reappear. The bubble is only restored when the customer clicks the "Chat with Live Agent" button again, even though the chat session remains active in the background.

    image

    As a result, users have no visual indication that the chat session is still connected or that new messages may have been received. Is there is a way to automatically restore the chat bubble after the app is relaunched following a force close?



    ------------------------------
    Tzi Young
    ------------------------------



  • 4.  RE: How to Restore Mobile Messenger Chat Bubble After App Restart?

    Posted 6 days ago

    Hello,

    This chat bubble in your screenshot is not a functionality of our SDK, it's part of your host app implementation. The SDK does not have a built-in minimized view. We cannot provide support for the a custom view that is implemented on your side.

    Regarding restoring a chat session after app restart:

    On a new app start in order to reconnect the mobile app to the chat session you need to repeat the same initialization steps as when the user originally initiated a chat session:

    • Initialize ChatController and set it's delegate
    • Wait for shouldPresentChatViewController(), and when it's called present the chat view

    Without this the only way to listen to new messages in the background is through the push notification integration.



    ------------------------------
    Andras Solyom
    Senior Mobile Software Engineer - iOS
    ------------------------------