![]() If you’re running Node-RED on a public webserver instead of your local machine, you can skip this stage. Next you’ll have to expose your local server to the internet, so that Vonage can access it. The http response node should have 200 set as Status code, but don’t worry about it, this is the default value.Įxposing Your Local Server to the Internet In the http input node, select GET as a Method and fill in the URL field with something like /inbound-sms. Connect a http input node to a http response node, as well as to a debug node, so that you can view your inbound messages in the debug area. Inbound Messages to that number will then be sent to your webhook endpoint.įirst, set up this webhook endpoint in your Node-RED editor. In order to receive SMS messages using the Vonage API, you need to associate a webhook endpoint with a virtual number that you have rented from Vonage. If you’ve just signed up, the initial cost of a number will be easily covered by your available credit. To purchase one, go to Numbers > Buy Numbers and search for one that meets your needs. ![]() This tutorial also uses a virtual phone number. Once you have an account, you can find your API Key and API Secret at the top of the Vonage API Dashboard. If you don’t have one already, you can sign up today and start building with free credit. ![]() To complete this tutorial, you will need a Vonage API account. Optional: ngrok-get up to speed with Aaron’s blog post.Node.js and Node-RED installed on your machine.Get this flow from the Node-RED Library or follow along! Prerequisitesīefore getting started, you’ll need a few things: Now it’s time to learn about receiving SMS messages by implementing a webhook endpoint using Node-RED. In the previous article, you set up your Vonage API account and Node-RED editor, learned how to send SMS messages, and learned how to handle delivery receipts. This is the second article in a series of “Getting Started with Nexmo and Node-RED” tutorials.
0 Comments
Leave a Reply. |