WILCYBERTEK
DOCS v1.0
Back to Gateway Dashboard Get API Key
▶ API Reference Documentation

WilCybertek SMS Gateway API

A direct, low-latency SMS gateway connecting your applications to Zambia's three major mobile networks — MTN, Airtel, and Zamtel — via physical on-premise GSM hardware. No international routing. No hidden relay fees.

All Networks Online TLS 1.3 Encrypted <5s Avg. Delivery REST / JSON

Quickstart

Send your first SMS message in under 5 minutes.

1
Register & Get Your API Key
Create a free developer account. Your unique 32-character API key is generated automatically and displayed in your dashboard.
2
Refill Your SMS Credits
Top up your balance via MTN, Airtel, or Zamtel Mobile Money directly from your dashboard. Credits are added instantly after payment confirmation.
3
Make Your First API Call
POST a JSON payload to our endpoint with your API key, recipient phone number, and message.
cURL — Quick Test
curl -X POST https://sms.wilcybertek.com/api \
  -H "Content-Type: application/json" \
  -d '{
    "api_key": "YOUR_API_KEY_HERE",
    "to":      "260977000000",
    "message": "Hello! This is my first WilCybertek SMS."
  }'

Authentication

Every API request must include your unique API Key.

Keep your API key secret. Never expose it in client-side JavaScript, public repositories, or shared environments.
You can regenerate your API key at any time from your dashboard. Regenerating immediately invalidates the previous key.

Including Your Key

JSON
{
  "api_key": "YOUR_32_CHAR_API_KEY",
  "to": "260977000000",
  "message": "Your message here"
}

Send SMS

The primary endpoint for sending a single SMS message to any Zambian mobile number.

POSThttps://sms.wilcybertek.com/api

Request Parameters

ParameterTypeRequiredDescription
api_keystringRequiredYour 32-character developer API key.
tostringRequiredRecipient phone number. E.g. 260977000000.
messagestringRequiredThe SMS message body. Max 160 chars per SMS.
sender_idstringOptionalCustom sender name (max 11 chars). Subject to network support.

Example Request

PHP
<?php
$payload = json_encode([
    "api_key" => getenv("WCT_API_KEY"),
    "to"      => "260977000000",
    "message" => "Your account balance is K250.00"
]);
$ch = curl_init("https://sms.wilcybertek.com/api");
curl_setopt_array($ch, [
    CURLOPT_POST=>true, CURLOPT_POSTFIELDS=>$payload,
    CURLOPT_RETURNTRANSFER=>true,
    CURLOPT_HTTPHEADER=>["Content-Type: application/json"]
]);
$r = json_decode(curl_exec($ch), true);
curl_close($ch);
echo $r['success'] ? "✓ Queued" : "Error: ".$r['error'];

Response

200 OK — Success
{
  "success": true,
  "id": 42,
  "status": "QUEUED"
}
401 Unauthorized — Error
{
  "error": "Invalid API key"
}

Bulk SMS

Send the same message to multiple recipients in a single API call.

POSThttps://sms.wilcybertek.com/api/bulk
Bulk sends are processed asynchronously. Each message deducts 1 credit. Maximum 500 recipients per bulk request.
JSON Body
{
  "api_key": "YOUR_API_KEY",
  "recipients": ["260977000001", "260966000002"],
  "message": "Flash sale! 30% off all services today."
}

Check Balance

Retrieve your current SMS credit balance programmatically.

GEThttps://sms.wilcybertek.com/api/balance?api_key=YOUR_KEY
200 OK
{
  "balance": 249,
  "is_unlimited": false
}

Message Logs

Retrieve a paginated list of your recent message activity including delivery statuses.

GEThttps://sms.wilcybertek.com/api/logs?api_key=KEY&page=1&limit=50

Supported Networks

WilCybertek routes messages through physical Android gateway hardware with active local SIM cards.

MTN Zambia
Prefixes: 076, 096, 097
Airtel Zambia
Prefixes: 075, 095, 077
Zamtel
Prefixes: 050, 055, 056
All three networks are active. The gateway polls every 5 seconds, ensuring typical delivery within 5–30 seconds.

Phone Number Formatting

All phone numbers must be submitted in Zambian international format.

FormatExampleAccepted?
International (recommended)260977123456✅ Yes
With + prefix+260977123456✅ Yes (auto-stripped)
Local format0977123456⚠️ Auto-converted
Without country code977123456❌ Will fail

Rate Limits

To maintain fair usage across all developers:

Single SMS
120
requests per minute
Bulk SMS
10
bulk requests per minute
Balance / Logs
300
requests per minute
Max Bulk Recipients
500
numbers per bulk call
When you exceed rate limits, the API returns HTTP 429 Too Many Requests.

Error Codes

All errors return a JSON body with an error field.

HTTP StatusError CodeDescription
400MISSING_PARAMSRequired fields are missing.
401INVALID_KEYThe API key is invalid or regenerated.
402INSUFFICIENT_CREDITSCredit balance is zero.
400INVALID_RECIPIENTPhone number is malformed.
429RATE_LIMITEDAPI rate limit exceeded.
503GATEWAY_UNAVAILABLEGSM gateway device is offline. Messages are queued.
500INTERNAL_ERRORUnexpected server error.

Security Best Practices

Never embed your API key in client-side code. Your key should only live in server-side backend code.
Rotate your key regularly. Use the Regenerate Key feature in your dashboard — old keys are invalidated immediately.
Use environment variables. Store your API key as WCT_API_KEY rather than hardcoding it in source files.
All traffic is TLS 1.3 encrypted. API keys are stored using Argon2id hashing — never in plain text.

PHP Examples

PHP — Send OTP
<?php
function sendOTP(string $phone, int $otp): bool {
    $ch = curl_init("https://sms.wilcybertek.com/api");
    curl_setopt_array($ch, [
        CURLOPT_POST=>true, CURLOPT_RETURNTRANSFER=>true,
        CURLOPT_HTTPHEADER=>["Content-Type: application/json"],
        CURLOPT_POSTFIELDS=>json_encode([
            "api_key" => getenv("WCT_API_KEY"),
            "to"      => $phone,
            "message" => "Your code is: {$otp}. Valid 5 mins."
        ])
    ]);
    $r = json_decode(curl_exec($ch), true);
    curl_close($ch);
    return !empty($r['success']);
}

Python Examples

Python
import os, requests

def send_sms(to: str, message: str) -> dict:
    r = requests.post("https://sms.wilcybertek.com/api",
        json={"api_key": os.environ["WCT_API_KEY"], "to": to, "message": message},
        timeout=10)
    r.raise_for_status()
    return r.json()

result = send_sms("260977000000", "Payment confirmed!")
print("Queued:", result.get("id"))

JavaScript Examples

Node.js
// Server-side only — never expose key in browser
const sendSMS = async (to, message) => {
  const r = await fetch("https://sms.wilcybertek.com/api", {
    method:"POST", headers:{"Content-Type":"application/json"},
    body: JSON.stringify({api_key: process.env.WCT_API_KEY, to, message})
  });
  return r.json();
};
sendSMS("260977000000", "Order ready!").then(d => console.log(d));

cURL Examples

cURL
curl -X POST https://sms.wilcybertek.com/api \
  -H "Content-Type: application/json" \
  -d '{"api_key":"YOUR_KEY","to":"260977000000","message":"Hello!"}'
READY TO BUILD?

Start Sending SMS in Minutes

Create your free developer account and connect to Zambia's fastest SMS gateway.

Create Free Account View Dashboard