If you want to handle an inbound message or receive message status updates, you will need to configure your inbound message webhook and message status webhook.
There are at least two webhooks you may need to configure:
- Message Status webhook
- Inbound Message webhook
If you want to receive inbound messages you will need to configure an Inbound Message Webhook URL. When an inbound message is received this webhook URL will be invoked with the message payload.
If you wish to get a status update on a sent message, such as
accepted, then you will need to configure the message status webhook.
TIP: If the Webhook URLs for messages in your Nexmo Account are already in production use and you would like a second one for using the Messages API, please email email@example.com and ask for a sub API Key.
Enter your Webhook URLs in the fields labeled Status URL and Inbound URL.
The values you enter for webhook URLs depends on where your webhook server is located. If your server was running on port 3000 on
example.com your webhook URLs might be:
NOTE: The default method of
POST should be used for both of the webhook URLs.
If you want to test your application locally you can use Ngrok.
See our information on Using Ngrok for local development
If using Ngrok in this manner you would use the Ngrok URLs for your webhook URLs: