E2EHIRING Logo
Jobs
Jobs
courses
Courses
mentorship
Mentorship
more
Moredropdown
E2EHIRING Logo
more
Jobs
Jobs
courses
Courses
mentorship
Mentorship
HomeSepratorIconBlogsSepratorIconHow to make the phone calls from your own application using JS and AsteriskSepratorIcon

How to make the phone calls from your own application using JS and Asterisk

Han SoloVigneswaran Sekar
calendar6 Jul 2022
poster

In this page, We will look into the connection between asterisk and web application.

Description

  • We needs to use WSS(web socket) to make the asterisk connection.
  • In my previous blog, We have done the PJSIP configuration in /asterisk/pjsip.conf.
  • We will be need a  PJSIP credentials to make the connection.

System Requirements 

1. We need IP address or domain name with installed SSL certificate(either self signed or TLS). (TLS certification is required only for OUTBOUND calls not for extension calls)

2. 80,443,8089 Ports should be accessible.

3. Sudo access  should be enabled for the user.

Connection between Asterisk and your own application

We will be use the below libraries to make the the connection between Asterisk and our application.

  1. https://www.doubango.org/sipml5/  (or)
  2. https://sipjs.com/

Once you imported the above libraries. Change the configuration settings. Use the Asterisk PJSIP credentials here.

Example:

realm -  'example.org' //Asterisk domain name

user name - 'webrtc_client' //pjsip user name 

password - 'webrc_client' //pjsip password

wss - 'sip:example.org:8089'  //full asterisk URL with port number

display_name - 'example' // organization or application name for asterisk connection

Once the configurations are done, You can make Outbound or Extension calls.

What can be done through Asterisk

We can use the below features in our applications from these libraries Sipml5 or Sipjs.

  1. Extension calls
  2. Outbound calls
  3. Messages
  4. Call Hold / Resume
  5. Explicit Call transfer


Posts related to Asterisk:

1. Asterisk server setup  -  https://e2ehiring.com/blogs/asterisk%20server%20setup-151

2. One way audio issue in Asterisk  - https://e2ehiring.com/blogs/one%20way%20audio%20issue%20in%20asterisk-232

Recent Posts

Rapid Changes in the Coding World: Need for High Skilled Programmers e2eHiring Bridges this Gap with the Mentorship Program April 2023

Rapid Changes in the Coding World: Need for High Skilled Programmers e2eHiring Bridges this Gap with the Mentorship Program April 2023

How to publish your Android app on Google Play Store

How to publish your Android app on Google Play Store

Creating Dynamic User Interfaces with Android Motion Layout

Creating Dynamic User Interfaces with Android Motion Layout

Bean Life Cycle

Bean Life Cycle

Pom.XML

Pom.XML

copycopycopycopy

Han Solo

Recent Posts

Rapid Changes in the Coding World: Need for High Skilled Programmers e2eHiring Bridges this Gap with the Mentorship Program April 2023

Rapid Changes in the Coding World: Need for High Skilled Programmers e2eHiring Bridges this Gap with the Mentorship Program April 2023

How to publish your Android app on Google Play Store

How to publish your Android app on Google Play Store

Creating Dynamic User Interfaces with Android Motion Layout

Creating Dynamic User Interfaces with Android Motion Layout

Bean Life Cycle

Bean Life Cycle

Pom.XML

Pom.XML