Menu

Getting Started with TaskRouter

TaskRouter is an attributes-based routing system for your Flex contact center. TaskRouter uses Tasks to represent a unit of work that needs to be completed across your configured communication channels and provides a set of tools to allow you to intelligently route a task to the agent best suited to handle it.

A diagram showing a task moving through the TaskRouter lifecycle

TaskRouter includes a variety of objects, including Workflows, which are human readable definitions of your routing logic, and Task Queues, which represent key segments of agents. All of these moving parts come together to offer you customizability and scalability for your routing rules.

How Flex Uses Tasks

Flex uses Tasks to power many parts of your contact center, including:

Upleveling Agent Experience with Task Attributes
You can dynamically expose task data in the Flex UI. This helps to ensure that your agents have context for the work they’re doing, and even allows you to change the look, feel and features of the Flex UI depending on the current Task.

Task Channels
By default, TaskRouter understands that you’ll create tasks for sms and voice. You can also define custom channels, like WhatsApp, Facebook Messenger, or Web Chat. You can route tasks based on their channels, and render the channel to the Agent in the Flex UI.

Analytics
As TaskRouter works, it generates a stream of valuable events and statistics about agent activity, task volume, and more. Flex can consume this Task data as the basis for workforce management in your contact center with Flex Insights.

Key Differences

TaskRouter for Flex differs from a vanilla TaskRouter implementation in the following ways:

Allows One Workspace
You’re limited to one workspace when using Flex. For majority contact centers, a single workspace is all you need, but you can work with your Twilio team to understand if this might be a limitation for you.

Uses the v2 SDK
Flex currently uses the v2 Flex SDK in order to support features like transfers. The v2 SDK is currently documented on Github.

Diving In

Now that you know a little bit about TaskRouter, why not try:

Rate this page:

Need some help?

We all do sometimes; code is hard. Get help now from our support team, or lean on the wisdom of the crowd browsing the Twilio tag on Stack Overflow.

Thank you for your feedback!

We are always striving to improve our documentation quality, and your feedback is valuable to us. How could this documentation serve you better?

Sending your feedback...
🎉 Thank you for your feedback!
Something went wrong. Please try again.

Thanks for your feedback!

Refer us and get $10 in 3 simple steps!

Step 1

Get link

Get a free personal referral link here

Step 2

Give $10

Your user signs up and upgrade using link

Step 3

Get $10

1,250 free SMSes
OR 1,000 free voice mins
OR 12,000 chats
OR more