Node.js
Configure your Voice Application
Now that you have defined your webhooks, you need to tell the Vonage API platform where to find them. You do that by configuring them in the Voice Application you created as part of the prerequisites for this tutorial.
You need to configure the Voice Application with the following information:
APPLICATION_ID- the UUID of your applicationAPPLICATION_NAME- a name for your applicationanswer_url- the URL where your webhook delivers the Nexmo Call Control Object that controls the flow of incoming calls.event_url- the URL the platform sends event information asynchronously to when the call status changes
The answer_url and event_url consist of your Ngrok domain name (as generated in the prerequisites for this tutorial) followed by the route for each webhook in your code.
Ensure that Ngrok is running before you perform this step.
Execute the following CLI command to update your application with the following data:
vonage apps:update APPLICATION_ID --name="APPLICATION_NAME" --voice_answer_url=https://mynewdomain.ngrok.io/webhooks/answer
For example:
vonage apps:update 228c1ad1-176d-406c-a63a-b97e6fd3fd52 --voice_answer_url=https://63daf1c05d6f.ngrok.io/webhooks/answer
Build a Call Menu
Create an interactive voice response (IVR) menu to handle customer calls
Available on:
Steps
1
Introduction2
Prerequisites3
What you will build4
Install the dependencies5
Create the server6
Create the answer webhook7
Create the DTMF webhook8
Create the event webhook9
Configure your Voice application10
Run it!11
Conclusion12
What's next?