-
Notifications
You must be signed in to change notification settings - Fork 11.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Events for onAgentsAvailable and onAgentsUnavailable #16264
Comments
Related #13583 #13583 covered On agents available event and On agents unavailable event although those two items didn't make it in time for merge. Is it correct to assume that, if those two items would be supported by the API, it would be possible to only show livechat in case a support agent is available and if that is not the case, not show the livechat at all? |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
Not sure why this should be closed. It is an important missing feature. |
@renatobecker what's your opinion? |
@rodrigok It makes sense, this is an old request we get from the community, but we need to plan the better way to provide those API methods to the widget since we can have thousands of agents. |
Just to be clear: from my limited understanding it currently is not possible to have RocketChat Live Widget only show on the website when an agent is available. Instead it switches to offline mode. While this may work for some use cases it certainly doesn't for everybody. Having an option to only show the widget when a support agent is available is a legit use-case. Having the two options discussed in this request here would allow for that use-case, if I am not mistaken. |
Actually you can control it from your side if you want, you just need to call the Livechat |
@renatobecker Of course thank you for pointing out the workaround for the status quo. The ideal solution form a user perspective would be, to have the chat behave as intended automatically i.e. |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
Please don't close valid issues. |
This is working fine, there's a message displayed when no agent is available, and when it does, you can see the agent. |
@damian-centrone thanks for responding. Could you explain how it is possible to automatically hide the chat when no agent is available please? |
The actual behaviour is showing the chat as inactive (grey) and if you click on that, you can leave an offline message, which I believe is a good practice. Hide the chat when no agent is available would be a new feature to discuss, maybe in another ticket pointing to https://github.com/RocketChat/feature-requests/issues greets! |
I am aware of the offline mode, but it is not what I am requesting. Have filed Feature Request #417. |
Would it be possible to implement the following events for the livechat API ?
onAgentsAvailable - fires when online agents are detected
onAgentsUnavailable - fires when no online agents are detected
They could be useful for example to have a different look and functionality on a "help button" if there is at least one agent available.
I know there is the onAgentStatusChange event, but it seems to only fire for agents that are assigned to an existing chat.
The text was updated successfully, but these errors were encountered: