[asterisk-users] Where can I find some good examples of listening to AMI events via PHP & how to listen to a specific event?

2012-02-23 Thread Ast Coder
Hi everyone,

I got HTTP AMI working fine here. For example this dials 1-415-999- and
then sends to Extension @from-internal:

http://192.168.0.100:8088/asterisk/manager?action=command&originate&DAHDI/g0/1415999&extension&@from-internal

However, I want to have some control over this call. I want to be notified
the moment this call is hangup. I guess there would be a hangup event
generated. I am not sure if that would be done through action:waitevent? or
if there is another method.

I am also looking for some php samples on listening for these events as I
am trying to create a Web GUI for a dialer that will allow me to show
status of a call in real-time like "Call In Progress", "Call Ended", etc...

I see that too many events are generated and I am wondering if there is an
easy way of listening for a particular event? Would that be ActionID? if
so, how to use it?

Thanks a lot
--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] Where can I find some good examples of listening to AMI events via PHP & how to listen to a specific event?

2012-02-24 Thread virendra bhati
hi,

it will help you ..
http://www.micpc.com/eventmonitor/

On Fri, Feb 24, 2012 at 9:38 AM, Ast Coder  wrote:

> Hi everyone,
>
> I got HTTP AMI working fine here. For example this dials 1-415-999-and 
> then sends to Extension @from-internal
> :
>
>
> http://192.168.0.100:8088/asterisk/manager?action=command&originate&DAHDI/g0/1415999&extension&@from-internal
>
> However, I want to have some control over this call. I want to be notified
> the moment this call is hangup. I guess there would be a hangup event
> generated. I am not sure if that would be done through action:waitevent? or
> if there is another method.
>
> I am also looking for some php samples on listening for these events as I
> am trying to create a Web GUI for a dialer that will allow me to show
> status of a call in real-time like "Call In Progress", "Call Ended", etc...
>
> I see that too many events are generated and I am wondering if there is an
> easy way of listening for a particular event? Would that be ActionID? if
> so, how to use it?
>
> Thanks a lot
>
> --
> _
> -- Bandwidth and Colocation Provided by http://www.api-digital.com --
> New to Asterisk? Join us for a live introductory webinar every Thurs:
>   http://www.asterisk.org/hello
>
> asterisk-users mailing list
> To UNSUBSCRIBE or update options visit:
>   http://lists.digium.com/mailman/listinfo/asterisk-users
>



-- 

Thanks and regards

 Virendra Bhati
+91-8885268942
Software Engineer
E-mail-: virbh...@gmail.com
Skype id:- virbhati2
--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Re: [asterisk-users] Where can I find some good examples of listening to AMI events via PHP & how to listen to a specific event?

2012-02-27 Thread Ast Coder
Thanks Virendra,

That was a good start but not quite what I am looking for. I want to know
the details of listening to a specific event rather than listening to all.

My questions specifically is regarding the Manager command "originate". I
just used it to dial an extension first and then dialling a PSTN number
after which both of them bridge. By the time I hangup the call there is 48
events generated, NONE of which includes the ActionID I specified in my
originate command. So, how am I going to track this with the events
generated? There is a uniqueid but that's not useful to me because it's
generated after I do the dial and it's system generated.

Here is how I started the call:
*
http://192.168.0.2:8088/asterisk/rawman?action=originate&actionid=MyTestID&channel=SIP/MyITSP/1415666&context=from-internal&exten=100&priority=1&timeout=3&callerid=415444
*

As you can see I set ActionID = MyTestID but that is not showing in any
of the events generated.

The response back in originate command is simply:

*Response: Success
ActionID: MyTestID
Message: Originate successfully queued*

Based on above response and the following events generated, I am
handicapped.

What is the right way to listen to events and track them?

Thanks


On Fri, Feb 24, 2012 at 6:23 AM, virendra bhati  wrote:

> hi,
>
> it will help you ..
> http://www.micpc.com/eventmonitor/
>
> On Fri, Feb 24, 2012 at 9:38 AM, Ast Coder wrote:
>
>> Hi everyone,
>>
>> I got HTTP AMI working fine here. For example this dials 1-415-999-and 
>> then sends to Extension @from-internal
>> :
>>
>>
>> http://192.168.0.100:8088/asterisk/manager?action=command&originate&DAHDI/g0/1415999&extension&@from-internal
>>
>> However, I want to have some control over this call. I want to be
>> notified the moment this call is hangup. I guess there would be a hangup
>> event generated. I am not sure if that would be done through
>> action:waitevent? or if there is another method.
>>
>> I am also looking for some php samples on listening for these events as I
>> am trying to create a Web GUI for a dialer that will allow me to show
>> status of a call in real-time like "Call In Progress", "Call Ended", etc...
>>
>> I see that too many events are generated and I am wondering if there is
>> an easy way of listening for a particular event? Would that be ActionID? if
>> so, how to use it?
>>
>> Thanks a lot
>>
>> --
>> _
>> -- Bandwidth and Colocation Provided by http://www.api-digital.com --
>> New to Asterisk? Join us for a live introductory webinar every Thurs:
>>   http://www.asterisk.org/hello
>>
>> asterisk-users mailing list
>> To UNSUBSCRIBE or update options visit:
>>   http://lists.digium.com/mailman/listinfo/asterisk-users
>>
>
>
>
> --
>
> Thanks and regards
>
>  Virendra Bhati
> +91-8885268942
> Software Engineer
> E-mail-: virbh...@gmail.com
> Skype id:- virbhati2
>
>
> --
> _
> -- Bandwidth and Colocation Provided by http://www.api-digital.com --
> New to Asterisk? Join us for a live introductory webinar every Thurs:
>   http://www.asterisk.org/hello
>
> asterisk-users mailing list
> To UNSUBSCRIBE or update options visit:
>   http://lists.digium.com/mailman/listinfo/asterisk-users
>
--
_
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
   http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users