Notify Outbound Calls Through Twilio - Identify the Originating Task from Call Workflow/Record?

Ben Vargas
Tera Guru

I am looking to enhance the ServiceNow "On-Call: Assign by Acknowledgement" workflow to also support calling the on-call individual's sms phone if they've so opted in their profile; the thought being it would read them the task short description and then prompt "1 to acknowledge or 2 to reject".

I have used the "Call" Workflow Activity provided by Notify and the workflow does trigger a call to the on-call's phone and successfully says "Hello World" via the workflow triggered by the 'Outgoing call workflow' on the number group. It appears that while the workflow runs, the notify_call record corresponding to the call is what is in scope as current, but there is no "source" field as there is with notify messages (notify_message).

So, has anyone solved for how to determine (and use data from) the task record from which the call was triggered? Right now I see no way of reading the contents of the task that triggered the call, or even knowing which task to acknowledge or reject when prompting the user for input.

ServiceNow 2017-03-31 09-44-32.jpg

ServiceNow 2017-03-31 09-46-01.jpg

1 ACCEPTED SOLUTION

Ben Vargas
Tera Guru

The HI Support INC has made it's way through Support and up to the dev team who advised that this is a platform limitation and would require an enhancement request... we will simply have to offer a generic "wake-up call" that a user has an SMS they need to respond to, but not actually gather accept/reject via the phone call.



Definitely unfortunate, these java libraries should be developed with similar capabilities... as of now Notify can't quite compete with PagerDuty or xMatters in terms of call processing/smarts as even though we have workflow control on calls, there is no link to the task that created it.



Details on the case...



We reviewed your use case with the on-call development team and they have provided us the answers . That is , 'call' activity definition in the workflow which creates notify_call record in the java layer does not have source column field defined . So , it is not populated . This seems to be an product enhancement .



I am still checking with the notify team if there is any workaround . I will update you , as soon as i hear from them .




On - Call Schedule Dev team's reply :



-------------------------------------------------



Firstly "notify_call" table doesn't have the column "source" to point back to the task that created this call record.



seems like the issue is not with the on-call workflow but the activity it is using "Call Escalatee" which internally using the Activity definition "call".



on-call workflow is just using the "call" activity definition to initiate the call which internally creates notify_call records.



upon digging into the source code found that in NotifyDatabase.java



addMessageRecord() - is used to create notify_message records and have "source" as a parameter.



addCallRecord() - is used to create notify_call records and doesn't have any "source" as a parameter.



I don't think issue is with the workflow but with the activity definition.


View solution in original post

17 REPLIES 17

Indeed... ran into the wall so decided to cry out for help to HI and Community. I have a hi ticket open pending update, will keep this updated with the outcome! I fear enhancement request will be required to have SNC.Notify().call() populate a reference field on notify_call similar to notify_message.



Thanks for the time and attempt!


Thanks. That's the beauty of investing time on community. I got to learn this use case which I didn't know before.


Good luck with the solution


Ben Vargas
Tera Guru

The HI Support INC has made it's way through Support and up to the dev team who advised that this is a platform limitation and would require an enhancement request... we will simply have to offer a generic "wake-up call" that a user has an SMS they need to respond to, but not actually gather accept/reject via the phone call.



Definitely unfortunate, these java libraries should be developed with similar capabilities... as of now Notify can't quite compete with PagerDuty or xMatters in terms of call processing/smarts as even though we have workflow control on calls, there is no link to the task that created it.



Details on the case...



We reviewed your use case with the on-call development team and they have provided us the answers . That is , 'call' activity definition in the workflow which creates notify_call record in the java layer does not have source column field defined . So , it is not populated . This seems to be an product enhancement .



I am still checking with the notify team if there is any workaround . I will update you , as soon as i hear from them .




On - Call Schedule Dev team's reply :



-------------------------------------------------



Firstly "notify_call" table doesn't have the column "source" to point back to the task that created this call record.



seems like the issue is not with the on-call workflow but the activity it is using "Call Escalatee" which internally using the Activity definition "call".



on-call workflow is just using the "call" activity definition to initiate the call which internally creates notify_call records.



upon digging into the source code found that in NotifyDatabase.java



addMessageRecord() - is used to create notify_message records and have "source" as a parameter.



addCallRecord() - is used to create notify_call records and doesn't have any "source" as a parameter.



I don't think issue is with the workflow but with the activity definition.


So on the notify_call table you have client and client table, you will fill those fields out with sys_id and table for the source. I don't get how the sendSMS you can tie in a source but call you can't.   I am having the same issue as you in trying to tie a call to a gliderecord so I can trigger the correct workflow.


andrewcobbold
Tera Contributor

Did anyone every solve this? I am also trying to use the notify workflow activities to send a voice call to someone's phone and have them accept or reject using a 1 or 2 on the key pad.