SMS Notifications
Forward inbound email summaries to a Tanzanian phone number via SMS. Configure per sender ID, inspect delivery status, and revoke when needed.
In addition to webhooks, you can forward a short summary of each inbound message to a mobile phone over SMS — handy for ops alerts and urgent customer contact. SMS is delivered through the SendAfrica platform.
Create a notification
curl -X POST https://api.mailafrica.online/api/sms/notifications \
-H "X-API-Key: MAIL_<your_api_key_here>" \
-H "Content-Type: application/json" \
-d '{
"address_id": 42,
"phone_number": "+255712345678",
"api_key": "sendafrica-api-key"
}'Fields: address_id (required, must be yours), phone_number (required, Tanzanian +255 or 0 format), api_key (required — the SendAfrica API key used to send the SMS).
api_key back once. Store it — it is not returned again. At rest the key is encrypted with an authenticated cipher before it touches the database, and it is used only to send these summary SMS messages. To rotate the key, revoke the notification and create a new one with the replacement key.What gets sent
On each inbound message, an SMS is sent like: New email from <From>: <Subject> — truncated to fit a single 160-character GSM-7 part (an ellipsis marks the cut). Each SMS is retried up to 3 times on transient provider errors.
Deliveries & revoke
# List notifications for an address
curl "https://api.mailafrica.online/api/sms/notifications?address_id=42" \
-H "X-API-Key: MAIL_<your_api_key_here>"
# Delivery history for a notification
curl https://api.mailafrica.online/api/sms/notifications/7/deliveries \
-H "X-API-Key: MAIL_<your_api_key_here>"
# Stop forwarding
curl -X POST https://api.mailafrica.online/api/sms/notifications/7/revoke \
-H "X-API-Key: MAIL_<your_api_key_here>"Deliveries report status (sent | failed), the provider message id, the attempt count, and any error code.