Michael Ulitskiy
2004-Aug-04 14:56 UTC
[Asterisk-Users] Identifying which call an event belongs to
Hi, I guess I need some help with management interface. I would like to watch calls through the management interface, but I don't know how to identify which call an event belongs to or in other words how to associate a call and uniqueid field of event. Let's say I send the following manager command: action: originate channel: sip/12125551111@pbx1 callerid: 12125551111 MaxRetries: 1 WaitTime: 10 Application: AGI Data: callback.agi|2&12125551111&12125552222 Then I'm receiving the following events: Uniqueid: 1091642334.98 Event: Newchannel Callerid: State: Down Channel: SIP/pbx1-fc4f Uniqueid: 1091642334.98 Event: Newcallerid Callerid: 12125551111 Channel: SIP/pbx1-fc4f Uniqueid: 1091642334.98 Event: Newchannel Callerid: 12125551111 State: Up Channel: SIP/pbx1-fc4f ... etc. The question is how do I associate event with the originated call. The could be other concurrent calls that also generate events and I don't seem to be able to find a way to distinguish them. Is it possible? Thank you, Michael
Nicolas Gudino
2004-Aug-04 16:15 UTC
[Asterisk-Users] Identifying which call an event belongs to
Hello, On Wed, 2004-08-04 at 18:56, Michael Ulitskiy wrote:> Hi, > > I guess I need some help with management interface. I would like to watch > calls through the management interface, but I don't know how to identify > which call an event belongs to or in other words how to associate a call > and uniqueid field of event. > Let's say I send the following manager command: > > action: originate > channel: sip/12125551111@pbx1 > callerid: 12125551111 > MaxRetries: 1 > WaitTime: 10 > Application: AGI > Data: callback.agi|2&12125551111&12125552222 >Try inserting in your originate command: ActionID: SOME_RANDOM_ID> Then I'm receiving the following events: > > Uniqueid: 1091642334.98 > Event: Newchannel > Callerid: > State: Down > Channel: SIP/pbx1-fc4f >And you would probably receive: Uniqueid: 1091642334.98 Event: Newchannel Callerid: State: Down Channel: SIP/pbx1-fc4f ActionID: SOME_RANDOM_ID I did not try this, but I know that ActionID is implemented in some manager commands. Best regards, -- Nicolas Gudino <nicolas@house.com.ar> House Internet S.R.L.
Seemingly Similar Threads
- Matching Originate action with its NewChannel event
- Manage api- Matching 'Newchannel' event with the 'Originate' command
- Fax for Asterisk, capable of receiving from website but not from fax machine !!
- [PATCH 1/1] Rename camel case variables in channel.c (updated)
- [PATCH 1/1] Rename camel case variables in channel.c (updated)