<div dir="ltr"><pre style="white-space:pre-wrap;color:rgb(0,0,0)">Sorry. I've had to switch to a different mail account because each time I try to reply I get a "you must be a member to post to this list" message, even though I'm already subscribed.</pre><pre style="white-space:pre-wrap;color:rgb(0,0,0)"><br></pre><pre style="white-space:pre-wrap;color:rgb(0,0,0)">Anyway, I don't have an issue with the use of the a-leg uuid. I think my problem stems from an assumption that the ids would be the same on the client and the server.</pre><div style="color:rgb(33,33,33);font-family:wf_segoe-ui_normal,"Segoe UI","Segoe WP",Tahoma,Arial,sans-serif,serif,EmojiFont;font-size:15px;margin:0px"><font size="2" style="font-family:Calibri,sans-serif,serif,EmojiFont"><span style="font-size:11pt"> </span></font></div><div style="color:rgb(33,33,33);font-family:wf_segoe-ui_normal,"Segoe UI","Segoe WP",Tahoma,Arial,sans-serif,serif,EmojiFont;font-size:15px;margin:0px"><font size="2" style="font-family:Calibri,sans-serif,serif,EmojiFont"><span style="font-size:11pt">I have a client UA which is placing a call through the server, which in turn is recording the conversation. The client needs a unique way of identifying the filename used in the recording and the use of the uuid seemed like a suitable way of identifying the file.</span></font></div><div style="color:rgb(33,33,33);font-family:wf_segoe-ui_normal,"Segoe UI","Segoe WP",Tahoma,Arial,sans-serif,serif,EmojiFont;font-size:15px;margin:0px"><font size="2" style="font-family:Calibri,sans-serif,serif,EmojiFont"><span style="font-size:11pt"> </span></font></div><div style="color:rgb(33,33,33);font-family:wf_segoe-ui_normal,"Segoe UI","Segoe WP",Tahoma,Arial,sans-serif,serif,EmojiFont;font-size:15px;margin:0px"><font size="2" style="font-family:Calibri,sans-serif,serif,EmojiFont"><span style="font-size:11pt">However I've realised that the call Id returned as a response to the pa call issued is a client-side id and doesn't correlate with the call id used at the server end of things. Is there any way for the client to know the call used by the server, or is there a way for the client to provide a custom id that will be accessible to the server when processing the dialplan?</span></font></div><pre style="white-space:pre-wrap;color:rgb(0,0,0)"><br></pre><pre style="white-space:pre-wrap;color:rgb(0,0,0)">> The answer is all of these uuid’s are being used by the server, 1 for a leg, and one for each b leg. Why do you have an issue with using the a leg uuid?
><i> On Aug 14, 2017, at 1:08 PM, Paul Mateer <<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users">paul.mateer at outlook.com</a>> wrote:
</i>><i>
</i>><i> Thanks Vladyslav.
</i>><i>
</i>><i> After reading your reply I found relevant information under the originating_leg_uuid section of the Channel Variables confluence page.
</i>><i>
</i>><i> I tried modifying the Dialplan entry on the server to include both ${uuid} and $(call_uuid} in the name of the session recording file as follows
</i>><i>
</i>><i> <extension name="Test Dialplan entry">
</i>><i> <condition field="destination_number" expression="^(4008)$">
</i>><i> <action application="export" data="execute_on_answer=record_session $${base_dir}/recordings/${strftime(%Y.%m.%d_%H.%M.%S)}_${uuid}_.${call_uuid}._${caller_id_number}.wav"/>
</i>><i> <action application="export" data="dialed_extension=$1"/>
</i>><i> <action application="set" data="call_timeout=30"/>
</i>><i> <action application="set" data="hangup_after_bridge=true"/>
</i>><i> <action application="set" data="continue_on_fail=true"/>
</i>><i> <action application="hash" data="insert/${domain_name}-call_return/${dialed_extension}/${caller_id_number}"/>
</i>><i> <action application="hash" data="insert/${domain_name}-last_dial_ext/${dialed_extension}/${uuid}"/>
</i>><i> <action application="set" data="called_party_callgroup=${user_data(${dialed_extension}@${domain_name} var callgroup)}"/>
</i>><i> <action application="hash" data="insert/${domain_name}-last_dial_ext/${called_party_callgroup}/${uuid}"/>
</i>><i> <action application="hash" data="insert/${domain_name}-last_dial_ext/global/${uuid}"/>
</i>><i> <action application="hash" data="insert/${domain_name}-last_dial/${called_party_callgroup}/${uuid}"/>
</i>><i> <action application="bridge" data="user/$1@${domain_name}"/>
</i>><i> <action application="answer"/>
</i>><i> </condition>
</i>><i> </extension>
</i>><i>
</i>><i> but the name generated had the same Guid for both uuid and call_uuid (which suggests that it's the a-leg).
</i>><i>
</i>><i>
</i>><i> My client issues a call to a number using embedded FreeSWITCH as follows:
</i>><i>
</i>><i> FreeSWITCH.Native.Api.Execute("pa", "call sofia/gateway/<gateway>/<number> XML <caller Id> <caller name>")
</i>><i>
</i>><i> and gets back a response like
</i>><i>
</i>><i> SUCCESS:<call number>:<Guid>
</i>><i>
</i>><i> The Guid in the response looks like it should be a call Id because it'd the same Guid that appears in the Unique-ID headers of the FreeSWITCH events that the client receives - it just doesn't seem to match the Guid(s) used by the server when it'd generating the recording name. Is there any way for the client FreeSWITCH to know or gain access to the IDs being used by the FreeSWITCH server?
</i>><i>
</i>><i> Paul
</i>><i>
</i>><i> From: FreeSWITCH-users <<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users">freeswitch-users-bounces at lists.freeswitch.org</a>> on behalf of Vladyslav Zakhozhai <<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users">v.zakhozhai at gmail.com</a>>
</i>><i> Sent: 14 August 2017 16:41:13
</i>><i> To: FreeSWITCH Users Help
</i>><i> Subject: Re: [Freeswitch-users] Channel variables on a-leg and b-leg
</i>><i>
</i>><i> Hi Paul,
</i>><i>
</i>><i> ${uuid} - is Unique Id of channel. For a-leg and b-leg it will be different (I mean that uuid is not Call-ID). You can try to use call_uuid instead. But I'm not sure about that.
</i>><i>
</i>><i> I think that you can use set instead of export and fetch recording data from a-leg. I'm using such approach and do not experience any problems with that.
</i>><i>
</i>><i> On Mon, Aug 14, 2017 at 5:01 PM, Paul Mateer <<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users">Paul.Mateer at outlook.com</a> <mailto:<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users">Paul.Mateer at outlook.com</a>>> wrote:
</i>><i> Guys, I'm using the C# interface to FreeSWITCH to add the ability to make and receive calls in an existing software application.
</i>><i>
</i>><i> I want to record the conversations on the server, but I need to be able to access the recording after the call is complete.
</i>><i> The Call-ID value seemed the perfect solution to this and I added the following action to my dialplan entry.
</i>><i>
</i>><i> <action application="export" data="execute_on_answer=record_session $${base_dir}/recordings/${strftime(%Y.%m.%d_%H.%M.%S)}_${uuid}_${caller_id_number}.wav"/>
</i>><i>
</i>><i> This seemed to work fine, as I would get recording files created with a Guid in the name, but on closer inspection I found that the Guid used in the filename was not the same Guid associated with the successfully placed call in the application. I assume that this is because the application sees the Call-ID for the a-leg, whereas the dialplan entry is executed in the b-leg and therefore has it's own separate Guid.
</i>><i>
</i>><i> Is there any way in which I can expose the Call-ID (or some other custom channel variable) for the a-leg to the b-leg so that it will be accessible within the XML dialplan and therefore be usable when creating the recording file?
</i>><i>
</i>><i> Thanks for any suggestions/assistance offered.
</i>><i>
</i>><i>
</i>><i>
</i>><i> _________________________________________________________________________
</i>><i> Professional FreeSWITCH Consulting Services:
</i>><i> <a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users">consulting at freeswitch.org</a> <mailto:<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users">consulting at freeswitch.org</a>>
</i>><i> <a href="http://www.freeswitchsolutions.com/">http://www.freeswitchsolutions.com</a> <<a href="http://www.freeswitchsolutions.com/">http://www.freeswitchsolutions.com/</a>>
</i>><i>
</i>><i> Official FreeSWITCH Sites
</i>><i> <a href="http://www.freeswitch.org/">http://www.freeswitch.org</a> <<a href="http://www.freeswitch.org/">http://www.freeswitch.org/</a>>
</i>><i> <a href="http://confluence.freeswitch.org/">http://confluence.freeswitch.org</a> <<a href="http://confluence.freeswitch.org/">http://confluence.freeswitch.org/</a>>
</i>><i> <a href="http://www.cluecon.com/">http://www.cluecon.com</a> <<a href="http://www.cluecon.com/">http://www.cluecon.com/</a>>
</i>><i>
</i>><i> FreeSWITCH-users mailing list
</i>><i> <a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users">FreeSWITCH-users at lists.freeswitch.org</a> <mailto:<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users">FreeSWITCH-users at lists.freeswitch.org</a>>
</i>><i> <a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a> <<a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a>>
</i>><i> UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users">http://lists.freeswitch.org/mailman/options/freeswitch-users</a> <<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users">http://lists.freeswitch.org/mailman/options/freeswitch-users</a>>
</i>><i> <a href="http://www.freeswitch.org/">http://www.freeswitch.org</a> <<a href="http://www.freeswitch.org/">http://www.freeswitch.org/</a>>
</i>><i>
</i>><i>
</i>><i>
</i>><i> --
</i>><i> С уважением,
</i>><i> Владислав Захожай
</i>><i>
</i>><i> _________________________________________________________________________
</i>><i> Professional FreeSWITCH Consulting Services:
</i>><i> <a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users">consulting at freeswitch.org</a>
</i>><i> <a href="http://www.freeswitchsolutions.com/">http://www.freeswitchsolutions.com</a>
</i>><i>
</i>><i> Official FreeSWITCH Sites
</i>><i> <a href="http://www.freeswitch.org/">http://www.freeswitch.org</a>
</i>><i> <a href="http://confluence.freeswitch.org/">http://confluence.freeswitch.org</a>
</i>><i> <a href="http://www.cluecon.com/">http://www.cluecon.com</a>
</i>><i>
</i>><i> FreeSWITCH-users mailing list
</i>><i> <a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users">FreeSWITCH-users at lists.freeswitch.org</a>
</i>><i> <a href="http://lists.freeswitch.org/mailman/listinfo/freeswitch-users">http://lists.freeswitch.org/mailman/listinfo/freeswitch-users</a>
</i>><i> UNSUBSCRIBE:<a href="http://lists.freeswitch.org/mailman/options/freeswitch-users">http://lists.freeswitch.org/mailman/options/freeswitch-users</a>
</i>><i> <a href="http://www.freeswitch.org/">http://www.freeswitch.org</a>
</i>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <<a href="http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20170814/5c471999/attachment-0001.html">http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20170814/5c471999/attachment-0001.html</a>></pre></div>