Node.js
Using the Dashboard
First you can browse your existing numbers.
If you have no spare numbers you can buy one.
Using the Vonage CLI
Once you have found a number you are satisfied with, you can purchase that using the vonage numbers buy command:
vonage numbers buy US 16127779311
β
Searching for numbers
Are you sure you want to purchase the number 16127779311 for β¬0.90? [y/n] y
β
Purchasing number
Number 16127779311 purchased
Number: 16127779311
Country: πΊπΈ United States
Type: Mobile
Features: MMS, SMS, VOICE
Monthly Cost: β¬0.90
Setup Cost: β¬0.00
Linked Application ID: Not linked to any application
Voice Callback: Not Set
Voice Callback Value: Not Set
Voice Status Callback: Not Set
vonage numbers buy US 16127779311 β
Searching for numbers Are you sure you want to purchase the number 16127779311 for β¬0.90? [y/n] y β
Purchasing number Number 16127779311 purchased Number: 16127779311 Country: πΊπΈ United States Type: Mobile Features: MMS, SMS, VOICE Monthly Cost: β¬0.90 Setup Cost: β¬0.00 Linked Application ID: Not linked to any application Voice Callback: Not Set Voice Callback Value: Not Set Voice Status Callback: Not Set
Connect to a WebSocket
Connect an inbound call to a WebSocket with the Voice API
Steps
1
Introduction2
Prerequisites3
Buy a Vonage number4
Create a Voice Application5
Link a Vonage number6
Create the project7
Write your answer webhook8
Write your event webhook9
Create the WebSocket10
Create your server11
Test your application12
Conclusion13
What's next?