Transports
Unifonic
Send SMS through the Unifonic el.cloud REST API.
Send SMS through Unifonic’s el.cloud REST API for transactional texts such as OTPs and alerts.
Wire the transport into createSmsSender so app code stays on the SMS channel API.
The one rule
Create this transport under
createSmsSender — do not call Unifonic from app code directly.Quick start
import { createSmsSender } from "sently/sms";
import { UnifonicTransport } from "sently/transports/unifonic";
const sender = createSmsSender({
transport: new UnifonicTransport({
appSid: process.env.UNIFONIC_APPSID!,
senderId: "MyBrand",
}),
});const result = await sender.send({ to: "+9665xxxxxxxx", body: "Hello" });
console.log(result.messageId, result.status);Configuration
| Option | Type | Default or requirement |
|---|---|---|
appSid | string | required (AppSid) |
senderId | string | required on send unless options.from is set |
statusCallback | string | optional public HTTPS DLR URL |
async | boolean | false |
options.from maps to SenderID. options.messageId maps to CorrelationID.
Phone numbers are normalized to international digits without + or leading 00.
Delivery webhooks
Parse Unifonic status callbacks with sently/webhooks/unifonic into DeliveryEvent[].
import { parse } from "sently/webhooks/unifonic";
const events = parse(await request.json());Troubleshooting
No. Use the sently SMS sender; this transport posts to el.cloud.unifonic.com for you.
Set senderId on the transport or pass from on each send.