Playbook · Automation

How to deploy a WhatsApp AI agent in Morocco in 14 days

TL;DR — A CNDP-compliant WhatsApp AI agent in Morocco ships in 14 days: 2 days scoping, 3 days WhatsApp Business API provisioning via Meta + BSP, 5 days RAG on your knowledge base, 2 days darija/French testing, 2 days production rollout with human handoff. Typical project budget: 45,000–90,000 MAD depending on integration complexity.

Why WhatsApp is Morocco's #1 channel

Morocco has 22M+ active WhatsApp users — by far the dominant messaging channel, ahead of Messenger and Instagram DM. For customer service, real estate, e-commerce or healthcare, it's the natural channel for leads and retention.

A well-designed WhatsApp AI agent absorbs 60–80% of first-line conversations (hours, availability, booking, order tracking, product FAQ) and cleanly hands off to a human when the conversation leaves scope.

Pre-requisites before you start

A verified Meta Business account (Moroccan entity KYC — RC, ICE, IF), a dedicated phone number not used on personal WhatsApp, an official Business Solution Provider (BSP) — 360dialog, Twilio or Gupshup are the most used in Morocco — and a structured knowledge base (FAQ, catalog, internal procedures) that we'll turn into a vector index.

On compliance: CNDP standard declaration, clear in-conversation notice that the user is talking to an automated agent, and log hosting on EU or Moroccan infrastructure.

The 7 deployment steps

Pre-requisites

  • Verified Meta Business account (RC, ICE, IF)
  • Dedicated phone number unused on WhatsApp
  • BSP access (360dialog, Twilio or Gupshup)
  • Knowledge base (FAQ, catalog, procedures)
  • API access to target CRM/PMS/ERP (Sage, HubSpot, Odoo…)
  1. Step 1

    Days 1–2 — Scoping & CNDP filing

    Scoping workshop: scope of managed conversations, handoff scenarios, default language (written darija/French), brand tone. In parallel, prep the CNDP file (standard declaration, processing register).

  2. Step 2

    Days 3–5 — WhatsApp Business API provisioning

    Verify Meta Business account, link the number to the BSP, configure message templates (HSM) approved by Meta for outbound notifications. Sandbox send/receive test.

  3. Step 3

    Days 6–8 — Knowledge base indexing (RAG)

    Convert documents (PDF, web pages, Notion, Sheets) into vector chunks stored in pgvector or Qdrant hosted in the EU. Set up the retrieval + generation pipeline with a multilingual model (GPT-4o-mini or Claude Haiku) in no-retention mode.

  4. Step 4

    Days 9–10 — CRM/ERP/PMS integrations

    Two-way connection to business tools: lead creation in HubSpot, stock lookup in Sage X3, booking in Cal.com, order verification in WooCommerce/Shopify. Each action exposed as a tool (function calling) to the agent.

  5. Step 5

    Days 11–12 — Darija/French testing & guardrails

    Bench of 60–100 test conversations covering written darija, French, code-switching, and adversarial cases (insults, out-of-scope, prompt-injection attempts). Calibrate the confidence threshold that triggers human handoff.

  6. Step 6

    Day 13 — Human handoff and agent console

    Set up the console (Chatwoot, Front, or the BSP UI) where reps take over in one click. Real-time notifications, statuses (bot/human/resolved), quality metrics.

  7. Step 7

    Day 14 — Production rollout and monitoring

    Progressive cutover: 10% of traffic in the morning, 50% at noon, 100% in the evening if KPIs are green. Supervision dashboard: deflection rate, CSAT, average response time, cost per conversation in MAD.

Questions fréquentes

How much does a WhatsApp AI agent cost in Morocco?+
Typical project budget: 45,000–90,000 MAD depending on the number of integrations (CRM, ERP, PMS) and knowledge-base complexity. Recurring: 800–2,500 MAD/month (BSP + LLM tokens + hosting) for 5,000–20,000 conversations/month.
Can the agent answer in darija?+
Yes — GPT-4o and Claude handle written darija (Latin and Arabic script) well. We fine-tune tone and vocabulary on 200–500 brand-specific examples to move from 'correct' to 'natural'.
Is it compliant with law 09-08 and CNDP?+
Yes, under conditions: standard processing declaration, in-conversation notice that the user is talking to an automated agent, log hosting on EU or Moroccan infra, and LLM use in no-retention mode. We provide the CNDP template file.
What happens when the agent doesn't know?+
Immediate human handoff. The conversation is routed to a rep (Chatwoot, Front, or BSP console) with full context. Target: 70% auto / 30% human in the first iteration, 85/15 after 60 days of learning.
Can we reuse an existing WhatsApp Business account?+
No — the WhatsApp Business API requires a number not used on the WhatsApp app (personal or Business). A dedicated number is required. Meta-side migration takes 1–3 days.

/ À lire ensuite

Un brief technique sur ce sujet ?

Atelier de cadrage gratuit. Un fondateur, pas un commercial.