# Extensions Extensions are part of **phonegroups** and serve as end points for calls, or where calls can be placed from. **Extensions** are set to use a **[Class of Service](https://public.intellasoft.net/books/cli/page/class-of-service)** to define how calls from this extension are handled. # Adding an Extension 1\) Enter the CLI's configuration mode. 2\) Enter the number of the **Extension** you wish to create. You will be prompted with the minimum required settings. An **extension** does not necessarily need to be a number, but in most this cases this is recommended. ``` servername(config)# extension 5000 servername(config-extension 5000)# ```
4\) Select a device type. (Press "Tab" after `device_type` to see available options) ``` servername(config-extension 5000)# device_type SIP         IAX2        DAHDI       VIRTUAL     SIP-VIRTUAL servername(config-extension 5000)# device_type SIP servername(config-extension 5000)# ```
Option Description
SIPPhysical phone (such as Polycom) or a software phone (such as Linphone or X-lite)
IAX2 Inter-Asterisk exchange
DAHDIPhone cards physically installed in computers, not commonly used
VIRTUAL Used mainly for mailboxes
SIP-VIRTUALActs as a secondary extension (or tertiary, if using two) for a SIP device, but is still considering a separate extension.
5\) By default the extension is created using your system defaults. Use the **show** command to see the default values for the extension. ``` servername(config-extension 5000)# show ! Generating running-config !!!!!   ! -------------- Extensions ---------------- extension 5000   always_autoanswer no   callerid_number 5000   call_screening no   cos internal+local+ld   device_type SIP   in_directory yes   phonegroup internal   phonemake_id generic   phonemodel_id generic   phone_type Generic   record no   tenant_name default   voicemail_enable no   sip     allow ulaw,alaw,adpcm,gsm     call-limit 4     canreinvite no     disallow g723,slin,ilbc,lpc10,g729,speex,g726aal2,g722     host dynamic     nat yes     qualify yes     rtpholdtimeout 60     rtptimeout 60     secret 35712c6fd77554c7d6902ebb5831030f     sendrpid yes     trustrpid no     username 5000     exit   exit   exit ``` 6\) A couple of settings that may need to be changed first are **Phonegroups** and **Class of Service (cos)**. Let's see what options we have for these. ``` servername(config-extension 5000)# phonegroup   ### Use the tab key to a get a list of the available options carpet_agents       hard_surface_agents internal servername(config-extension 5000)# cos    internal+local+ld+intl internal+local+ld      internal+local         internal ```
7\) Change the **phonegroup**. ``` servername(config-extension 5000)# phonegroup carpet_agents       hard_surface_agents internal servername(config-extension 5000)# phonegroup carpet_agents ```
8\) Next change the **Class of Service (cos)** ``` servername(config-extension 5000)# cos internal+local+ld+intl internal+local+ld      internal+local         internal servername(config-extension 5000)# cos internal+local ```
9\) Afterwards check to ensure the changes were saved. ``` servername(config-extension 5000)# show ! Generating running-config !!!!!   ! -------------- Extensions ---------------- extension 5000   always_autoanswer no   callerid_number 5000   call_screening no   cos internal+local         ### changes saves successfully   device_type SIP   in_directory yes   phonegroup carpet_agents   ### changes saves successfully   phonemake_id generic   phonemodel_id generic   phone_type Generic   record no   tenant_name default   voicemail_enable no   sip     allow ulaw,alaw,adpcm,gsm     call-limit 4     canreinvite no     disallow g723,slin,ilbc,lpc10,g729,speex,g726aal2,g722     host dynamic     nat yes     qualify yes     rtpholdtimeout 60     rtptimeout 60     secret 35712c6fd77554c7d6902ebb5831030f     sendrpid yes     trustrpid no     username 5000     exit   exit   exit ```
# Voicemail Setup Voicemail must be enabled manually on an **extension**. On most systems, voicemail is disabled by default 1\) Enter the CLI's configuration mode. 2\) Select the **extension** to set up voicemail on. ``` vbox-markm(config)# extension 1000 1001 1005 1234 5000 1050 AB   560 vbox-markm(config)# extension 5000 vbox-markm(config-extension 5000)# ```
3\) Enable voicemail using the following command. ``` vbox-markm(config-extension 5000)# voicemail_enable yes ```
4\) Use the show command to show voicemail has been enabled. ``` vbox-markm(config-extension 5000)# show ! Generating running-config !!!!!   ! -------------- Extensions ---------------- extension 5000   always_autoanswer no   callerid_number 5000   call_screening no   cos internal+local+ld   device_type SIP   in_directory yes   phonegroup carpet_agents   phonemake_id generic   phonemodel_id generic   phone_type Generic   record no   tenant_name default   vmail_phonegroup_override internal   voicemail_enable yes              ### Voicemail has been enabled   sip     allow ulaw,alaw,adpcm,gsm     call-limit 4     canreinvite no     disallow g723,slin,ilbc,lpc10,g729,speex,g726aal2,g722     host dynamic     nat yes     qualify yes     rtpholdtimeout 60     rtptimeout 60     secret 35712c6fd77554c7d6902ebb5831030f     sendrpid yes     trustrpid no     username 5000     exit   voicemail                         ### Voicemail has been enabled, when it's disabled this and it's settings will not show.     format sln     override_phonegroup_name internal     pin 5000     voicemail yes     exit   exit   exit ```
5\) There are additional voicemail options, such as setting an email to forward voicemail. ``` vbox-markm(config-extension 5000)# voicemail vbox-markm(config-extension 5000 voicemail)#                            ### Use ? to see the available options, it will also show the description as shown below   attach                        Enable/Disable attach voicemail recording to email   callback                      Context to call back from   delete                        Enable/Disable deleting voicemail from the server after notification   dialout                       Context to dial out from (option 4 from advanced menu if enabled)   do                            To run exec commands in config mode   email                         Email address to use when sending voicemail email notification   envelope                      Enable/Disable envelope information playback before message playback   exit                          Exit from this level (with notification of incomplete config)   forcegreetings                Force greeting to be recorded if the mailbox password is the same as the mailbox number   forcename                     Force name to be recorded if the mailbox password is the same as the mailbox number   format                        Format for the voicemail recording   fromstring                    The 'From' name when sending a voicemail email notification   hidefromdir                   Enable/Disable hiding this mailbox from the company directory   maxgreetingstime              Maximum number of seconds for a voicemail greeting   maxlogins                     Maximum number of failed login attempts before hanging up on user   maxmsgs                       Maximum number of messages that this voicemail box can contain before it is considered full   maxsecs                       Maximum number of seconds that a voicemail message can be   minsecs                       Minimum number of seconds that a voicemail must be in order to be saved   nextaftercmd                  Enable/Disable automatically proceeding to the next message after the user enters a command   no                            Clear setting   operator                      Enable/Disable the ability for the caller to dial 0 from voicemail   override_phonegroup_name      Optionally put this mailbox into a different phonegroup than the one the extension is a part of   pin                           (*) Voicemail pin number   portal_voicemail_folders_hide   review                        Enable/Disable the ability for the caller leaving a message to review and/or rerecord message before saving it   saycid                        Enable/Disable say callerid for voicemail message   sayduration                   Enable/Disable saying the message duration before playing the message   saydurationm                  Minimum number of minutes of duration needed when saying the duration   sendvoicemail                 Enable/Disable the ability for the user to compose and send a voicemail while inside voicemail (option 5 from advanced menu if enabled)   show                          Show the running-config for the current item   silencethreshold              What level do we consider silence.  Lower numbers mean more sensitive   tz                            Timezone to use for this mailbox   voicemail ```
6\) Enable the voicemail to email feature, set the email where voicemail should be forwarded, and then use the **show** command to ensure your settings were saved. ``` vbox-markm(config-extension 5000 voicemail)# attach yes                         ### enables attachment of voicemail on emails vbox-markm(config-extension 5000 voicemail)# email notarealemail@zeromail.com   ### email address voicemail will be sent to. vbox-markm(config-extension 5000 voicemail)# show ! Generating running-config !!!!!   ! -------------- Extensions ---------------- extension 5000   always_autoanswer no   callerid_number 5000   call_screening no   cos internal+local+ld   device_type SIP   in_directory yes   phonegroup carpet_agents   phonemake_id generic   phonemodel_id generic   phone_type Generic   record no   tenant_name default   vmail_phonegroup_override internal   voicemail_enable yes   sip     allow ulaw,alaw,adpcm,gsm     call-limit 4     canreinvite no     disallow g723,slin,ilbc,lpc10,g729,speex,g726aal2,g722     host dynamic     nat yes     qualify yes     rtpholdtimeout 60     rtptimeout 60     secret 35712c6fd77554c7d6902ebb5831030f     sendrpid yes     trustrpid no     username 5000     exit   voicemail     attach yes                            ### saved successfully     email notarealemail@zeromail.com      #### " "     format sln     override_phonegroup_name internal     pin 5000     voicemail yes     exit   exit   exit ```

