Zack_Pemberton | 2019-09-30 17:47:53 UTC | #1
I am wanting to write some information directly into the interaction notes. I'm assuming the best way to accomplish this would be with a custom script when the call in picked up. I cannot find a way to write anything to the interaction notes specifically via scripting. I am pulling all of the data I need through the IVR, but I need that variable to transfer to the interaction notes. Any help would be appreciated.
anon28066628 | 2019-09-30 18:08:13 UTC | #2
Hi Zack, it's possible to PATCH a conversation and add a wrap-up note via a data action. The wrap-up code is also required.
PATCH /api/v2/conversations/{conversationId}/participants/{participantId}
However you'd need to have the Agent's participant ID, so you may need another data action to get that first (since the Agent participant will not exist while the call is still in the IVR).
Also be aware that the Agent can overwrite the code and note during their after-call work. The note is intended to be applied as a last step as the Agent wraps up the conversation.
Zack_Pemberton | 2019-10-01 15:26:23 UTC | #3
Thank you for the response. Got me in the right direction. When attempting to gather the participantid from the GETconversation, I am receiving 4 different id's within participants. Is there an easy way to only return the first id?
anon28066628 | 2019-10-01 15:44:48 UTC | #4
Hi Zack, this expression in a translationMap should get the Agent participant's ID:
$..participants[?(@.purpose=="agent")].id
There's a nice JsonPath testing tool helpful with manipulating responses here: http://jsonpath.com/. It seems a little buggy, so be liberal with refresh...
system | 2019-11-01 15:44:54 UTC | #5
This topic was automatically closed 31 days after the last reply. New replies are no longer allowed.
This post was migrated from the old Developer Forum.
ref: 6142