Setting up your endpoint to listen for callbacks

You can initially set up a web application to receive the callbacks on your local machine and check how the callback process works. For this, you need to expose a web server running on your local machine to the internet. This process can be done with the help of the ngrok application. For more information, refer to this link.

Ngrok can be installed on your machine using the following command line.

npm install ngrok -g

Once the setup is installed, you can expose your local web application port, which you have configured to listen and respond to callbacks using the following command line:

ngrok http -host-header=localhost <Your local web application port>

Ex:
ngrok http -host-header=localhost http://localhost:42033

After executing the above command, you will get an output, as follows:

Session Expires               1 hour, 59 minutes                                                                        
Version                       2.3.38                                                                                    
Region                        United States (us)                                                                        
Web Interface                 http://127.0.0.1:4040                                                                     
Forwarding                    http://ecaa591de0f5.ngrok.io -> http://localhost:42033                                    Forwarding                    https:// ecaa591de0f5.ngrok.io -> http://localhost:42033

Choose the link with "HTTPS" and use it in the upcoming webhook setup within your BoldSign application.