Issue symptoms
I am having issues with live chat department routing. Department routing is active in live chat, but does not route chats correctly.
- Chats route to the wrong agents and wrong departments.
- Chats route to offline agents.
- Chats do not route to a department when they should.
How do I set or change the department in Zendesk Chat?
Resolution steps
Note: This article applies to accounts using live chat in Agent Workspace. To route conversations using messaging, see the article: Routing messaging tickets and notifications.
To verify the issue is not caused by online status
- Verify that agents in the department are online to receive chats.
When you route live chats with triggers, the conversation goes to the department specified in the trigger even if that department is offline. This behavior can cause lost chats.
To verify the pre-chat form works correctly
If you use the pre-chat form to allow customers to choose a department:
- Turn on the pre-chat form and verify that it works correctly in the account.
- Ensure the department option is not hidden on the pre-chat form.
- With the pre-chat form turned on, select the Require Department to allow end users to choose the department when they request a chat.
Note: The mobile SDK does not support the use of chat triggers to set departments. This feature is only compatible with the Web Widget or Chat widget.
To verify the trigger setup
First, use the correct trigger
When using triggers to route live chats to different groups in Agent Workspace:
- Use Chat triggers that can set the department for a chat before the visitor reaches out. This ensures the chat will be routed to the appropriate group in Support from
the moment the ticket is created, and is recommended for chat routing in Agent
Workspace. - Do not use Support triggers, these cannot run until the ticket has been created later on.
- If your chat routing needs are more robust than what chat trigger conditions have to offer, the next best method for routing is through the use of the department's API endpoint and custom code. Similar to chat triggers, using the API to set the department on chats will take effect for the chat before a ticket is created.
Then, use the correct department condition
If you use a trigger to route chats to departments, use the correct department condition in the trigger.
- Use the Set visitor department action in a live chat trigger > make sure Run trigger is set to When a visitor has loaded the chat widget.
- Department routing does not work if Run trigger is set to When a visitor requests a chat or When a chat message is sent. See the image below for an example:
- If a proactive chat trigger starts the chat instead of the visitor, this bypasses other routing triggers. In this case, the chat routes to any available agent regardless of the department. If you want chats that start with a proactive message to route correctly, make sure proactive chat triggers include the Set visitor department action.
Note: The Set visitor department action must be above the Send message to visitor action. The visitor department can only set the chat department before a chat starts.
After a chat starts
After a chat session starts:
- It's too late for a trigger to make a change.
- Your agents can manually reassign the ticket.
- If you use a bot and your team has developers, assign the chat with the Chat Conversations API. The bot will read the message and initiates a transfer to your specified department.