Robo SMS API Documentation

Welcome to the official Robo SMS Pakistan API documentation.

Our REST API allows you to:

  • Send Transactional SMS
  • Send Marketing SMS
  • Send Bulk SMS
  • Check Account Balance
  • Integrate messaging into your software, CRM, ERP, website, or mobile app

All integrations are secure and API-key protected.


๐Ÿ” Authentication

To use the Robo SMS Pakistan API, you need:

  • Registered Email Address
  • API Key

You can generate your API key from your Robo SMS Pakistan Dashboard after logging in.

Required Parameters for Authentication:

  • email โ€“ Your registered account email
  • key โ€“ Your unique API key

โš ๏ธ Keep your API key secure. Do not expose it in frontend code or public repositories.


๐Ÿš€ 1. Send SMS API

Endpoint

POST
https://portal.robosms.pk/api/send-message

โš ๏ธ GET method is NOT supported for this route.


Request Headers

You can send data using either:

  • Content-Type: application/json
    OR
  • Content-Type: application/x-www-form-urlencoded

Both are supported.


Required Parameters (Single SMS)

ParameterTypeRequiredDescription
emailstringYesRegistered account email
keystringYesYour API key
maskstringYesApproved sender mask (e.g., SMS-ALERT)
tostringYesRecipient number in international format (923001234567)
messagestringYesSMS text (Recommended: max 160 characters)

Example: Send Single SMS (JSON)

curl -X POST https://portal.robosms.pk/api/send-message \
-H "Content-Type: application/json" \
-d '{
  "email": "[email protected]",
  "key": "YOUR_API_KEY",
  "mask": "SMS-ALERT",
  "to": "923001234567",
  "message": "Your order #12345 has been confirmed."
}'

Example: Send Single SMS (Form URL Encoded)

curl -X POST https://portal.robosms.pk/api/send-message \
-H "Content-Type: application/x-www-form-urlencoded" \
--data "[email protected]&key=YOUR_API_KEY&mask=SMS-ALERT&to=923001234567&message=Your%20order%20confirmed"

๐Ÿ“ฆ Bulk SMS (Multiple Numbers โ€“ Same Message)

To send the same message to multiple numbers in one request:

Add this parameter:

  • multiple=1

Send numbers comma-separated in the to field.


Required Parameters (Bulk SMS)

ParameterRequired
emailYes
keyYes
maskYes
multipleYes (set value to 1)
toYes (comma-separated numbers)
messageYes

Example: Bulk SMS Request

curl -X POST https://portal.robosms.pk/api/send-message \
-H "Content-Type: application/x-www-form-urlencoded" \
--data "[email protected]&key=YOUR_API_KEY&mask=SMS-ALERT&multiple=1&to=923151231015,923151231016&message=Special%20discount%20available"

Important Note

If each user requires a personalized message, send requests individually in a loop from your system.


๐Ÿ“Š 2. Check SMS Balance API

Endpoint

GET

https://portal.robosms.pk/api/check-balance?key=YOUR_API_KEY


Example Request

curl https://portal.robosms.pk/api/check-balance?key=YOUR_API_KEY

Sample Response

{
  "sms": {
    "code": "000",
    "balance": "12.50",
    "username": "yourusername",
    "message_rates": "0.50"
  }
}

๐Ÿ“˜ API Response Codes

CodeMeaning
000Message queued successfully
100Message sent successfully
101Message sending failed
102Message handed to telecom
200Success response
201General API error
202Required parameters missing
203Invalid API key
204Admin balance insufficient
205User balance insufficient
206Account suspended or blocked
210IP not whitelisted
212Masking not authorized
213Character limit exceeded
215Invalid number format (0345…)
216Invalid number format (345…)

๐Ÿ›  How to Start Using Robo SMS API

  1. Sign Up on Robo SMS Portal
  2. Purchase an SMS Package (Transactional / Marketing)
  3. Get your Sender Mask Approved from PTA
  4. Generate API Key from Dashboard
  5. Integrate API into your system

You can integrate using:

  • PHP
  • Laravel
  • Node.js
  • Python
  • Google Sheets
  • CRM/ERP systems
  • Any REST-supported environment

๐Ÿ”’ Security Best Practices

  • Store API keys on server-side only
  • Do not expose keys in JavaScript frontend
  • Whitelist your server IP for additional security
  • Validate numbers before sending

๐Ÿ“ž Need Help?

Email: [email protected]
Portal: https://portal.robosms.pk

Our technical team is available to assist with integration.