This Flex plugin adds a feature to apply multiple skills to multiple agents at the same time using textual or query searches to select the agents:
- Textual: type the name directly
- Query: use
data.
notation to search for any information related to workers such asattributes
. For example, let's say you have an attribute calledteam
and you want to select all workers withteam
equal to "Leads":data.attributes.team == "Leads"
. As this notation is the same used in Flex Sync Live Query, please refer to this documentation for more details.
You will need the Twilio CLI and the serverless plugin to deploy the functions inside the serverless
folder of this project. You can install the necessary dependencies with the following commands:
npm install twilio-cli -g
and then
twilio plugins:install @twilio-labs/plugin-serverless
-
Setup all dependency above: Twilio CLI
-
Clone this repository
-
Copy ./serverless/.env.example to ./serverless/.env and populate the appropriate environment variables.
-
cd into ./serverless/ then run
npm install
and thentwilio serverless:deploy
(optionally you can run locally withtwilio serverless:start --ngrok=""
-
Copy .env.example to .env.development and to .env.production and set the following variables:
- REACT_APP_SERVICE_BASE_URL: your Twilio Functions base url (this will be available after you deploy your functions). In local development environment, it could be your localhost base url.
-
Copy
public/appConfig.example.js
topublic/appConfig.js
-
Run
npm install
-
cd back to the root folder and run
npm start
to run locally ornpm run-script build
and deploy the generated ./build/plugin-dialpad.js to twilio assests to include plugin with hosted Flex. Also, you want to use Twilio Serverless, just runnpm run deploy
to send your plugin directly to your Flex.
Note: as the bulk update is updating many workers at the same time, for large lists of workers, it is possible to hit API limits. To handle that, you can change the worker-bulk-update
implementing some strategy to send the requests with some timeout between them.