Skip to main content
Glama
customer-replies-mcp-server

customer-replies-mcp-server

by alsaltitop

customer-replies-mcp-server

خادم MCP لإدارة وتوليد ردود العملاء لمحل صيانة الهواتف النقالة وأجهزة الكمبيوتر. يعمل مع Claude Desktop و Claude Code وأي عميل MCP آخر.

MCP server for managing and composing customer replies for a phone & computer repair shop. Arabic-first with English variants.

الأدوات | Tools

Tool

الوظيفة

replies_list_categories

عرض تصنيفات الردود وعدد القوالب في كل تصنيف

replies_search_templates

البحث في القوالب بالكلمة، التصنيف، اللغة، أو النبرة

replies_get_template

جلب قالب كامل مع المتغيرات {{variable}}

replies_compose_reply

تعبئة قالب بقيم حقيقية وإرجاع رد جاهز للإرسال

replies_whatsapp_link

تحويل رد (من قالب أو نص حر) إلى رابط wa.me جاهز للفتح والإرسال يدوياً على واتساب

replies_add_template

إضافة قالب جديد (المتغيرات تُستخرج تلقائياً من النص)

replies_update_template

تعديل قالب موجود

replies_delete_template

حذف قالب نهائياً

Related MCP server: whatsapp-mcp-server

التصنيفات | Categories

greeting, price_inquiry, diagnosis, repair_status, ready_for_pickup, delay_apology, warranty, complaint, unrepairable, data_disclaimer, part_unavailable, location_hours, payment, follow_up

17 قالباً جاهزاً مضمّناً (عربي + إنجليزي) تغطي: الترحيب، التسعير، نتيجة الفحص، تحديث الحالة، جاهزية الاستلام، الاعتذار عن التأخير، الضمان، الشكاوى، تعذر الإصلاح، إخلاء مسؤولية البيانات، قطع الغيار، الموقع والأوقات، الدفع، والمتابعة بعد التسليم.

التثبيت | Install

npm install
npm run build

التشغيل مع Claude Desktop / Claude Code

claude_desktop_config.json أو .mcp.json:

{
  "mcpServers": {
    "customer-replies": {
      "command": "node",
      "args": ["/ABSOLUTE/PATH/customer-replies-mcp-server/dist/index.js"],
      "env": {
        "REPLIES_DATA_PATH": "/ABSOLUTE/PATH/data/templates.json"
      }
    }
  }
}

Claude Code:

claude mcp add customer-replies -- node /ABSOLUTE/PATH/customer-replies-mcp-server/dist/index.js

تخزين البيانات | Data storage

القوالب تُحفظ في ملف JSON. المسار الافتراضي: ~/.customer-replies/templates.json. يُغيّر عبر متغير البيئة REPLIES_DATA_PATH. عند أول تشغيل يُنشأ الملف بالقوالب المضمّنة تلقائياً.

مثال استخدام | Usage example

Prompt: "اكتب رد لأحمد، جهازه iPhone 13، الحالة بانتظار قطعة الشاشة، التسليم غداً 5 مساءً"

Flow:

  1. replies_search_templates → category: repair_status, language: ar

  2. replies_compose_reply → template_id: status-ar-1 + variables

Output:

مرحباً أحمد 👋
تحديث بخصوص جهازك iPhone 13:
الحالة الحالية: بانتظار قطعة الشاشة
الموعد المتوقع للتسليم: غداً 5 مساءً
سنبلغك فور جاهزية الجهاز.

replies_whatsapp_link يبني رابط https://wa.me/<phone>?text=<message> من قالب (template_id + variables) أو نص حر (text). العربية مدعومة بالكامل عبر ترميز UTF-8 القياسي في الرابط. فتح الرابط يفتح واتساب مع الرسالة معبّأة مسبقاً، لكن الإرسال يبقى ضغطة يدوية — لا إرسال تلقائي.

مثال: phone: "+966 5x xxx xxxx", template_id: "status-ar-1", variables: {...} → { url, text, missingVariables }.

واجهة الويب المحلية | Local web UI

صفحة ويب محلية بالعربية (RTL) لتصفح القوالب وتعبئتها وإرسالها عبر واتساب دون الحاجة لـ Claude أو Inspector — مخصصة لموظف المحل مباشرة.

npm run build
npm run web

ثم افتح http://localhost:8787 (يمكن تغيير المنفذ عبر PORT). التدفق: اختر تصنيفاً من الشريط الجانبي أو ابحث ← اضغط على القالب ← عبّئ المتغيرات وشاهد المعاينة الحيّة ← أدخل رقم العميل ← اضغط فتح واتساب لفتح محادثة واتساب مع الرسالة جاهزة (الإرسال يبقى ضغطة يدوية بشرية).

الواجهة متجاوبة مع الجوال (RTL أيضاً على الشاشات الصغيرة).

تسجيل الدخول

الواجهة محمية بـ HTTP Basic Auth. اسم المستخدم الافتراضي admin. إن لم تُحدَّد WEB_PASSWORD، تُولَّد كلمة مرور عشوائية وتُطبع في الطرفية عند بدء التشغيل — راقب الناتج. لتحديد بيانات دخول ثابتة:

WEB_USERNAME=shop WEB_PASSWORD=your-secret npm run web

النسخ الاحتياطي

قبل كل عملية حفظ (إضافة/تعديل/حذف قالب)، يُنسخ الملف الحالي إلى <REPLIES_DATA_PATH>.bak قبل الكتابة فوقه. للاستعادة من نسخة احتياطية، أعد تسمية .bak إلى الاسم الأصلي يدوياً.

