Tap here to compare the top VoIP providersTap here to hide the top VoIP Providers
Asterisk cmd Directory
Asterisk Directory Command
SynopsisProvide directory of voicemail extensions
Directory(vm-context[|dial-context[|options]]) - 1.4 Directory(vm-context[,dial-context[,options]]) - 1.6
Presents the user with a directory of extensions from which they may select by name. The list of names and extensions is discovered from voicemail.conf. The vm-context argument is required, and specifies the context of voicemail.conf to use. The dial-context is the context to use for dialing the users, and defaults to the vm-context if unspecified. The 'f' option causes the directory to match based on the first name in voicemail.conf instead of the last name. Returns 0 unless the user hangs up. It also sets up the channel on exit to enter the extension the user selected.
- e: In addition to the name, also read the extension number to the caller before presenting dialing options.
- f: Allow the caller to enter the first name of a user in the directory instead of using the last name.
- b: Allow the caller to enter the first name OR last name of a user in the directory.
Options can be applied together, such as ef or eb
To use b, patch 7151 must be applied
To use e, patch 6938 must be applied
- hidefromdir: Hides the entry from the directory.
100 => 1234,John Doe,firstname.lastname@example.org,,hidefromdir=yes
DescriptionPresents the user with a directory of extensions from which they may select by name. This feature is known as 'Dial by name' on other vendors systems. The list of names and extensions is discovered from voicemail.conf. The vm-context argument is required, and specifies the context in which to interpret the extensions. The dial-context is the context to use for dialing the users, and defaults to the vm-context if unspecified.
Limitations: Directory() in Asterisk 1.0.x does not support voicemail users stored in a database (MySQL, Postgres etc). According to bug 2475 this has been fixed for Asterisk 1.2.
- Plays directory introduction file (dir-intro) and waits upto 5 seconds for 3 digits
- Intro file says "Please enter the first three letters of the persons last name..."
- Name is the last word found in in the <name> field in the voice mailbox entry in voicemail.conf
- Plays directory instructions file (dir-instr) for instructions on how to connect to that extension.
- Also plays the "name" as recorded by the voice mailbox owner to identify the extension. If this recording does not exist, it will speak the letters of the name (bee-oh-bee-space-ess-em-aye-tee-aich)
- If more than one matching last name is found, it will allow the caller to cycle through all the matches found.
- If no matches, it repeats the introduction
- Pressing "*" will exit
- Pressing "1" will exit setting up the channel to enter the extension selected
Return codesReturns 0 unless the user hangs up. It also sets up the channel on exit to enter the
extension the user selected.
- Patches to add feature to read numeric extension after lookup
Asterisk | Applications | Functions | Variables | Expressions | Asterisk FAQ
Please update this page with new information, just login and click on the "Edit" or "Discussion" tab. Get a free login here: Register Thanks! - Find us on Google+