Im trying to detect when the person I call pick up the phone and also when I (and the other side) hang up. Until now I've tried with the "G" option in the Dial app. wich one continues running dialplan when the other side picks up, but I have no option to know when he hungs up. Other option was to use the "g" option in the Dial, that when one hungs up, dialplan continues running, but this there is no way to know when the phone is picked up or if the caller hungs up, it just doesn't do anything (as the Dial help says) Without options when Dial ends the call, dialplan ends too, meanwhile Dial mantains the control. Now, I've noticed that if I run the application in verbose mode, there are events wich show when I pick up and hung up the phone. When I pick up, the event is: -- SIP/sipdiscount-0d27 answered SIP/localuser-da9c (event that appears in app_dial.c) When I hung up, for example: == Spawn extension (default, 4233398, 3) exited non-zero on 'SIP/localuser-da9c' (but this is not happening in app_dial.c, I've seen its happening on pbx.c) So, what I'm trying to do is change the source in those lines to run some command with certain vars like the number that is being called, UNIQUEID, DATETIME, and the IP addres that is generating the call. But before I change anything I would like to know if there is already something developed that allows me to do this in a more conventional or standart way. I've searched but I haven't fond anything... Wile