Invoke the MatchingRuleProcessor API
task brazil Updated Sep 10, 2026 1 min read t_InvokeMatchingRuleAPI.md
After you create one or more matching rules, you can invoke the MatchingRuleProcessor API and run the rules.
Before you begin
Role required: sn_customerservice_agent, sn_customerservice_manager, admin
Procedure
-
You can invoke the matching engine using the processAndGetCandidates method of the matchingRuleProcessor class.
Pass in the task record and the number of resources. The result is an array of resource sys_ids.
-
The system processes the matching rules based on the number stored in the Execution Order field for each rule.
The result is a list of users (sys_ids), which you can use for case routing and assignment.
32 lines · 1.2 KB
---
title: Invoke the MatchingRuleProcessor API
description: After you create one or more matching rules, you can invoke the MatchingRuleProcessor API and run the rules.
locale: en-US
canonical_url: https://www.servicenow.com/docs/r/customer-service-management/t\_InvokeMatchingRuleAPI.html
release: brazil
topic_type: task
last_updated: "2026-09-10"
reading_time_minutes: 1
breadcrumb: [Configure case routing and assignment, Route and assign cases, Configure case management, Case management, Organize agent workspaces, Configure, Customer Service Management]
---
# Invoke the MatchingRuleProcessor API
After you create one or more matching rules, you can invoke the MatchingRuleProcessor API and run the rules.
## Before you begin
Role required: sn\_customerservice\_agent, sn\_customerservice\_manager, admin
## Procedure
- You can invoke the matching engine using the processAndGetCandidates method of the matchingRuleProcessor class.
Pass in the task record and the number of resources. The result is an array of resource sys\_ids.
- The system processes the matching rules based on the number stored in the **Execution Order** field for each rule.
The result is a list of users \(sys\_ids\), which you can use for case routing and assignment.
| title | Invoke the MatchingRuleProcessor API |
| description | After you create one or more matching rules, you can invoke the MatchingRuleProcessor API and run the rules. |
| locale | en-US |
| canonical_url | https://www.servicenow.com/docs/r/customer-service-management/t\_InvokeMatchingRuleAPI.html |
| release | brazil |
| topic_type | task |
| last_updated | 2026-09-10 |
| reading_time_minutes | 1 |
| breadcrumb | Configure case routing and assignmentRoute and assign casesConfigure case managementCase managementOrganize agent workspacesConfigureCustomer Service Management |