Why the QueueRoutingConfig Metadata Type Is the Brain of Omni-Channel
When an incoming Case, MessagingSession, or Lead enters an Omni-Channel Queue (or is routed via an Omni-Channel Flow), QueueRoutingConfig (queueRoutingConfigs/<Name>.queueRoutingConfig-meta.xml) determines:
- Queue Priority (
routingPriority): Lower numbers (1vs5) are pushed to agents first across competing queues. - Agent Selection Algorithm (
routingModel):LEAST_ACTIVE,MOST_AVAILABLE, orEXTERNAL_ROUTING. - Work Item Size (
capacityWeightvs.capacityPercentage): How much of an agent’s capacity (defined in PresenceUserConfig) one work item consumes—including separatepausedCapacityWeight(API v64.0+) when status-based work is paused. - Push Timeouts & Skill Fallback (
pushTimeout,dropAdditionalSkillsTimeout): How long an agent’s widget rings before re-routing, and when optional skills are dropped so work doesn’t stall.
Key Metadata Fields on QueueRoutingConfig
| Field | Type | Required | Description |
|---|---|---|---|
label |
string |
Yes | Display name of the routing configuration in Setup. |
routingModel |
RoutingModel |
Yes | LEAST_ACTIVE, MOST_AVAILABLE, or EXTERNAL_ROUTING. |
routingPriority |
int |
Yes | Priority integer (1 is highest priority). Items from priority 1 queues always route before priority 2. |
capacityWeight |
double |
Conditional | Exact unit capacity consumed by each work item (mutually exclusive with capacityPercentage). |
capacityPercentage |
double |
Conditional | Percentage (0–100) of an agent’s capacity consumed by each work item. |
pausedCapacityWeight |
double |
No | (API v64.0+) Capacity units consumed while a status-based work item is in a PAUSED state. |
pushTimeout |
int |
No | Seconds before an unanswered push offer is recalled from the agent and routed to the next available agent. |
isAttributeBased |
boolean |
No | Enables Skills-Based Routing rules (SkillMappingConfig) for this routing config. |
dropAdditionalSkillsTimeout |
int |
No | Seconds before additional (non-mandatory) skills are dropped so any core-skilled agent can take the work item. |
isInterruptible |
boolean |
No | (API v57.0+) Marks work items from this config as interruptible by real-time channels like Voice or Chat. |
Real-World XML Example (queueRoutingConfigs/VIP_Case_Routing.queueRoutingConfig-meta.xml)
<?xml version="1.0" encoding="UTF-8"?>
<QueueRoutingConfig xmlns="http://soap.sforce.com/2006/04/metadata">
<capacityWeight>2.0</capacityWeight>
<dropAdditionalSkillsTimeout>120</dropAdditionalSkillsTimeout>
<isAttributeBased>false</isAttributeBased>
<isInterruptible>true</isInterruptible>
<label>VIP Case Routing</label>
<pausedCapacityWeight>0.5</pausedCapacityWeight>
<pushTimeout>45</pushTimeout>
<routingModel>MOST_AVAILABLE</routingModel>
<routingPriority>1</routingPriority>
</QueueRoutingConfig>Querying QueueRoutingConfig and Linked Queues via SOQL
You can query QueueRoutingConfig in standard SOQL and join it to Group (Type = 'Queue') to audit your entire Omni-Channel routing matrix.
1. Audit All Omni-Channel Routing Configurations by Priority
SELECT Id, DeveloperName, MasterLabel, RoutingPriority, RoutingModel,
CapacityWeight, CapacityPercentage, PushTimeout, DropAdditionalSkillsTimeout
FROM QueueRoutingConfig
ORDER BY RoutingPriority ASC, DeveloperName ASC2. Find Which Queues Use Each QueueRoutingConfig
SELECT Id, Name, DeveloperName, QueueRoutingConfigId
FROM Group
WHERE Type = 'Queue'
AND QueueRoutingConfigId != null
ORDER BY Name ASCSenior Architect Best Practices
- Link
QueueRoutingConfigInside YourQueueMetadata: AQueueRoutingConfigdoes nothing on its own until it is referenced by<queueRoutingConfig>VIP_Case_Routing</queueRoutingConfig>inside a Queue metadata file or selected in an Omni-Channel FlowRoute Workaction. Always deployQueueRoutingConfigbefore (or alongside)Queue. - Use
MOST_AVAILABLEWhen Mixing Part-Time and Senior Agents: If senior agents have a total capacity of10and junior agents have a capacity of4,LEAST_ACTIVEwill keep routing to a junior agent with2active items over a senior agent with3active items.MOST_AVAILABLEroutes to the senior agent (7free units vs.2free units).
Frequently asked questions
What is the difference between Least Active and Most Available routingModel in QueueRoutingConfig?
LEAST_ACTIVE routes the incoming work item to the agent holding the lowest total amount of consumed capacity, whereas MOST_AVAILABLE routes the work item to the agent with the largest remaining unused capacity (Configured Capacity minus Consumed Capacity).
Can you set both capacityWeight and capacityPercentage on the same QueueRoutingConfig?
No. A QueueRoutingConfig must specify either capacityWeight (exact unit weight consumed per work item) or capacityPercentage (percentage of the agent's total capacity consumed), never both.
What does dropAdditionalSkillsTimeout do in a QueueRoutingConfig?
When using skills-based routing with skills marked as additional, dropAdditionalSkillsTimeout specifies the number of seconds Omni-Channel waits for an agent with all skills before dropping additional skills to expand the eligible agent pool.
How do you query QueueRoutingConfig records using SOQL?
You can query the QueueRoutingConfig standard object in SOQL to inspect DeveloperName, MasterLabel, RoutingModel, RoutingPriority, CapacityWeight, CapacityPercentage, and PushTimeout.
Comments
Questions, corrections and tips are welcome. Comments are GitHub Discussions, so you sign in with GitHub.