Proactive SMS to customers

From PegaWiki
Add 2 GB Data case implementation- Proactive SMS to customers / This is the approved revision of this page, as well as being the most recent.
Jump to navigation Jump to search

Add 2 GB Data case implementation- Proactive SMS to customers

Description To enable clients to trigger SMS to customers proactively using Twilio account.
Version as of 8.7
Application Pega Foundation for Communications
Capability/Industry Area Communications and Media



Enter your topic description[edit]

This article covers the configuration and usage of the implementation for proactively sending SMS to customers on business conditions and help the clients to inform/advertise their products to the designated customers.

The implementation is done on the Pega Customer service Communications as part of Self service application shipped as "Add 2 GB data" case.

This is a use case suitable for scenarios involving sending an SMS to selected customers by the clients proactively-post checking client imposed, configurable business conditions.

Use case examples[edit]

Customers of Communications client, when exhausted, at least of 80% of their internet pack and having at least of 10+ more days of validity, will receive SMS from the client proactively encouraging them to utilize a top-up of 2GB data to be added to their usage for seamless experience, aiming for better customer satisfaction.

Before you begin[edit]

Following are the key factors to note while using this use case:

  • The environment should be a DMZ enabled server.
  • Sample DML is to be added.
  • Twilio account should be acquired for sending the SMS from.

High level process and design:[edit]

HLD PSMS.png
  1. .csv file is placed in the location is picked up by the file listener. As per the current implementation, it is set to '/tmp' folder.
  2. File listener will consider each line in .csv file as a record and would delimit the contents of the line and queue it to the queue processor.
  3. Queue processor will invoke Data transform “EvaluateSmsResponse” which constructs the customer data and the account data of the designated customer using the phone number of the customer which are needed for sending the appropriate SMS.
  4. The initial SMS is sent to the customer via Twilio API to the customer number.
  5. Customer, if interested, would respond back to the initial SMS with valid options available. (Buy, Add Plan, Usage, Help)
  6. DM channel “Add 2GB Data” which is configured on the same Twilio account, would listen to the SMS response from the customer and would do the following:
    • For Add/Help/Usage/Plan: Would reuse and hit Data transform “EvaluateSmsResponse” to construct the customer and account related data.
    • For Buy: An “Add2GBData” case is created.
  7. Pega Platform constructs the corresponding SMS reply to the customer by constructing the customer context and the account context.
  8. Relevant SMS as per the response of the customer is sent out to the customer via Digital messaging channel.
  9. Customer receives the constructed SMS on the details requested as per communication.
  10. Steps 8 and 9 are repeated as needed/as per the SMS replies sent by customer.

Process/Steps to achieve objective[edit]

The "Add 2GB Data" use case is implemented by considering .csv file as an input file containing the list of customers who are considered for sending the SMS. The same can be further extended to utilize SOR or any other Integrations as per the requirement.

Below is the configurational aspects that are to be covered for the proper functionality of Add 2GB data case:

  • Configure the Manager Key and ID of the environment in the Application definition of "PegaCSCSelfService" under the security tab.
PSMS AD Security Key.png
  • Validate the business conditions imposed on sending the initial SMS (proactive) to customers under configuration settings in App studio, as under:
PSMS configset.png
  • The number acquired from Twilio is to be setup in the filed value : ProactiveSMSFromNumber with the country code included.
PSMS PhoneNumber.png
  • Authentication profile "ProactiveSMS" is to be configured with the right Authentication ID and key values received from Twilio.
PSMS AuthenticationProfile.png
  • Ensure your File listener is configured correctly as shown below. By default, the listener is set to listen on '/tmp/' folder.
PSMS FileListener.png
  • Validate if the file listener is running on the server by switching to Admin studio under the Listener section inside the "Resources" pane.
PSMS FileListener2.png
  • Resource path of Connect Rest "ProactiveSMS" is to be updated with the authentication ID received from Twilio as shown under.
PSMS ConnectREST.png
  • Ensure the queue processor "InitiateSmsToCustomers" is active and running.
  • Ensure the System runtime context contains application "PegaCSCSelfService" of 8.7 is present as shown under.
PSMS SysRunTimeContext.png
  • Ensure that the "ProactiveSMS" file listener is active and running.
  • Configure the Twilio setup under "Add 2GB Data" digital messaging channel by clicking "Manage connections" under connections tab under channels and interfaces component of "PegaCSCSelfService" application as shown in series of snapshots below: (Please note that the snapshots are from v-8.7 and might vary on versions being implemented on)
PSMS DM 2.png
PSMS DM 3.png
PSMS DM 4.png
  • Do note the Webhook URL which should reflect same as Manager key's and ID of the Application.
PSMS DM 5.png
  • Add the country codes which are supported for receiving the response from customers to the corresponding Twilio number.
PSMS DM 6.png
  • The Number reflects when added successfully in the Connections tab of the Channel.

Limitations:

  • A case gets created only when the customer responds with "Buy" in the current OOTB implementation.
  • The initial SMS sent via Twilio API is not saved as part of the conversation, if case gets created. The rest of the interactions between customers is captured as part of the conversation history.

Results[edit]

The SMS conversation can be initiated between client and customers via SMS channel.