by mflorell » Tue Jan 10, 2012 10:52 pm
# agi-AGENT_route.agi version 2.4
#
# for use with a Call Menu in the custom dialplan section or as an AGI route.
#
# ; settings for this script:
# ; 1. DID pattern to use for In-group initiation settings ('default' is default)
# ; 2. the agentdirect in-group to send the calls to ('AGENTDIRECT' is default)
# ; 3. transfer only to ACTIVE in the system agent or vicidial LOGGED_IN agent
# ; ('ACTIVE' is default)
# ; 4. prompt for user ID, if this is filled in with a filename it will ask,
# ; otherwise it will assume $extension is the user ID
# ; 5. number of digits required for user ID validation, X will allow anything,
# ; this will only be enforced if "prompt for user ID" prompt is populated
# ; 6. audio filename for invalid selection, agent not available ('invalid' is default)
# ; 7. audio filename for invalid user id re-enter prompt, agent not available
# ; 8. number of retry attempts to enter a valid user ID
# ; this will only be enforced if "prompt for user ID" prompt is populated
# ; 9. in-group to send the call to if there is no valid agent, if none is
# ; defined, then the call will be directed to 's' exten
# ; 10. audio filename before sending call to no-agent route
# ; 11. audio filename before sending call to no-agent route if agent active but
# ; not logged-in to vicidial
#
#; example in CallMenu AGI route with all options
# "agi-AGENT_route.agi,default---AGENTDIRECT---LOGGED_IN---if-u-know-ext-dial---X---invalid---please-try-again---3---TEST_IN3---pbxtransfer---outside-transfer"
#; example with 4-digit agent IDs
# exten => _XXXX,1,AGI(agi-AGENT_route.agi,default---AGENTDIRECT---ACTIVE)
#