The global and channel variables are already available to your AGI using
the GET VARIABLE agi command. You do not need to pass variables on the
command line.
I prefer the GET VARIABLE approach because it is more obvious and robust.
Compare:
fputs(GET VARIABLE BILLSEC, stdout);
Hi,
I am trying to get the duration of a call passed to an agi to do the
billing for the the call using
exten = h,1,Set(BILLSEC=${CDR(billsec)})
exten =
h,2,DeadAgi(billCall.php|${CALLERIDNUM}|${DESTINATION}|${BILLSEC}|${RATE}|${DESTNAME})
But I get a blank duration (${BILLSEC}) every time.