صيغة المتغيرات | Placeholder syntax

{{variable_name}} — أحرف لاتينية وأرقام وشرطة سفلية. replies_compose_reply يعيد missingVariables لأي متغير لم تُمرَّر قيمته، ويُبقي العنصر النائب في النص كما هو.

الاختبار | Testing

npx @modelcontextprotocol/inspector node dist/index.js

Available Tools

8 tools
replies_add_templateAdd Reply TemplateA

Create a new reply template. Placeholders in body use {{variable}} syntax; variables are auto-extracted from the body.

Args:

  • id (string): unique slug, e.g. 'promo-ar-1'

  • category (string): one of greeting, price_inquiry, diagnosis, repair_status, ready_for_pickup, delay_apology, warranty, complaint, unrepairable, data_disclaimer, part_unavailable, location_hours, payment, follow_up

  • title (string)

  • language ('ar'|'en')

  • tone ('formal'|'friendly')

  • body (string): reply text with {{placeholders}}

  • tags (string[], optional)

Returns: the created template JSON.

Inputs: id (required), body (required), tone (required), title (required), +3 more.

replies_compose_replyCompose Customer ReplyA
Read-onlyIdempotent

Render a ready-to-send customer reply by filling a template's {{variables}} with real values.

Args:

  • template_id (string): id from replies_search_templates

  • variables (object): map of variable name -> value, e.g. { "customer_name": "أحمد", "device_model": "iPhone 13", "status": "بانتظار قطعة الشاشة", "eta": "غداً الساعة 5 مساءً" }

Returns: { text, missingVariables }. If missingVariables is non-empty the reply still contains raw {{placeholders}} — fill them and call again, or ask the user for the values.

Example: compose a status update in Arabic for customer أحمد about his iPhone 13.

Inputs: template_id (required), variables.

replies_delete_templateDelete Reply TemplateA
DestructiveIdempotent

Permanently delete a template by id. This cannot be undone.

Args:

  • id (string): template id

Returns: { deleted: boolean, id }.

Inputs: id (required).

replies_get_templateGet Reply TemplateA
Read-onlyIdempotent

Get one template by id, including the full body with {{variable}} placeholders.

Args:

  • id (string): template id from replies_search_templates

Returns: full template JSON { id, category, title, language, tone, body, variables, tags, createdAt, updatedAt }.

Inputs: id (required).

replies_list_categoriesList Reply CategoriesA
Read-onlyIdempotent

List all reply categories with template counts per category and language.

Use this first to discover what kinds of customer replies exist (greeting, price_inquiry, repair_status, ready_for_pickup, warranty, complaint, etc.).

Returns: JSON array of { category, count, languages }.

Inputs: no named parameters.

replies_search_templatesSearch Reply TemplatesA
Read-onlyIdempotent

Search customer reply templates by keyword, category, language, or tone.

Args:

  • query (string, optional): keyword matched against title, body, category, and tags (Arabic or English)

  • category (string, optional): exact category, e.g. 'repair_status', 'complaint'

  • language ('ar'|'en', optional)

  • tone ('formal'|'friendly', optional)

Returns: JSON array of template summaries { id, category, title, language, tone, variables, tags }. Use the id with replies_get_template or replies_compose_reply.

Examples:

  • "Find a reply for a delayed repair" -> category='delay_apology', language='ar'

  • "رد على شكوى" -> query='شكوى'

Inputs: tone, query, category, language.

replies_update_templateUpdate Reply TemplateA
Idempotent

Update fields of an existing template. Only provided fields change. If body changes, variables are re-extracted automatically.

Args:

  • id (string): existing template id

  • title, category, language, tone, body, tags: all optional

Returns: the updated template JSON.

Inputs: id (required), body, tags, tone, +3 more.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A4.3/5.0

    Scored across 8 tools

    Disambiguation5/5

    Each tool has a distinct purpose: CRUD for templates, search, categories listing, composing a reply, and generating a WhatsApp link. There is no overlap or ambiguity.

    Naming Consistency4/5

    All tools share the 'replies_' prefix and most follow a verb_noun pattern (e.g., replies_add_template, replies_delete_template). The exception is replies_whatsapp_link, which is a noun_noun and slightly deviates from the pattern.

    Tool Count5/5

    Eight tools is a well-scoped number for a customer reply template management server. It covers creation, retrieval, updating, deletion, search, categories, composition, and WhatsApp integration without bloat.

    Completeness4/5

    The server covers the full CRUD lifecycle for templates, plus search, categories, composition, and WhatsApp linking. A direct 'list all templates' tool is missing, but the search tool with no filters likely serves that purpose.

    Related MCP Connectors

    Related MCP Servers

    • F
      license
      Not graded
      quality
      D
      maintenance
      An MCP (Multi-Agent Conversation Protocol) Server that enables interaction with the WhatsApp Business API, allowing agents to send messages, manage media, and perform other WhatsApp business operations through natural language.
      1
      -
    • A
      license
      Not graded
      quality
      F
      maintenance
      MCP server for interacting with the official Meta WhatsApp Business Platform/Cloud API, enabling sending messages, managing contacts, templates, and handling webhook callbacks.
      Apache 2.0
    • A
      license
      A
      quality
      D
      maintenance
      MCP server for the WhatsApp Business API that enables managing business accounts, phone numbers, message templates, sending template messages, and tracking message status via the Meta Graph API.
      8
      34 npm
      MIT