SUPPORT.TWILIO.COM END OF LIFE NOTICE: This site, support.twilio.com, is scheduled to go End of Life on February 27, 2024. All Twilio Support content has been migrated to help.twilio.com, where you can continue to find helpful Support articles, API docs, and Twilio blog content, and escalate your issues to our Support team. We encourage you to update your bookmarks and begin using the new site today for all your Twilio Support needs.

What Is a Twilio TaskRouter Worker Expression and How Is It Used?

Question

What is a target expression in Flex and TaskRouter?

 

Product

Twilio Flex, TaskRouter

 

Answer

Twilio Flex and TaskRouter uses a SQL-like expression syntax for binding Workers to TaskQueues and filtering Tasks into TaskQueues in a Workflow configuration. Expressions are composed of constants, JSON keys, as well as logical and comparison operators.

For example, a TaskQueue TargetWorkers expression looks like:

(skills HAS 'support') AND (languages HAS 'english')

And a Workflow filter expression looks like:

customer_value == 'Gold' AND type == 'ticket'

 

Additional Information

Have more questions? Submit a request
Powered by Zendesk