Writing Queue Queries using the Advanced Query Editor

Add queries to queues for CxEngage to search for and route calls to resources or groups of resources. Use queries to target:

  • Specific resources or groups
  • Resources with certain skills
  • Resources with specific proficiencies or who lie within a range of proficiencies

You can build queries with resources, comparators, logical operators, and list operations.

Note: If you prefer, you can use the query builder to create your queue query. See Creating Queue Queries using the Basic Query Builder.

Building Queries

A query is made of up one or more resources. Resources are the names and values CxEngage searches for. Use these resources when you build a query:

Resource Description
id The unique system identifier for an agent, a tenant, or a resource.
groups The ID for a user group in CxEngage.
skills

The ID of a skill that has been added to CxEngage.

Proficiency The proficiency level of a skill that has been added to CxEngage with it's "Has Proficiency" setting enabled.

When you build queries, ensure that you:

  • Surround the query with curly braces ({ and })
  • Surround IDs with quotation marks

    Each skill, user, and group has a unique identifier to include in queries. See Finding Object IDs for instructions on locating user, skill, and group IDs.

  • Include a colon before the name of a resource.

Queries that find resources with a specific skill and proficiency can be restrictive. You can make your queries more flexible with comparators, logical operators, and list operations.

Using Comparators

With comparators, you can expand the scope of your queries by specifying ranges and boundaries for searches. For example, your queries can search for:

  • Values above a certain number
  • Values below a certain number
  • One of several values

If a skill has a proficiency associated with it, enter the numerical value of the skill. For example, if the proficiency is set on a scale of 1 to 100, you can enter 75 as the value. If a skill doesn't have Has Proficiency enabled, resources either have the skill or they don't. Enter the value "1" for true and "0" for false.

Use these comparators with queries:

Comparator Description
> Greater than
>= Greater than or equal to
< Less than
<= Less than or equal to
= Equal to
missing The value doesn't exist. The resource does not have the skill or isn't part of the group listed.
#{ } The value is one of the values inside the curly braces

Using Logical Operators

Logical operators let you search for resources that match a range of criteria or which match two specific criteria. Use these logical operators in your queries:

Operator Description
or One of the values must be true
and All of the values must be true

Using List Operations

With list operations, you can search for resources who match one or more of the criteria in a list of criteria. You can use these list operators with your queries:

Operation Description
some At least one element in the list is true
all All elements in the list must be true

Combining Skills and Groups in a Query

You can combine skills and groups in the same query if, for example, you want to route calls to resources with a specific skill or proficiency in a group. Additionally, you can add multiple skills with different proficiency criteria to a query.

Note: The value "1" can either mean:

  • The resource's proficiency level is "1" if Has Proficiencyis enabled on the skill
  • The resource has the skill if there if Has Proficiencyis not enabled on it.

You might also be interested in