jcp | 2018-02-19 12:07:19 UTC | #1
Hi,
What are the options to get SIP Headers into Architect. I need to pass some custom data into Architect which is provided through the SIP Invite header. The only possibility I can find is UUID which appears to be for Outbound flows. In the following there is reference to PURE-1138: SIP Header Information Available in API? Is this something that would allow passing a custom field into Architect ?
The only option I have seen for the moment is to modify the optional 'From Display' which is sent with the From URI in the SIP INVITE. However this will then be displayed in Queues Activities and general interactions (on Agent screen or Historical Interaction views).
Any idea welcome ?
tim.smith | 2018-02-20 15:06:53 UTC | #2
https://help.mypurecloud.com/articles/set-uui-data-action/
The built-in, read-only Call.UUIData variable is a string type and allows you to read UUI data that enters the call flow.
jcp | 2018-02-21 18:19:59 UTC | #3
Hi Tim, This seems to be UUI info to pass on outbound from Edge to another device of from call flow to call flow. The particular thing I am trying to get is some data defined in the SIP INVITE header, which can be picked-up in Architect.
example: Outbound calls will have the additional header: x-inin-cnv: bde34db0-9759-4933-8a55-450029050625 populated with the PureCloud ConversationId
I have populated the User-to-User field in the SIP Header, on an incomming call. It is showing in the Edge SIP logs, but not displayed in Architect Call.CallUUID Is there some possible to get the Call.CallUUID populated with the value of this header ?
MelissaBailey | 2018-02-21 22:33:16 UTC | #4
Hi jcp,
Are you encoding the value correctly & prepending the protocol discriminator? For this example, I'm using the User-To-User header with a protocol discriminator of 00 and hex encoding.
<<<<<< REQUEST <<<<<< INVITE sip:+13177891183@172.26.23.198:5060;transport=udp SIP/2.0 To: <sip:+13177891183@172.26.23.198:5060> From: <sip:+444207999181@172.26.16.30:8062>;tag=110047 Call-ID: 1b595ced-173c-4012-b520-76e5b815a752 CSeq: 1 INVITE Allow-Events: conference, talk, hold Contact: <sip:+444207999181@172.26.16.30:8062> X-Phonesim-Proxy-Type: primary User-To-User: 007768617420696620736f6d65626f6479206465636964657320746f20627265616b206974 Content-Type: application/sdp X-Phonesim: 1.0.0-520 Content-Length: 266 Via: SIP/2.0/UDP qf-etphonehome:8062;branch=z9hG4bK6a2c9a06b7ac4701a80ce25f32463a7e;rport
jcp | 2018-02-22 12:43:27 UTC | #5
Hi Melissa,
I have tried varied options but no luck here.
Just to recap:
- This is an Inbound call to one edge.
- I have enabled the trunk for User-to-User / ascii
- In Architect I pass Call.UUIdata to a script
- The value is empty, no UUI data showing in GET /api/v2/conversations/{conversationId}
- The SIP trace on the Edge captures the User-to-User data as below
example User-to-User encoded in ascii :
Session Initiation Protocol (INVITE) Request-Line: INVITE sip:+44134xxxxxxx@123.123.123.160;user=phone;transport=tcp SIP/2.0 Message Header Via: SIP/2.0/UDP 123.123.123.207;branch=z9hG4bKkYGOaalU;rport From: "+44330xxxxxxx" <sip:+44330xxxxxxx@123.123.123.81;user=phone>;tag=Xct0gXe726QeN To: <sip:0203xxxxxxx@123.123.123.160;user=phone> CSeq: 119314037 INVITE Call-ID: 69355860-3728289003-295456@GW.tele.com Max-Forwards: 54 User-Agent: Tele.com Server Supported: path, replaces Privacy: none Content-Disposition: session P-Asserted-Identity: <sip:+44330xxxxxxx@123.123.123.45> SIP PAI Address: sip:+44330xxxxxxx@123.123.123.45 Allow: INVITE, ACK, BYE, CANCEL, OPTIONS User-To-User: 0069355860-3728289003-295456@GW.tele.com Content-Type: application/sdp Content-Length: 265 Contact: <sip:1053B0A8-5A8EAE6B0005DE83-96B68700@123.123.123.207;transport=udp> Message Body
What am I missing ?
jcp | 2018-02-22 14:17:18 UTC | #6
OK,
It seems that after all, the Protocol settings in the External Trunks are not that relevant for Inbound calls. Even if Header: Encoding Format is set to ascii, this is not relevant on Inbound calls. I had two calls using the sample User-to-User value provided in your example:
User-To-User: 007768617420696620736f6d65626f6479206465636964657320746f20627265616b206974
The Call.UUIData contained the Ascii equivalent.
"uuiData": "what if somebody decides to break it"
For the ascii value to be shown in Call.UUIData or "uuiData" in the output of /api/v2/conversations/{conversationId}, the Message format seems to be:
User-To-User: 00{asciiData};encoding=ascii
where based on the example SIP Invite above {asciiData} is 69355860-3728289003-295456@GW.tele.com
Resolved, thanks for your help.
tim.smith | 2018-02-22 15:50:00 UTC | #7
This is a little tricky to find, but I think this documentation explains the necessary format: https://help.mypurecloud.com/articles/external-trunk-settings/. Under Protocol > User to User Information (UUI) > Header: Type:
- User-To-User: This is the general header, which requires the use of the protocol discriminator in the format:
User-to-User: XXhexdata;encoding=hex;purpose=isdn-uui;content=isdn-uui
where XX is the protocol discriminator.
system | 2018-03-25 15:50:18 UTC | #8
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: 2513