Skip to content

FreeSWITCH Rayo Extension

polysics edited this page Oct 9, 2012 · 7 revisions

FreeSWITCH Rayo Extension

rayo-freeswitch extends the Rayo specification and has its base namespace at urn:xmpp:rayo:freeswitch. It provides the means to access the FreeSWITCH Inbound Event Socket interface via Rayo.

Events

Events are sent by FS to all subscribing clients that registered using the "event" command. They are propagated by Rayo to all registered parties by way of an XMPP presence stanza. The following is the minimum data sent for a FreeSWITCH event (more information)

Event-Name: RE_SCHEDULE
Core-UUID: 6d2375b0-5183-11e1-b24c-f527b57af954
FreeSWITCH-Hostname: freeswitch.local
FreeSWITCH-Switchname: freeswitch.local
FreeSWITCH-IPv4: 127.0.0.1
FreeSWITCH-IPv6: ::1
Event-Date-Local: 2012-02-07 19:36:31
Event-Date-GMT: Tue, 07 Feb 2012 18:36:31 GMT
Event-Date-Timestamp: 1328639791116026
Event-Calling-File: switch_scheduler.c
Event-Calling-Function: switch_scheduler_execute
Event-Calling-Line-Number: 65
Event-Sequence: 3349

Which will translate to the following XMPP stanza:

<presence to="[email protected]/1" from="call.rayo.net">
  <event xmlns="urn:xmpp:rayo:freeswitch:ies:1" name="RE_SCHEDULE" core-uuid="6d2375b0-5183-11e1-b24c-f527b57af954">
    <attribute name="FreeSWITCH-Hostname" value="freeswitch.local"/>
    <attribute name="FreeSWITCH-Switchname" value="freeswitch.local"/>
    <attribute name="FreeSWITCH-IPv4" value="127.0.0.1"/>
    <attribute name="FreeSWITCH-IPv6" value="::1"/>
    <attribute name="Event-Date-Local" value="2012-02-07 19:36:31"/>
    <attribute name="Event-Date-GMT" value="Tue, 07 Feb 2012 18:36:31 GMT"/>
    <attribute name="Event-Date-Timestamp" value="1328639791116026"/>
    <attribute name="Event-Calling-File" value="switch_scheduler.c"/>
    <attribute name="Event-Calling-Function" value="switch_scheduler_execute"/>
    <attribute name="Event-Calling-Line-Number" value="65"/>
    <attribute name="Event-Sequence" value="3349"/>
  </event>
</presence>
Clone this wiki locally