I am working on asterisk 11.0 and created a small dialplan of outgoing which converts text from english to other language
I have dowladed googletranslate.agi ansd installed all the perl modules
My problem is that everytime i send some arguments to googletranslate.agi it returns -1
part of my dialplan
same => n,agi(googletranslate.agi,"${name}",fr)
same => n,Verbose(1,Translated text: ${gtranslation})
and my cli shows
Executing [3065700@outgoingsamplesfr:8] AGI("DAHDI/i1/09********-7", "googletranslate.agi,"akash",fr") in new stack
-- Launched AGI Script /var/lib/asterisk/agi-bin/googletranslate.agi
-- <DAHDI/i1/09********-7>AGI Script googletranslate.agi completed, returning 0
-- Executing [3065700@outgoingsamplesfr:9] Verbose("DAHDI/i1/09971197459-7", "1,Translated text: -1") in new stack
Translated text: -1
Here is how to debug any agi script:
1) stop asterisk
2) start asterisk in your local console like
asterisk -vvvc
3) type "agi set debug on"
4) run your dialling to get agi execution.
If do like described above, you will get agi's error in your screen, also you will get agi execution debug which show all script to asterisk communication.