Question
Serialized Solutions Inc
CA
Last activity: 28 Sep 2017 20:59 EDT
SMS Chatbot: Auditing all incoming SMS requests
Hi,
I have gotten the SMS Virtual Assistant/Chatbot up and running with the initial minimum prototype.
One thing I have not figured out or found is how to audit all incoming requests so that I can keep track of, for say, future chatbot enhancements by reviewing and keeping track of all SMS interactions and/or posts.
Does anyone know how to audit all requests, what was sent via SMS and whom sent it?
thank you,
Rob
-
Like (0)
-
Share this page Facebook Twitter LinkedIn Email Copying... Copied!
Accepted Solution
Pegasystems Inc.
US
Hi Rob,
I am doing something similar for the Facebook Channel where when the user request comes in, I use their Page scoped ID to lookup their name via the Facebook API. A record is then created in a data table with the user data that is returned from the FB API (Name, Locale, etc. ) using the Page Scoped ID as the key. When subsequent requests come in, I perform a lookup on the incoming request Page Scoped ID and see if we have any profile data for that ID. If we do, we can use that data to personalize the message. In your case, I would use the incoming message Phone number as the key in a data table and map any user data that is collected to this record. Let me know if you need any other clarification regarding this.
Thanks,
-Skye
Serialized Solutions Inc
CA
#HelpMe
I can't be the only one doing this prototype!
-
Sreeja Boorla
Pegasystems Inc.
US
Hi Rob, You should be able to look at the class
Work-Channel-Interaction-Tropo-SMS to see the conversation history and meta data. It might be easiest/most efficient to write a report against this class that gets you precisely what you want.
Serialized Solutions Inc
CA
Hi LAKEM
thank you for the response. Thank you for the class and the suggestion to see history and meta data. That definitely works for historical data, but what if I wanted to have personalized responses via the case management flow based on whom initiated the response.
I.e. the first SMS I send to system, the system could ask for first name. I would respond Rob.
the second conversation I send (granted, from same cellphone), the system could respond with welcome back Rob, and then the conversation could continue.
Is this a feasible scenario/use case or am I thinking through this conversational piece too specific?
Rob
Accepted Solution
Pegasystems Inc.
US
Hi Rob,
I am doing something similar for the Facebook Channel where when the user request comes in, I use their Page scoped ID to lookup their name via the Facebook API. A record is then created in a data table with the user data that is returned from the FB API (Name, Locale, etc. ) using the Page Scoped ID as the key. When subsequent requests come in, I perform a lookup on the incoming request Page Scoped ID and see if we have any profile data for that ID. If we do, we can use that data to personalize the message. In your case, I would use the incoming message Phone number as the key in a data table and map any user data that is collected to this record. Let me know if you need any other clarification regarding this.
Thanks,
-Skye
Serialized Solutions Inc
CA
Hi perrs
thank you for your response. I understand what you mean. Just one clarity question, by Page Scoped ID, are you referring to the interaction definition Page that Pega creates as part of the interaction (in my example, the interaction scoped page -- as Lakem pointed out -- Work-Channel-Interaction-Tropo-SMS , which has my phone number/interaction that used as a part of the interaction)
Rob
Pegasystems Inc.
US
Rob, The page scoped ID is specific to the Facebook channel and is the value that is used as the operator ID when someone interacts with that channel. You're correct - In the case of Tropo, the phone number is used as the operator ID and this is what you'll want to use as the key for your user records. you can access your operator ID (phone number in your case) at any point in the process, by referencing the page OperatorID ( of class Data-Admin-Operator-ID ) in your pages and classes and referencing property OperatorID.pyUserIdentifier.
-Skye