ScottBub | 2017-01-19 21:36:19 UTC | #1
We would like to pop a screen for an agent receiving a call. We would like for a Notes box to pop up that allow the agent to type in the notes and click save. Once saved, the notes would get sent through an integration to a MS SQL Database and update a specific record. In this case, it would be a Service Order # that was entered earlier in the call flow that routed the call to an agent.
My question is: Can a screen be popped for an agent that displays a box for them to enter details and after clicking save, it sends those details through the data dip connector updating a database that is on the company network?
OR
Can we just pop up the record in the database for the agent in Pure Cloud for them to enter the notes into?
Basically, I want to know if we can pop a screen in Pure Cloud in any fashion that will get the data entered into the database?
Please help!
tim.smith | 2017-01-20 17:06:06 UTC | #2
I'll break this down into two parts:
Agent UI
Currently, you will have to provide the UI to the agent outside of the PureCloud app. This could be in the form of a browser extension, open a new tab in the browser to your page, a desktop app, or whatever mode fits your environment. Your app will need to authenticate the user via an OAuth flow to obtain an auth token.
The app should use Notifications to recieve events for the user's conversations. This will provide the necessary data and timing to allow the app to know when to prompt the user and provide contextual data about the conversation.
There is an upcoming addin API that will allow you to add UI elements to the PureCloud UI (via an iframe), which will simplify this type of integration significantly. I don't have an ETA on the release, but it is in progress.
Storing data
Once your application has collected data, there are two things you could do with it:
- Store the data completely out of band of PureCloud - You can build whatever you need into your app to interface with your database and write records.
- Store the data to the PureCloud conversation to be retrieved later. Use PATCH /api/v2/conversations/{conversationId}/participants/{participantId}/attributes to set custom data from your app on the participant. At a later time, you can retrieve participant data from the conversation using GET /api/v2/conversations/{conversationId} and could sync it to your local database.
tim.smith | 2017-01-20 19:29:52 UTC | #3
@ScottBub Additionally, I think you could use an inbound script to <strike>write the data to participant attributes or</strike> (jumped the gun, feature will be released soon) use a bridge action, which could negate the need for an external UI. Check out this Resource Center article on the subject: https://help.mypurecloud.com/articles/advanced-lesson-create-a-screen-pop-script-and-add-it-to-a-call-flow/
There are some actions that might be useful:
ScottBub | 2017-01-20 19:43:32 UTC | #4
Thanks, Tim.
Is there a way that I can mark this as best answer or did I not submit it correctly?
I have reviewed the information in the latest response and it seems to me that you are saying that when the script pops up in PureCloud we can create a custom connector action and write in our web service some sort of DB execute that takes the data Pure Cloud gathered from the pop up and instead of performing a query like the connector thinks it would, perform an update to the DB instead.
We would tie this together using a bridge action inside of a call flow after the pop up is saved to trigger the connector action we created. Is all of that correct?
tim.smith | 2017-01-20 20:09:48 UTC | #5
ScottBub, post:4, topic:816
Is there a way that I can mark this as best answer or did I not submit it correctly?
The forum doesn't currently have a feature to mark posts as answers/correct.
ScottBub, post:4, topic:816
Is all of that correct?
Yep, looks right. Collect data in the script and send it to a bridge action at an appropriate time (button press or something).
ScottBub | 2017-01-20 20:14:14 UTC | #6
Awesome! Thanks for the help.
system | 2017-08-28 19:30:50 UTC | #7
This post was migrated from the old Developer Forum.
ref: 816