I am currently working on a project involving the Panoramisk library for Asterisk Management Interface (AMI) and the development of FastAGI scripts. In the context of my project, I am facing challenges regarding the handling of variables—both channel variables and those passed as arguments to the AGI scripts.
Here are the scenarios I would like to address:
exten => 5551212,1,Answer()
exten => 5551212,n,Set(TEST_RECORDING=hello-world)
exten => 5551212,n,Set(${CALLERID(name)}=Google)
- How can I set channel variables in a Panoramisk FastAGI script?
- Can I access these variables later in the script?
I do know we can use pprint(['AGI variables:', request.headers])
but the issue is if I make custom headers in Asterisk, they don’t show here.
exten => 5551212,n,AGI(agi://172.208.27.161:4574/call_waiting)
exten => 5551212,n,AGI(agi://172.208.27.161:4574/say_digits?digit=987654321)
exten => 5551212,n,AGI(agi://172.208.27.161:4574/play_recording?filename='hello-world')
exten => 5551212,n,AGI(agi://172.208.27.161:4574/update_callerID)
- How can I pass variables to a Panoramisk FastAGI script via AGI arguments?
- What is the procedure to retrieve these variables within the script?