Role: <dial> command is used when call needs to leave the system and connect with another number. For example, forwarding the call on number 1949300360 to another number 19492321402, requires system to dial another number and connect the 2nd leg with original caller. More actions can be taken if the called part does not pickup the call.


  • Number Masking: You don't want to expose your cell phone number to your contacts. People call the DID number and that number can be forwarded to your cell phone.

  • Multiple Business Numbers: You have many numbers from different sources and want to forward all the call to your main office line.

  • Call tacking and lean generation: Have a dedicated number for each ad or landing page and forward the call to a call center. Later you can generate a report which number was called most often.

While there are no limitation on where <dial> can be used, there definitely is requirement or set of attributes to use with <dial>. Below is a list of attributes to be used with <dial>, each attribute has a specific function and can use certain values.






Callback URL







30 seconds


integer value

4 hours


valid phone number

caller’s caller id

Here is an example of how <dial> is used within code.

<?xml version="1.0" encoding="UTF-8"?> 

In another example, dial will record the sessions and disconnect the call after 60 seconds.

<?xml version="1.0" encoding="UTF-8"?> 
    <dial record="on" timeout="60">19492321402</dial>

DIDforSale offer many ways you can connect the caller. Some are free and some are paid. For example, forward the call to another sip account or sip based pbx does not cost extra, While forwarding the call to another number might include outbound charges as well as inbound (Depending on what plan and agreement you have in place).

Here are more keyword you can use inside dial to connect the caller to second leg. These keywords can be nested inside dial command.




phone number to dial


get the free SIP client and connect the call to SIP Cleint


Sip URI, spi:bob@example.com

Connect the caller to a conference bridge


Connect the caller to the 1st person waiting in the queue

A simple example to nest <number> keyword to <dial>

<?xml version="1.0" encoding="UTF-8"?> 
    <dial record="on" timeout="60">        


Example to Call a SIP Trunk using >sip>, here call will be forwarded to sip.mydomain.com. sip.mydomain.com must accept all calls from our IP. In the example username part is blank, so dialed number will be appended to the make full uri.

<?xml version="1.0" encoding="UTF-8"?> 
    <dial record="on" timeout="60">        

Last updated