Configure routing based on external schedules (preview)
Applies to: Dynamics 365 Contact Center—standalone and Dynamics 365 Customer Service only
[This article is prerelease documentation and is subject to change.]
Configure assignment rules to route and assign cases and conversations based on agents' shift schedules imported from external workforce management (WFM) systems. By verifying agents' schedules in advance, organizations can avoid routing tasks to off-duty agents, and reduce the risk of delays.
You can incorporate shift assignments and time-off considerations into the routing process to foster an employee-centric approach, and streamline operational workflows for productivity and improved retention rates.
Note
Routing based on external schedules isn't supported in the Government Community Cloud (GCC) or sovereign clouds.
Prerequisites
- Workforce Management for Customer Service is enabled in your environment.
- Unified routing is provisioned and set up.
- Workstreams and advanced queues are set up.
- Custom assignment method is configured for the queue.
- You must have a third-party adapter configured to import agent schedules from an external system. Without an adapter in place, external schedules can't be surfaced in the agent calendar, and agents can't view their schedules in Dynamics 365 Customer Service.
- Shift-based routing is enabled.
- When you are importing external schedules using the third-party adapter, opt in every agent (bookableresource) into shift-based routing by setting the msdyn_generatecalendarfromshift column of the corresponding bookableresource entry to True.
Enable shift-based routing
- In the Customer Service admin center site map, select Workforce management under Operations.
- In the Shift based routing (preview) section, select Manage.
- On the Shift based routing (preview) page, turn on the Enable routing based on shift bookings toggle, and then select Save.
Import external schedule data
You can use a third-party adapter to import schedules from external WFM systems into Dynamics 365 for Customer Service.
Alternatively, you can also use Organization Service or Dataverse OData Web API to import agent schedules from external systems into Dynamics 365. For a detailed overview of how to import external schedules and the entities in Customer Service that can represent these external schedules, see the Schedule import integration guide.
Configure an assignment rule
- In the Customer Service admin center site map, select Queues, and then select Manage in the Advanced queues area.
- Select the queue that you want to configure the assignment rule for, select the custom assignment method, and select Edit.
- Create a rule or modify an existing rule and do the following:
In Conditions, select Add row, and then select Calendar schedule. The Is working value is automatically selected.
Save and close.
View routing diagnostics records
View the routing diagnostics record to understand how a work item is routed when routing is configured based on agent calendar attribute.
How shift-based routing works
The imported schedules from external systems are represented in Dynamics 365 as "bookings". The bookableresourcebooking entity stores this information. Each booking is assigned to an agent. The agent is represented as a bookable resource. Every agent with one or more bookings has a corresponding entry in the bookableresource entity.
An automated process synchronizes the agent's imported schedules with the agent's work hour calendar. The following rules apply for the automatic synchronization:
- After you opt in the agent for shift-based routing, the first automated sync occurs after 180 minutes to allow the external schedules to be imported for the agent.
- After the first automated sync, the agent's bookings are synchronized with their work hour calendar every 180 minutes.
- Each automated run synchronizes the agent's bookings for the next 28 days, starting from the time of the automated sync. Bookings beyond 28 days aren't synchronized.
- Any updates to the booking, including deletion of the booking, are immediately reflected in the corresponding work hour entry for the booking. For example, if the end time for a synchronized booking is updated, then the end time of the corresponding work hour calendar entry is also updated immediately. Similarly, if a synchronized booking is deleted, then the corresponding work hour calendar entry is also removed.
After the agent's bookings are synchronized with their work hour calendar, unified routing routes work items based on the work hour calendar entries.