Platform
Chatbot Builder Bulk Messaging Team Inbox Mini CRM API & Webhooks AI Integration WhatsApp Flows
Industries
E-commerce & D2C Real Estate Education Healthcare Finance & BFSI Logistics Hospitality Retail
Integrations 📚 Learn 🗂 Codex Compare Pricing About Contact Start Free Trial →
Technical Guide Step-by-Step ⏱ 15 min read

Connect Microsoft Dynamics 365 to WhatsApp API — Power Automate + Direct API

Microsoft Dynamics 365 runs sales, finance, and operations for thousands of Indian enterprises. WA.Expert adds WhatsApp to every Dynamics event — lead created, invoice posted, order confirmed. Three integration methods: Power Automate (no code), Dynamics webhooks (developer), and direct API calls from plugins.

Get WA.Expert API Key → Talk to a Developer

What this guide covers

Microsoft Dynamics 365 is a suite of business applications: Sales (CRM), Business Central (ERP), Finance & Supply Chain, and Customer Service. This guide covers integration for all three most common setups in India. The easiest path for non-developers is Microsoft Power Automate (part of Microsoft 365). For developers, Dynamics 365 Webhooks and server-side plugins provide real-time event-driven integration.

Integration approachComplexityBest for
Power Automate (Microsoft 365)⭐ Easy — no code, visual builderTeams using Microsoft 365. Quickest setup — 30 minutes.
Dynamics 365 Webhooks⭐⭐ Medium — requires developerReal-time event-driven. Best for CRM lead/opportunity events.
Dataverse API + Power Apps⭐⭐ Medium — low-code/pro-codeCustom apps and portals built on Dataverse (Common Data Service).
Business Central AL Extension⭐⭐⭐ Complex — AL developer neededDynamics 365 Business Central ERP — purchase orders, invoices, inventory.

How to connect — all methods explained

Method 1 Power Automate — No-Code Method

1

Create a new Flow in Power Automate

Go to flow.microsoft.com → My Flows → New Flow → Automated Cloud Flow. Search for "Dynamics 365" triggers. Common triggers: When a record is created (Lead, Opportunity), When a record is updated (Order status changed), When a record is deleted.

2

Configure the Dynamics 365 trigger

Select your Dynamics 365 environment and entity name (leads, opportunities, salesorders, invoices). For CRM: use "When a record is created" on the leads table. For Business Central: use the Business Central connector with a similar trigger.

3

Add an HTTP action to call WA.Expert

Add a new step → HTTP action. Method: POST. URI: https://api.wa.expert/v1/send. Headers: Authorization: Bearer YOUR_API_KEY, Content-Type: application/json. Body: use dynamic content from Dynamics to fill name, phone, document number.

4

Map Dynamics fields to WhatsApp variables

Use Power Automate's dynamic content picker to map: mobilephone (Lead) or telephone1 (Account/Contact) to the "to" field. Map fullname or companyname to the name variable. Map estimatedvalue or totalamount to the amount variable.

5

Test and enable

Manually trigger by creating a test record in Dynamics. Verify the WhatsApp fires correctly. Enable the Flow for production. Power Automate handles retries automatically if WA.Expert API is temporarily unavailable.

// Power Automate HTTP action body // Dynamic content from Dynamics CRM trigger: { "to": "@{triggerOutputs()?['body/mobilephone']}", "template": "d365_lead_followup", "variables": { "name": "@{triggerOutputs()?['body/fullname']}", "company": "@{triggerOutputs()?['body/companyname']}", "source": "@{triggerOutputs()?['body/leadsourcecode@OData.Community.Display.V1.FormattedValue']}" } }

Power Automate is included in most Microsoft 365 Business plans. Check your subscription at admin.microsoft.com. If Power Automate is available, this is the recommended path — zero server infrastructure needed.

Method 2 Dynamics 365 Webhooks — Developer Method

1

Register a webhook endpoint in Dynamics

