HomeAPI & DevSend SMS with Node.js

Send SMS with 🟢 Node.js

Integrate iSMS bulk SMS into your Node.js application using the built-in https module — no external dependencies required.

Node.js · https module HTTPS POST v2.0
ℹ️
Before using the API, register a free iSMS account and purchase SMS credits. See the full SMS API docs for all parameters and error codes.
API Endpoints
HTTPS Endpoints — use all 3 for high availability
// Primary
https://smtpapi.vocotext.com/isms_send_all_id.php

// Mirror 2
https://smtpapi2.vocotext.com/isms_send_all_id.php

// Mirror 3
https://www.isms.com.my/isms_send_all_id.php
Send a Single SMS
Node.js · https module POST
const https = require('https');
const querystring = require('querystring');

const params = querystring.stringify({
  un:          'your_username',   // iSMS account username
  pwd:         'your_password',   // iSMS account password
  dstno:       '601X-XXXXXXX',    // Recipient — full international format
  msg:         'Hello from iSMS!',
  type:        '1',              // 1 = ASCII (English/BM), 2 = Unicode (Chinese/Arabic)
  agreedterm:  'YES',
  sendid:      'MyBrand'         // Optional sender ID (max 11 chars)
});

const options = {
  hostname: 'smtpapi.vocotext.com',
  path:     '/isms_send_all_id.php',
  method:   'POST',
  headers: {
    'Content-Type':   'application/x-www-form-urlencoded',
    'Content-Length': Buffer.byteLength(params)
  }
};

const req = https.request(options, (res) => {
  let data = '';
  res.on('data', chunk => data += chunk);
  res.on('end', () => {
    if (data.includes('2000')) {
      const trxId = data.split(':')[1];
      console.log('SMS sent! Transaction ID:', trxId);
    } else {
      console.error('Failed:', data); // e.g. -1004 = INSUFFICIENT CREDITS
    }
  });
});

req.on('error', err => console.error('Connection error:', err.message));
req.write(params);
req.end();
Multiple Recipients
Separate multiple numbers with semicolons ; — recommended max 30 per call.
Node.js · Multiple Recipients
const recipients = ['601X-XXXXXXX', '601X-XXXXXXX', '601X-XXXXXXX'];

const params = querystring.stringify({
  un:         'your_username',
  pwd:        'your_password',
  dstno:      recipients.join(';'),   // Semicolon-separated
  msg:        'Dear customer, your order is ready!',
  type:       '1',
  agreedterm: 'YES'
}); // ... same https.request() as above
✅ Success
2000 = SUCCESS:1143007207
// Save the transaction ID for delivery tracking
❌ Error
-1001 = AUTHENTICATION FAILED
-1003 = IP NOT ALLOWED
-1004 = INSUFFICIENT CREDITS
-1008 = MISSING PARAMETER
-1013 = INVALID TERM AGREEMENT
⚠️
Delivery Status Note (Malaysia): A 2000 response confirms submission to Telco SMSC only — not delivery to handset. For confirmed Sent → Received → Read tracking, consider WhatsApp Business API.

Ready to Integrate?

Register free, get your API credentials, and start sending in minutes.

📱 SMS Coverage — All Countries Worldwide

A B C D E F G H I J K L M N O P Q R S T U V Y Z