Messaging
Unified messaging API for SMS, WhatsApp, and USSD.
Channels
| Channel | Providers | Features |
|---|---|---|
| SMS | Clickatell, Africa's Talking | OTPs, Notifications |
| WhatsApp Business API | Rich Media, Templates | |
| USSD | Network Providers | Interactive Menu Sessions |
Sending SMS
TypeScript
await client.messaging.sms.send({
to: '+27820000000',
body: 'Your Luna OTP is 1234'
});
Python
await client.messaging.sms.send(
to="+27820000000",
body="Your Luna OTP is 1234"
)
Go
client.Messaging().SMS().Send(ctx, &luna.SMSParams{
To: "+27820000000",
Body: "Your Luna OTP is 1234",
})
WhatsApp Templates
await client.messaging.whatsapp.send_template(
to="+27820000000",
template="welcome_message",
parameters=["John"]
)