It is important to remember to use the correct email address. That being said, it is NOT recommended to disable saving the voicemail on the extension itself and only have it sent through email since your voicemail could be lost if there is something wrong outside of the Intellasoft platform (transmission issues, email server (SMTP) issues).

7\) Lastly it is important to set a PIN for the voicemail, so the user of the extension can access their voicemail securely and prevent unwanted access. ``` vbox-markm(config-extension 5000 voicemail)# pin 0011 ```
# Extension Settings Description You can also use the "**?**" key to view the description while in the CLI. **\*** indicates a required setting.
Setting Description
all\_call\_forward Call forwarding
always\_autoanswer Whether or not to send an always answer header when calling this extension
autoanswergroup\_id
busy\_call\_forward If the extension is busy or unava
call\_screening
callerid\_nameCaller ID name
callerid\_number Caller ID number
cosClass of service when this extension makes a call
department\_name
device\_type (\*) Protocol that this device will use
didInbound DID (Direct Inward Dialing)
doTo run exec commands in config mode
exitExit from this level (with notification of incomplete config)
external\_calleridWhat callerid to use when the extension dials out a route
iaxChange IAX-specific extension settings
in\_directory Enable/Disable showing this extension in company directories
no Clear settings
override\_extensionOverride the dialable extension
phone\_typeExtension type
phonegroupPhonegroup that this extension is a member of
phonemake\_id
phonemodel\_id
polycomMAC Address of the physical phone this extension is assigned to
polycom\_reg Registration number on the physical phone (ie: polycom reg number)
recordWhether to record all calls to/from this device
ringseconds\_till\_voicemail
showShow the running-config for the current item
sipChange SIP-specific extension settings
tenant\_name Tenant that owns this phone
twinning\_numberTwinning number. Ring an external number such as a cell phone.
user\_id
username Web portal username that is assigned to this extension (Note: a username can be assigned to more than one extension)
vmail\_phonegroup\_overrideOverride what phonegroup this extension's mailbox is a member of
vmail\_subscribe\_overrideOverride what mailbox this extension subscribes to
voicemailChange voicemail settings
voicemail\_enable Enable/disable voicemail for this extension