Skip to main content

Signature

sendSMS(payload: SMSPayload): Promise<any>

HTTP request

POST https://api.pindo.io/v1/sms/

Parameters

to
string
required
The recipient’s phone number in E.164 format (e.g. +250781234567).
text
string
required
The text content of the SMS message.
sender
string
required
The sender ID displayed to the recipient. Must be a registered sender ID or an approved alphanumeric string.

Example

import { PindoSMS } from 'pindo-sms';

const pindo = new PindoSMS('your-api-token');

const result = await pindo.sendSMS({
  to: '+250781234567',
  text: 'Hello from Pindo',
  sender: 'Pindo',
});

console.log(result);

Error handling

try {
  const result = await pindo.sendSMS({
    to: '+250781234567',
    text: 'Hello from Pindo',
    sender: 'Pindo',
  });
} catch (err) {
  console.error('Failed to send SMS:', err.message);
}
The phone number must be in E.164 format, including the country code (e.g. +250 for Rwanda). Requests with invalid numbers will be rejected by the API.

Build docs developers (and LLMs) love