[Freeswitch-users] ESL: uuid events with filtering

lakshmanan ganapathy lakindia89 at gmail.com
Fri Sep 16 08:03:41 MSD 2011


I've not tried applying filter for Event-Name. But what I do is to register
only for the specific events that I need.

If you want to get only specific events, you can do as follows

$sock->SendRecv("events plain CHANNEL_ANSWER") # You will see only the
CHANNEL_ANSWER event....

Before getting into the code, you can actually experiment this using nc (
Outbound Socket ) or telnet ( Inbound Socket ), so that you will have a
better idea on how to in-corporate it in code.



On Fri, Sep 16, 2011 at 3:38 AM, Jayesh Nambiar <jayesh.voip at gmail.com>wrote:

> Hi,
> Is it possible to filter specific events for a particular uuid through ESL.
> I am using it from a PHP application as follows:
>
> $sock->SendRecv("events plain ALL");
> $sock->SendRecv("filter unique-id 12345");
> $sock->sendRecv("filter Event-Name CHANNEL_ANSWER");
> $sock->sendRecv("filter Event-Name CHANNEL_HANGUP");
> $sock->sendRecv("filter Event-Name CHANNEL_HANGUP_COMPLETE");
>
> In the case above, I start seeing the events coming from CHANNEL_ANSWER and
> thereafter all events for that uuid is received.
> Even if I write:
>
> $sock2->SendRecv("events plain ALL");
> $sock2->SendRecv("filter unique-id 12345");
> $sock2->sendRecv("filter Event-Name CHANNEL_HANGUP_COMPLETE");
>
> I get all the events belonging to uuid 12345 starting from CHANNEL_ANSWER
> event name. I also tried doing "myevents 12345 plain" and then applying
> filters but it still doesnt work as expected.
> I tried googling a bit but could'nt find much help. Anybody pointing me to
> a proper direction in this regards is highly appreciated.
>
> Thanks,
>
> --- Jayesh
>
>
> FreeSWITCH-users mailing list
> FreeSWITCH-users at lists.freeswitch.org
> http://lists.freeswitch.org/mailman/listinfo/freeswitch-users
> UNSUBSCRIBE:http://lists.freeswitch.org/mailman/options/freeswitch-users
> http://www.freeswitch.org
>
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.freeswitch.org/pipermail/freeswitch-users/attachments/20110916/6d970ab8/attachment-0001.html 


Join us at ClueCon 2011 Aug 9-11, 2011
More information about the FreeSWITCH-users mailing list