In Dynamics 365 → Settings → Customizations → Plugin Registration Tool (download from NuGet: Microsoft.CrmSdk.XrmTooling.PluginRegistrationTool). Connect to your Dynamics instance. Register a new Webhook step with your WA.Expert webhook URL.

2

Configure the webhook step

Select the entity (lead, opportunity, salesorder) and message (Create, Update, Delete). Set the filtering attributes — for status changes, filter on statecode or statuscode. Set the execution mode to Asynchronous for non-blocking operation.

3

Parse the Dynamics webhook payload

Dynamics sends a JSON payload with the entity's attributes. The phone number is in the mobilephone (Lead) or telephone1 (Account) field. Your webhook handler extracts this and calls WA.Expert API.

4

Handle authentication

Dynamics webhooks can include a shared secret in the header. Verify this in your webhook handler to prevent unauthorized calls. The shared secret is configured in the Plugin Registration Tool when setting up the webhook.

// Dynamics 365 webhook payload (partial) // POST to your WA.Expert webhook endpoint { "InputParameters": [{ "key": "Target", "value": { "Attributes": [ {"key": "fullname", "value": "Priya Sharma"}, {"key": "mobilephone", "value": "+919876543210"}, {"key": "emailaddress1", "value": "priya@acme.com"}, {"key": "estimatedvalue", "value": "500000"} ] } }] }

The Plugin Registration Tool connects to Dynamics 365 using your admin credentials. Download it from NuGet: Install-Package Microsoft.CrmSdk.XrmTooling.PluginRegistrationTool. Run PluginRegistration.exe from the bin folder.

Common questions

Does Microsoft Dynamics 365 have a native WhatsApp integration?
Microsoft Dynamics 365 Customer Service has a native WhatsApp channel via Microsoft's Digital Messaging add-on. For outbound WhatsApp automation (order notifications, invoice alerts, lead follow-up), WA.Expert is used via Power Automate or webhooks — providing more flexibility and lower cost than the native Digital Messaging licence.
Does this work with Dynamics 365 Business Central (BC)?
Yes — Dynamics 365 Business Central has its own integration approach. Power Automate works well with BC via the Business Central connector. For code-based integration, BC uses AL (Application Language) extensions — a developer creates an event subscriber that fires on document posting (OnAfterPostSalesOrder) and calls WA.Expert API via AL's HttpClient.
How do I find phone numbers in Dynamics 365 CRM?
In Dynamics CRM: Lead entity uses mobilephone and telephone1. Contact entity uses mobilephone, telephone1, telephone2. Account entity uses telephone1 (main), telephone2, telephone3. For consistent WhatsApp storage, create a custom field whatsapp_number (string, 20 chars) on Lead, Contact, and Account entities.
What Power Automate plan is needed?
Power Automate is included in Microsoft 365 Business Basic, Standard, and Premium. Dynamics 365 licences also include Power Automate per-user plan. The HTTP connector (needed to call WA.Expert API) requires Power Automate Premium — check if your licence includes premium connectors, otherwise upgrade to the per-user premium plan.
Can I send WhatsApp from Dynamics 365 Finance & Operations?
D365 F&O uses X++ business logic and has an integration framework (Data Management, Business Events). For WhatsApp: set up a Business Event in D365 F&O that fires on document status changes, subscribe to the event via Azure Logic Apps or Power Automate, and call WA.Expert API. This requires a D365 F&O developer familiar with X++ and Business Events.
How do I test Dynamics webhooks before going live?
Use ngrok (ngrok.io) to expose your local development server as a public HTTPS URL. Register this ngrok URL as your webhook endpoint in Dynamics Plugin Registration Tool. Create test records in a sandbox Dynamics environment and verify the webhook payload arrives correctly before switching to your production WA.Expert endpoint.

More connection guides

Ready to connect Microsoft Dynamics to WhatsApp?

WA.Expert provides the WhatsApp API layer. Power Automate gives you the no-code bridge. Your Dynamics events become WhatsApp messages in under an hour.

Start Free Trial → Talk to a Developer