vernig / outbound-messaging-iac

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Setup

  1. Install Twilio CLI following these instructions
  2. Install the Infra Plugin for Twilio CLI
$ twilio plugins:install plugin-twilio-infra
  1. Download and Install the Pulumi CLI
  2. Login in to the Pulumi service. You can either use the Pulumi service backend (you need to sign up to a free account for that) or the local storage, using one of the commands below:
# Pulumi Service backend
$ pulumi login

# Local storage
$ pulumi login --local
  1. If you've never used the Twilio CLI with this project, create a new profile with
$ twilio login
  1. Login to the project using
$ twilio profile:use <profile name>
  1. Add the following environment variables:
  • CHAT_SERVICE_SID
  • FLEX_WORKSPACE_SID
  • SMS_TASK_CHANNEL_SID
  • EVERYONE_TASK_QUEUE_SID
  • TWILIO_PHONE_NUMBER
  • FLEX_PROXY_SERVICE_SID
  1. If you don't have an environment defined, use the following command
$ twilio infra:environment:new <environment name>
  1. Deploy the solution using:
$ TWILIO_AUTH_TOKEN=xxxxxx twilio infra:deploy
  1. In the Twilio Console Settings page for Flex make sure that the "Enable Dialpad" is Enabled

Usage

  1. In Flex click the dialpad button (next to the microhpne on the top right corner). At the bottom of the dialpad you will find the "Outbound SMS" section.
  2. Type the destination number and press on START
  3. A new Task / Reservation is generated: Click the accpet button to accept and start chatting

About

License:MIT License


Languages

Language:JavaScript 69.2%Language:TypeScript 22.6%Language:HTML 8.0%Language:Shell 0.2%