Thread: [Asterisk-java-users] Agi scripts and native transfers
Brought to you by:
srt
From: E. M. <mar...@gm...> - 2008-03-26 22:44:20
|
Hello, I'm going to develop an AGI script but first I want to know if they have problems with attended transfers. For instance, imagine an agi script with a loop playing a sound (tt-monkeys?). Party A calls to Party B. Then Party A also calls to the AGI script and start hearing the monkeys. If Party A transfers Party B to the AGI script call, it will work? Sadly now I can test it because I don't have a phone with attended transfer support. Thank you. |
From: Martin S. <ma...@be...> - 2008-03-27 13:35:49
|
Can ongoing channel be able to be the target of a transfer? I don't think so. You can transfer BOTH calls into a conference room (meetme). You can also transfer party B to a new instance of the AGI script (transfer them to an extension that invokes the script). Otherwise, I think you'll need to consult the asterisk-users list. As an example, I haven't been able (in my one 5 minute try, anyway) to convince Asterisk to do an attended transfer to voicemail. Asterisk-Java is beside the issue here. I don't think you can have a pre-existing channel as the target of an attended transfer, short of using an app that lets channels comingle, like meet me. Hopefully someone can correct me if I'm wrong. Martin Smith, Systems Developer ma...@be... Bureau of Economic and Business Research University of Florida (352) 392-0171 Ext. 221 ________________________________ From: ast...@li... [mailto:ast...@li...] On Behalf Of Eduard Martínez Sent: Wednesday, March 26, 2008 6:44 PM To: ast...@li... Subject: [Asterisk-java-users] Agi scripts and native transfers Hello, I'm going to develop an AGI script but first I want to know if they have problems with attended transfers. For instance, imagine an agi script with a loop playing a sound (tt-monkeys?). Party A calls to Party B. Then Party A also calls to the AGI script and start hearing the monkeys. If Party A transfers Party B to the AGI script call, it will work? Sadly now I can test it because I don't have a phone with attended transfer support. Thank you. |
From: E. M. <mar...@gm...> - 2008-03-27 18:35:41
|
On Thu, Mar 27, 2008 at 2:36 PM, Martin Smith <ma...@be...> wrote: > Can ongoing channel be able to be the target of a transfer? [...] > As far as I know, yes. But that's not the point. Maybe a valid example for you is: Party A calls Party B. Party B puts the call on hold and calls to the AGI script with the monkeys. Then Party B does the atended transfer with Party A and the AGI call. Think in the loop directly in the dialplan: exten => 1234, 1, PlayBack(tt-monkeys) exten => 1234, 2, Goto(1) If Party B does a native transfer to this extension, Party A starts hearing the monkeys and the loop continues with his channel. > > As an example, I haven't been able (in my one 5 minute try, anyway) to > convince Asterisk to do an attended transfer to voicemail. Asterisk-Java is > beside the issue here. I don't think you can have a pre-existing channel as > the target of an attended transfer, short of using an app that lets channels > comingle, like meet me. > > Hopefully someone can correct me if I'm wrong. > > > Martin Smith, Systems Developer > ma...@be... > Bureau of Economic and Business Research > University of Florida > (352) 392-0171 Ext. 221 > > > ------------------------------ > *From:* ast...@li... [mailto: > ast...@li...] *On Behalf Of *Eduard > Martínez > *Sent:* Wednesday, March 26, 2008 6:44 PM > *To:* ast...@li... > *Subject:* [Asterisk-java-users] Agi scripts and native transfers > > Hello, > I'm going to develop an AGI script but first I want to know if they have > problems with attended transfers. For instance, imagine an agi script with a > loop playing a sound (tt-monkeys?). Party A calls to Party B. Then Party A > also calls to the AGI script and start hearing the monkeys. If Party A > transfers Party B to the AGI script call, it will work? Sadly now I can test > it because I don't have a phone with attended transfer support. > Thank you. > > > ------------------------------------------------------------------------- > Check out the new SourceForge.net Marketplace. > It's the best place to buy or sell services for > just about anything Open Source. > > http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace > _______________________________________________ > Asterisk-java-users mailing list > Ast...@li... > https://lists.sourceforge.net/lists/listinfo/asterisk-java-users > > |
From: Martin S. <ma...@be...> - 2008-03-27 20:18:48
|
I haven't been able to do an attended transfer to anything natively. I was under the impression that app_transfer does not do attended transfers and ONLY transfers to an extension location in the dialplan (NOT an extension in progress), and you can only do an attended transfer via the features.conf method or a phone which knows how with a given channel technology that also supports it i.e. NOT an attended transfer to Voicemail, Playback, or any other such app. Maybe someone else here can comment on this. Martin Smith, Systems Developer ma...@be... Bureau of Economic and Business Research University of Florida (352) 392-0171 Ext. 221 ________________________________ From: ast...@li... [mailto:ast...@li...] On Behalf Of Eduard Martínez Sent: Thursday, March 27, 2008 2:36 PM To: ast...@li... Subject: Re: [Asterisk-java-users] Agi scripts and native transfers On Thu, Mar 27, 2008 at 2:36 PM, Martin Smith <ma...@be...> wrote: Can ongoing channel be able to be the target of a transfer? [...] As far as I know, yes. But that's not the point. Maybe a valid example for you is: Party A calls Party B. Party B puts the call on hold and calls to the AGI script with the monkeys. Then Party B does the atended transfer with Party A and the AGI call. Think in the loop directly in the dialplan: exten => 1234, 1, PlayBack(tt-monkeys) exten => 1234, 2, Goto(1) If Party B does a native transfer to this extension, Party A starts hearing the monkeys and the loop continues with his channel. As an example, I haven't been able (in my one 5 minute try, anyway) to convince Asterisk to do an attended transfer to voicemail. Asterisk-Java is beside the issue here. I don't think you can have a pre-existing channel as the target of an attended transfer, short of using an app that lets channels comingle, like meet me. Hopefully someone can correct me if I'm wrong. Martin Smith, Systems Developer ma...@be... Bureau of Economic and Business Research University of Florida (352) 392-0171 Ext. 221 ________________________________ From: ast...@li... [mailto:ast...@li...] On Behalf Of Eduard Martínez Sent: Wednesday, March 26, 2008 6:44 PM To: ast...@li... Subject: [Asterisk-java-users] Agi scripts and native transfers Hello, I'm going to develop an AGI script but first I want to know if they have problems with attended transfers. For instance, imagine an agi script with a loop playing a sound (tt-monkeys?). Party A calls to Party B. Then Party A also calls to the AGI script and start hearing the monkeys. If Party A transfers Party B to the AGI script call, it will work? Sadly now I can test it because I don't have a phone with attended transfer support. Thank you. ------------------------------------------------------------------------- Check out the new SourceForge.net Marketplace. It's the best place to buy or sell services for just about anything Open Source. http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace _______________________________________________ Asterisk-java-users mailing list Ast...@li... https://lists.sourceforge.net/lists/listinfo/asterisk-java-users |
From: E. M. <mar...@gm...> - 2008-03-27 21:27:01
|
Well in my case I was thinking in SIP attended transfers. With SIP phones in attended transfers the transfered channel starts doing whathever was doing the other channel: playing a sound, a bridge with another channel etc. On Thu, Mar 27, 2008 at 9:19 PM, Martin Smith <ma...@be...> wrote: > I haven't been able to do an attended transfer to anything natively. I > was under the impression that app_transfer does not do attended transfers > and ONLY transfers to an extension location in the dialplan (NOT an > extension in progress), and you can only do an attended transfer via the > features.conf method or a phone which knows how with a given channel > technology that also supports it i.e. NOT an attended transfer to > Voicemail, Playback, or any other such app. > > Maybe someone else here can comment on this. > > Martin Smith, Systems Developer > ma...@be... > Bureau of Economic and Business Research > University of Florida > (352) 392-0171 Ext. 221 > > > ------------------------------ > *From:* ast...@li... [mailto: > ast...@li...] *On Behalf Of *Eduard > Martínez > *Sent:* Thursday, March 27, 2008 2:36 PM > *To:* ast...@li... > *Subject:* Re: [Asterisk-java-users] Agi scripts and native transfers > > > > On Thu, Mar 27, 2008 at 2:36 PM, Martin Smith <ma...@be...> > wrote: > > > Can ongoing channel be able to be the target of a transfer? [...] > > > > As far as I know, yes. But that's not the point. Maybe a valid example for > you is: > Party A calls Party B. Party B puts the call on hold and calls to the AGI > script with the monkeys. Then Party B does the atended transfer with Party A > and the AGI call. > > Think in the loop directly in the dialplan: > > exten => 1234, 1, PlayBack(tt-monkeys) > exten => 1234, 2, Goto(1) > > If Party B does a native transfer to this extension, Party A starts > hearing the monkeys and the loop continues with his channel. > > > > > > As an example, I haven't been able (in my one 5 minute try, anyway) to > > convince Asterisk to do an attended transfer to voicemail. Asterisk-Java is > > beside the issue here. I don't think you can have a pre-existing channel as > > the target of an attended transfer, short of using an app that lets channels > > comingle, like meet me. > > > > Hopefully someone can correct me if I'm wrong. > > > > > > Martin Smith, Systems Developer > > ma...@be... > > Bureau of Economic and Business Research > > University of Florida > > (352) 392-0171 Ext. 221 > > > > > > ------------------------------ > > *From:* ast...@li... [mailto: > > ast...@li...] *On Behalf Of *Eduard > > Martínez > > *Sent:* Wednesday, March 26, 2008 6:44 PM > > *To:* ast...@li... > > *Subject:* [Asterisk-java-users] Agi scripts and native transfers > > > > Hello, > > I'm going to develop an AGI script but first I want to know if they have > > problems with attended transfers. For instance, imagine an agi script with a > > loop playing a sound (tt-monkeys?). Party A calls to Party B. Then Party A > > also calls to the AGI script and start hearing the monkeys. If Party A > > transfers Party B to the AGI script call, it will work? Sadly now I can test > > it because I don't have a phone with attended transfer support. > > Thank you. > > > > > > > > ------------------------------------------------------------------------- > > Check out the new SourceForge.net Marketplace. > > It's the best place to buy or sell services for > > just about anything Open Source. > > > > http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace > > _______________________________________________ > > Asterisk-java-users mailing list > > Ast...@li... > > https://lists.sourceforge.net/lists/listinfo/asterisk-java-users > > > > > > ------------------------------------------------------------------------- > Check out the new SourceForge.net Marketplace. > It's the best place to buy or sell services for > just about anything Open Source. > > http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace > _______________________________________________ > Asterisk-java-users mailing list > Ast...@li... > https://lists.sourceforge.net/lists/listinfo/asterisk-java-users > > |
From: E. M. <mar...@gm...> - 2008-04-04 14:55:02
|
Finally I can test it. If it is useful for someone, AGI works OK with attended transfers. However, if thereis an attended transfer inside an agi script, AGIChannel.getName() returns the 'old' channel name, and AGIChannel.getVariable("CHANNEL") returns the updated name. In example, figure two phones: SIP/101 and SIP/102 and this code for an AGI script in extension 123: //////////////////////////////////////// package test; import org.asteriskjava.fastagi.*; public class HelloAgiScript extends BaseAgiScript{ public void service(AgiRequest request, AgiChannel channel) throws AgiException { answer(); while(true){ streamFile("tt-monkeys"); System.out.println("Original: "+channel.getName()); System.out.println("New channel: "+channel.getVariable("CHANNEL")); } } ////////////////////////////////////////// If SIP/102 does an attended transfer of SIP/101 to this extension, the output of the program is: Original: SIP/102-xxxxx New channel: SIP/101-xxxxx Original: SIP/102-xxxxx New channel: SIP/101-xxxxx Original: SIP/102-xxxxx New channel: SIP/101-xxxxx On Thu, Mar 27, 2008 at 11:27 PM, Eduard Martínez <mar...@gm...> wrote: > Well in my case I was thinking in SIP attended transfers. With SIP phones > in attended transfers the transfered channel starts doing whathever was > doing the other channel: playing a sound, a bridge with another channel etc. > > > On Thu, Mar 27, 2008 at 9:19 PM, Martin Smith <ma...@be...> > wrote: > > > I haven't been able to do an attended transfer to anything natively. I > > was under the impression that app_transfer does not do attended transfers > > and ONLY transfers to an extension location in the dialplan (NOT an > > extension in progress), and you can only do an attended transfer via the > > features.conf method or a phone which knows how with a given channel > > technology that also supports it i.e. NOT an attended transfer to Voicemail, > > Playback, or any other such app. > > > > Maybe someone else here can comment on this. > > > > Martin Smith, Systems Developer > > ma...@be... > > Bureau of Economic and Business Research > > University of Florida > > (352) 392-0171 Ext. 221 > > > > > > ------------------------------ > > *From:* ast...@li... [mailto: > > ast...@li...] *On Behalf Of *Eduard > > Martínez > > *Sent:* Thursday, March 27, 2008 2:36 PM > > *To:* ast...@li... > > *Subject:* Re: [Asterisk-java-users] Agi scripts and native transfers > > > > > > > > On Thu, Mar 27, 2008 at 2:36 PM, Martin Smith <ma...@be...> > > wrote: > > > > > Can ongoing channel be able to be the target of a transfer? [...] > > > > > > > As far as I know, yes. But that's not the point. Maybe a valid example > > for you is: > > Party A calls Party B. Party B puts the call on hold and calls to the > > AGI script with the monkeys. Then Party B does the atended transfer with > > Party A and the AGI call. > > > > Think in the loop directly in the dialplan: > > > > exten => 1234, 1, PlayBack(tt-monkeys) > > exten => 1234, 2, Goto(1) > > > > If Party B does a native transfer to this extension, Party A starts > > hearing the monkeys and the loop continues with his channel. > > > > > > > > > > As an example, I haven't been able (in my one 5 minute try, anyway) to > > > convince Asterisk to do an attended transfer to voicemail. Asterisk-Java is > > > beside the issue here. I don't think you can have a pre-existing channel as > > > the target of an attended transfer, short of using an app that lets channels > > > comingle, like meet me. > > > > > > Hopefully someone can correct me if I'm wrong. > > > > > > > > > Martin Smith, Systems Developer > > > ma...@be... > > > Bureau of Economic and Business Research > > > University of Florida > > > (352) 392-0171 Ext. 221 > > > > > > > > > ------------------------------ > > > *From:* ast...@li... [mailto: > > > ast...@li...] *On Behalf Of *Eduard > > > Martínez > > > *Sent:* Wednesday, March 26, 2008 6:44 PM > > > *To:* ast...@li... > > > *Subject:* [Asterisk-java-users] Agi scripts and native transfers > > > > > > Hello, > > > I'm going to develop an AGI script but first I want to know if they > > > have problems with attended transfers. For instance, imagine an agi script > > > with a loop playing a sound (tt-monkeys?). Party A calls to Party B. Then > > > Party A also calls to the AGI script and start hearing the monkeys. If Party > > > A transfers Party B to the AGI script call, it will work? Sadly now I can > > > test it because I don't have a phone with attended transfer support. > > > Thank you. > > > > > > > > > > > > ------------------------------------------------------------------------- > > > Check out the new SourceForge.net Marketplace. > > > It's the best place to buy or sell services for > > > just about anything Open Source. > > > > > > http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace > > > _______________________________________________ > > > Asterisk-java-users mailing list > > > Ast...@li... > > > https://lists.sourceforge.net/lists/listinfo/asterisk-java-users > > > > > > > > > > > > ------------------------------------------------------------------------- > > Check out the new SourceForge.net Marketplace. > > It's the best place to buy or sell services for > > just about anything Open Source. > > > > http://ad.doubleclick.net/clk;164216239;13503038;w?http://sf.net/marketplace > > _______________________________________________ > > Asterisk-java-users mailing list > > Ast...@li... > > https://lists.sourceforge.net/lists/listinfo/asterisk-java-users > > > > > |
From: Stefan R. <ste...@re...> - 2008-04-05 06:00:43
Attachments:
signature.asc
|
Eduard Martínez wrote: > Finally I can test it. If it is useful for someone, AGI works OK with > attended transfers. However, if thereis an attended transfer inside an > agi script, AGIChannel.getName() returns the 'old' channel name, and > AGIChannel.getVariable("CHANNEL") returns the updated name. Thanks for this pointer. The AgiRequest is only populated when the AgiScript is started with the data received from Asterisk. The implications are interesting for the new AsyncAGI stuff where AgiCommands are converted to Manager actions that include the channel name. So I guess I have to watch for RenameEvents there and update my AgiWriter in to use the new channel name. =Stefan -- reuter network consulting Neusser Str. 110 50760 Koeln Germany Telefon: +49 221 1305699-0 Telefax: +49 221 1305699-90 E-Mail: ste...@re... Jabber: ste...@re... WWW: http://www.reucon.com Steuernummern 215/5140/1791 USt-IdNr. DE220701760 |
From: E. M. <mar...@gm...> - 2008-04-22 16:41:07
|
Hi Stefan, I just read about the new support for Async AGI and I think that this is great :) But again I was wondering which behaviour will have the new system with attended transfers. Have you test it? When I have time I will give a try. On Sat, Apr 5, 2008 at 8:00 AM, Stefan Reuter <ste...@re...> wrote: > Eduard Martínez wrote: > > Finally I can test it. If it is useful for someone, AGI works OK with > > attended transfers. However, if thereis an attended transfer inside an > > agi script, AGIChannel.getName() returns the 'old' channel name, and > > AGIChannel.getVariable("CHANNEL") returns the updated name. > > Thanks for this pointer. > The AgiRequest is only populated when the AgiScript is started with the > data received from Asterisk. > The implications are interesting for the new AsyncAGI stuff where > AgiCommands are converted to Manager actions that include the channel > name. So I guess I have to watch for RenameEvents there and update my > AgiWriter in to use the new channel name. > > =Stefan > > -- > reuter network consulting > Neusser Str. 110 > 50760 Koeln > Germany > Telefon: +49 221 1305699-0 > Telefax: +49 221 1305699-90 > E-Mail: ste...@re... > Jabber: ste...@re... > WWW: http://www.reucon.com > > Steuernummern 215/5140/1791 USt-IdNr. DE220701760 > > > ------------------------------------------------------------------------- > This SF.net email is sponsored by the 2008 JavaOne(SM) Conference > Register now and save $200. Hurry, offer ends at 11:59 p.m., > Monday, April 7! Use priority code J8TLD2. > > http://ad.doubleclick.net/clk;198757673;13503038;p?http://java.sun.com/javaone > _______________________________________________ > Asterisk-java-users mailing list > Ast...@li... > https://lists.sourceforge.net/lists/listinfo/asterisk-java-users > > |
From: Stefan R. <ste...@re...> - 2008-04-22 17:17:41
Attachments:
signature.asc
|
Eduard Martínez wrote: > Hi Stefan, I just read about the new support for Async AGI and I think > that this is great :) > But again I was wondering which behaviour will have the new system with > attended transfers. Have you test it? When I have time I will give a try. Uh this will be funny as the channel is used to send the AgiCommands to Asterisk so if it changes... we'll see. Please report back any issues or open a bug report at jira.reucon.org if you encounter trouble :-) =Stefan -- reuter network consulting Neusser Str. 110 50760 Koeln Germany Telefon: +49 221 1305699-0 Telefax: +49 221 1305699-90 E-Mail: ste...@re... Jabber: ste...@re... WWW: http://www.reucon.com Steuernummern 215/5140/1791 USt-IdNr. DE220701760 |