![]() ![]() On Figure 3, you can see the source code of the SendScheduledSMS project, opened on Notepad. Video 1 - How to download and set up your project Node.Js sms example: SendScheduledSms.mjs (in Notepad) Your browser does not support the video tag. This is the file that contains the MessageApi and all the stuffs you need to Once youĪdded the needed files to your project, you might notice that a there is a file called This video shows you how to download and use the SendScheduledSms.js project. How to send SMS from Node.Js using the sms api (Video tutorial) "response_msg": "Messages queued for delivery.", User-Agent: OZEKI 10.3.120 (Content-Type: application/json charset=utf8 If it is installed on a different computer it should Installed on the same computer where the JavaScript sms application is running, Note that the IP address (127.0.0.1) shouldīe replaced to the IP address of your SMS gateway. ![]() To send SMS from Node.Js, your JavaScript will will have to issue an HTTP request to the SMS gateway. HTTP API url to use send sms from Node.Js The final step to prepare your environment is to create a HTTP sms api userĬreate a user with a username of "http_user", and with a password of "qwe123" to makeĪfter the environment is setup, you can run your JavaScript code. You can send a test sms from the Ozeki GUI to verify, that your mobile The SMS gateway can be installed on the same computer, where you develop your JavaScript code in Viusal Studio Code or any other code editor.Īfter installation, the next step is to connect Ozeki SMS Gateway to the mobile network. To be able to send SMS from Node.Js, first you need to install Ozeki SMS Gateway Install Ozeki SMS Gateway and create an HTTP API user Read the response message on the console.Use the Send method to send your message.Create the SMS by creating a new Message object.Connect Ozeki SMS Gateway to the mobile network.How to send a scheduled SMS from Node.Js (Quick steps) Node-fetch package with the following command:Ĭode 1 - Command to install the node-fetch package. This project has dependencies, so before you start you have to install the You will also findĪ SendScheduledSms.mjs file in the project, which contains the example code to show The SendScheduledSms.js.zip file contains the library, which gives youĪll the tools neccessary to send and receive SMS messages. What is in the SendScheduledSms.js.zip file? The source code explained in this article can be downloaded and used and modified free of charge.ĭownload: SendScheduledSms.js.zip (4.46Kb) The SMS gateway will forward your message to the mobile network either through a wireless SMS and you can use the MessageApi class to send the SMS to the SMS gateway. You can use the Message class to create the ![]()
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |