للمطورين

توثيق الـ API

Base URL: https://whatsappsender.codenji.com/api/v1 — أرسل مفتاحك في ترويسة Authorization: Bearer wsk_xxxx. أصدر مفتاحك من لوحة التحكم.

إرسال رسالة

POST /messages

{
  "to": "962790000000",
  "message": "مرحباً! طلبك جاهز 🎉"
}

قواعد الرد الآلي

GET|POST /auto-reply · PATCH|DELETE /auto-reply/:id

{
  "name": "استفسار المنيو",
  "match_mode": "contains",
  "keywords": ["منيو", "أسعار"],
  "reply_text": "أهلاً! منيو اليوم هنا: https://...",
  "priority": 10
}

Webhooks

GET|POST /webhooks · DELETE /webhooks/:id — كل حدث يصل موقّع بـ HMAC-SHA256 في ترويسة X-Signature.

الحساب والرسائل

GET /me — بيانات الحساب والرصيد. GET /messages?limit=50 — سجل الرسائل.