Skip to contentSkip to navigationSkip to topbar
Rate this page:
On this page

Queued Callback and Voicemail (Flex UI 1.x.x)


(information)

Info

Pre-built Queued Callback and Voicemail plugin is available in Flex UI 2.x.x
This guide is only for Flex UI 1.x.x. If you have Flex UI 2.x.x, install the ready-to-use Queued Callback and Voicemail(link takes you to an external page) plugin. You must be logged in to Twilio console to access the Flex Plugin Library.


Overview

overview page anchor
(warning)

Warning

This solution features sample code that is provided "as is" and is not production grade. The featured code does not account for edge case handling, scalability, and reliability. It is not covered under Twilio's Service Level Agreement (SLA)(link takes you to an external page) and support plans(link takes you to an external page).

(warning)

Warning

This solution supports Flex applications that can handle up to 1 call per second. We do not recommend this solution if your contact center exceeds that limit as you will run into API limits enforced by TaskRouter.

The Queued Callback and Voicemail for Flex solution helps Flex admins automate handling of agent callback requests from customers instead of having them wait longer in a queue. In this solution, the customer hears the callback menu options as soon as they call the number provisioned on your Flex application. Your contact center agents will receive the details including the requested callback number, and a localized time for the customer's inbound call.

The call is on hold for the period of time that you've configured within queue-menu.protected.js(link takes you to an external page). When the time period expires, it will go on and route according to the workflow configuration.


User leaving a voicemail message or requesting a callback from an agent

vm-or-callback-request.npm -v in your terminal to check)
  • A Node.js long-term-support (LTS) version(link takes you to an external page) installed, 14 recommended (type node -v in your terminal to check)
  • Native Dialpad configured on your Flex application
  • Twilio CLI along with the Flex CLI Plugin and the Serverless Plugin. Run the following commands to install them:


    _10
    # Install the Twilio CLI
    _10
    npm install twilio-cli@2.0 -g
    _10
    # Install the Serverless and Flex as Plugins
    _10
    twilio plugins:install @twilio-labs/plugin-serverless
    _10
    twilio plugins:install @twilio-labs/plugin-flex

  • (information)

    Info

    If you're running Linux, click on the Linux tab for the Twilio CLI installation instructions. If you're running Windows, make sure to run the Windows command prompt as an administrator to install the Serverles/Flex plugins for the Twilio CLI. The Windows commands in this guide use PowerShell (for Node.js/npm installation).

    (information)

    Info

    To provision Twilio resources and deploy this solution using a script, skip to the download step. After installing the dependencies, run node provision and follow the instructions.

    Make sure to activate the correct Twilio account before deploying the Flex plugin.

    After the script is complete, enable the plugin on your Flex application.


    30-45 minutes


    Tested Flex Versions and Operating Systems

    tested-flex-versions-and-operating-systems page anchor
    • Flex v1.18.1 - 1.30.1
    • macOS / Unix
    • Windows 10

    Configure your Flex Workspace

    configure-your-flex-workspace page anchor

    In order to use the solution, you need to prepare your Flex Task Assignment workspace.

    Retrieve your Flex settings

    retrieve-your-flex-settings page anchor

    Step 1

    step-1 page anchor

    Navigate to your Flex project in the Twilio Console(link takes you to an external page). Copy your ACCOUNT SID and AUTH TOKEN, and create a new Twilio CLI profile using those credentials:


    _10
    twilio profiles:create

    You will be prompted to enter your Twilio Account SID, Auth Token, and a shorthand identifier for your profile. When choosing a shorthand identifier, pick one that is meaningful and easy to remember. Once your profile has been created, activate it by running:


    _10
    twilio profiles:use PROFILE_ID

    Keep in mind that this account will be used for the rest of the deployment. In order to switch accounts, use the following command:


    _10
    twilio profiles:use DIFFERENT_PROFILE_ID

    Retrieve your Flex Task Assignment workspace ID:


    _10
    twilio api:taskrouter:v1:workspaces:list

    Example Workspace SID


    _10
    SID Friendly Name Prioritize Queue Order
    _10
    WSXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX Flex Task Assignment FIFO

    To retrieve your Flex workspace SID from the Twilio Console, navigate to the TaskRouter Dashboard.

    In the Twilio Console, select your Flex project and navigate to All Products & Services > TaskRouter > Workspaces > Flex Task Assignment > Task Channels. Create two task channels: one for callback and one for voicemail, so you can route the associated tasks to available agents.

    Two task channels- callback and voicemail.Rate this page:

    Need some help?

    Terms of service

    Copyright © 2024 Twilio Inc.