[asterisk-users] Urgent help = RUBY & AGI
Jim Dickenson
dickenson at cfmc.com
Thu Jul 29 09:48:29 CDT 2010
Do you just have one agi you are running? If so that will not work. Your one agi is hung on the dial step until it finishes at which time the agi will go away, I think. You need the one agi to cause the dial to occur and another one to capture the information when the macro runs. You can try adding option g to the dial command and then retrieve the variable you set in the macro after the dial step finishes. I do not use agi's much so I might be off base with all this but it is something to look in to.
--
Jim Dickenson
mailto:dickenson at cfmc.com
CfMC
http://www.cfmc.com/
On Jul 29, 2010, at 7:22 AM, Zarko Zivanovic wrote:
> That looks easy. I must say that I am very frustrated as this has took my all week, and beside dumpling that data via macro I wasnt able to
> use that data in the ruby script that we have. I didnt write the script is something old that we use but i was sure we could add few things in that very script and continue
> to use it. I posted almost all script that we use and it surprised me that no one was able to find the solution so far.
>
> Zarko
>
>
>
>
> On Thu, Jul 29, 2010 at 3:46 PM, Danny Nicholas <danny at debsinc.com> wrote:
> I can’t even spell RUBY, so I don’t have a clue as to how the AGI works. I do know a little bit about AGI in general. The way I typically run my AGI’s is something like this:
>
> exten => 933,1,Answer
>
> exten => 933,n,Set(ABA=777702107)
>
> exten => 933,n,Set(city=Birmingham)
>
> exten => 933,n,Set(state=AL)
>
> exten => 933,n,Set(zip=35244)
>
> exten => 933,n,AGI(cityweather.agi,${ABA},${city},${state},${zip},${CHANNEL(language)})
>
> exten => 933,n,hangup()
>
>
> I’m a PERL weenie, so I can “shell check” my agi’s by going to /var/lib/asterisk/agi-bin and doing
>
> ./cityweather.agi 777702107 Birmingham AL 35244 en
>
>
> And getting back a STDOUT output that simulates what I should get from the CLI output.
>
>
> --
> _____________________________________________________________________
> -- 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
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20100729/0d20188f/attachment.htm
More information about the asterisk-users
mailing list