Please read this information carefully, so you can best use the code snippets.
- Create a Nexmo Account
- Install Node JS - required for using the Nexmo Command Line Interface (CLI).
- Install the Beta version of the Nexmo CLI
- Install or update the Beta version of the Nexmo Node client library - only required if using Node.
- Configure webhooks.
- Know how to write a webhook server
- Know how to test your webhook server locally
The following replaceable information depends on the library and specific call:
||Private key path.|
||The Nexmo Application ID.|
All phone numbers are in E.164 format.
||Replace with your Nexmo Number. E.g. 447700900000|
||Replace with number you are sending from. E.g. 447700900002|
||Replace with the number you are sending to. E.g. 447700900001|
Some code snippets have more specialized variables, such as Facebook Page IDs, that will need to be replaced by actual values. Where required, these are specified on a per-code snippet basis.
The main ones you will meet here are:
/webhooks/inbound-message- You will receive a callback here when Nexmo receives a message.
/webhooks/message-status- You will receive a callback here when Nexmo receives a message status update.
If you are testing locally using Ngrok you will set your webhook URLs in the Nexmo Application object using a format similar to the following examples:
demo in the above with whatever Ngrok generates for you, unless you have paid for a reusable URL.