This app demonstrates how to concatenate long text messages using the SMS API.
You will need:
git clone https://github.com/Nexmo/sms-node-concat-tutorial.git
cd sms-node-concat-tutorial
npm install
Rename the config file:
mv .env-example .env
Fill in the values in .env
as appropriate.
Run the following command in the application directory:
npm start
The application should be running on the port you specified in .env
.
Configure the webhook URL (https://example.com/webhooks/inbound-sms
) in your Dashboard Settings. If you are using ngrok
, this will be in the form:
https://demo.ngrok.io/webhooks/inbound-sms
Send a long (> 160 standard GSM characters) text message to the number you specified in the TO_NUMBER
setting in your .env
file.
The console output of server.js
should show the invididual message parts and then the complete message once all the parts have been received and reassembled.
The content of this project itself is licensed under the Creative Commons Attribution 4.0 International license, and the underlying source code used to format and display that content is licensed under the MIT license.