Skip to main content

Overview

This guide shows how to send an SMS notification using Plivo’s APIs and the Node.js SDK.

Prerequisites

  • A Plivo account — sign up for free if you don’t have one.
  • An SMS-enabled Plivo phone number to send messages to the US and Canada. You can rent a number from the Plivo console.
  • Node.js and the Plivo Node.js SDK installed.

Create and run the application

Create a file named send_sms.js and paste this code into it. This script sends a notification using the messages.create function.Replace the <auth_id>, <auth_token>, <sender_id>, and <destination_number> placeholders with your actual values.

Test

Save the file and run it from your terminal.
You should receive the SMS notification on your destination phone.